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
Returns the value of a uniform variable
func GetUniformfv(program uint32, location int32, params *float32) { C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n\tsyscall.Syscall(gpGetUniformfv, 3, uintptr(program), uintptr(location), uintptr(unsafe.Pointer(params)))\n}", "func (uni *Uniform1fv) Get(pos int, v float32) float32 {\n\n\treturn uni.v[pos]\n}", "func Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func GetUniformiv(program uint32, location int32, params *int32) {\n C.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params)))\n}", "func Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (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 (d *UniformDistribution) Get() float64 {\n\treturn d.value\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 Uniform3uiv(location int32, count int32, value *uint32) {\n C.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\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 Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform2uiv(location int32, count int32, value *uint32) {\n C.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func GetUniformiv(program uint32, location int32, params *int32) {\n\tC.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetUniformiv(program uint32, location int32, params *int32) {\n\tC.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params)))\n}", "func uniform(rgba uint32) *image.Uniform {\n\treturn image.NewUniform(Hex(rgba))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\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 Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform1fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func (s *Shader) GetUniform(str string) *Uniform {\n\tif uid, ok := s.uniforms[str]; ok {\n\t\treturn uid\n\t}\n\ts.uniforms[str] = &Uniform{\n\t\tname: str,\n\t\tprogram: s.programID,\n\t}\n\treturn s.uniforms[str]\n}", "func Uint() uint { return globalRand.Uint() }", "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 Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\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 (uni *UniformMatrix3f) Get(pos int) float32 {\n\n\treturn uni.v[pos]\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 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 GetUniformiv(program uint32, location int32, params *int32) {\n\tsyscall.Syscall(gpGetUniformiv, 3, uintptr(program), uintptr(location), uintptr(unsafe.Pointer(params)))\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 Uniform3fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform3fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func GetUniformLocation(program uint32, name *int8) int32 {\n ret := C.glowGetUniformLocation(gpGetUniformLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "func GetUniformLocation(p Program, name string) Uniform {\n\treturn Uniform{Value: gl.GetUniformLocation(p.Value, gl.Str(name+\"\\x00\"))}\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func GetUniformfv(program Uint, location Int, params []Float) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tclocation, _ := (C.GLint)(location), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetUniformfv(cprogram, clocation, cparams)\n}", "func (u Uniform) Rand() float64 {\n\treturn rand.Float64()*(u.Max-u.Min) + u.Min\n}", "func Uniform2i(location int32, v0 int32, v1 int32) {\n C.glowUniform2i(gpUniform2i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\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 ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\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 ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func GetUniformfv(dst []float32, src Uniform, p Program) {\n\tgl.GetUniformfv(p.Value, src.Value, &dst[0])\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func Uniform1i(dst Uniform, v int) {\n\tgl.Uniform1i(dst.Value, int32(v))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func Uniform1i(location int32, v0 int32) {\n\tC.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func Uniform1i(location int32, v0 int32) {\n\tC.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\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 (r *Rand) Uint() uint {\n\tif x, err := r.cryptoRand.Uint(); err == nil {\n\t\treturn x\n\t}\n\treturn r.mathRand.Uint()\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n\tC.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n\tC.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (native *OpenGL) Uniform3fv(location int32, count int32, value *float32) {\n\tgl.Uniform3fv(location, count, 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 Uniform1iv(location int32, count int32, value *int32) {\n\tC.glowUniform1iv(gpUniform1iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func (s *SparkCoreAdaptor) Variable(name string) (result string, err error) {\n\turl := fmt.Sprintf(\"%v/%s?access_token=%s\", s.deviceURL(), name, s.AccessToken)\n\tresp, err := s.requestToSpark(\"GET\", url, nil)\n\n\tif err != nil {\n\t\treturn\n\t}\n\n\tval := resp[\"result\"]\n\tswitch val.(type) {\n\tcase bool:\n\t\tresult = strconv.FormatBool(val.(bool))\n\tcase float64:\n\t\tresult = strconv.FormatFloat(val.(float64), 'f', -1, 64)\n\tcase string:\n\t\tresult = val.(string)\n\t}\n\n\treturn\n}", "func (debugging *debuggingOpenGL) GetUniformLocation(program uint32, name string) int32 {\n\tdebugging.recordEntry(\"GetUniformLocation\", program, name)\n\tresult := debugging.gl.GetUniformLocation(program, name)\n\tdebugging.recordExit(\"GetUniformLocation\", result)\n\treturn result\n}", "func Uniform3uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform3uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (uni *Uniform3fv) Get(idx int) (v0, v1, v2 float32) {\n\n\tpos := idx * 3\n\treturn uni.v[pos], uni.v[pos+1], uni.v[pos+2]\n}", "func (native *OpenGL) GetUniformLocation(program uint32, name string) int32 {\n\treturn gl.GetUniformLocation(program, gl.Str(name+\"\\x00\"))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func (program Program) GetUniformLocation(name string) UniformLocation {\n\treturn UniformLocation(gl.GetUniformLocation(uint32(program), gl.Str(name+\"\\x00\")))\n}", "func Uniform2f(location int32, v0 float32, v1 float32) {\n C.glowUniform2f(gpUniform2f, (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\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 ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1Int(location UniformLocation, v0 int32) {\n\tgl.Uniform1i(int32(location), v0)\n}", "func Uniform3fv(location int32, count int32, value *float32) {\n\tC.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform3fv(location int32, count int32, value *float32) {\n\tC.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform2uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform2uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func (r *RunningStats) Var() float64 {\n\treturn r.m2 / float64(r.n-1)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\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 Uniform3f(location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpUniform3f, 4, uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0, 0)\n}", "func Uniform1iv(location int32, count int32, value *int32) {\n\tsyscall.Syscall(gpUniform1iv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func Uniform4fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform4fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform3iv(location int32, count int32, value *int32) {\n\tsyscall.Syscall(gpUniform3iv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func GetUniformLocation(program Uint, name string) Int {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcname, _ := unpackPCharString(name)\n\t__ret := C.glGetUniformLocation(cprogram, cname)\n\t__v := (Int)(__ret)\n\treturn __v\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 UniformMatrix4x3fv(location int32, count int32, transpose bool, value *float32) {\n C.glowUniformMatrix4x3fv(gpUniformMatrix4x3fv, (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func GetUniformLocation(program uint32, name *uint8) int32 {\n\tret, _, _ := syscall.Syscall(gpGetUniformLocation, 2, uintptr(program), uintptr(unsafe.Pointer(name)), 0)\n\treturn (int32)(ret)\n}", "func UniformMatrix3fv(location int32, count int32, transpose bool, value *float32) {\n C.glowUniformMatrix3fv(gpUniformMatrix3fv, (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform2fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func Uniform4i(location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n\tsyscall.Syscall6(gpUniform4i, 5, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), uintptr(v3), 0)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1f(location int32, v0 float32) {\n\tsyscall.Syscall(gpUniform1f, 2, uintptr(location), uintptr(math.Float32bits(v0)), 0)\n}" ]
[ "0.6617731", "0.6482883", "0.6452393", "0.640932", "0.631057", "0.61913973", "0.6153511", "0.6148114", "0.6143711", "0.6107737", "0.6098144", "0.60758877", "0.60660994", "0.6041608", "0.60092354", "0.59648925", "0.59552354", "0.594257", "0.594257", "0.5935811", "0.59283304", "0.5886644", "0.5862745", "0.58623385", "0.58424824", "0.5819097", "0.58119994", "0.5811137", "0.58100873", "0.5809042", "0.58031225", "0.57849365", "0.57777035", "0.57600725", "0.57522637", "0.57369775", "0.5731934", "0.57006437", "0.57006437", "0.5700276", "0.569821", "0.5689679", "0.5674728", "0.5669301", "0.56670254", "0.56670254", "0.5666392", "0.5637964", "0.56170946", "0.5607223", "0.56047463", "0.5604182", "0.55986786", "0.55986786", "0.55881965", "0.55825424", "0.5562844", "0.5562844", "0.5560949", "0.55422527", "0.55422527", "0.5530447", "0.55268735", "0.5522746", "0.5522626", "0.5522626", "0.5521224", "0.5519105", "0.55190253", "0.551786", "0.5502727", "0.54986984", "0.5493583", "0.5484521", "0.5481512", "0.5481512", "0.54732066", "0.5466867", "0.5466867", "0.54668", "0.54668", "0.5464442", "0.5457389", "0.54558223", "0.54558223", "0.54557496", "0.54546946", "0.5451063", "0.5444256", "0.5433216", "0.54316324", "0.5431507", "0.5423412", "0.54177105", "0.5409851", "0.5405048", "0.5380181", "0.53800344", "0.53800184" ]
0.6340282
5
Returns the value of a uniform variable
func GetUniformiv(program uint32, location int32, params *int32) { C.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n\tsyscall.Syscall(gpGetUniformfv, 3, uintptr(program), uintptr(location), uintptr(unsafe.Pointer(params)))\n}", "func (uni *Uniform1fv) Get(pos int, v float32) float32 {\n\n\treturn uni.v[pos]\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n\tC.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n\tC.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func GetUniformiv(program uint32, location int32, params *int32) {\n C.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params)))\n}", "func Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (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 (d *UniformDistribution) Get() float64 {\n\treturn d.value\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 Uniform3uiv(location int32, count int32, value *uint32) {\n C.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\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 Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform2uiv(location int32, count int32, value *uint32) {\n C.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func uniform(rgba uint32) *image.Uniform {\n\treturn image.NewUniform(Hex(rgba))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\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 Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform1fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func (s *Shader) GetUniform(str string) *Uniform {\n\tif uid, ok := s.uniforms[str]; ok {\n\t\treturn uid\n\t}\n\ts.uniforms[str] = &Uniform{\n\t\tname: str,\n\t\tprogram: s.programID,\n\t}\n\treturn s.uniforms[str]\n}", "func Uint() uint { return globalRand.Uint() }", "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 Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\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 (uni *UniformMatrix3f) Get(pos int) float32 {\n\n\treturn uni.v[pos]\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 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 GetUniformiv(program uint32, location int32, params *int32) {\n\tsyscall.Syscall(gpGetUniformiv, 3, uintptr(program), uintptr(location), uintptr(unsafe.Pointer(params)))\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 Uniform3fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform3fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func GetUniformLocation(program uint32, name *int8) int32 {\n ret := C.glowGetUniformLocation(gpGetUniformLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "func GetUniformLocation(p Program, name string) Uniform {\n\treturn Uniform{Value: gl.GetUniformLocation(p.Value, gl.Str(name+\"\\x00\"))}\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func GetUniformfv(program Uint, location Int, params []Float) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tclocation, _ := (C.GLint)(location), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetUniformfv(cprogram, clocation, cparams)\n}", "func (u Uniform) Rand() float64 {\n\treturn rand.Float64()*(u.Max-u.Min) + u.Min\n}", "func Uniform2i(location int32, v0 int32, v1 int32) {\n C.glowUniform2i(gpUniform2i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\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 ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\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 ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func GetUniformfv(dst []float32, src Uniform, p Program) {\n\tgl.GetUniformfv(p.Value, src.Value, &dst[0])\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func Uniform1i(dst Uniform, v int) {\n\tgl.Uniform1i(dst.Value, int32(v))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func Uniform1i(location int32, v0 int32) {\n\tC.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func Uniform1i(location int32, v0 int32) {\n\tC.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\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 (r *Rand) Uint() uint {\n\tif x, err := r.cryptoRand.Uint(); err == nil {\n\t\treturn x\n\t}\n\treturn r.mathRand.Uint()\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n\tC.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n\tC.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (native *OpenGL) Uniform3fv(location int32, count int32, value *float32) {\n\tgl.Uniform3fv(location, count, 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 Uniform1iv(location int32, count int32, value *int32) {\n\tC.glowUniform1iv(gpUniform1iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func (s *SparkCoreAdaptor) Variable(name string) (result string, err error) {\n\turl := fmt.Sprintf(\"%v/%s?access_token=%s\", s.deviceURL(), name, s.AccessToken)\n\tresp, err := s.requestToSpark(\"GET\", url, nil)\n\n\tif err != nil {\n\t\treturn\n\t}\n\n\tval := resp[\"result\"]\n\tswitch val.(type) {\n\tcase bool:\n\t\tresult = strconv.FormatBool(val.(bool))\n\tcase float64:\n\t\tresult = strconv.FormatFloat(val.(float64), 'f', -1, 64)\n\tcase string:\n\t\tresult = val.(string)\n\t}\n\n\treturn\n}", "func (debugging *debuggingOpenGL) GetUniformLocation(program uint32, name string) int32 {\n\tdebugging.recordEntry(\"GetUniformLocation\", program, name)\n\tresult := debugging.gl.GetUniformLocation(program, name)\n\tdebugging.recordExit(\"GetUniformLocation\", result)\n\treturn result\n}", "func Uniform3uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform3uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (uni *Uniform3fv) Get(idx int) (v0, v1, v2 float32) {\n\n\tpos := idx * 3\n\treturn uni.v[pos], uni.v[pos+1], uni.v[pos+2]\n}", "func (native *OpenGL) GetUniformLocation(program uint32, name string) int32 {\n\treturn gl.GetUniformLocation(program, gl.Str(name+\"\\x00\"))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func (program Program) GetUniformLocation(name string) UniformLocation {\n\treturn UniformLocation(gl.GetUniformLocation(uint32(program), gl.Str(name+\"\\x00\")))\n}", "func Uniform2f(location int32, v0 float32, v1 float32) {\n C.glowUniform2f(gpUniform2f, (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\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 ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1Int(location UniformLocation, v0 int32) {\n\tgl.Uniform1i(int32(location), v0)\n}", "func Uniform3fv(location int32, count int32, value *float32) {\n\tC.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform3fv(location int32, count int32, value *float32) {\n\tC.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform2uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform2uiv(location int32, count int32, value *uint32) {\n\tC.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func (r *RunningStats) Var() float64 {\n\treturn r.m2 / float64(r.n-1)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\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 Uniform3f(location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpUniform3f, 4, uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0, 0)\n}", "func Uniform1iv(location int32, count int32, value *int32) {\n\tsyscall.Syscall(gpUniform1iv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func Uniform4fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform4fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform3iv(location int32, count int32, value *int32) {\n\tsyscall.Syscall(gpUniform3iv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func GetUniformLocation(program Uint, name string) Int {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcname, _ := unpackPCharString(name)\n\t__ret := C.glGetUniformLocation(cprogram, cname)\n\t__v := (Int)(__ret)\n\treturn __v\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 UniformMatrix4x3fv(location int32, count int32, transpose bool, value *float32) {\n C.glowUniformMatrix4x3fv(gpUniformMatrix4x3fv, (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func GetUniformLocation(program uint32, name *uint8) int32 {\n\tret, _, _ := syscall.Syscall(gpGetUniformLocation, 2, uintptr(program), uintptr(unsafe.Pointer(name)), 0)\n\treturn (int32)(ret)\n}", "func UniformMatrix3fv(location int32, count int32, transpose bool, value *float32) {\n C.glowUniformMatrix3fv(gpUniformMatrix3fv, (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform2fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func Uniform4i(location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n\tsyscall.Syscall6(gpUniform4i, 5, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), uintptr(v3), 0)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1f(location int32, v0 float32) {\n\tsyscall.Syscall(gpUniform1f, 2, uintptr(location), uintptr(math.Float32bits(v0)), 0)\n}" ]
[ "0.6617731", "0.6482883", "0.6452393", "0.640932", "0.6340282", "0.6340282", "0.631057", "0.61913973", "0.6153511", "0.6148114", "0.6143711", "0.6107737", "0.6098144", "0.60758877", "0.60660994", "0.6041608", "0.60092354", "0.59648925", "0.59552354", "0.5935811", "0.59283304", "0.5886644", "0.5862745", "0.58623385", "0.58424824", "0.5819097", "0.58119994", "0.5811137", "0.58100873", "0.5809042", "0.58031225", "0.57849365", "0.57777035", "0.57600725", "0.57522637", "0.57369775", "0.5731934", "0.57006437", "0.57006437", "0.5700276", "0.569821", "0.5689679", "0.5674728", "0.5669301", "0.56670254", "0.56670254", "0.5666392", "0.5637964", "0.56170946", "0.5607223", "0.56047463", "0.5604182", "0.55986786", "0.55986786", "0.55881965", "0.55825424", "0.5562844", "0.5562844", "0.5560949", "0.55422527", "0.55422527", "0.5530447", "0.55268735", "0.5522746", "0.5522626", "0.5522626", "0.5521224", "0.5519105", "0.55190253", "0.551786", "0.5502727", "0.54986984", "0.5493583", "0.5484521", "0.5481512", "0.5481512", "0.54732066", "0.5466867", "0.5466867", "0.54668", "0.54668", "0.5464442", "0.5457389", "0.54558223", "0.54558223", "0.54557496", "0.54546946", "0.5451063", "0.5444256", "0.5433216", "0.54316324", "0.5431507", "0.5423412", "0.54177105", "0.5409851", "0.5405048", "0.5380181", "0.53800344", "0.53800184" ]
0.594257
20
retrieve parameters of a vertex array object
func GetVertexArrayiv(vaobj uint32, pname uint32, param *int32) { C.glowGetVertexArrayiv(gpGetVertexArrayiv, (C.GLuint)(vaobj), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(param))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexArrayiv(vaobj uint32, pname uint32, param *int32) {\n\tsyscall.Syscall(gpGetVertexArrayiv, 3, uintptr(vaobj), uintptr(pname), uintptr(unsafe.Pointer(param)))\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 (a Ant) GetVertexesRNValue() []float64 {\n numVertex := len((*(*a.graph).vertexes))\n rnvalues := make([]float64, numVertex)\n //fmt.Printf(\"Num vertexes %d\\n\", numVertex)\n count := 0;\n for count < numVertex {\n indexVertex := (*(*a.graph).vertexes)[count].index\n pheromoneVertex := (*(*a.graph).vertexes)[count].pheromone\n weightVertex := (*a.graph).FullWeightOfVertex(indexVertex)\n rnvalues[indexVertex] = pheromoneVertex*weightVertex\n //fmt.Printf(\"Index: %d Pheromone: %f Weight: %f RN: %f\\n\", indexVertex,pheromoneVertex,weightVertex, rnvalues[indexVertex])\n count = count+1\n }\n return rnvalues\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 GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func (e Edge) GetVertex1() int {\n return e.v1_index\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 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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func (p Plane) GetVertices() VertexValues {\n\treturn p.vertexValues\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tsyscall.Syscall(gpVertexArrayElementBuffer, 2, uintptr(vaobj), uintptr(buffer), 0)\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 GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\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 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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetQueryIndexediv(target uint32, index uint32, pname uint32, params *int32) {\n C.glowGetQueryIndexediv(gpGetQueryIndexediv, (C.GLenum)(target), (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpGenVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\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 GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\n}", "func (v Vertex) GetIndex() int {\n return v.index\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 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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\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 GenVertexArrays(n int32, arrays *uint32) {\n C.glowGenVertexArrays(gpGenVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\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 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 (d *DAG) GetVertices() map[string]interface{} {\n\td.muDAG.RLock()\n\tdefer d.muDAG.RUnlock()\n\tout := make(map[string]interface{})\n\tfor id, value := range d.vertexIds {\n\t\tout[id] = value\n\t}\n\treturn out\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 GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\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 GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 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 parseVertex(line string) Vector3 {\n\tvar x, y, z float64\n\t_, err := fmt.Sscanf(line, \"v %f %f %f\", &x, &y, &z)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tfmt.Printf(\"Parsed vertex %v\\n\", Vector3{x, y, z})\n\treturn Vector3{x, y, z}\n}", "func GetTransformFeedbackVarying(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *int8) {\n C.glowGetTransformFeedbackVarying(gpGetTransformFeedbackVarying, (C.GLuint)(program), (C.GLuint)(index), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLsizei)(unsafe.Pointer(size)), (*C.GLenum)(unsafe.Pointer(xtype)), (*C.GLchar)(unsafe.Pointer(name)))\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 GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\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 (tr *GremlinGraph) GetParameters() (map[string]interface{}, error) {\n\tp, err := json.TFParser.Marshal(tr.Spec.ForProvider)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tbase := map[string]interface{}{}\n\treturn base, json.TFParser.Unmarshal(p, &base)\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 (o BoundingPolyOutput) Vertices() VertexArrayOutput {\n\treturn o.ApplyT(func(v BoundingPoly) []Vertex { return v.Vertices }).(VertexArrayOutput)\n}", "func (ja *Array) GetParameters() []Parameter {\n\tvar (\n\t\tparams []Parameter\n\t)\n\n\tfor i, v := range ja.Values {\n\t\tswitch v.Type() {\n\t\tcase StringType:\n\t\t\tpms, ok := ja.params[i]\n\t\t\tif ok && len(pms) > 0 {\n\t\t\t\tparams = append(params, pms...)\n\t\t\t}\n\t\tcase ObjectType:\n\t\t\to, ok := v.(*Object)\n\t\t\tif ok {\n\t\t\t\tparams = append(params, o.GetParameters()...)\n\t\t\t}\n\t\tcase ArrayType:\n\t\t\ta, ok := v.(*Array)\n\t\t\tif ok {\n\t\t\t\tparams = append(params, a.GetParameters()...)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn params\n}", "func (o Orbit) V() (V []float64) {\n\treturn o.vVec\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func vertexInterp(isolevel float64, p1, p2 gl.Vector, valp1, valp2 float64) gl.Vector {\n\tif math.Abs(isolevel-valp1) < epsilon {\n\t\treturn p1\n\t}\n\tif math.Abs(isolevel-valp2) < epsilon {\n\t\treturn p2\n\t}\n\tif math.Abs(valp1-valp2) < epsilon {\n\t\treturn p1\n\t}\n\tmu := (isolevel - valp1) / (valp2 - valp1)\n\treturn gl.Vector{\n\t\tX: p1.X + mu*(p2.X-p1.X),\n\t\tY: p1.Y + mu*(p2.Y-p1.Y),\n\t\tZ: p1.Z + mu*(p2.Z-p1.Z),\n\t}\n}", "func (*Vertex) Descriptor() ([]byte, []int) {\n\treturn file_yandex_cloud_ai_ocr_v1_ocr_proto_rawDescGZIP(), []int{1}\n}", "func (j *Jsonnet) Params(envName string) ([]ModuleParameter, error) {\n\tj.log().WithField(\"env-name\", envName).Debug(\"getting component params\")\n\n\tparamsData, err := j.readParams(envName)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tprops, err := params.ToMap(j.Name(false), paramsData, paramsComponentRoot)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"could not find components\")\n\t}\n\n\tvar params []ModuleParameter\n\tfor k, v := range props {\n\t\tvStr, err := j.paramValue(v)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tnp := ModuleParameter{\n\t\t\tComponent: j.Name(false),\n\t\t\tKey: k,\n\t\t\tValue: vStr,\n\t\t}\n\n\t\tparams = append(params, np)\n\t}\n\n\tsort.Slice(params, func(i, j int) bool {\n\t\treturn params[i].Key < params[j].Key\n\t})\n\n\treturn params, nil\n}", "func GetUniformiv(program uint32, location int32, params *int32) {\n C.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params)))\n}", "func ProvokingVertex(mode uint32) {\n C.glowProvokingVertex(gpProvokingVertex, (C.GLenum)(mode))\n}", "func VertexArrayBindingDivisor(vaobj uint32, bindingindex uint32, divisor uint32) {\n\tsyscall.Syscall(gpVertexArrayBindingDivisor, 3, uintptr(vaobj), uintptr(bindingindex), uintptr(divisor))\n}", "func GetProgramiv(program uint32, pname uint32, params *int32) {\n C.glowGetProgramiv(gpGetProgramiv, (C.GLuint)(program), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func (a *Affine) Parameters() []*anydiff.Var {\n\treturn []*anydiff.Var{a.Scalers, a.Biases}\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 VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[0])\n}", "func (p *Program) getParameter(param uint32) int {\n\tvar v int32\n\tgl.GetProgramiv(uint32(p.glHandle), param, &v)\n\treturn int(v)\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 (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\n}", "func StructFields() {\n\tv := vertex{1, 2}\n\tv.X = 11\n\n\tfmt.Println(v.X, v.Y)\n}", "func (g GraphSONv3Parser) ParseVertex(in []byte) (v graphson.VertexRecord, err error) {\n\tv.Properties = map[string][]graphson.VertexPropertyRecord{}\n\n\tif typeName, err := jsonparser.GetString(in, \"@type\"); err != nil || typeName != vertexTypeName {\n\t\treturn v, graphson.ParsingError{err, \"@type\", \"parseVertex\"}\n\t}\n\n\t// value location mapping on original json record, using the jsonparser package to avoid as much reflection as we can\n\tvar paths = [][]string{\n\t\t{\"@value\", \"label\"},\n\t\t{\"@value\", \"id\", \"@value\"},\n\t\t{\"@value\", \"properties\"},\n\t}\n\n\tparsingErrors := graphson.ParsingErrors{}\n\n\tjsonparser.EachKey(in, func(idx int, value []byte, vt jsonparser.ValueType, err error) {\n\t\tvar currentError = graphson.ParsingError{nil, strings.Join(paths[idx], \" \"), \"parseVertex\"}\n\t\tif err != nil {\n\t\t\tcurrentError.Message = err.Error()\n\t\t\tparsingErrors = append(parsingErrors, currentError)\n\t\t\treturn\n\t\t}\n\n\t\tswitch idx {\n\t\tcase 0: // @value -> label\n\t\t\tlabel, e := jsonparser.ParseString(value)\n\t\t\tif e != nil {\n\t\t\t\tcurrentError.Message = e.Error()\n\t\t\t\tbreak\n\t\t\t}\n\n\t\t\tv.Label = label\n\n\t\tcase 1: // @value -> label -> @value\n\t\t\tid, e := parsedToType(value, vt)\n\t\t\tif e != nil {\n\t\t\t\tcurrentError.Message = e.Error()\n\t\t\t\tbreak\n\t\t\t}\n\n\t\t\tv.ID = id\n\n\t\tcase 2: // @value -> properties (VertexPropertyRecord)\n\t\t\te := jsonparser.ObjectEach(value, func(key []byte, prop []byte, dataType jsonparser.ValueType, offset int) error {\n\t\t\t\tpropertyName, e := jsonparser.ParseString(key)\n\t\t\t\tif e != nil {\n\t\t\t\t\tcurrentError.Message = e.Error()\n\t\t\t\t\treturn e\n\t\t\t\t}\n\n\t\t\t\tparsedProperties, e := g.ParseVertexProperties(prop)\n\t\t\t\tif e != nil {\n\t\t\t\t\tcurrentError.Message = e.Error()\n\t\t\t\t\treturn e\n\t\t\t\t}\n\n\t\t\t\tv.Properties[propertyName] = append(v.Properties[propertyName], parsedProperties...)\n\n\t\t\t\treturn nil\n\t\t\t})\n\n\t\t\tif e != nil {\n\t\t\t\tcurrentError.Message = e.Error()\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t\tif currentError.Message != nil {\n\t\t\tparsingErrors = append(parsingErrors, currentError)\n\t\t}\n\n\t}, paths...)\n\n\treturn v, parsingErrors.Combine()\n}", "func (o *OctahedronGeometry) JSObject() *js.Object { return o.p }", "func NewPrimitives() Primitives {\n\treturn Primitives{\n\t\t\"vtxs\": NewAttributes(Int, 0),\n\t}\n}", "func getParamsAndValues(b *ingestcommon.BenchData) ([]paramtools.Params, []float32, paramtools.ParamSet) {\n\tparams := []paramtools.Params{}\n\tvalues := []float32{}\n\tps := paramtools.ParamSet{}\n\tfor testName, allConfigs := range b.Results {\n\t\tfor configName, result := range allConfigs {\n\t\t\tkey := paramtools.Params(b.Key).Copy()\n\t\t\tkey[\"test\"] = testName\n\t\t\tkey[\"config\"] = configName\n\t\t\tkey.Add(paramtools.Params(b.Options))\n\n\t\t\t// If there is an options map inside the result add it to the params.\n\t\t\tif resultOptions, ok := result[\"options\"]; ok {\n\t\t\t\tif opts, ok := resultOptions.(map[string]interface{}); ok {\n\t\t\t\t\tfor k, vi := range opts {\n\t\t\t\t\t\t// Ignore the very long and not useful GL_ values, we can retrieve\n\t\t\t\t\t\t// them later via ptracestore.Details.\n\t\t\t\t\t\tif strings.HasPrefix(k, \"GL_\") {\n\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif s, ok := vi.(string); ok {\n\t\t\t\t\t\t\tkey[k] = s\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor k, vi := range result {\n\t\t\t\tif k == \"options\" || k == \"samples\" {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tkey[\"sub_result\"] = k\n\t\t\t\tfloatVal, ok := vi.(float64)\n\t\t\t\tif !ok {\n\t\t\t\t\tsklog.Errorf(\"Found a non-float64 in %v\", result)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tkey = query.ForceValid(key)\n\t\t\t\tparams = append(params, key.Copy())\n\t\t\t\tvalues = append(values, float32(floatVal))\n\t\t\t\tps.AddParams(key)\n\t\t\t}\n\t\t}\n\t}\n\tps.Normalize()\n\treturn params, values, ps\n}", "func (mg *Graph) GetVertexList(ctx context.Context, load bool) <-chan *gripql.Vertex {\n\to := make(chan *gripql.Vertex, 100)\n\n\tgo func() {\n\t\tdefer close(o)\n\t\tsession := mg.ar.session.Copy()\n\t\tdefer session.Close()\n\t\tvCol := mg.ar.VertexCollection(session, mg.graph)\n\t\tquery := vCol.Find(nil)\n\t\tif !load {\n\t\t\tquery = query.Select(bson.M{\"_id\": 1, \"label\": 1})\n\t\t}\n\t\titer := query.Iter()\n\t\tdefer iter.Close()\n\t\tresult := map[string]interface{}{}\n\t\tfor iter.Next(&result) {\n\t\t\tselect {\n\t\t\tcase <-ctx.Done():\n\t\t\t\treturn\n\t\t\tdefault:\n\t\t\t}\n\t\t\tv := UnpackVertex(result)\n\t\t\to <- v\n\t\t}\n\t\tif err := iter.Close(); err != nil {\n\t\t\tlog.WithFields(log.Fields{\"error\": err}).Error(\"GetVertexList\")\n\t\t}\n\t}()\n\n\treturn o\n}", "func makeParams(args ...interface{}) []rpcValue {\n\tif len(args) == 0 {\n\t\treturn nil\n\t}\n\tarr := make([]rpcValue, 0, len(args))\n\tfor _, v := range args {\n\t\tarr = append(arr, makeValue(v))\n\t}\n\treturn arr\n}", "func (d *ImageDoc) GetVector() []float64 { return d.Vector }", "func (g *Graph) getVertex(k int) *Vertex {\n\tfor i, v := range g.vertices {\n\t\tif v.key == k {\n\t\t\treturn g.vertices[i]\n\t\t}\n\t}\n\treturn nil\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\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 BindVertexArray(array uint32) {\n C.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func (jo *Object) GetParameters() []Parameter {\n\tvar (\n\t\tparams []Parameter\n\t)\n\n\tfor _, jp := range jo.Properties {\n\t\tif len(jp.namep) > 0 {\n\t\t\tparams = append(params, jp.namep...)\n\t\t}\n\n\t\tswitch jp.Value.Type() {\n\t\tcase StringType:\n\t\t\tif len(jp.valuep) > 0 {\n\t\t\t\tparams = append(params, jp.valuep...)\n\t\t\t}\n\t\tcase ObjectType:\n\t\t\to, ok := jp.Value.(*Object)\n\t\t\tif ok {\n\t\t\t\tparams = append(params, o.GetParameters()...)\n\t\t\t}\n\t\tcase ArrayType:\n\t\t\ta, ok := jp.Value.(*Array)\n\t\t\tif ok {\n\t\t\t\tparams = append(params, a.GetParameters()...)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn params\n}", "func (native *OpenGL) GenVertexArrays(n int32) []uint32 {\n\tids := make([]uint32, n)\n\tgl.GenVertexArrays(n, &ids[0])\n\treturn ids\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (em edgeMap) vertices() []*Vertex {\n\temMu.Lock()\n\tdefer emMu.Unlock()\n\n\tvar out []*Vertex\n\tfor _, vs := range em {\n\t\tfor _, v := range vs {\n\t\t\tout = append(out, v.From)\n\t\t\tout = append(out, v.To)\n\t\t}\n\t}\n\treturn out\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}" ]
[ "0.57522565", "0.5722515", "0.56959337", "0.55869", "0.54317236", "0.5371315", "0.5345207", "0.52188206", "0.51970226", "0.51970226", "0.5188035", "0.5178479", "0.51687473", "0.5128255", "0.5121753", "0.5121238", "0.5121238", "0.51135916", "0.5105355", "0.5105355", "0.50604165", "0.5057689", "0.5053658", "0.5015304", "0.50035256", "0.4994273", "0.4982917", "0.49602917", "0.49406368", "0.4928748", "0.49240556", "0.49170086", "0.49170086", "0.48968816", "0.48493767", "0.48348582", "0.48327544", "0.48315632", "0.48280448", "0.4814957", "0.4805152", "0.4793224", "0.478494", "0.47808963", "0.47808963", "0.4778255", "0.4778255", "0.47697714", "0.47697714", "0.4764434", "0.4735162", "0.47192195", "0.47163823", "0.4708037", "0.4702587", "0.4686558", "0.46816018", "0.46809706", "0.4668526", "0.4668526", "0.46668637", "0.46657085", "0.46656397", "0.46448192", "0.46368", "0.46312368", "0.46306995", "0.46300292", "0.46273044", "0.46247992", "0.4623593", "0.46213526", "0.4587169", "0.45739374", "0.45686617", "0.45686617", "0.45678595", "0.45637023", "0.45612672", "0.45555544", "0.45490128", "0.45460266", "0.45417875", "0.45408684", "0.45331702", "0.45296174", "0.4529062", "0.45209667", "0.45129704", "0.45124435", "0.45032573", "0.45004165", "0.44999164", "0.44996968", "0.44990325", "0.4496298", "0.44901076", "0.44891137", "0.44891137" ]
0.54755205
5
Return a generic vertex attribute parameter
func GetVertexAttribIiv(index uint32, pname uint32, params *int32) { C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(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 GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\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 GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[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 (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 GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func VertexAttrib1f(index uint32, v0 float32) {\n\tgl.VertexAttrib1f(index, v0)\n}", "func VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func VertexAttrib1f(dst Attrib, x float32) {\n\tgl.VertexAttrib1f(uint32(dst.Value), x)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func VertexAttrib1f(index Uint, x Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tC.glVertexAttrib1f(cindex, cx)\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 VertexAttrib1fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib1fv(uint32(dst.Value), &src[0])\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 VertexAttrib3f(index uint32, v0, v1, v2 float32) {\n\tgl.VertexAttrib3f(index, v0, v1, v2)\n}", "func setVertexTypedProperty(theType string, vertex *graphson.Vertex, key string, value interface{}) {\n\tgv := graphson.GenericValue{Type: \"string\", Value: key}\n\tpv := graphson.VertexPropertyValue{\n\t\tID: gv,\n\t\tLabel: key,\n\t\tValue: value,\n\t}\n\tvertexProperty := graphson.VertexProperty{Type: theType, Value: pv}\n\tvertexProperties := []graphson.VertexProperty{vertexProperty}\n\tvertex.Value.Properties[key] = vertexProperties\n}", "func (e *rawData) AddAttribute(key string, val string) {}", "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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\n}", "func getPrimitive(att *expr.AttributeExpr) *expr.AttributeExpr {\n\tif ut, ok := att.Type.(*expr.UserTypeExpr); ok {\n\t\tif _, ok := ut.Type.(expr.Primitive); ok {\n\t\t\treturn ut.AttributeExpr\n\t\t}\n\t\treturn getPrimitive(ut.AttributeExpr)\n\t}\n\treturn nil\n}", "func VertexAttrib3fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib3fv(cindex, cv)\n}", "func generateAttrib() int {\n\treturn random(8, 18)\n}", "func VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func (g *GLTF) validateAccessorAttribute(ac Accessor, attribName string) error {\n\n\tparts := strings.Split(attribName, \"_\")\n\tsemantic := parts[0]\n\n\tusage := \"attribute \" + attribName\n\n\tif attribName == \"POSITION\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"NORMAL\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"TANGENT\" {\n\t\t// Note that morph targets only support VEC3 whereas normal attributes only support VEC4.\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT})\n\t} else if semantic == \"TEXCOORD\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC2}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"COLOR\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"JOINTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"WEIGHTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else {\n\t\treturn fmt.Errorf(\"attribute %v is not supported\", attribName)\n\t}\n}", "func GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "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 (e Edge) GetVertex1() int {\n return e.v1_index\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 VertexAttribDivisor(index uint32, divisor uint32) {\n C.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\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 VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (d *DAG) AddVertex(v interface{}) (string, error) {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\treturn d.addVertex(v)\n}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func (i *Index) Attr(name string) (starlark.Value, error) {\n\tswitch name {\n\tcase \"name\":\n\t\treturn starlark.String(i.name), nil\n\tcase \"str\":\n\t\treturn &stringMethods{subject: i}, nil\n\t}\n\treturn nil, starlark.NoSuchAttrError(name)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (obj *Edge) GetAttribute(attrName string) types.TGAttribute {\n\treturn obj.getAttribute(attrName)\n}", "func VertexAttrib3fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib3fv(uint32(dst.Value), &src[0])\n}", "func (mg *Graph) GetVertex(key string, load bool) *gripql.Vertex {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\td := map[string]interface{}{}\n\tq := mg.ar.VertexCollection(session, mg.graph).FindId(key)\n\tif !load {\n\t\tq = q.Select(map[string]interface{}{\"_id\": 1, \"label\": 1})\n\t}\n\terr := q.One(d)\n\tif err != nil {\n\t\treturn nil\n\t}\n\n\tv := UnpackVertex(d)\n\treturn v\n}", "func VertexAttrib2fv(index uint32, value []float32) {\n\tgl.VertexAttrib2fv(index, &value[0])\n}", "func VertexAttrib3f(index Uint, x Float, y Float, z Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLfloat)(y), cgoAllocsUnknown\n\tcz, _ := (C.GLfloat)(z), cgoAllocsUnknown\n\tC.glVertexAttrib3f(cindex, cx, cy, cz)\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 GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (c EntityObject) Attribute(key string) (interface{}, error) {\n\tif key == \"\" {\n\t\treturn nil, errors.New(\"Attribute key must be non-empty\")\n\t}\n\n\tif c.attributes == nil {\n\t\treturn nil, nil\n\t}\n\n\tvalue, found := c.attributes[key]\n\tif !found {\n\t\treturn nil, nil\n\t}\n\n\treturn value, nil\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (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 GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\n}", "func (g *UndirectedGraph) AddVertex(val interface{}) {\n\tg.vertices[val] = &Vertex{val, make(map[interface{}]*Vertex)}\n}" ]
[ "0.61261106", "0.6115076", "0.594166", "0.594166", "0.59032947", "0.5809674", "0.57940775", "0.57808095", "0.5760031", "0.5760031", "0.56938803", "0.56938803", "0.55741006", "0.5543747", "0.5543747", "0.55168235", "0.5514072", "0.55108327", "0.5486837", "0.54687995", "0.54627216", "0.5452464", "0.5442633", "0.54405904", "0.5437533", "0.5433371", "0.5418465", "0.5418465", "0.5410253", "0.54063916", "0.53909594", "0.53739834", "0.53343844", "0.53343844", "0.53140545", "0.5307658", "0.5245566", "0.5199902", "0.5179481", "0.5179481", "0.5149669", "0.5131668", "0.51274955", "0.51158684", "0.5099735", "0.50811595", "0.5071421", "0.5068534", "0.5068534", "0.504517", "0.5042739", "0.50377965", "0.502073", "0.5015971", "0.49893376", "0.49689645", "0.49615517", "0.49517527", "0.49441323", "0.49384376", "0.49384376", "0.49317318", "0.4916216", "0.49053606", "0.49037474", "0.4897188", "0.48927638", "0.48880714", "0.48637435", "0.48537222", "0.4846925", "0.4846925", "0.48417547", "0.48322746", "0.48313698", "0.48290393", "0.47996962", "0.47764394", "0.47745872", "0.4761003", "0.4756531", "0.4756531", "0.47415704", "0.47308826", "0.4729511", "0.47254965", "0.47204807", "0.47135684", "0.47038788", "0.469645", "0.46920833", "0.46920833", "0.46791628", "0.4670774", "0.4670774", "0.46638572", "0.46584988", "0.46452674", "0.46433792" ]
0.53847593
32
Return a generic vertex attribute parameter
func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) { C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(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 GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\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 GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[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 (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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func VertexAttrib1f(index uint32, v0 float32) {\n\tgl.VertexAttrib1f(index, v0)\n}", "func VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func VertexAttrib1f(dst Attrib, x float32) {\n\tgl.VertexAttrib1f(uint32(dst.Value), x)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func VertexAttrib1f(index Uint, x Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tC.glVertexAttrib1f(cindex, cx)\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 VertexAttrib1fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib1fv(uint32(dst.Value), &src[0])\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 VertexAttrib3f(index uint32, v0, v1, v2 float32) {\n\tgl.VertexAttrib3f(index, v0, v1, v2)\n}", "func setVertexTypedProperty(theType string, vertex *graphson.Vertex, key string, value interface{}) {\n\tgv := graphson.GenericValue{Type: \"string\", Value: key}\n\tpv := graphson.VertexPropertyValue{\n\t\tID: gv,\n\t\tLabel: key,\n\t\tValue: value,\n\t}\n\tvertexProperty := graphson.VertexProperty{Type: theType, Value: pv}\n\tvertexProperties := []graphson.VertexProperty{vertexProperty}\n\tvertex.Value.Properties[key] = vertexProperties\n}", "func (e *rawData) AddAttribute(key string, val string) {}", "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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\n}", "func getPrimitive(att *expr.AttributeExpr) *expr.AttributeExpr {\n\tif ut, ok := att.Type.(*expr.UserTypeExpr); ok {\n\t\tif _, ok := ut.Type.(expr.Primitive); ok {\n\t\t\treturn ut.AttributeExpr\n\t\t}\n\t\treturn getPrimitive(ut.AttributeExpr)\n\t}\n\treturn nil\n}", "func VertexAttrib3fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib3fv(cindex, cv)\n}", "func generateAttrib() int {\n\treturn random(8, 18)\n}", "func VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func (g *GLTF) validateAccessorAttribute(ac Accessor, attribName string) error {\n\n\tparts := strings.Split(attribName, \"_\")\n\tsemantic := parts[0]\n\n\tusage := \"attribute \" + attribName\n\n\tif attribName == \"POSITION\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"NORMAL\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"TANGENT\" {\n\t\t// Note that morph targets only support VEC3 whereas normal attributes only support VEC4.\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT})\n\t} else if semantic == \"TEXCOORD\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC2}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"COLOR\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"JOINTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"WEIGHTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else {\n\t\treturn fmt.Errorf(\"attribute %v is not supported\", attribName)\n\t}\n}", "func GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "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 (e Edge) GetVertex1() int {\n return e.v1_index\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 VertexAttribDivisor(index uint32, divisor uint32) {\n C.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\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 VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (d *DAG) AddVertex(v interface{}) (string, error) {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\treturn d.addVertex(v)\n}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func (i *Index) Attr(name string) (starlark.Value, error) {\n\tswitch name {\n\tcase \"name\":\n\t\treturn starlark.String(i.name), nil\n\tcase \"str\":\n\t\treturn &stringMethods{subject: i}, nil\n\t}\n\treturn nil, starlark.NoSuchAttrError(name)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (obj *Edge) GetAttribute(attrName string) types.TGAttribute {\n\treturn obj.getAttribute(attrName)\n}", "func VertexAttrib3fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib3fv(uint32(dst.Value), &src[0])\n}", "func (mg *Graph) GetVertex(key string, load bool) *gripql.Vertex {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\td := map[string]interface{}{}\n\tq := mg.ar.VertexCollection(session, mg.graph).FindId(key)\n\tif !load {\n\t\tq = q.Select(map[string]interface{}{\"_id\": 1, \"label\": 1})\n\t}\n\terr := q.One(d)\n\tif err != nil {\n\t\treturn nil\n\t}\n\n\tv := UnpackVertex(d)\n\treturn v\n}", "func VertexAttrib2fv(index uint32, value []float32) {\n\tgl.VertexAttrib2fv(index, &value[0])\n}", "func VertexAttrib3f(index Uint, x Float, y Float, z Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLfloat)(y), cgoAllocsUnknown\n\tcz, _ := (C.GLfloat)(z), cgoAllocsUnknown\n\tC.glVertexAttrib3f(cindex, cx, cy, cz)\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 GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (c EntityObject) Attribute(key string) (interface{}, error) {\n\tif key == \"\" {\n\t\treturn nil, errors.New(\"Attribute key must be non-empty\")\n\t}\n\n\tif c.attributes == nil {\n\t\treturn nil, nil\n\t}\n\n\tvalue, found := c.attributes[key]\n\tif !found {\n\t\treturn nil, nil\n\t}\n\n\treturn value, nil\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (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 GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\n}", "func (g *UndirectedGraph) AddVertex(val interface{}) {\n\tg.vertices[val] = &Vertex{val, make(map[interface{}]*Vertex)}\n}" ]
[ "0.61261106", "0.6115076", "0.594166", "0.594166", "0.59032947", "0.5809674", "0.57940775", "0.57808095", "0.5760031", "0.5760031", "0.56938803", "0.56938803", "0.55741006", "0.5543747", "0.5543747", "0.55168235", "0.5514072", "0.55108327", "0.5486837", "0.54687995", "0.54627216", "0.5452464", "0.5442633", "0.54405904", "0.5437533", "0.5433371", "0.5418465", "0.5418465", "0.5410253", "0.54063916", "0.53909594", "0.53847593", "0.53847593", "0.53739834", "0.53140545", "0.5307658", "0.5245566", "0.5199902", "0.5179481", "0.5179481", "0.5149669", "0.5131668", "0.51274955", "0.51158684", "0.5099735", "0.50811595", "0.5071421", "0.5068534", "0.5068534", "0.504517", "0.5042739", "0.50377965", "0.502073", "0.5015971", "0.49893376", "0.49689645", "0.49615517", "0.49517527", "0.49441323", "0.49384376", "0.49384376", "0.49317318", "0.4916216", "0.49053606", "0.49037474", "0.4897188", "0.48927638", "0.48880714", "0.48637435", "0.48537222", "0.4846925", "0.4846925", "0.48417547", "0.48322746", "0.48313698", "0.48290393", "0.47996962", "0.47764394", "0.47745872", "0.4761003", "0.4756531", "0.4756531", "0.47415704", "0.47308826", "0.4729511", "0.47254965", "0.47204807", "0.47135684", "0.47038788", "0.469645", "0.46920833", "0.46920833", "0.46791628", "0.4670774", "0.4670774", "0.46638572", "0.46584988", "0.46452674", "0.46433792" ]
0.53343844
35
Return a generic vertex attribute parameter
func GetVertexAttribLdv(index uint32, pname uint32, params *float64) { C.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(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 GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\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 GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[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 (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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func VertexAttrib1f(index uint32, v0 float32) {\n\tgl.VertexAttrib1f(index, v0)\n}", "func VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func VertexAttrib1f(dst Attrib, x float32) {\n\tgl.VertexAttrib1f(uint32(dst.Value), x)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func VertexAttrib1f(index Uint, x Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tC.glVertexAttrib1f(cindex, cx)\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 VertexAttrib1fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib1fv(uint32(dst.Value), &src[0])\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 VertexAttrib3f(index uint32, v0, v1, v2 float32) {\n\tgl.VertexAttrib3f(index, v0, v1, v2)\n}", "func setVertexTypedProperty(theType string, vertex *graphson.Vertex, key string, value interface{}) {\n\tgv := graphson.GenericValue{Type: \"string\", Value: key}\n\tpv := graphson.VertexPropertyValue{\n\t\tID: gv,\n\t\tLabel: key,\n\t\tValue: value,\n\t}\n\tvertexProperty := graphson.VertexProperty{Type: theType, Value: pv}\n\tvertexProperties := []graphson.VertexProperty{vertexProperty}\n\tvertex.Value.Properties[key] = vertexProperties\n}", "func (e *rawData) AddAttribute(key string, val string) {}", "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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\n}", "func getPrimitive(att *expr.AttributeExpr) *expr.AttributeExpr {\n\tif ut, ok := att.Type.(*expr.UserTypeExpr); ok {\n\t\tif _, ok := ut.Type.(expr.Primitive); ok {\n\t\t\treturn ut.AttributeExpr\n\t\t}\n\t\treturn getPrimitive(ut.AttributeExpr)\n\t}\n\treturn nil\n}", "func VertexAttrib3fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib3fv(cindex, cv)\n}", "func generateAttrib() int {\n\treturn random(8, 18)\n}", "func VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func (g *GLTF) validateAccessorAttribute(ac Accessor, attribName string) error {\n\n\tparts := strings.Split(attribName, \"_\")\n\tsemantic := parts[0]\n\n\tusage := \"attribute \" + attribName\n\n\tif attribName == \"POSITION\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"NORMAL\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"TANGENT\" {\n\t\t// Note that morph targets only support VEC3 whereas normal attributes only support VEC4.\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT})\n\t} else if semantic == \"TEXCOORD\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC2}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"COLOR\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"JOINTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"WEIGHTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else {\n\t\treturn fmt.Errorf(\"attribute %v is not supported\", attribName)\n\t}\n}", "func GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "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 (e Edge) GetVertex1() int {\n return e.v1_index\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 VertexAttribDivisor(index uint32, divisor uint32) {\n C.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\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 VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (d *DAG) AddVertex(v interface{}) (string, error) {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\treturn d.addVertex(v)\n}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func (i *Index) Attr(name string) (starlark.Value, error) {\n\tswitch name {\n\tcase \"name\":\n\t\treturn starlark.String(i.name), nil\n\tcase \"str\":\n\t\treturn &stringMethods{subject: i}, nil\n\t}\n\treturn nil, starlark.NoSuchAttrError(name)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (obj *Edge) GetAttribute(attrName string) types.TGAttribute {\n\treturn obj.getAttribute(attrName)\n}", "func VertexAttrib3fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib3fv(uint32(dst.Value), &src[0])\n}", "func (mg *Graph) GetVertex(key string, load bool) *gripql.Vertex {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\td := map[string]interface{}{}\n\tq := mg.ar.VertexCollection(session, mg.graph).FindId(key)\n\tif !load {\n\t\tq = q.Select(map[string]interface{}{\"_id\": 1, \"label\": 1})\n\t}\n\terr := q.One(d)\n\tif err != nil {\n\t\treturn nil\n\t}\n\n\tv := UnpackVertex(d)\n\treturn v\n}", "func VertexAttrib2fv(index uint32, value []float32) {\n\tgl.VertexAttrib2fv(index, &value[0])\n}", "func VertexAttrib3f(index Uint, x Float, y Float, z Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLfloat)(y), cgoAllocsUnknown\n\tcz, _ := (C.GLfloat)(z), cgoAllocsUnknown\n\tC.glVertexAttrib3f(cindex, cx, cy, cz)\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 GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (c EntityObject) Attribute(key string) (interface{}, error) {\n\tif key == \"\" {\n\t\treturn nil, errors.New(\"Attribute key must be non-empty\")\n\t}\n\n\tif c.attributes == nil {\n\t\treturn nil, nil\n\t}\n\n\tvalue, found := c.attributes[key]\n\tif !found {\n\t\treturn nil, nil\n\t}\n\n\treturn value, nil\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (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 GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\n}", "func (g *UndirectedGraph) AddVertex(val interface{}) {\n\tg.vertices[val] = &Vertex{val, make(map[interface{}]*Vertex)}\n}" ]
[ "0.61261106", "0.6115076", "0.594166", "0.594166", "0.59032947", "0.5809674", "0.57940775", "0.57808095", "0.5760031", "0.5760031", "0.56938803", "0.56938803", "0.55741006", "0.5543747", "0.5543747", "0.55168235", "0.5514072", "0.55108327", "0.5486837", "0.54687995", "0.54627216", "0.5452464", "0.5442633", "0.54405904", "0.5437533", "0.5433371", "0.5418465", "0.5418465", "0.5410253", "0.54063916", "0.53909594", "0.53847593", "0.53847593", "0.53739834", "0.53343844", "0.53343844", "0.53140545", "0.5307658", "0.5245566", "0.5199902", "0.5149669", "0.5131668", "0.51274955", "0.51158684", "0.5099735", "0.50811595", "0.5071421", "0.5068534", "0.5068534", "0.504517", "0.5042739", "0.50377965", "0.502073", "0.5015971", "0.49893376", "0.49689645", "0.49615517", "0.49517527", "0.49441323", "0.49384376", "0.49384376", "0.49317318", "0.4916216", "0.49053606", "0.49037474", "0.4897188", "0.48927638", "0.48880714", "0.48637435", "0.48537222", "0.4846925", "0.4846925", "0.48417547", "0.48322746", "0.48313698", "0.48290393", "0.47996962", "0.47764394", "0.47745872", "0.4761003", "0.4756531", "0.4756531", "0.47415704", "0.47308826", "0.4729511", "0.47254965", "0.47204807", "0.47135684", "0.47038788", "0.469645", "0.46920833", "0.46920833", "0.46791628", "0.4670774", "0.4670774", "0.46638572", "0.46584988", "0.46452674", "0.46433792" ]
0.5179481
41
return the address of the specified generic vertex attribute pointer
func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) { C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), 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 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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\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 (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 VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\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 (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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n C.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func (indx AttribLocation) AttribPointerInternal(size uint, t gl.Enum, normalized bool, stride int, offset uintptr) {\n\tgl.VertexAttribPointer(gl.Uint(indx), gl.Int(size), gl.Enum(t), gl.GLBool(normalized), gl.Sizei(stride), gl.Pointer(offset))\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 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 GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func VertexPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n\tsyscall.Syscall6(gpVertexPointer, 4, uintptr(size), uintptr(xtype), uintptr(stride), uintptr(pointer), 0, 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 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 GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 GetAttribLocation(program uint32, name *uint8) int32 {\n\tret, _, _ := syscall.Syscall(gpGetAttribLocation, 2, uintptr(program), uintptr(unsafe.Pointer(name)), 0)\n\treturn (int32)(ret)\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\n}", "func GetAttribLocation(program uint32, name *uint8) int32 {\n\tret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n\treturn (int32)(ret)\n}", "func GetAttribLocation(program uint32, name *uint8) int32 {\n\tret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n\treturn (int32)(ret)\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\n}", "func (program Program) GetAttribLocation(name string) int32 {\n\treturn gl.GetAttribLocation(uint32(program), gl.Str(name+\"\\x00\"))\n}", "func BindAttribLocation(program uint32, index uint32, name *int8) {\n C.glowBindAttribLocation(gpBindAttribLocation, (C.GLuint)(program), (C.GLuint)(index), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (native *OpenGL) GetAttribLocation(program uint32, name string) int32 {\n\treturn gl.GetAttribLocation(program, gl.Str(name+\"\\x00\"))\n}", "func GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\n}", "func VertexPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n\tC.glowVertexPointer(gpVertexPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[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 (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\n}", "func struct_implicit_deref(tri Triangle) {\n vert_ptr := &tri.A\n fmt.Printf(\"X coordinate of vertex A is %d\\n\", vert_ptr.X)\n // Can also explicitly dereference for clarity\n fmt.Printf(\"Y coordinate of vertex A is %d\\n\", (*vert_ptr).Y)\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 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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func GetAttribLocation(program Uint, name string) Int {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcname, _ := unpackPCharString(name)\n\t__ret := C.glGetAttribLocation(cprogram, cname)\n\t__v := (Int)(__ret)\n\treturn __v\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 (native *OpenGL) GLGetAttribLocation(program uint32, name *uint8) int32 {\n\treturn gl.GetAttribLocation(program, name)\n}", "func (debugging *debuggingOpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tdebugging.recordEntry(\"VertexAttribOffset\", index, size, attribType, normalized, stride, offset)\n\tdebugging.gl.VertexAttribOffset(index, size, attribType, normalized, stride, offset)\n\tdebugging.recordExit(\"VertexAttribOffset\")\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func GetPointerv(pname uint32, params *unsafe.Pointer) {\n C.glowGetPointerv(gpGetPointerv, (C.GLenum)(pname), params)\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func (f *FormationAssignment) GetAddress() uintptr {\n\treturn uintptr(unsafe.Pointer(f))\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func BindAttribLocation(program uint32, index uint32, name *uint8) {\n\tsyscall.Syscall(gpBindAttribLocation, 3, uintptr(program), uintptr(index), uintptr(unsafe.Pointer(name)))\n}", "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tsyscall.Syscall(gpEnableVertexArrayAttrib, 2, uintptr(vaobj), uintptr(index), 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 IndexPointer(xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowIndexPointer(gpIndexPointer, (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func BindAttribLocation(program uint32, index uint32, name *uint8) {\n\tC.glowBindAttribLocation(gpBindAttribLocation, (C.GLuint)(program), (C.GLuint)(index), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func BindAttribLocation(program uint32, index uint32, name *uint8) {\n\tC.glowBindAttribLocation(gpBindAttribLocation, (C.GLuint)(program), (C.GLuint)(index), (*C.GLchar)(unsafe.Pointer(name)))\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 (d DevicePtr) PtrAttribute(attr PointerAttribute) (unsafe.Pointer, error) {\n\tvar p unsafe.Pointer\n\tdevPtr := C.CUdeviceptr(d)\n\ta := C.CUpointer_attribute(attr)\n\tif err := result(C.cuPointerGetAttribute(p, a, devPtr)); err != nil {\n\t\treturn nil, err\n\t}\n\treturn p, nil\n}", "func (obj *Value) GetPointer() string {\n\treturn obj.Candy().Guify(\"g_value_get_pointer\", obj).String()\n}", "func (prg Program) Pointer(ctx gl.Context, a gl.Attrib, size int) {\n\tctx.EnableVertexAttribArray(a)\n\tctx.VertexAttribPointer(a, size, gl.FLOAT, false, 0, 0)\n}", "func GetPointerv(pname uint32, params *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetPointerv, 2, uintptr(pname), uintptr(unsafe.Pointer(params)), 0)\n}", "func (obj *Device) GetVertexDeclaration() (decl VertexDeclaration, err Error) {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.GetVertexDeclaration,\n\t\t2,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(&decl)),\n\t\t0,\n\t)\n\terr = toErr(ret)\n\treturn\n}", "func GetPointerv(pname uint32, params *unsafe.Pointer) {\n\tC.glowGetPointerv(gpGetPointerv, (C.GLenum)(pname), params)\n}", "func GetPointerv(pname uint32, params *unsafe.Pointer) {\n\tC.glowGetPointerv(gpGetPointerv, (C.GLenum)(pname), params)\n}", "func NormalPointer(xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowNormalPointer(gpNormalPointer, (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (s *BasevhdlListener) EnterAttribute_declaration(ctx *Attribute_declarationContext) {}", "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 (debugging *debuggingOpenGL) GetAttribLocation(program uint32, name string) int32 {\n\tdebugging.recordEntry(\"GetAttribLocation\", program, name)\n\tresult := debugging.gl.GetAttribLocation(program, name)\n\tdebugging.recordExit(\"GetAttribLocation\", result)\n\treturn result\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func TexCoordPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n\tsyscall.Syscall6(gpTexCoordPointer, 4, uintptr(size), uintptr(xtype), uintptr(stride), uintptr(pointer), 0, 0)\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n C.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\n}", "func BindAttribLocation(program Program, index uint32, name string) {\n\tgl.BindAttribLocation(uint32(program), index, gl.Str(name+\"\\x00\"))\n}" ]
[ "0.7100245", "0.70918846", "0.6895436", "0.6761777", "0.6761777", "0.67304206", "0.66731364", "0.64958525", "0.6483871", "0.63685584", "0.6300858", "0.6234352", "0.6114593", "0.6023855", "0.5942245", "0.59172857", "0.5869704", "0.58387804", "0.58387804", "0.5824477", "0.5821986", "0.57986087", "0.5776852", "0.5776852", "0.57595104", "0.5729761", "0.57073814", "0.57044625", "0.5690137", "0.56674457", "0.56342566", "0.56342566", "0.5627702", "0.5614544", "0.55782366", "0.5526274", "0.5526274", "0.55215526", "0.5508395", "0.5483487", "0.54561055", "0.54561055", "0.5446824", "0.5444146", "0.5429578", "0.54165184", "0.5403898", "0.54001474", "0.53741175", "0.5370762", "0.5338251", "0.5338251", "0.53295887", "0.5325765", "0.52999085", "0.52860934", "0.52583563", "0.52583563", "0.5240763", "0.52350754", "0.52350754", "0.52296114", "0.52287567", "0.5193263", "0.518627", "0.51602495", "0.51602495", "0.5132507", "0.51184464", "0.509968", "0.50851476", "0.5033525", "0.5032878", "0.5023282", "0.4997529", "0.49824715", "0.49824715", "0.4972855", "0.49585402", "0.49585402", "0.49558967", "0.495336", "0.49441534", "0.49088916", "0.48995557", "0.48988613", "0.4871178", "0.4871178", "0.486526", "0.4860091", "0.4860091", "0.4857614", "0.48562786", "0.48562786", "0.48528025", "0.4852558", "0.48292527", "0.48060858", "0.47845614" ]
0.66372466
8
Return a generic vertex attribute parameter
func GetVertexAttribdv(index uint32, pname uint32, params *float64) { C.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\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 GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[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 (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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func VertexAttrib1f(index uint32, v0 float32) {\n\tgl.VertexAttrib1f(index, v0)\n}", "func VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func VertexAttrib1f(dst Attrib, x float32) {\n\tgl.VertexAttrib1f(uint32(dst.Value), x)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func VertexAttrib1f(index Uint, x Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tC.glVertexAttrib1f(cindex, cx)\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 VertexAttrib1fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib1fv(uint32(dst.Value), &src[0])\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 VertexAttrib3f(index uint32, v0, v1, v2 float32) {\n\tgl.VertexAttrib3f(index, v0, v1, v2)\n}", "func setVertexTypedProperty(theType string, vertex *graphson.Vertex, key string, value interface{}) {\n\tgv := graphson.GenericValue{Type: \"string\", Value: key}\n\tpv := graphson.VertexPropertyValue{\n\t\tID: gv,\n\t\tLabel: key,\n\t\tValue: value,\n\t}\n\tvertexProperty := graphson.VertexProperty{Type: theType, Value: pv}\n\tvertexProperties := []graphson.VertexProperty{vertexProperty}\n\tvertex.Value.Properties[key] = vertexProperties\n}", "func (e *rawData) AddAttribute(key string, val string) {}", "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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\n}", "func getPrimitive(att *expr.AttributeExpr) *expr.AttributeExpr {\n\tif ut, ok := att.Type.(*expr.UserTypeExpr); ok {\n\t\tif _, ok := ut.Type.(expr.Primitive); ok {\n\t\t\treturn ut.AttributeExpr\n\t\t}\n\t\treturn getPrimitive(ut.AttributeExpr)\n\t}\n\treturn nil\n}", "func VertexAttrib3fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib3fv(cindex, cv)\n}", "func generateAttrib() int {\n\treturn random(8, 18)\n}", "func VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func (g *GLTF) validateAccessorAttribute(ac Accessor, attribName string) error {\n\n\tparts := strings.Split(attribName, \"_\")\n\tsemantic := parts[0]\n\n\tusage := \"attribute \" + attribName\n\n\tif attribName == \"POSITION\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"NORMAL\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"TANGENT\" {\n\t\t// Note that morph targets only support VEC3 whereas normal attributes only support VEC4.\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT})\n\t} else if semantic == \"TEXCOORD\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC2}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"COLOR\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"JOINTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"WEIGHTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else {\n\t\treturn fmt.Errorf(\"attribute %v is not supported\", attribName)\n\t}\n}", "func GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "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 (e Edge) GetVertex1() int {\n return e.v1_index\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 VertexAttribDivisor(index uint32, divisor uint32) {\n C.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\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 VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (d *DAG) AddVertex(v interface{}) (string, error) {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\treturn d.addVertex(v)\n}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func (i *Index) Attr(name string) (starlark.Value, error) {\n\tswitch name {\n\tcase \"name\":\n\t\treturn starlark.String(i.name), nil\n\tcase \"str\":\n\t\treturn &stringMethods{subject: i}, nil\n\t}\n\treturn nil, starlark.NoSuchAttrError(name)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (obj *Edge) GetAttribute(attrName string) types.TGAttribute {\n\treturn obj.getAttribute(attrName)\n}", "func VertexAttrib3fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib3fv(uint32(dst.Value), &src[0])\n}", "func (mg *Graph) GetVertex(key string, load bool) *gripql.Vertex {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\td := map[string]interface{}{}\n\tq := mg.ar.VertexCollection(session, mg.graph).FindId(key)\n\tif !load {\n\t\tq = q.Select(map[string]interface{}{\"_id\": 1, \"label\": 1})\n\t}\n\terr := q.One(d)\n\tif err != nil {\n\t\treturn nil\n\t}\n\n\tv := UnpackVertex(d)\n\treturn v\n}", "func VertexAttrib2fv(index uint32, value []float32) {\n\tgl.VertexAttrib2fv(index, &value[0])\n}", "func VertexAttrib3f(index Uint, x Float, y Float, z Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLfloat)(y), cgoAllocsUnknown\n\tcz, _ := (C.GLfloat)(z), cgoAllocsUnknown\n\tC.glVertexAttrib3f(cindex, cx, cy, cz)\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 GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (c EntityObject) Attribute(key string) (interface{}, error) {\n\tif key == \"\" {\n\t\treturn nil, errors.New(\"Attribute key must be non-empty\")\n\t}\n\n\tif c.attributes == nil {\n\t\treturn nil, nil\n\t}\n\n\tvalue, found := c.attributes[key]\n\tif !found {\n\t\treturn nil, nil\n\t}\n\n\treturn value, nil\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (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 GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\n}", "func (g *UndirectedGraph) AddVertex(val interface{}) {\n\tg.vertices[val] = &Vertex{val, make(map[interface{}]*Vertex)}\n}" ]
[ "0.61261106", "0.6115076", "0.594166", "0.594166", "0.59032947", "0.5809674", "0.57940775", "0.57808095", "0.5760031", "0.5760031", "0.56938803", "0.56938803", "0.55741006", "0.55168235", "0.5514072", "0.55108327", "0.5486837", "0.54687995", "0.54627216", "0.5452464", "0.5442633", "0.54405904", "0.5437533", "0.5433371", "0.5418465", "0.5418465", "0.5410253", "0.54063916", "0.53909594", "0.53847593", "0.53847593", "0.53739834", "0.53343844", "0.53343844", "0.53140545", "0.5307658", "0.5245566", "0.5199902", "0.5179481", "0.5179481", "0.5149669", "0.5131668", "0.51274955", "0.51158684", "0.5099735", "0.50811595", "0.5071421", "0.5068534", "0.5068534", "0.504517", "0.5042739", "0.50377965", "0.502073", "0.5015971", "0.49893376", "0.49689645", "0.49615517", "0.49517527", "0.49441323", "0.49384376", "0.49384376", "0.49317318", "0.4916216", "0.49053606", "0.49037474", "0.4897188", "0.48927638", "0.48880714", "0.48637435", "0.48537222", "0.4846925", "0.4846925", "0.48417547", "0.48322746", "0.48313698", "0.48290393", "0.47996962", "0.47764394", "0.47745872", "0.4761003", "0.4756531", "0.4756531", "0.47415704", "0.47308826", "0.4729511", "0.47254965", "0.47204807", "0.47135684", "0.47038788", "0.469645", "0.46920833", "0.46920833", "0.46791628", "0.4670774", "0.4670774", "0.46638572", "0.46584988", "0.46452674", "0.46433792" ]
0.5543747
14
Return a generic vertex attribute parameter
func GetVertexAttribfv(index uint32, pname uint32, params *float32) { C.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(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 GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\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 GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[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 (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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func VertexAttrib1f(index uint32, v0 float32) {\n\tgl.VertexAttrib1f(index, v0)\n}", "func VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func VertexAttrib1f(dst Attrib, x float32) {\n\tgl.VertexAttrib1f(uint32(dst.Value), x)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func VertexAttrib1f(index Uint, x Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tC.glVertexAttrib1f(cindex, cx)\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 VertexAttrib1fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib1fv(uint32(dst.Value), &src[0])\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 VertexAttrib3f(index uint32, v0, v1, v2 float32) {\n\tgl.VertexAttrib3f(index, v0, v1, v2)\n}", "func setVertexTypedProperty(theType string, vertex *graphson.Vertex, key string, value interface{}) {\n\tgv := graphson.GenericValue{Type: \"string\", Value: key}\n\tpv := graphson.VertexPropertyValue{\n\t\tID: gv,\n\t\tLabel: key,\n\t\tValue: value,\n\t}\n\tvertexProperty := graphson.VertexProperty{Type: theType, Value: pv}\n\tvertexProperties := []graphson.VertexProperty{vertexProperty}\n\tvertex.Value.Properties[key] = vertexProperties\n}", "func (e *rawData) AddAttribute(key string, val string) {}", "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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\n}", "func getPrimitive(att *expr.AttributeExpr) *expr.AttributeExpr {\n\tif ut, ok := att.Type.(*expr.UserTypeExpr); ok {\n\t\tif _, ok := ut.Type.(expr.Primitive); ok {\n\t\t\treturn ut.AttributeExpr\n\t\t}\n\t\treturn getPrimitive(ut.AttributeExpr)\n\t}\n\treturn nil\n}", "func VertexAttrib3fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib3fv(cindex, cv)\n}", "func generateAttrib() int {\n\treturn random(8, 18)\n}", "func VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func (g *GLTF) validateAccessorAttribute(ac Accessor, attribName string) error {\n\n\tparts := strings.Split(attribName, \"_\")\n\tsemantic := parts[0]\n\n\tusage := \"attribute \" + attribName\n\n\tif attribName == \"POSITION\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"NORMAL\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"TANGENT\" {\n\t\t// Note that morph targets only support VEC3 whereas normal attributes only support VEC4.\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT})\n\t} else if semantic == \"TEXCOORD\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC2}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"COLOR\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"JOINTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"WEIGHTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else {\n\t\treturn fmt.Errorf(\"attribute %v is not supported\", attribName)\n\t}\n}", "func GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "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 (e Edge) GetVertex1() int {\n return e.v1_index\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 VertexAttribDivisor(index uint32, divisor uint32) {\n C.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\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 VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (d *DAG) AddVertex(v interface{}) (string, error) {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\treturn d.addVertex(v)\n}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func (i *Index) Attr(name string) (starlark.Value, error) {\n\tswitch name {\n\tcase \"name\":\n\t\treturn starlark.String(i.name), nil\n\tcase \"str\":\n\t\treturn &stringMethods{subject: i}, nil\n\t}\n\treturn nil, starlark.NoSuchAttrError(name)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (obj *Edge) GetAttribute(attrName string) types.TGAttribute {\n\treturn obj.getAttribute(attrName)\n}", "func VertexAttrib3fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib3fv(uint32(dst.Value), &src[0])\n}", "func (mg *Graph) GetVertex(key string, load bool) *gripql.Vertex {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\td := map[string]interface{}{}\n\tq := mg.ar.VertexCollection(session, mg.graph).FindId(key)\n\tif !load {\n\t\tq = q.Select(map[string]interface{}{\"_id\": 1, \"label\": 1})\n\t}\n\terr := q.One(d)\n\tif err != nil {\n\t\treturn nil\n\t}\n\n\tv := UnpackVertex(d)\n\treturn v\n}", "func VertexAttrib2fv(index uint32, value []float32) {\n\tgl.VertexAttrib2fv(index, &value[0])\n}", "func VertexAttrib3f(index Uint, x Float, y Float, z Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLfloat)(y), cgoAllocsUnknown\n\tcz, _ := (C.GLfloat)(z), cgoAllocsUnknown\n\tC.glVertexAttrib3f(cindex, cx, cy, cz)\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 GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (c EntityObject) Attribute(key string) (interface{}, error) {\n\tif key == \"\" {\n\t\treturn nil, errors.New(\"Attribute key must be non-empty\")\n\t}\n\n\tif c.attributes == nil {\n\t\treturn nil, nil\n\t}\n\n\tvalue, found := c.attributes[key]\n\tif !found {\n\t\treturn nil, nil\n\t}\n\n\treturn value, nil\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (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 GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\n}", "func (g *UndirectedGraph) AddVertex(val interface{}) {\n\tg.vertices[val] = &Vertex{val, make(map[interface{}]*Vertex)}\n}" ]
[ "0.61261106", "0.6115076", "0.59032947", "0.5809674", "0.57940775", "0.57808095", "0.5760031", "0.5760031", "0.56938803", "0.56938803", "0.55741006", "0.5543747", "0.5543747", "0.55168235", "0.5514072", "0.55108327", "0.5486837", "0.54687995", "0.54627216", "0.5452464", "0.5442633", "0.54405904", "0.5437533", "0.5433371", "0.5418465", "0.5418465", "0.5410253", "0.54063916", "0.53909594", "0.53847593", "0.53847593", "0.53739834", "0.53343844", "0.53343844", "0.53140545", "0.5307658", "0.5245566", "0.5199902", "0.5179481", "0.5179481", "0.5149669", "0.5131668", "0.51274955", "0.51158684", "0.5099735", "0.50811595", "0.5071421", "0.5068534", "0.5068534", "0.504517", "0.5042739", "0.50377965", "0.502073", "0.5015971", "0.49893376", "0.49689645", "0.49615517", "0.49517527", "0.49441323", "0.49384376", "0.49384376", "0.49317318", "0.4916216", "0.49053606", "0.49037474", "0.4897188", "0.48927638", "0.48880714", "0.48637435", "0.48537222", "0.4846925", "0.4846925", "0.48417547", "0.48322746", "0.48313698", "0.48290393", "0.47996962", "0.47764394", "0.47745872", "0.4761003", "0.4756531", "0.4756531", "0.47415704", "0.47308826", "0.4729511", "0.47254965", "0.47204807", "0.47135684", "0.47038788", "0.469645", "0.46920833", "0.46920833", "0.46791628", "0.4670774", "0.4670774", "0.46638572", "0.46584988", "0.46452674", "0.46433792" ]
0.594166
3
Return a generic vertex attribute parameter
func GetVertexAttribiv(index uint32, pname uint32, params *int32) { C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\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 GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(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 GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index Uint, pname Enum, params []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribfv(cindex, cpname, cparams)\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 GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetVertexAttribiv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 GetVertexAttribfv(dst []float32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &dst[0])\n}", "func (s *Shader) VertexFormat() AttrFormat {\n\treturn s.vertexFmt\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 GetVertexAttribf(src Attrib, pname Enum) float32 {\n\tlog.Println(\"GetVertexAttribf: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result float32\n\tgl.GetVertexAttribfv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 GetVertexAttribi(src Attrib, pname Enum) int32 {\n\tvar result int32\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &result)\n\treturn result\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 VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[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 (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 GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n\tC.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index Uint, pname Enum, params []Int) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetVertexAttribiv(cindex, cpname, cparams)\n}", "func VertexAttrib1f(index uint32, v0 float32) {\n\tgl.VertexAttrib1f(index, v0)\n}", "func VertexAttrib3fv(index uint32, value []float32) {\n\tgl.VertexAttrib3fv(index, &value[0])\n}", "func (graph *Graph) GetAttr(x, y int) byte {\n\treturn graph.Tiles[y][x].Attr\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func VertexAttrib1f(dst Attrib, x float32) {\n\tgl.VertexAttrib1f(uint32(dst.Value), x)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n C.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func VertexAttrib1f(index Uint, x Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tC.glVertexAttrib1f(cindex, cx)\n}", "func VertexAttrib1fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib1fv(cindex, cv)\n}", "func (v Vertex) GetIndex() int {\n return v.index\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n\tsyscall.Syscall(gpGetVertexAttribLdv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 VertexAttrib1fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib1fv(uint32(dst.Value), &src[0])\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func GetVertexAttribiv(dst []int32, src Attrib, pname Enum) {\n\tgl.GetVertexAttribiv(uint32(src.Value), uint32(pname), &dst[0])\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 VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\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 VertexAttrib3f(index uint32, v0, v1, v2 float32) {\n\tgl.VertexAttrib3f(index, v0, v1, v2)\n}", "func setVertexTypedProperty(theType string, vertex *graphson.Vertex, key string, value interface{}) {\n\tgv := graphson.GenericValue{Type: \"string\", Value: key}\n\tpv := graphson.VertexPropertyValue{\n\t\tID: gv,\n\t\tLabel: key,\n\t\tValue: value,\n\t}\n\tvertexProperty := graphson.VertexProperty{Type: theType, Value: pv}\n\tvertexProperties := []graphson.VertexProperty{vertexProperty}\n\tvertex.Value.Properties[key] = vertexProperties\n}", "func (e *rawData) AddAttribute(key string, val string) {}", "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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\n}", "func GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tC.glowGetVertexAttribPointerv(gpGetVertexAttribPointerv, (C.GLuint)(index), (C.GLenum)(pname), pointer)\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 GetVertexAttribPointerv(index uint32, pname uint32, pointer *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetVertexAttribPointerv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(pointer)))\n}", "func getPrimitive(att *expr.AttributeExpr) *expr.AttributeExpr {\n\tif ut, ok := att.Type.(*expr.UserTypeExpr); ok {\n\t\tif _, ok := ut.Type.(expr.Primitive); ok {\n\t\t\treturn ut.AttributeExpr\n\t\t}\n\t\treturn getPrimitive(ut.AttributeExpr)\n\t}\n\treturn nil\n}", "func VertexAttrib3fv(index Uint, v []Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcv, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&v)).Data)), cgoAllocsUnknown\n\tC.glVertexAttrib3fv(cindex, cv)\n}", "func generateAttrib() int {\n\treturn random(8, 18)\n}", "func VertexAttribPointer(dst Attrib, size int, ty Enum, normalized bool, stride, offset int) {\n\tgl.VertexAttribPointer(uint32(dst.Value), int32(size), uint32(ty), normalized, int32(stride), gl.PtrOffset(offset))\n}", "func (g *GLTF) validateAccessorAttribute(ac Accessor, attribName string) error {\n\n\tparts := strings.Split(attribName, \"_\")\n\tsemantic := parts[0]\n\n\tusage := \"attribute \" + attribName\n\n\tif attribName == \"POSITION\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"NORMAL\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3}, []int{FLOAT})\n\t} else if attribName == \"TANGENT\" {\n\t\t// Note that morph targets only support VEC3 whereas normal attributes only support VEC4.\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT})\n\t} else if semantic == \"TEXCOORD\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC2}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"COLOR\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC3, VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"JOINTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else if semantic == \"WEIGHTS\" {\n\t\treturn g.validateAccessor(ac, usage, []string{VEC4}, []int{FLOAT, UNSIGNED_BYTE, UNSIGNED_SHORT})\n\t} else {\n\t\treturn fmt.Errorf(\"attribute %v is not supported\", attribName)\n\t}\n}", "func GetAttribLocation(program uint32, name *int8) int32 {\n ret := C.glowGetAttribLocation(gpGetAttribLocation, (C.GLuint)(program), (*C.GLchar)(unsafe.Pointer(name)))\n return (int32)(ret)\n}", "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 (e Edge) GetVertex1() int {\n return e.v1_index\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 VertexAttribDivisor(index uint32, divisor uint32) {\n C.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\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 VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (d *DAG) AddVertex(v interface{}) (string, error) {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\treturn d.addVertex(v)\n}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func (i *Index) Attr(name string) (starlark.Value, error) {\n\tswitch name {\n\tcase \"name\":\n\t\treturn starlark.String(i.name), nil\n\tcase \"str\":\n\t\treturn &stringMethods{subject: i}, nil\n\t}\n\treturn nil, starlark.NoSuchAttrError(name)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tC.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (obj *Edge) GetAttribute(attrName string) types.TGAttribute {\n\treturn obj.getAttribute(attrName)\n}", "func VertexAttrib3fv(dst Attrib, src []float32) {\n\tgl.VertexAttrib3fv(uint32(dst.Value), &src[0])\n}", "func (mg *Graph) GetVertex(key string, load bool) *gripql.Vertex {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\td := map[string]interface{}{}\n\tq := mg.ar.VertexCollection(session, mg.graph).FindId(key)\n\tif !load {\n\t\tq = q.Select(map[string]interface{}{\"_id\": 1, \"label\": 1})\n\t}\n\terr := q.One(d)\n\tif err != nil {\n\t\treturn nil\n\t}\n\n\tv := UnpackVertex(d)\n\treturn v\n}", "func VertexAttrib2fv(index uint32, value []float32) {\n\tgl.VertexAttrib2fv(index, &value[0])\n}", "func VertexAttrib3f(index Uint, x Float, y Float, z Float) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcx, _ := (C.GLfloat)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLfloat)(y), cgoAllocsUnknown\n\tcz, _ := (C.GLfloat)(z), cgoAllocsUnknown\n\tC.glVertexAttrib3f(cindex, cx, cy, cz)\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 GetAttribLocation(p Program, name string) Attrib {\n\treturn Attrib{Value: uint(gl.GetAttribLocation(p.Value, gl.Str(name+\"\\x00\")))}\n}", "func (c EntityObject) Attribute(key string) (interface{}, error) {\n\tif key == \"\" {\n\t\treturn nil, errors.New(\"Attribute key must be non-empty\")\n\t}\n\n\tif c.attributes == nil {\n\t\treturn nil, nil\n\t}\n\n\tvalue, found := c.attributes[key]\n\tif !found {\n\t\treturn nil, nil\n\t}\n\n\treturn value, nil\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func VertexAttribDivisor(index uint32, divisor uint32) {\n\tC.glowVertexAttribDivisor(gpVertexAttribDivisor, (C.GLuint)(index), (C.GLuint)(divisor))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.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 (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 GetVertexAttribPointerv(index Uint, pname Enum, pointer *unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcpointer, _ := (*unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glGetVertexAttribPointerv(cindex, cpname, cpointer)\n}", "func (native *OpenGL) VertexAttribOffset(index uint32, size int32, attribType uint32, normalized bool, stride int32, offset int) {\n\tgl.VertexAttribPointer(index, size, attribType, normalized, stride, gl.PtrOffset(offset))\n}", "func (g *UndirectedGraph) AddVertex(val interface{}) {\n\tg.vertices[val] = &Vertex{val, make(map[interface{}]*Vertex)}\n}" ]
[ "0.61261106", "0.6115076", "0.594166", "0.594166", "0.59032947", "0.5809674", "0.57940775", "0.57808095", "0.5760031", "0.5760031", "0.55741006", "0.5543747", "0.5543747", "0.55168235", "0.5514072", "0.55108327", "0.5486837", "0.54687995", "0.54627216", "0.5452464", "0.5442633", "0.54405904", "0.5437533", "0.5433371", "0.5418465", "0.5418465", "0.5410253", "0.54063916", "0.53909594", "0.53847593", "0.53847593", "0.53739834", "0.53343844", "0.53343844", "0.53140545", "0.5307658", "0.5245566", "0.5199902", "0.5179481", "0.5179481", "0.5149669", "0.5131668", "0.51274955", "0.51158684", "0.5099735", "0.50811595", "0.5071421", "0.5068534", "0.5068534", "0.504517", "0.5042739", "0.50377965", "0.502073", "0.5015971", "0.49893376", "0.49689645", "0.49615517", "0.49517527", "0.49441323", "0.49384376", "0.49384376", "0.49317318", "0.4916216", "0.49053606", "0.49037474", "0.4897188", "0.48927638", "0.48880714", "0.48637435", "0.48537222", "0.4846925", "0.4846925", "0.48417547", "0.48322746", "0.48313698", "0.48290393", "0.47996962", "0.47764394", "0.47745872", "0.4761003", "0.4756531", "0.4756531", "0.47415704", "0.47308826", "0.4729511", "0.47254965", "0.47204807", "0.47135684", "0.47038788", "0.469645", "0.46920833", "0.46920833", "0.46791628", "0.4670774", "0.4670774", "0.46638572", "0.46584988", "0.46452674", "0.46433792" ]
0.56938803
11
Return value has type C.GLVULKANPROCNV.
func GetVkProcAddrNV(name *uint8) unsafe.Pointer { ret := C.glowGetVkProcAddrNV(gpGetVkProcAddrNV, (*C.GLchar)(unsafe.Pointer(name))) return (unsafe.Pointer)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func GetNVList(rw io.ReadWriter) ([]uint32, error) {\n\tbuf, err := getCapability(rw, CapNVList, 0)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tnvList := make([]uint32, len(buf)/4)\n\tfor i := range nvList {\n\t\tnvList[i] = uint32(binary.BigEndian.Uint32(buf[i*4 : (i+1)*4]))\n\t}\n\n\treturn nvList, err\n}", "func (ms *mergeSort) Primitive() engine.Primitive {\n\treturn ms.input.Primitive()\n}", "func Vflt32_byte(input []byte, inputStride int, output []float32, outputStride int) {\n\tC.vDSP_vflt32((*C.int)(unsafe.Pointer(&input[0])), C.vDSP_Stride(inputStride), (*C.float)(&output[0]), C.vDSP_Stride(outputStride), minLen(len(input)/(4*inputStride), len(output)/outputStride))\n}", "func (client *XenClient) VGPUGetAll() (result []string, err error) {\n\tobj, err := client.APICall(\"VGPU.get_all\")\n\tif err != nil {\n\t\treturn\n\t}\n\n\tresult = make([]string, len(obj.([]interface{})))\n\tfor i, value := range obj.([]interface{}) {\n\t\tresult[i] = value.(string)\n\t}\n\n\treturn\n}", "func (vn VecN) Raw() []float64 {\n\treturn vn.vec\n}", "func GetMultisamplefv(pname uint32, index uint32, val *float32) {\n C.glowGetMultisamplefv(gpGetMultisamplefv, (C.GLenum)(pname), (C.GLuint)(index), (*C.GLfloat)(unsafe.Pointer(val)))\n}", "func (native *OpenGL) GetIntegerv(name uint32, data *int32) {\n\tgl.GetIntegerv(name, data)\n}", "func (d *ImageDoc) GetVector() []float64 { return d.Vector }", "func (client *XenClient) VGPUGetRecord(self string) (result VGPU, err error) {\n\tobj, err := client.APICall(\"VGPU.get_record\", self)\n\tif err != nil {\n\t\treturn\n\t}\n\n\tresult = *ToVGPU(obj.(interface{}))\n\n\treturn\n}", "func VFNMSUB213PD(ops ...operand.Op) { ctx.VFNMSUB213PD(ops...) }", "func GetSynciv(sync unsafe.Pointer, pname uint32, bufSize int32, length *int32, values *int32) {\n C.glowGetSynciv(gpGetSynciv, (C.GLsync)(sync), (C.GLenum)(pname), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLint)(unsafe.Pointer(values)))\n}", "func (c *Client) listStoredInfoTypeRaw(ctx context.Context, r *StoredInfoType, pageToken string, pageSize int32) ([]byte, error) {\n\tu, err := r.urlNormalized().listURL(c.Config.BasePath)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tm := make(map[string]string)\n\tif pageToken != \"\" {\n\t\tm[\"pageToken\"] = pageToken\n\t}\n\n\tif pageSize != StoredInfoTypeMaxPage {\n\t\tm[\"pageSize\"] = fmt.Sprintf(\"%v\", pageSize)\n\t}\n\n\tu, err = dcl.AddQueryParams(u, m)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tresp, err := dcl.SendRequest(ctx, c.Config, \"GET\", u, &bytes.Buffer{}, c.Config.RetryProvider)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdefer resp.Response.Body.Close()\n\treturn ioutil.ReadAll(resp.Response.Body)\n}", "func DXObjectAccessNV(hObject unsafe.Pointer, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpDXObjectAccessNV, 2, uintptr(hObject), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (t *VLDblInt) VecType() string {\n\treturn \"list\"\n}", "func GetMultisamplefv(pname uint32, index uint32, val *float32) {\n\tsyscall.Syscall(gpGetMultisamplefv, 3, uintptr(pname), uintptr(index), uintptr(unsafe.Pointer(val)))\n}", "func GetIntegerv(pname Enum, data []int32) {\n\tgl.GetIntegerv(uint32(pname), &data[0])\n}", "func VFNMSUB132PD(ops ...operand.Op) { ctx.VFNMSUB132PD(ops...) }", "func (client *XenClient) VGPUGetType(self string) (result string, err error) {\n\tobj, err := client.APICall(\"VGPU.get_type\", self)\n\tif err != nil {\n\t\treturn\n\t}\n\tresult = obj.(string)\n\treturn\n}", "func (m *moduleService) VifRingParam() RingParam {\n\treturn m.vrp\n}", "func ProcessVirusTotalResult(res []byte) (VTResult, error) {\n\tvar json *jason.Object\n\tvar r VTResult\n\tvar err error\n\n\tjson, err = jason.NewObjectFromBytes(res)\n\tif err != nil {\n\t\treturn VTResult{}, err\n\t}\n\n\tr.id, _ = json.GetString(\"data\", \"id\")\n\tr.Md5, _ = json.GetString(\"data\", \"attributes\", \"md5\")\n\tr.Sha1, _ = json.GetString(\"data\", \"attributes\", \"sha1\")\n\tr.Sha256, _ = json.GetString(\"data\", \"attributes\", \"sha256\")\n\tr.VHash, _ = json.GetString(\"data\", \"attributes\", \"vhash\")\n\tr.rawCreationDate, _ = json.GetInt64(\"data\", \"attributes\", \"creation_date\")\n\tr.rawFirstSubmission, _ = json.GetInt64(\"data\", \"attributes\", \"first_submission_date\")\n\tr.rawLastAnalysis, _ = json.GetInt64(\"data\", \"attributes\", \"last_analysis_date\")\n\tr.Filename, _ = json.GetStringArray(\"data\", \"attributes\", \"names\")\n\tr.rawFilesize, _ = json.GetInt64(\"data\", \"attributes\", \"size\")\n\tr.FileType, _ = json.GetString(\"data\", \"attributes\", \"exiftool\", \"filetype\")\n\tr.ImpHash, _ = json.GetString(\"data\", \"attributes\", \"pe_info\", \"imphash\")\n\tr.MSDefender, _ = json.GetString(\"data\", \"attributes\", \"last_analysis_results\", \"Microsoft\", \"result\")\n\tt1, _ := json.GetInt64(\"data\", \"attributes\", \"last_analysis_stats\", \"malicious\")\n\tt2, _ := json.GetInt64(\"data\", \"attributes\", \"last_analysis_stats\", \"undetected\")\n\n\tr.Statement = fmt.Sprintf(\"%d / %d\", t1, t1+t2)\n\n\tr.FileSize = fmt.Sprintf(\"%.2fKB (%d bytes)\", math.Round(float64(r.rawFilesize)/1024), r.rawFilesize)\n\n\tr.CreationDate = timestampToYMD(r.rawCreationDate)\n\tr.FirstSubmission = timestampToYMD(r.rawFirstSubmission)\n\tr.LastAnalysis = timestampToYMD(r.rawLastAnalysis)\n\n\tr.Tags, _ = json.GetStringArray(\"data\", \"attributes\", \"tags\")\n\tr.URL = \"https://www.virustotal.com/gui/file/\" + r.id\n\treturn r, nil\n}", "func (debugging *debuggingOpenGL) GetIntegerv(name uint32, data *int32) {\n\tdebugging.recordEntry(\"GetIntegerv\", name, data)\n\tdebugging.gl.GetIntegerv(name, data)\n\tdebugging.recordExit(\"GetIntegerv\")\n}", "func (p RProc) Value() Value { return mrbObjValue(unsafe.Pointer(p.p)) }", "func VFMSUB213PD(ops ...operand.Op) { ctx.VFMSUB213PD(ops...) }", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func VFMSUB132PD(ops ...operand.Op) { ctx.VFMSUB132PD(ops...) }", "func (args *SPH_UDF_ARGS) mva32(idx int) []uint32 {\n\treturn GoSliceUint32(args.valueptr(idx), args.lenval(idx))\n}", "func Vthr(input []float32, inputStride int, low float32, output []float32, outputStride int) {\n\tC.vDSP_vthr((*C.float)(&input[0]), C.vDSP_Stride(inputStride), (*C.float)(&low), (*C.float)(&output[0]), C.vDSP_Stride(outputStride), minLen(len(input)/inputStride, len(output)/outputStride))\n}", "func (t *VLDbl) VecType() string {\n\treturn \"list\"\n}", "func NormalPointer(xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowNormalPointer(gpNormalPointer, (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func GetInternalformativ(target uint32, internalformat uint32, pname uint32, count int32, params *int32) {\n\tC.glowGetInternalformativ(gpGetInternalformativ, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(pname), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetInternalformativ(target uint32, internalformat uint32, pname uint32, count int32, params *int32) {\n\tC.glowGetInternalformativ(gpGetInternalformativ, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(pname), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(params)))\n}", "func (ch *Channel) OVPLimit() (float64, error) {\n\treturn ch.QueryFloat64(\"VOLT:PROT?\\n\")\n}", "func (client *XenClient) VGPUGetAllRecords() (result map[string]VGPU, err error) {\n\tobj, err := client.APICall(\"VGPU.get_all_records\")\n\tif err != nil {\n\t\treturn\n\t}\n\n\tinterim := reflect.ValueOf(obj)\n\tresult = map[string]VGPU{}\n\tfor _, key := range interim.MapKeys() {\n\t\tobj := interim.MapIndex(key)\n\t\tmapObj := ToVGPU(obj.Interface())\n\t\tresult[key.String()] = *mapObj\n\t}\n\n\treturn\n}", "func Vflt32(input []int32, inputStride int, output []float32, outputStride int) {\n\tC.vDSP_vflt32((*C.int)(&input[0]), C.vDSP_Stride(inputStride), (*C.float)(&output[0]), C.vDSP_Stride(outputStride), minLen(len(input)/inputStride, len(output)/outputStride))\n}", "func BindVideoImageNV(hVideoDevice unsafe.Pointer, hPbuffer unsafe.Pointer, iVideoBuffer unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpBindVideoImageNV, 3, uintptr(hVideoDevice), uintptr(hPbuffer), uintptr(iVideoBuffer))\n\treturn (unsafe.Pointer)(ret)\n}", "func DXOpenDeviceNV(dxDevice unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpDXOpenDeviceNV, 1, uintptr(dxDevice), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func native(name string) []Type {}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func BindVertexArray(array uint32) {\n C.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func (vl BytesValue) GetType() int {\n\treturn ParticleType.BLOB\n}", "func (vl BytesValue) GetType() int {\n\treturn ParticleType.BLOB\n}", "func (c *Context) VUNPCKLPD(ops ...operand.Op) {\n\tc.addinstruction(x86.VUNPCKLPD(ops...))\n}", "func GetBooleanv(pname Enum, data []Boolean) {\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcdata, _ := (*C.GLboolean)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&data)).Data)), cgoAllocsUnknown\n\tC.glGetBooleanv(cpname, cdata)\n}", "func (o TypeOutput) Primitive() TypePrimitivePtrOutput {\n\treturn o.ApplyT(func(v Type) *TypePrimitive { return v.Primitive }).(TypePrimitivePtrOutput)\n}", "func (msg MsgCreatePDV) Type() string { return \"create_pdv\" }", "func VFNMSUB231PD(ops ...operand.Op) { ctx.VFNMSUB231PD(ops...) }", "func GetFloatv(dst []float32, pname Enum) {\n\tgl.GetFloatv(uint32(pname), &dst[0])\n}", "func (t *VLIntInt) VecType() string {\n\treturn \"list\"\n}", "func (c *Context) VFNMSUB213PD(ops ...operand.Op) {\n\tc.addinstruction(x86.VFNMSUB213PD(ops...))\n}", "func (t *VLInt) VecType() string {\n\treturn \"list\"\n}", "func (t *VLDblDbl) VecType() string {\n\treturn \"list\"\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 (t *VLDblStr) VecType() string {\n\treturn \"list\"\n}", "func (d *DSP) ParameterData(index C.int, data **interface{}, length *C.uint, valuestr *C.char, valuestrlen C.int) error {\n\t//FMOD_RESULT F_API FMOD_DSP_GetParameterData(FMOD_DSP *dsp, int index, void **data, unsigned int *length, char *valuestr, int valuestrlen);\n\treturn ErrNoImpl\n}", "func GetUniformiv(program uint32, location int32, params *int32) {\n C.glowGetUniformiv(gpGetUniformiv, (C.GLuint)(program), (C.GLint)(location), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n C.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\n}", "func (v *PixbufLoader) Native() *C.GdkPixbufLoader {\n\tif v == nil || v.GObject == nil {\n\t\treturn nil\n\t}\n\tp := unsafe.Pointer(v.GObject)\n\treturn C.toGdkPixbufLoader(p)\n}", "func GetInternalformativ(target uint32, internalformat uint32, pname uint32, bufSize int32, params *int32) {\n\tsyscall.Syscall6(gpGetInternalformativ, 5, uintptr(target), uintptr(internalformat), uintptr(pname), uintptr(bufSize), uintptr(unsafe.Pointer(params)), 0)\n}", "func MrbProcValue(p RProc) Value { return p.Value() }", "func (s *Session) ListVirtualMachineImagesFromCL(ctx context.Context, clUUID string,\n\tcurrentCLImages map[string]v1alpha1.VirtualMachineImage) ([]*v1alpha1.VirtualMachineImage, error) {\n\n\tlog.V(4).Info(\"Listing VirtualMachineImages from ContentLibrary\", \"contentLibraryUUID\", clUUID)\n\n\titems, err := s.contentLibProvider.GetLibraryItems(ctx, clUUID)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tvar images []*v1alpha1.VirtualMachineImage\n\tfor i := range items {\n\t\tvar ovfEnvelope *ovf.Envelope\n\t\titem := items[i]\n\n\t\tif curImage, ok := currentCLImages[item.Name]; ok {\n\t\t\t// If there is already an VMImage for this item, and it is the same - as determined by _just_ the\n\t\t\t// annotation - reuse the existing VMImage. This is to avoid repeated CL fetch tasks that would\n\t\t\t// otherwise be created, spamming the UI. It would be nice if CL provided an external API that\n\t\t\t// allowed us to silently fetch the OVF.\n\t\t\tannotations := curImage.GetAnnotations()\n\t\t\tif ver := annotations[VMImageCLVersionAnnotation]; ver == libItemVersionAnnotation(&item) {\n\t\t\t\timages = append(images, &curImage)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\n\t\tswitch item.Type {\n\t\tcase library.ItemTypeOVF:\n\t\t\tif ovfEnvelope, err = s.contentLibProvider.RetrieveOvfEnvelopeFromLibraryItem(ctx, &item); err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\t\tcase library.ItemTypeVMTX:\n\t\t\t// Do not try to populate VMTX types, but resVm.GetOvfProperties() should return an\n\t\t\t// OvfEnvelope.\n\t\tdefault:\n\t\t\t// Not a supported type. Keep this in sync with cloneVMFromContentLibrary().\n\t\t\tcontinue\n\t\t}\n\n\t\timages = append(images, LibItemToVirtualMachineImage(&item, ovfEnvelope))\n\t}\n\n\treturn images, nil\n}", "func (v SmsBulkStatus) Ptr() *SmsBulkStatus {\n\treturn &v\n}", "func NormalPointer(xtype uint32, stride int32, pointer unsafe.Pointer) {\n\tC.glowNormalPointer(gpNormalPointer, (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func VPSUBUSB(ops ...operand.Op) { ctx.VPSUBUSB(ops...) }", "func (l *Libvirt) DomainGetVcpuPinInfo(Dom Domain, Ncpumaps int32, Maplen int32, Flags uint32) (rCpumaps []byte, rNum int32, err error) {\n\tvar buf []byte\n\n\targs := DomainGetVcpuPinInfoArgs {\n\t\tDom: Dom,\n\t\tNcpumaps: Ncpumaps,\n\t\tMaplen: Maplen,\n\t\tFlags: Flags,\n\t}\n\n\tbuf, err = encode(&args)\n\tif err != nil {\n\t\treturn\n\t}\n\n\tvar r response\n\tr, err = l.requestStream(230, constants.Program, buf, nil, nil)\n\tif err != nil {\n\t\treturn\n\t}\n\n\t// Return value unmarshaling\n\ttpd := typedParamDecoder{}\n\tct := map[string]xdr.TypeDecoder{\"libvirt.TypedParam\": tpd}\n\trdr := bytes.NewReader(r.Payload)\n\tdec := xdr.NewDecoderCustomTypes(rdr, 0, ct)\n\t// Cpumaps: []byte\n\t_, err = dec.Decode(&rCpumaps)\n\tif err != nil {\n\t\treturn\n\t}\n\t// Num: int32\n\t_, err = dec.Decode(&rNum)\n\tif err != nil {\n\t\treturn\n\t}\n\n\treturn\n}", "func (a API) GetRawMempoolGetRes() (out *[]string, e error) {\n\tout, _ = a.Result.(*[]string)\n\te, _ = a.Result.(error)\n\treturn \n}", "func conNativeVector(flag BitFlag, args ...Native) (nat Sliceable) {\n\n\tvar slice = []Native{}\n\n\tswitch {\n\tcase FlagMatch(flag, Nil.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(NilVal))\n\t\t}\n\tcase FlagMatch(flag, Bool.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(BoolVal))\n\t\t}\n\tcase FlagMatch(flag, Int.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(IntVal))\n\t\t}\n\tcase FlagMatch(flag, Int8.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Int8Val))\n\t\t}\n\tcase FlagMatch(flag, Int16.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Int16Val))\n\t\t}\n\tcase FlagMatch(flag, Int32.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Int32Val))\n\t\t}\n\tcase FlagMatch(flag, Uint.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(UintVal))\n\t\t}\n\tcase FlagMatch(flag, Uint8.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Uint8Val))\n\t\t}\n\tcase FlagMatch(flag, Uint16.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Uint16Val))\n\t\t}\n\tcase FlagMatch(flag, Uint32.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Uint32Val))\n\t\t}\n\tcase FlagMatch(flag, Float.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(FltVal))\n\t\t}\n\tcase FlagMatch(flag, Flt32.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Flt32Val))\n\t\t}\n\tcase FlagMatch(flag, Imag.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Imag64Val))\n\t\t}\n\tcase FlagMatch(flag, Imag64.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(Imag64Val))\n\t\t}\n\tcase FlagMatch(flag, Byte.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(ByteVal))\n\t\t}\n\tcase FlagMatch(flag, Rune.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(RuneVal))\n\t\t}\n\tcase FlagMatch(flag, Bytes.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(BytesVal))\n\t\t}\n\tcase FlagMatch(flag, String.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(StrVal))\n\t\t}\n\tcase FlagMatch(flag, BigInt.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(BigIntVal))\n\t\t}\n\tcase FlagMatch(flag, BigFlt.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(BigFltVal))\n\t\t}\n\tcase FlagMatch(flag, Ratio.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(RatioVal))\n\t\t}\n\tcase FlagMatch(flag, Time.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(TimeVal))\n\t\t}\n\tcase FlagMatch(flag, Duration.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(DuraVal))\n\t\t}\n\tcase FlagMatch(flag, Error.Type().Flag()):\n\t\tfor _, v := range args {\n\t\t\tslice = append(slice, v.(ErrorVal))\n\t\t}\n\t}\n\treturn NewUnboxed(flag.Type(), slice...)\n}", "func GetMultisamplefv(pname uint32, index uint32, val *float32) {\n\tC.glowGetMultisamplefv(gpGetMultisamplefv, (C.GLenum)(pname), (C.GLuint)(index), (*C.GLfloat)(unsafe.Pointer(val)))\n}", "func GetMultisamplefv(pname uint32, index uint32, val *float32) {\n\tC.glowGetMultisamplefv(gpGetMultisamplefv, (C.GLenum)(pname), (C.GLuint)(index), (*C.GLfloat)(unsafe.Pointer(val)))\n}", "func (t *VLStrInt) VecType() string {\n\treturn \"list\"\n}", "func (s *BasePlSqlParserListener) EnterVarray_type_def(ctx *Varray_type_defContext) {}", "func GetUniformfv(program uint32, location int32, params *float32) {\n\tsyscall.Syscall(gpGetUniformfv, 3, uintptr(program), uintptr(location), uintptr(unsafe.Pointer(params)))\n}", "func EnumGpusNV(iGpuIndex unsafe.Pointer, phGpu unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpEnumGpusNV, 2, uintptr(iGpuIndex), uintptr(phGpu), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (m *moduleService) VifInput() *dpdk.Ring {\n\treturn m.vifInput\n}", "func Vdpsp_byte(input []byte, inputStride int, output []float32, outputStride int) {\n\tC.vDSP_vdpsp((*C.double)(unsafe.Pointer(&input[0])), C.vDSP_Stride(inputStride), (*C.float)(&output[0]), C.vDSP_Stride(outputStride), minLen(len(input)/8/inputStride, len(output)/outputStride))\n}", "func GetProgramiv(program uint32, pname uint32, params *int32) {\n C.glowGetProgramiv(gpGetProgramiv, (C.GLuint)(program), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func VBROADCASTI32X2_Z(mx, k, xyz operand.Op) { ctx.VBROADCASTI32X2_Z(mx, k, xyz) }", "func primitiveConversion(inType, outType reflect.Type) (string, bool) {\n\tswitch inType.Kind() {\n\tcase reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64,\n\t\treflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64,\n\t\treflect.Float32, reflect.Float64:\n\t\tswitch outType.Kind() {\n\t\tcase reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64,\n\t\t\treflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64,\n\t\t\treflect.Float32, reflect.Float64:\n\t\t\treturn outType.Name(), true\n\t\t}\n\t}\n\treturn \"\", false\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 jcallScalar(e *Env, code *byte)", "func (t *VLIntDbl) VecType() string {\n\treturn \"list\"\n}", "func SendPbufferToVideoNV(hPbuffer unsafe.Pointer, iBufferType unsafe.Pointer, pulCounterPbuffer unsafe.Pointer, bBlock unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpSendPbufferToVideoNV, 4, uintptr(hPbuffer), uintptr(iBufferType), uintptr(pulCounterPbuffer), uintptr(bBlock), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (_BaseContent *BaseContentCaller) STATUSPUBLISHED(opts *bind.CallOpts) ([32]byte, error) {\n\tvar out []interface{}\n\terr := _BaseContent.contract.Call(opts, &out, \"STATUS_PUBLISHED\")\n\n\tif err != nil {\n\t\treturn *new([32]byte), err\n\t}\n\n\tout0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)\n\n\treturn out0, err\n\n}", "func (t *VLIntStr) VecType() string {\n\treturn \"list\"\n}", "func (c *Context) VFNMSUB132PD(ops ...operand.Op) {\n\tc.addinstruction(x86.VFNMSUB132PD(ops...))\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n\tC.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n\tC.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\n}", "func CallList(list uint32) {\n C.glowCallList(gpCallList, (C.GLuint)(list))\n}", "func GetIntegerv(pname Enum, data []Int) {\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcdata, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&data)).Data)), cgoAllocsUnknown\n\tC.glGetIntegerv(cpname, cdata)\n}", "func Uniform2uiv(location int32, count int32, value *uint32) {\n C.glowUniform2uiv(gpUniform2uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (a *ImagesApiService) GetImageVulnerabilityTypesExecute(r ApiGetImageVulnerabilityTypesRequest) ([]string, *http.Response, error) {\n\tvar (\n\t\tlocalVarHTTPMethod = http.MethodGet\n\t\tlocalVarPostBody interface{}\n\t\tformFiles []formFile\n\t\tlocalVarReturnValue []string\n\t)\n\n\tlocalBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, \"ImagesApiService.GetImageVulnerabilityTypes\")\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()}\n\t}\n\n\tlocalVarPath := localBasePath + \"/images/{imageDigest}/vuln\"\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"imageDigest\"+\"}\", url.PathEscape(parameterToString(r.imageDigest, \"\")), -1)\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := url.Values{}\n\tlocalVarFormParams := url.Values{}\n\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\"}\n\n\t// set Accept header\n\tlocalVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts)\n\tif localVarHTTPHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHTTPHeaderAccept\n\t}\n\tif r.xAnchoreAccount != nil {\n\t\tlocalVarHeaderParams[\"x-anchore-account\"] = parameterToString(*r.xAnchoreAccount, \"\")\n\t}\n\treq, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles)\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 == 500 {\n\t\t\tvar v ApiErrorResponse\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 (vl *ValueArray) GetType() int {\n\treturn ParticleType.LIST\n}", "func DispatchComputeIndirect(indirect int) {\n C.glowDispatchComputeIndirect(gpDispatchComputeIndirect, (C.GLintptr)(indirect))\n}", "func VUNPCKLPD(ops ...operand.Op) { ctx.VUNPCKLPD(ops...) }", "func VCVTSD2USIL(mx, r operand.Op) { ctx.VCVTSD2USIL(mx, r) }", "func (device *IndustrialDigitalIn4V2Bricklet) GetValue() (value [4]bool, err error) {\n\tvar buf bytes.Buffer\n\n\tresultBytes, err := device.device.Get(uint8(FunctionGetValue), buf.Bytes())\n\tif err != nil {\n\t\treturn value, err\n\t}\n\tif len(resultBytes) > 0 {\n\t\tvar header PacketHeader\n\n\t\theader.FillFromBytes(resultBytes)\n\n\t\tif header.Length != 9 {\n\t\t\treturn value, fmt.Errorf(\"Received packet of unexpected size %d, instead of %d\", header.Length, 9)\n\t\t}\n\n\t\tif header.ErrorCode != 0 {\n\t\t\treturn value, DeviceError(header.ErrorCode)\n\t\t}\n\n\t\tresultBuf := bytes.NewBuffer(resultBytes[8:])\n\t\tcopy(value[:], ByteSliceToBoolSlice(resultBuf.Next(1)))\n\n\t}\n\n\treturn value, nil\n}", "func DXUnregisterObjectNV(hDevice unsafe.Pointer, hObject unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpDXUnregisterObjectNV, 2, uintptr(hDevice), uintptr(hObject), 0)\n\treturn (unsafe.Pointer)(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 runtime_procPin()" ]
[ "0.47217992", "0.46881145", "0.45882735", "0.44653612", "0.4458546", "0.44288853", "0.4385663", "0.43714806", "0.43645296", "0.43441445", "0.4312077", "0.43080658", "0.4298448", "0.42758155", "0.4259315", "0.42544064", "0.42462194", "0.42406696", "0.42257932", "0.4220042", "0.42148626", "0.4204137", "0.42021263", "0.41941276", "0.41881296", "0.41853732", "0.41842076", "0.41834015", "0.41789043", "0.4170332", "0.4170332", "0.4164292", "0.41603565", "0.41423637", "0.41402066", "0.40953693", "0.40941504", "0.40911156", "0.40908784", "0.40881792", "0.40881792", "0.40872738", "0.40760475", "0.4075193", "0.40622532", "0.40620157", "0.4060565", "0.40584973", "0.4056687", "0.40534964", "0.40374216", "0.40308678", "0.4029588", "0.40251222", "0.40223977", "0.40210947", "0.4017855", "0.39925697", "0.39904284", "0.39896157", "0.39896128", "0.39895988", "0.3984654", "0.3983328", "0.39787528", "0.39781427", "0.39708146", "0.39708146", "0.39661512", "0.39587426", "0.39560038", "0.3955372", "0.39531785", "0.39480963", "0.39478126", "0.39476997", "0.39304382", "0.39252657", "0.39252657", "0.39251536", "0.39241272", "0.39215922", "0.39214498", "0.39187863", "0.391864", "0.39170766", "0.39170766", "0.39156583", "0.39089346", "0.39059848", "0.3900709", "0.39001888", "0.38995287", "0.3899032", "0.38949347", "0.38832518", "0.3881882", "0.38807255", "0.38801557" ]
0.40291238
54
control the writing of individual bits in the color index buffers
func IndexMask(mask uint32) { C.glowIndexMask(gpIndexMask, (C.GLuint)(mask)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (pal *CGBPalette) updateIndex(value byte) {\n\tpal.index = value & 0x3F\n\tpal.inc = bits.Test(value, 7)\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 (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 (w *Writer) BitIndex() int64", "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 (n *alterIndexNode) ReadingOwnWrites() {}", "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 ClearIndex(c float32) {\n C.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func IndexMask(mask uint32) {\n C.glowIndexMask(gpIndexMask, (C.GLuint)(mask))\n}", "func (bitmap *bitmap) set(index int, bit int) {\n\tif index >= bitmap.Size {\n\t\tpanic(\"index out of range\")\n\t}\n\n\tdiv, mod := index/8, index%8\n\tshift := byte(1 << uint(7-mod))\n\n\tbitmap.data[div] &= ^shift\n\tif bit > 0 {\n\t\tbitmap.data[div] |= shift\n\t}\n}", "func ClearIndex(c float32) {\n\tC.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func (pal *CGBPalette) readIndex() byte {\n\treturn pal.index\n}", "func (c *Controller) Write(value byte) {\n\tc.strobe = value&1 == 1\n\tif c.strobe {\n\t\tc.index = 0\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) 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 (i *index) Write(off uint32, pos uint64) error {\n\tif uint64(len(i.mmap)) < i.size+entWidth {\n\t\treturn io.EOF\n\t}\n\n\tenc.PutUint32(i.mmap[i.size:i.size+offWidth], off)\n\tenc.PutUint64(i.mmap[i.size+offWidth:i.size+entWidth], pos)\n\ti.size += uint64(entWidth)\n\treturn nil\n}", "func (x *Index) Write(w io.Writer) error", "func (pw *PixelWand) SetColorCount(count uint) {\n\tC.PixelSetColorCount(pw.pw, C.size_t(count))\n\truntime.KeepAlive(pw)\n}", "func (color *Color) writeType(w io.Writer) (err error) {\n\n\tvar colorType int16\n\n\tswitch color.Type {\n\tcase \"Global\":\n\t\tcolorType = 0\n\t\tbreak\n\tcase \"Spot\":\n\t\tcolorType = 1\n\t\tbreak\n\tcase \"Normal\":\n\t\tcolorType = 2\n\t\tbreak\n\tdefault:\n\t\treturn ErrInvalidColorType\n\t}\n\n\treturn binary.Write(w, binary.BigEndian, []int16{colorType})\n}", "func IndexWrite(x *suffixarray.Index, w io.Writer) error", "func (v *Bitmap256) Set(pos uint8) {\n\tv[pos>>6] |= 1 << (pos & 63)\n}", "func setBit(bitmap []byte, idx int) {\n\tbitmap[idx/8] = bitmap[idx/8] | (1 << uint(idx%8))\n}", "func (c *Chip8) SetIndex() {\n\tc.index = c.inst & 0x0FFF\n}", "func (e *encoder) emit(bits, nBits uint32) {\n\tnBits += e.nBits\n\tbits <<= 32 - nBits\n\tbits |= e.bits\n\tfor nBits >= 8 {\n\t\tb := uint8(bits >> 24)\n\t\te.writeByte(b)\n\t\tif b == 0xff {\n\t\t\te.writeByte(0x00)\n\t\t}\n\t\tbits <<= 8\n\t\tnBits -= 8\n\t}\n\te.bits, e.nBits = bits, nBits\n}", "func (x *Index) Write(w io.Writer) error {}", "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 writeBitacora(file *os.File, index int64, log *bitacora) {\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, log)\n\twriteNextBytes(file, binaryDisc.Bytes())\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 (w *Writer) writeIndex() (int64, error) {\n\tw.written = true\n\n\tbuf := new(bytes.Buffer)\n\tst := sst.NewWriter(buf)\n\n\tw.spaceIds.Sort()\n\n\t// For each defined space, we index the space's\n\t// byte offset in the file and the length in bytes\n\t// of all data in the space.\n\tfor _, spaceId := range w.spaceIds {\n\t\tb := new(bytes.Buffer)\n\n\t\tbinary.WriteInt64(b, w.spaceOffsets[spaceId])\n\t\tbinary.WriteInt64(b, w.spaceLengths[spaceId])\n\n\t\tif err := st.Set([]byte(spaceId), b.Bytes()); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t}\n\n\tif err := st.Close(); err != nil {\n\t\treturn 0, err\n\t}\n\n\treturn buf.WriteTo(w.file)\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 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 DrawBuffers(n int32, bufs *uint32) {\n C.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func (cpu *CPU) set_C(i uint16) {\r\n\tcpu.regs[2] = (cpu.regs[2] & 0xfffe) | (i & 1)\r\n}", "func (p *Buffer) saveIndex(ptr unsafe.Pointer, idx uint) {\n\tif p.array_indexes == nil {\n\t\t// the 1st time we need to allocate\n\t\tp.array_indexes = make(map[unsafe.Pointer]uint)\n\t}\n\tp.array_indexes[ptr] = idx\n}", "func ClearIndex(c float32) {\n\tsyscall.Syscall(gpClearIndex, 1, uintptr(math.Float32bits(c)), 0, 0)\n}", "func (b *bitWriter) flush32() {\n\tif b.nBits < 32 {\n\t\treturn\n\t}\n\tb.out = append(b.out,\n\t\tbyte(b.bitContainer),\n\t\tbyte(b.bitContainer>>8),\n\t\tbyte(b.bitContainer>>16),\n\t\tbyte(b.bitContainer>>24))\n\tb.nBits -= 32\n\tb.bitContainer >>= 32\n}", "func (z *Int) SetBits(abs []Word) *Int {}", "func (i *InterruptController) Write(address uint32, value uint16) {\n\taddress = limitAddress(address)\n\tif address == clearAddress {\n\t\ti.clear = value\n\t\ti.status = i.status &^ i.clear\n\t\treturn\n\t}\n\tif address == maskAddress {\n\t\ti.mask = value\n\t}\n}", "func (r *R1_eg) setBit(idx1 int, value int) {\n\tr.Values[idx1] = value\n}", "func (color *Color) write(w io.Writer) (err error) {\n\n\t// Write the block type\n\tif err = color.writeBlockType(w); err != nil {\n\t\treturn\n\t}\n\n\t// Write the block length\n\tif err = color.writeBlockLength(w); err != nil {\n\t\treturn\n\t}\n\n\t// Write the color data\n\tif err = color.writeNameLen(w); err != nil {\n\t\treturn\n\t}\n\n\tif err = color.writeName(w); err != nil {\n\t\treturn\n\t}\n\n\tif err = color.writeModel(w); err != nil {\n\t\treturn\n\t}\n\n\tif err = color.writeValues(w); err != nil {\n\t\treturn\n\t}\n\n\tif err = color.writeType(w); err != nil {\n\t\treturn\n\t}\n\n\treturn\n}", "func (this *DefaultOutputBitStream) WriteBits(value uint64, count uint) uint {\n\tif count == 0 {\n\t\treturn 0\n\t}\n\n\tif count > 64 {\n\t\tpanic(fmt.Errorf(\"Invalid length: %v (must be in [1..64])\", count))\n\t}\n\n\tvalue &= (0xFFFFFFFFFFFFFFFF >> (64 - count))\n\tbi := uint(this.bitIndex + 1)\n\n\t// Pad the current position in buffer\n\tif count < bi {\n\t\t// Enough spots available in 'current'\n\t\tremaining := bi - count\n\t\tthis.current |= (value << remaining)\n\t\tthis.bitIndex -= int(count)\n\t} else {\n\t\t// Not enough spots available in 'current'\n\t\tremaining := count - bi\n\t\tthis.current |= (value >> remaining)\n\t\tthis.pushCurrent()\n\n\t\tif remaining != 0 {\n\t\t\tthis.current |= (value << (64 - remaining))\n\t\t\tthis.bitIndex -= int(remaining)\n\t\t}\n\t}\n\n\treturn count\n}", "func Indices(itr Iterator) chan int {\n\tch := make(chan int)\n\tgo func() {\n\t\tid := 0\n\t\tfor {\n\t\t\tw, n := itr.Next()\n\t\t\tif n == 0 {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tfor i := 0; i < n; i++ {\n\t\t\t\tif w&(1<<uint(i)) != 0 {\n\t\t\t\t\tch <- id + i\n\t\t\t\t}\n\t\t\t}\n\t\t\tid += bitLength - 1\n\t\t}\n\t\tclose(ch)\n\t}()\n\treturn ch\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func writeIndexChanges(tx *bolt.Tx, changes map[string][]string, op indexOp) error {\n\tfor idxName, indexEntries := range changes {\n\t\tbucket := tx.Bucket([]byte(idxName))\n\t\tfor _, entry := range indexEntries {\n\t\t\tif err := op(bucket, []byte(entry)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\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 WriteInt16(buffer []byte, offset int, value int16) {\n buffer[offset + 0] = byte(value >> 0)\n buffer[offset + 1] = byte(value >> 8)\n}", "func (i *Index) Write(off uint32, pos uint64) error {\n\tif uint64(len(i.mmap)) < i.size+entWidth {\n\t\treturn lib.Wrap(io.EOF, \"Not enough space to append index data\")\n\t}\n\n\tenc.PutUint32(i.mmap[i.size:i.size+offWidth], off)\n\tenc.PutUint64(i.mmap[i.size+offWidth:i.size+entWidth], pos)\n\n\ti.size += entWidth\n\n\treturn nil\n}", "func TestBufferWrite(t *testing.T) {\n\tt.Run(\"Valid\", func(t *testing.T) {\n\t\tw := &Buffer{}\n\n\t\ttoWrite := []byte{0x3f, 0x12, 0x86}\n\n\t\tn, err := w.Write(toWrite)\n\t\trequire.NoError(t, err)\n\n\t\tassert.Equal(t, 3, n)\n\n\t\tn, err = w.Write([]byte{0xff})\n\t\trequire.NoError(t, err)\n\n\t\tassert.Equal(t, 1, n)\n\n\t\texpected := append(toWrite, 0xff)\n\t\tfor i, bt := range w.Data() {\n\t\t\tassert.Equal(t, expected[i], bt, \"%d\", i)\n\t\t}\n\t})\n\n\tt.Run(\"Shifted\", func(t *testing.T) {\n\t\tw := &Buffer{}\n\t\t// write empty byte and reset it's byte index to 0.\n\t\trequire.NoError(t, w.WriteByte(0x00))\n\t\tw.byteIndex = 0\n\t\t// assume that 3 '0' bits were already written.\n\t\tw.bitIndex = 3\n\n\t\ttoWrite := []byte{0x3f, 0x12, 0x86}\n\n\t\tn, err := w.Write(toWrite)\n\t\trequire.NoError(t, err)\n\t\tassert.Equal(t, 3, n)\n\n\t\t// 0x3f - 00111111\n\t\t// 00111111 << 3 = 11111000\n\t\texpected := byte(0xf8)\n\t\tassert.Equal(t, expected, w.data[0])\n\n\t\t// 0x12 - 00010010\n\t\t// 00111111 >> 5 = 00000001\n\t\t// 00010010 << 3 = 10010000\n\t\t// \t\t\t\t | 10010101\n\t\t// 10010111 - 0x91\n\t\texpected = byte(0x91)\n\t\tassert.Equal(t, expected, w.data[1])\n\n\t\t// 0x86 - 10000110\n\t\t// 00010010 >> 5 = \t00000000\n\t\t// 10000110 << 3 = \t00110000\n\t\t// \t\t\t\t |\t00110000\n\t\t// 00110000 = 0x30\n\t\texpected = byte(0x30)\n\t\tassert.Equal(t, expected, w.data[2])\n\t\tassert.Len(t, w.Data(), 4)\n\t})\n\n\tt.Run(\"MSB\", func(t *testing.T) {\n\t\tt.Run(\"Valid\", func(t *testing.T) {\n\t\t\tw := BufferedMSB()\n\n\t\t\ttoWrite := []byte{0x3f, 0x12, 0x86}\n\n\t\t\tn, err := w.Write(toWrite)\n\t\t\trequire.NoError(t, err)\n\n\t\t\tassert.Equal(t, 3, n)\n\n\t\t\tn, err = w.Write([]byte{0xff})\n\t\t\trequire.NoError(t, err)\n\n\t\t\tassert.Equal(t, 1, n)\n\n\t\t\texpected := append(toWrite, 0xff)\n\t\t\tfor i, bt := range w.Data() {\n\t\t\t\tassert.Equal(t, expected[i], bt, \"%d\", i)\n\t\t\t}\n\t\t})\n\n\t\tt.Run(\"Shifted\", func(t *testing.T) {\n\t\t\tw := BufferedMSB()\n\t\t\t// write empty byte so the buffer data is initialized\n\t\t\trequire.NoError(t, w.WriteByte(0x00))\n\t\t\t// reset it's byteindex\n\t\t\tw.byteIndex = 0\n\t\t\t// assume three '0' bits are already stored.\n\t\t\tw.bitIndex = 3\n\n\t\t\ttoWrite := []byte{0x3f, 0x12, 0x86}\n\n\t\t\tn, err := w.Write(toWrite)\n\t\t\trequire.NoError(t, err)\n\t\t\tassert.Equal(t, 3, n)\n\n\t\t\t// 0x3f - 00111111\n\t\t\t// 00111111 >> 3 = 00000111\n\t\t\t// 00000111 = 0x07\n\t\t\texpected := byte(0x07)\n\t\t\tassert.Equal(t, expected, w.data[0])\n\n\t\t\t// 0x12 - 00010010\n\t\t\t// 00111111 << 5 = 11100000\n\t\t\t// 00010010 >> 3 = 00000010\n\t\t\t// \t\t\t\t | 11100010\n\t\t\t// 11100010 - 0xE2\n\t\t\texpected = byte(0xE2)\n\t\t\tassert.Equal(t, expected, w.data[1])\n\n\t\t\t// 0x86 - 10000110\n\t\t\t// 00010010 << 5 = \t01000000\n\t\t\t// 10000110 >> 3 = \t00010000\n\t\t\t// \t\t\t\t |\t01010000\n\t\t\t// 00110000 = 0x50\n\t\t\texpected = byte(0x50)\n\t\t\tassert.Equal(t, expected, w.data[2])\n\n\t\t\t// 0x86 - 10000110\n\t\t\t// 10000110 << 5 = \t11000000\n\t\t\t// 11000000 = 0xC0\n\t\t\texpected = byte(0xC0)\n\t\t\tassert.Equal(t, expected, w.data[3])\n\t\t})\n\t})\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func putbit_correction_0(wps *WavpackStream) {\n\tvar bs Bitstream = wps.wvcbits\n\n\tbs.bc++\n\tif bs.bc == 8 {\n\t\twps.block2buff[bs.buf_index] = byte(bs.sr)\n\t\tbs.buf_index++\n\t\tbs.bc = 0\n\t\tbs.sr = 0\n\n\t\tif bs.buf_index >= bs.end {\n\t\t\tbs_wrap(&bs) // error\n\t\t}\n\t}\n\twps.wvcbits = bs\n}", "func TestBufferFinishByte(t *testing.T) {\n\tfor i := 0; i < 2; i++ {\n\t\t// Having a buffer with some bits already written.\n\t\tvar (\n\t\t\tname string\n\t\t\tw *Buffer\n\t\t)\n\t\tswitch i {\n\t\tcase 0:\n\t\t\tname = \"LSB\"\n\t\t\tw = &Buffer{}\n\t\tcase 1:\n\t\t\tname = \"MSB\"\n\t\t\tw = BufferedMSB()\n\t\t}\n\t\tt.Run(name, func(t *testing.T) {\n\t\t\tbits := []int{1, 0, 1}\n\t\t\tfor _, bit := range bits {\n\t\t\t\terr := w.WriteBit(bit)\n\t\t\t\trequire.NoError(t, err)\n\t\t\t}\n\t\t\t// the bit index is now at the third position\n\t\t\tassert.Equal(t, uint8(3), w.bitIndex)\n\t\t\t// and the byte index is at 0'th position.\n\t\t\tassert.Equal(t, 0, w.byteIndex)\n\n\t\t\t// by using the FinishByte method the bitIndex should be reset to 0\n\t\t\tw.FinishByte()\n\t\t\tassert.Equal(t, uint8(0), w.bitIndex)\n\t\t\t// and the byte index should point to the next byte\n\t\t\tassert.Equal(t, 1, w.byteIndex)\n\t\t\t// and the data should contain only a single byte\n\t\t\tassert.Equal(t, 1, len(w.data))\n\t\t\t// but the cap should be much equal to smallSize\n\t\t\tassert.Equal(t, smallSize, cap(w.data))\n\t\t})\n\t}\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 EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func (bitmap *bitmap) Set(index int) {\n\tbitmap.set(index, 1)\n}", "func Set(data []uintptr, bitIdx int) {\n\t// Unsigned division by a power-of-2 constant compiles to a right-shift,\n\t// while signed does not due to negative nastiness.\n\tdata[uint(bitIdx)/BitsPerWord] |= 1 << (uint(bitIdx) % BitsPerWord)\n}", "func Plot(x, y, color, mode gb.UINT8) {}", "func TestBufferWriteBit(t *testing.T) {\n\tt.Run(\"Valid\", func(t *testing.T) {\n\t\tbuf := &Buffer{}\n\t\t// 10010011 11000111\n\t\t// 0x93 \t0xC7\n\t\tbits := []int{1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1}\n\t\tfor i := len(bits) - 1; i > -1; i-- {\n\t\t\tbit := bits[i]\n\t\t\terr := buf.WriteBit(bit)\n\t\t\trequire.NoError(t, err)\n\t\t}\n\n\t\tassert.Equal(t, byte(0xC7), buf.data[0], \"expected: %08b, is: %08b\", 0xc7, buf.data[0])\n\t\tassert.Equal(t, byte(0x93), buf.data[1], \"expected: %08b, is: %08b\", 0x93, buf.data[1])\n\t})\n\n\tt.Run(\"BitShifted\", func(t *testing.T) {\n\t\tt.Run(\"Empty\", func(t *testing.T) {\n\t\t\tbuf := &Buffer{}\n\t\t\t// fill thee buffer with 3 bits\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\terr := buf.WriteBit(int(0))\n\t\t\t\trequire.NoError(t, err)\n\t\t\t}\n\n\t\t\t// bits 11101\n\t\t\tbits := []int{1, 1, 1, 0, 1}\n\t\t\tfor i := len(bits) - 1; i > -1; i-- {\n\t\t\t\tbit := bits[i]\n\t\t\t\terr := buf.WriteBit(bit)\n\t\t\t\trequire.NoError(t, err)\n\t\t\t}\n\n\t\t\t// should be 11101000 - 0xe8\n\t\t\tassert.Equal(t, byte(0xe8), buf.data[0])\n\t\t})\n\t})\n\n\tt.Run(\"ByteShifted\", func(t *testing.T) {\n\t\tbuf := &Buffer{}\n\t\trequire.NoError(t, buf.WriteByte(0x00))\n\n\t\t// write 8 bits that should look like a byte 0xe3\n\t\t// 11100011 - 0xe3\n\t\tbits := []int{1, 1, 1, 0, 0, 0, 1, 1}\n\t\tfor i := len(bits) - 1; i > -1; i-- {\n\t\t\tbit := bits[i]\n\t\t\terr := buf.WriteBit(bit)\n\t\t\trequire.NoError(t, err)\n\t\t}\n\t\tassert.Equal(t, 2, len(buf.data))\n\t\tassert.Equal(t, byte(0xe3), buf.data[1])\n\n\t\t// there should be no error on writing additional byte.\n\t\tassert.NoError(t, buf.WriteByte(0x00))\n\t})\n\n\tt.Run(\"Finished\", func(t *testing.T) {\n\t\tbuf := &Buffer{}\n\n\t\t// write some bits to the first byte.\n\t\tfirstBits := []int{1, 0, 1}\n\t\tfor _, bit := range firstBits {\n\t\t\terr := buf.WriteBit(bit)\n\t\t\trequire.NoError(t, err)\n\t\t}\n\n\t\t// finish this byte\n\t\tbuf.FinishByte()\n\t\tsecondBits := []int{1, 0, 1}\n\n\t\t// write some bits to the second byte.\n\t\tfor _, bit := range secondBits {\n\t\t\terr := buf.WriteBit(bit)\n\t\t\trequire.NoError(t, err)\n\t\t}\n\n\t\tif assert.Len(t, buf.data, 2) {\n\t\t\t// 00000101 - 0x05\n\t\t\tassert.Equal(t, byte(0x05), buf.Data()[0])\n\t\t\tassert.Equal(t, byte(0x05), buf.Data()[1])\n\t\t}\n\t})\n\n\tt.Run(\"Inverse\", func(t *testing.T) {\n\t\tt.Run(\"Valid\", func(t *testing.T) {\n\t\t\tw := BufferedMSB()\n\n\t\t\t// \t10010111 10101100\n\t\t\t//\t0x97\t 0xac\n\t\t\tbits := []int{1, 0, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 1, 1, 0, 0}\n\n\t\t\t// write all the bits\n\t\t\tfor _, bit := range bits {\n\t\t\t\terr := w.WriteBit(bit)\n\t\t\t\trequire.NoError(t, err)\n\t\t\t}\n\n\t\t\texpected := byte(0x97)\n\t\t\tassert.Equal(t, expected, w.data[0], \"expected: %08b is: %08b\", expected, w.data[0])\n\t\t\texpected = byte(0xac)\n\t\t\tassert.Equal(t, expected, w.data[1], \"expected: %08b is: %08b\", expected, w.data[1])\n\t\t})\n\n\t\tt.Run(\"ByteShifted\", func(t *testing.T) {\n\t\t\tbuf := BufferedMSB()\n\t\t\terr := buf.WriteByte(0x00)\n\t\t\trequire.NoError(t, err)\n\n\t\t\t// 11100011 - 0xe3\n\t\t\tbits := []int{1, 1, 1, 0, 0, 0, 1, 1}\n\t\t\tfor _, bit := range bits {\n\t\t\t\terr := buf.WriteBit(bit)\n\t\t\t\trequire.NoError(t, err)\n\t\t\t}\n\n\t\t\tassert.Equal(t, byte(0xe3), buf.data[1], \"expected: %08b, is: %08b\", byte(0xe3), buf.data[1])\n\t\t})\n\n\t\tt.Run(\"BitShifted\", func(t *testing.T) {\n\t\t\tw := BufferedMSB()\n\n\t\t\t// 0xE0 - 11100000\n\t\t\terr := w.WriteByte(0xE0)\n\t\t\trequire.NoError(t, err)\n\n\t\t\tw.bitIndex = 5\n\t\t\tw.byteIndex = 0\n\n\t\t\tbits := []int{1, 0, 1, 0, 1}\n\t\t\tfor _, bit := range bits {\n\t\t\t\terr := w.WriteBit(bit)\n\t\t\t\trequire.NoError(t, err)\n\t\t\t}\n\n\t\t\t// should be 11100101 01000000 ...\n\t\t\t//\t\t\t 0xE5\t 0x40\n\t\t\tassert.Equal(t, byte(0xE5), w.data[0], \"expected: %08b, is: %08b\", byte(0xE5), w.data[0])\n\t\t\tassert.Equal(t, byte(0x40), w.data[1], \"expected: %08b, is: %08b\", byte(0x40), w.data[1])\n\t\t})\n\n\t\tt.Run(\"Finished\", func(t *testing.T) {\n\t\t\tbuf := BufferedMSB()\n\n\t\t\t// write some bits to the first byte\n\t\t\tfirstBits := []int{1, 0, 1}\n\t\t\tfor _, bit := range firstBits {\n\t\t\t\trequire.NoError(t, buf.WriteBit(bit))\n\t\t\t}\n\t\t\t// finish the byte\n\t\t\tbuf.FinishByte()\n\n\t\t\t// write bits to the second byte.\n\t\t\tsecondBits := []int{1, 0, 1}\n\t\t\tfor _, bit := range secondBits {\n\t\t\t\trequire.NoError(t, buf.WriteBit(bit))\n\t\t\t}\n\n\t\t\tif assert.Len(t, buf.Data(), 2) {\n\t\t\t\t// 10100000 - 0xa0\n\t\t\t\tassert.Equal(t, byte(0xa0), buf.Data()[0])\n\t\t\t\tassert.Equal(t, byte(0xa0), buf.Data()[1])\n\t\t\t}\n\t\t})\n\t})\n}", "func writer(ch <-chan Word, index *sync.Map, wg *sync.WaitGroup) {\n\tfor {\n\t\tif word, more := <-ch; more {\n\t\t\t// fmt.Printf(\"Writing: %s\\n\", word)\n\t\t\tseen, loaded := index.LoadOrStore(word.word, []int{word.index})\n\t\t\tif loaded && !contains(seen.([]int), word.index) {\n\t\t\t\tseen = append(seen.([]int), word.index)\n\t\t\t\tindex.Store(word.word, seen)\n\t\t\t}\n\t\t} else {\n\t\t\twg.Done()\n\t\t\treturn\n\t\t}\n\t}\n}", "func (color *Color) writeName(w io.Writer) (err error) {\n\tname := utf16.Encode([]rune(color.Name))\n\tname = append(name, uint16(0))\n\treturn binary.Write(w, binary.BigEndian, name)\n}", "func (cpu *CPU) set_N(i uint16) {\r\n\tcpu.regs[2] = (cpu.regs[2] & 0xfb) | ((i & 1) << 2)\r\n}", "func writeKey(i int, rw io.ReadWriter) (err error) {\r\n\t_, err = fmt.Fprintf(rw, \"%c\", i)\r\n\tif err != nil {\r\n\t\treturn err\r\n\t}\r\n\r\n\treturn nil\r\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 (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 (color *Color) writeBlockType(w io.Writer) (err error) {\n\treturn binary.Write(w, binary.BigEndian, colorEntry)\n}", "func opI16Bitclear(expr *CXExpression, fp int) {\n\toutB0 := ReadI16(fp, expr.Inputs[0]) &^ ReadI16(fp, expr.Inputs[1])\n\tWriteI16(GetOffset_i16(fp, expr.Outputs[0]), outB0)\n}", "func (bA *CompactBitArray) SetIndex(i int, v bool) bool {\n\tif bA == nil {\n\t\treturn false\n\t}\n\n\tif i < 0 || i >= bA.Count() {\n\t\treturn false\n\t}\n\n\tif v {\n\t\tbA.Elems[i>>3] |= (1 << uint8(7-(i%8)))\n\t} else {\n\t\tbA.Elems[i>>3] &= ^(1 << uint8(7-(i%8)))\n\t}\n\n\treturn true\n}", "func (b *BrainFuck) inc(v int) {\n\tb.memory.cell[b.cur()] = (b.memory.cell[b.cur()] + v) % 255\n}", "func DrawBuffers(n int32, bufs *uint32) {\n\tsyscall.Syscall(gpDrawBuffers, 2, uintptr(n), uintptr(unsafe.Pointer(bufs)), 0)\n}", "func WriteUInt16(buffer []byte, offset int, value uint16) {\n buffer[offset + 0] = byte(value >> 0)\n buffer[offset + 1] = byte(value >> 8)\n}", "func intEncoder(e *encodeState, v reflect.Value) error {\n\tsz := e.size\n\tval := int(v.Int())\n\n\tcolor := \"black\"\n\tif val <= 0 {\n\t\tcolor = \"red\"\n\t\tval = -val\n\t}\n\tfactor := .1\n\tcellSz := (sz / 8)\n\tblkSz := cellSz * (1 - factor)\n\tmargin := cellSz * (factor / 2)\n\n\tfor y := sz - cellSz; y > 0; y -= cellSz {\n\t\tfor x := sz - cellSz; x > 0; x -= cellSz {\n\t\t\tbit := val % 2\n\t\t\tif bit == 1 {\n\t\t\t\tr := e.Rect(x+margin, y-margin, blkSz, blkSz)\n\t\t\t\tr.Style.Set(\"stroke-width\", \"0\")\n\t\t\t\tr.Style.Set(\"fill\", color)\n\t\t\t}\n\t\t\tval = val >> 1\n\t\t\tif val == 0 {\n\t\t\t\treturn nil\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (bm *filterBitmap) forEachSetBit(f func(idx int) bool) {\n\ta := bm.a\n\tbitsLen := bm.bitsLen\n\tfor i, word := range a {\n\t\tif word == 0 {\n\t\t\tcontinue\n\t\t}\n\t\tfor j := 0; j < 64; j++ {\n\t\t\tmask := uint64(1) << j\n\t\t\tif (word & mask) == 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tidx := i*64 + j\n\t\t\tif idx >= bitsLen {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif !f(idx) {\n\t\t\t\ta[i] &= ^mask\n\t\t\t}\n\t\t}\n\t}\n}", "func (dbg *Debug) testBuffers(addr, n uint) error {\n\n\t// random write values\n\twr := make([]uint32, n)\n\tfor i := range wr {\n\t\twr[i] = rand.Uint32()\n\t}\n\n\t// write to dmi registers\n\tfor i := range wr {\n\t\terr := dbg.wrDmi(addr+uint(i), wr[i])\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// read back from dmi registers\n\tfor i := range wr {\n\t\tx, err := dbg.rdDmi(addr + uint(i))\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif x != wr[i] {\n\t\t\treturn fmt.Errorf(\"w/r mismatch at 0x%x\", addr+uint(i))\n\t\t}\n\t}\n\n\treturn nil\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 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 (iob *IndexOptionsBuilder) Bits(bits int32) *IndexOptionsBuilder {\n\tiob.document = append(iob.document, bson.E{\"bits\", bits})\n\treturn iob\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 (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 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 setIndex(resp http.ResponseWriter, index uint64) {\n\t// If we ever return X-Consul-Index of 0 blocking clients will go into a busy\n\t// loop and hammer us since ?index=0 will never block. It's always safe to\n\t// return index=1 since the very first Raft write is always an internal one\n\t// writing the raft config for the cluster so no user-facing blocking query\n\t// will ever legitimately have an X-Consul-Index of 1.\n\tif index == 0 {\n\t\tindex = 1\n\t}\n\tresp.Header().Set(\"X-Consul-Index\", strconv.FormatUint(index, 10))\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 (b *bitWriter) flushBits() error {\n\tbinary.BigEndian.PutUint64(b.bytes[b.bw:], b.bits)\n\tb.bits = 0\n\tb.nBits = 0\n\tb.bw += 8\n\tif b.bw < uint32(len(b.bytes)) {\n\t\treturn nil\n\t}\n\tb.bw = 0\n\tif b.order != MSB {\n\t\treverseBitsWithinBytes(b.bytes[:])\n\t}\n\t_, err := b.w.Write(b.bytes[:])\n\treturn err\n}", "func FastWrite(out io.Writer, x []int16) (int, error) {\n\tconst sizeOfScalar = 2\n\tif len(x) == 0 {\n\t\treturn 0, nil\n\t}\n\tnumBytes := len(x) * sizeOfScalar\n\tvar xb []byte\n\thx := (*reflect.SliceHeader)(unsafe.Pointer(&xb))\n\thx.Cap = numBytes\n\thx.Len = numBytes\n\thx.Data = uintptr(unsafe.Pointer(&x[0]))\n\tn, err := out.Write(xb)\n\truntime.KeepAlive(x)\n\treturn n, err\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (b *buffer) index(i uint32) *unsafe.Pointer {\n\treturn risky.Index(unsafe.Pointer(&b.data), ptrSize, uintptr(i))\n}", "func (writer *Writer) WriteColoredFace(vertices []int) {\n\twriter.write16(uint16(CmdColoredFace))\n\twriter.write16(uint16(len(vertices)))\n\tfor _, vertex := range vertices {\n\t\twriter.write16(uint16(vertex))\n\t}\n}", "func TestEngine_WriteIndex_Append(t *testing.T) {\n\te := OpenDefaultEngine()\n\tdefer e.Close()\n\n\t// Append points to index.\n\tif err := e.WriteIndex(map[string][][]byte{\n\t\t\"cpu\": [][]byte{\n\t\t\tappend(u64tob(1), 0x10),\n\t\t\tappend(u64tob(2), 0x20),\n\t\t},\n\t\t\"mem\": [][]byte{\n\t\t\tappend(u64tob(0), 0x30),\n\t\t},\n\t}, nil, nil); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Start transaction.\n\ttx := e.MustBegin(false)\n\tdefer tx.Rollback()\n\n\t// Iterate over \"cpu\" series.\n\tc := tx.Cursor(\"cpu\")\n\tif k, v := c.Seek(u64tob(0)); !reflect.DeepEqual(k, []byte{0, 0, 0, 0, 0, 0, 0, 1}) || !reflect.DeepEqual(v, []byte{0x10}) {\n\t\tt.Fatalf(\"unexpected key/value: %x / %x\", k, v)\n\t} else if k, v = c.Next(); !reflect.DeepEqual(k, []byte{0, 0, 0, 0, 0, 0, 0, 2}) || !reflect.DeepEqual(v, []byte{0x20}) {\n\t\tt.Fatalf(\"unexpected key/value: %x / %x\", k, v)\n\t} else if k, _ = c.Next(); k != nil {\n\t\tt.Fatalf(\"unexpected key/value: %x / %x\", k, v)\n\t}\n\n\t// Iterate over \"mem\" series.\n\tc = tx.Cursor(\"mem\")\n\tif k, v := c.Seek(u64tob(0)); !reflect.DeepEqual(k, []byte{0, 0, 0, 0, 0, 0, 0, 0}) || !reflect.DeepEqual(v, []byte{0x30}) {\n\t\tt.Fatalf(\"unexpected key/value: %x / %x\", k, v)\n\t} else if k, _ = c.Next(); k != nil {\n\t\tt.Fatalf(\"unexpected key/value: %x / %x\", k, v)\n\t}\n}", "func (n *saturationDegreeIterator) Reset() { panic(\"coloring: invalid call to Reset\") }", "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 (ctl *Controller) Update() error {\n\tn, err := ctl.spi.Write(ctl.buffer)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif n != len(ctl.buffer) {\n\t\treturn errors.New(\"Unable to send the full LED colour buffer to device\")\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 BenchmarkBinaryBuffer(b *testing.B) {\n\tscratch := new(buffer.Buffer)\n\tvin := UVWI(0xFFFFFFFFFFFFFFFF)\n\tvar vout UVWI\n\tbenchmarkCodec(b, scratch, &vin, &vout)\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 WriteInt32(buffer []byte, offset int, value int32) {\n buffer[offset + 0] = byte(value >> 0)\n buffer[offset + 1] = byte(value >> 8)\n buffer[offset + 2] = byte(value >> 16)\n buffer[offset + 3] = byte(value >> 24)\n}", "func (d *Device) InvertColors(invert bool) {\n\td.startWrite()\n\tif invert {\n\t\td.sendCommand(INVON, nil)\n\t} else {\n\t\td.sendCommand(INVOFF, nil)\n\t}\n\td.endWrite()\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func Clear(data []uintptr, bitIdx int) {\n\twordIdx := uint(bitIdx) / BitsPerWord\n\tdata[wordIdx] = data[wordIdx] &^ (1 << (uint(bitIdx) % BitsPerWord))\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 writeDumpIndex(filepath string, dumpInfo *blockDumpInfo) error {\n\tdumpInfoData, err := json.Marshal(dumpInfo)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn ioutil.WriteFile(filepath, dumpInfoData, 0666)\n}" ]
[ "0.62844443", "0.5790385", "0.5768539", "0.57655627", "0.56250745", "0.56088126", "0.550877", "0.5501777", "0.5496045", "0.53742635", "0.52181643", "0.5210275", "0.5206621", "0.5200608", "0.51650155", "0.51043737", "0.5078711", "0.50605685", "0.50455046", "0.5020095", "0.50185543", "0.49910265", "0.49893853", "0.49882045", "0.49769285", "0.49735737", "0.4972266", "0.49675098", "0.494417", "0.49440056", "0.4924665", "0.4919246", "0.48968142", "0.48930305", "0.48867708", "0.48495525", "0.48414886", "0.4833523", "0.48244628", "0.48220378", "0.4818438", "0.4801696", "0.48001257", "0.4799521", "0.4782533", "0.47798514", "0.47769886", "0.47691226", "0.4766622", "0.47450647", "0.47330266", "0.47219217", "0.4713275", "0.47089174", "0.47082534", "0.4699976", "0.46994984", "0.4696773", "0.46841747", "0.46767718", "0.4671045", "0.46694028", "0.46687117", "0.4663911", "0.4658316", "0.4655256", "0.4655173", "0.46460634", "0.46414775", "0.46409857", "0.46377006", "0.46376678", "0.46356332", "0.46308059", "0.46278524", "0.46253693", "0.46232563", "0.46232563", "0.46204296", "0.46135125", "0.46054533", "0.46034747", "0.460111", "0.45996147", "0.45994538", "0.4596959", "0.4595659", "0.45949814", "0.45872173", "0.4585826", "0.45832062", "0.45764858", "0.45676976", "0.45675683", "0.45637986", "0.45592877", "0.4549913", "0.4543582", "0.4542605", "0.45417896" ]
0.5010082
21
define an array of color indexes
func IndexPointer(xtype uint32, stride int32, pointer unsafe.Pointer) { C.glowIndexPointer(gpIndexPointer, (C.GLenum)(xtype), (C.GLsizei)(stride), pointer) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 (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 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 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 IndexMask(mask uint32) {\n C.glowIndexMask(gpIndexMask, (C.GLuint)(mask))\n}", "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 getIndices(b []byte) [16]int {\n\n\tif len(b) != 6 {\n\t\tpanic(\"invalid index array size\")\n\t}\n\n\tdata := binary.BigEndian.Uint64(append([]byte{0, 0}, b...))\n\n\tix := [16]int{}\n\tfor i := 0; i < 16; i++ {\n\t\t//Bit shift data right by i*3 and & with 0x0111 to get index\n\t\tix[i] = int((data >> uint(i*3)) & 7)\n\t}\n\treturn ix\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 Colors() []string {\n\treturn []string{\"black\", \"brown\", \"red\", \"orange\", \"yellow\", \"green\", \"blue\", \"violet\", \"grey\", \"white\"}\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 Color(foreColor, backColor, mode gb.UINT8) {}", "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 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 COLORSn(n uint) Component {\n\t//aiComponent_COLORSn(n) (1u << (n+20u))\n\treturn Component(1 << (n + 20))\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 (c Color) At(idx int) float64 {\n\treturn c[idx]\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 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 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 (pal *CGBPalette) updateIndex(value byte) {\n\tpal.index = value & 0x3F\n\tpal.inc = bits.Test(value, 7)\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 (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 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 (c Color) Values() []float64 {\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 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 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 ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\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 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 IndexFindAllIndex(x *suffixarray.Index, r *regexp.Regexp, n int) [][]int", "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 GetUniformIndices(program uint32, uniformCount int32, uniformNames **int8, uniformIndices *uint32) {\n C.glowGetUniformIndices(gpGetUniformIndices, (C.GLuint)(program), (C.GLsizei)(uniformCount), (**C.GLchar)(unsafe.Pointer(uniformNames)), (*C.GLuint)(unsafe.Pointer(uniformIndices)))\n}", "func (p PropertyHashList) Indexes() []uint64 {\n\tindexes := make([]uint64, len(p))\n\tfor idx, pp := range p {\n\t\tindexes[idx] = pp.Index\n\t}\n\n\treturn indexes\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 appendHLColor(hl []byte, n int, hlType byte) []byte {\n\treturn append(hl, bytes.Repeat([]byte{hlType}, n)...)\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 (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 GetColors() map[int]string {\n\treturn colors\n}", "func Analyze(data []byte, n int) (ColorList, error) {\n\tif n <= 0 {\n\t\treturn nil, fmt.Errorf(\"Size of result slice should be above 0\")\n\t}\n\treader := bytes.NewReader(data)\n\timg, _, err := image.Decode(reader)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"image.Decode returns an error: %s\", err)\n\t}\n\n\tbounds := img.Bounds()\n\tcolors := make(map[rgbSet]uint)\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, _ := img.At(x, y).RGBA()\n\t\t\trgb := rgbSet{byte(r >> 8), byte(g >> 8), byte(b >> 8)}\n\t\t\tcolors[rgb]++\n\t\t}\n\t}\n\tvar size int\n\tif len(colors) >= n {\n\t\tsize = n\n\t} else {\n\t\tsize = len(colors)\n\t}\n\n\tcl := make(ColorList, size)\n\tfor rgb, count := range colors {\n\t\tfor key := size - 1; key >= 0; key-- {\n\t\t\tif cl[key].Count > count {\n\t\t\t\tif key < size-1 {\n\t\t\t\t\tcl.insert(Color{toHex(rgb), count}, key+1)\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t} else if key == 0 {\n\t\t\t\tcl.insert(Color{toHex(rgb), count}, 0)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn cl, nil\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 (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 (cc Counter) Rank() []RGB {\n\tcolors := []RGB{}\n\tfor rgb := range cc {\n\t\tcolors = append(colors, rgb)\n\t}\n\tless := func(i, j int) bool {\n\t\tiColor := colors[i]\n\t\tjColor := colors[j]\n\t\tiCount := cc[iColor]\n\t\tjCount := cc[jColor]\n\t\treturn iCount < jCount\n\t}\n\tsort.Slice(colors, less)\n\treturn colors\n}", "func (receiver Type) At(x, y int) color.Color {\n\tconst black = 0\n\tconst white = 255\n\n\tif x < minX || maxX < x || y < minY || maxY < y {\n\t\treturn color.Gray{black}\n\t}\n\n\tresult := receiver[y] & (0x01 << byte(x))\n\n\tif 0 == result {\n\t\treturn color.Gray{black}\n\t}\n\n\treturn color.Gray{white}\n}", "func Uniform3IntArray(location UniformLocation, value []int32) {\n\tgl.Uniform3iv(int32(location), 1, &value[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 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 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 (hs Headers) Indices(titles ...string) (\n\t[]int, error) {\n\tindices := make([]int, len(titles))\n\tfor i, title := range titles {\n\t\tindex, err := hs.Index(title)\n\t\tif err != nil {\n\t\t\treturn []int{}, err\n\t\t}\n\t\tindices[i] = index\n\t}\n\treturn indices, nil\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 Uniform2IntArray(location UniformLocation, value []int32) {\n\tgl.Uniform2iv(int32(location), 1, &value[0])\n}", "func IndexMask(mask uint32) {\n\tC.glowIndexMask(gpIndexMask, (C.GLuint)(mask))\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 colorPointsForModel(model string) (points []XY) {\n\tpoints = make([]XY, 3)\n\tswitch model {\n\tcase \"LCT001\", \"LCT002\", \"LCT003\":\n\t\tpoints[colorPointRed].X = 0.674\n\t\tpoints[colorPointRed].Y = 0.322\n\t\tpoints[colorPointGreen].X = 0.408\n\t\tpoints[colorPointGreen].Y = 0.517\n\t\tpoints[colorPointBlue].X = 0.168\n\t\tpoints[colorPointBlue].Y = 0.041\n\t\treturn\n\n\tcase \"LLC001\", \"LLC005\", \"LLC006\", \"LLC007\", \"LLC011\", \"LLC012\", \"LLC013\", \"LST001\":\n\t\tpoints[colorPointRed].X = 0.703\n\t\tpoints[colorPointRed].Y = 0.296\n\t\tpoints[colorPointGreen].X = 0.214\n\t\tpoints[colorPointGreen].Y = 0.709\n\t\tpoints[colorPointBlue].X = 0.139\n\t\tpoints[colorPointBlue].Y = 0.081\n\t\treturn\n\t}\n\n\tpoints[colorPointRed].X = 1.0\n\tpoints[colorPointRed].Y = 0.0\n\tpoints[colorPointGreen].X = 0.0\n\tpoints[colorPointGreen].Y = 1.0\n\tpoints[colorPointBlue].X = 0.0\n\tpoints[colorPointBlue].Y = 0.0\n\treturn\n}", "func ColorCount() int {\n\treturn palette.count\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "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 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 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 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 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 ShowColors() {\n\tfmt.Printf(\"%#v\\n\", colors)\n}", "func (image *Image2D) getIdx(x, y int) int {\n\treturn (x + y*image.width) * image.channels\n}", "func findOrIndex(abc *st.Art, index int) bool {\n\tfor _, indexF := range abc.Flag.Color.ByIndex.Range {\n\t\tif index == indexF {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\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 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 (fb FrameBuffer) ColorAt(x int, y int) color.Color {\n\tc := fb.img.At(x, y)\n\treturn c\n}", "func initPxMap() [][]bool {\n\tmaze, err := os.Open(mazeFile)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tdefer maze.Close()\n\n\tcolorMap, err := png.Decode(maze)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tsizeX = colorMap.Bounds().Max.X\n\tsizeY = colorMap.Bounds().Max.Y\n\tvar pxMap [][]bool\n\n\tfor x := 0; x < sizeX; x++ {\n\t\tvar temp []bool\n\t\tfor y := 0; y < sizeY; y++ {\n\t\t\ttemp = append(temp, false)\n\t\t}\n\t\tpxMap = append(pxMap, temp)\n\t}\n\n\tfor x := 0; x < sizeX; x++ {\n\t\tfor y := 0; y < sizeY; y++ {\n\t\t\tif color.GrayModel.Convert(colorMap.At(x, y)).(color.Gray).Y == 255 {\n\t\t\t\tpxMap[x][y] = true\n\t\t\t} else {\n\t\t\t\tpxMap[x][y] = false\n\t\t\t}\n\t\t}\n\t}\n\treturn pxMap\n}", "func newHashArray(indexSize int) hashArray {\n\tha := make(hashArray, indexSize)\n\tfor i := 0; i < indexSize; i += 1 {\n\t\tha[i] = -1\n\t}\n\n\treturn ha\n}", "func (d *drawingsVML) buildIndexes() {\n\tfor id, s := range d.ml.Shape {\n\t\t_ = d.shapeIndex.Add(s, id)\n\t}\n}", "func EnableClientState(array uint32) {\n C.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\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 (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 (uni *Uniform3fv) GetColor(idx int) math32.Color {\n\n\tpos := idx * 3\n\treturn math32.Color{uni.v[pos], uni.v[pos+1], uni.v[pos+2]}\n}", "func (g *GLTF) loadIndices(ai int) (math32.ArrayU32, error) {\n\n\treturn g.loadAccessorU32(ai, \"indices\", []string{SCALAR}, []int{UNSIGNED_BYTE, UNSIGNED_SHORT, UNSIGNED_INT}) // TODO verify that it's ELEMENT_ARRAY_BUFFER\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 (o *MultiMesh) X_GetColorArray() gdnative.PoolColorArray {\n\t//log.Println(\"Calling MultiMesh.X_GetColorArray()\")\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(\"MultiMesh\", \"_get_color_array\")\n\n\t// Call the parent method.\n\t// PoolColorArray\n\tretPtr := gdnative.NewEmptyPoolColorArray()\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.NewPoolColorArrayFromPointer(retPtr)\n\treturn ret\n}", "func (c NCMYKA80) RGBA() (uint32, uint32, uint32, uint32) {\n\tw := uint32(c.K)\n\tr := uint32(c.C) * w / 0xffff\n\tg := uint32(c.M) * w / 0xffff\n\tb := uint32(c.Y) * w / 0xffff\n\tif c.A == 0xffff {\n\t\treturn r, g, b, 0xffff\n\t}\n\tif c.A == 0 {\n\t\treturn 0, 0, 0, 0\n\t}\n\n\ta := uint32(c.A)\n\tr = r * a / 0xffff\n\tg = g * a / 0xffff\n\tb = b * a / 0xffff\n\treturn r, g, b, a\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 (filter *BloomFilter) getIndexes(key interface{}) []uint {\n\tindexes := make([]uint, filter.hashCount)\n\tkeyBytes, _ := getBytes(key)\n\tmax := uint(filter.capacity)\n\th1, h2 := murmur3Hash(keyBytes)\n\n\tfor hashIndex := 0; hashIndex < filter.hashCount; hashIndex++ {\n\t\ti := uint(hashIndex)\n\t\tindexes[i] = (uint(h1) + i*uint(h2) + i*i) % max\n\t}\n\n\treturn indexes\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 smallGridIndices(i, j int) (int, int) {\n\tvar smallGrid_i, smallGrid_j int\n\tif i <= 3 {\n\t\tsmallGrid_i = 1\n\t} else if i <= 6 {\n\t\tsmallGrid_i = 2\n\t} else {\n\t\tsmallGrid_i = 3\n\t}\n\n\tif j <= 3 {\n\t\tsmallGrid_j = 1\n\t} else if j <= 6 {\n\t\tsmallGrid_j = 2\n\t} else {\n\t\tsmallGrid_j = 3\n\t}\n\n\treturn smallGrid_i, smallGrid_j\n}", "func Viridis(v, vmin, vmax float64) drawing.Color {\n\tnormalized := (v - vmin) / (vmax - vmin)\n\tindex := uint8(normalized * 255)\n\treturn viridisColors[index]\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 MapByteToIndices(byte_at byte) []int {\n\t//\n\t// WARNING: Handy for testing, but too slow for production\n\t//\n\tswitch byte_at {\n\tcase 0x00:\n\t\treturn []int{}\n\n\tcase 0xFF:\n\t\treturn []int{0, 1, 2, 3, 4, 5, 6, 7}\n\n\tdefault:\n\t}\n\n\toutput := make([]int, 8)\n\tcount := 0\n\n\t//\n\t// WARNING!! We are counting from Left --> Right here!\n\t//\n\tfor j := 0; j < 8; j++ {\n\t\tmask := byte(1) << uint(7-j)\n\t\tif mask&(byte_at) != 0 {\n\t\t\toutput[count] = j\n\t\t\tcount++\n\t\t}\n\t}\n\n\t// Return the slice of live ids\n\treturn output[0:count]\n}", "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 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 generateIndexes(cantidad int, rango int) []int {\n\trand.Seed(time.Now().UnixNano())\n\tvar resp []int = make([]int, cantidad)\n\tfor i := 1; i < cantidad; i++ {\n\t\tvar value int = rand.Intn(rango)\n\t\tvar b bool = find(resp, value)\n\t\tfor b {\n\t\t\tvalue = rand.Intn(rango)\n\t\t\tb = find(resp, value)\n\t\t}\n\t\tresp[i] = value\n\t}\n\treturn resp\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 cellsPainted(markedVals []int, index indexedCluster) (neededCells []int) {\n\tfor _, value := range markedVals {\n\t\tneededCells = addArr(neededCells, index[value])\n\t}\n\treturn\n}", "func (a *APIGen) Indices(ctx context.Context, filter string) ([]Index, error) {\n\tpanic(\"Should Not Be Called from Gen Pattern.\")\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 get1N(indices *[]uint16, start, end int) []uint16 {\n\tif end > cap(*indices) {\n\t\t*indices = make([]uint16, end)\n\t\tfor i := range *indices {\n\t\t\t(*indices)[i] = uint16(i)\n\t\t}\n\t}\n\treturn (*indices)[start:end]\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 HexRanges(origins []H3Index, k int) ([][]H3Index, error) {\n\trsz := rangeSize(k)\n\toutHexes := make([]C.H3Index, rsz*len(origins))\n\tinHexes := h3SliceToC(origins)\n\trv := C.hexRanges(&inHexes[0], C.int(len(origins)), C.int(k), &outHexes[0])\n\tif rv != 0 {\n\t\treturn nil, ErrPentagonEncountered\n\t}\n\n\tret := make([][]H3Index, len(origins))\n\tfor i := 0; i < len(origins); i++ {\n\t\tret[i] = make([]H3Index, rsz)\n\t\tfor j := 0; j < rsz; j++ {\n\t\t\tret[i][j] = H3Index(outHexes[i*rsz+j])\n\t\t}\n\t}\n\treturn ret, nil\n}", "func HexRanges(origins []H3Index, k int) ([][]H3Index, error) {\n\trsz := rangeSize(k)\n\toutHexes := make([]C.H3Index, rsz*len(origins))\n\tinHexes := h3SliceToC(origins)\n\trv := C.hexRanges(&inHexes[0], C.int(len(origins)), C.int(k), &outHexes[0])\n\tif rv != 0 {\n\t\treturn nil, ErrPentagonEncountered\n\t}\n\n\tret := make([][]H3Index, len(origins))\n\tfor i := 0; i < len(origins); i++ {\n\t\tret[i] = make([]H3Index, rsz)\n\t\tfor j := 0; j < rsz; j++ {\n\t\t\tret[i][j] = H3Index(outHexes[i*rsz+j])\n\t\t}\n\t}\n\treturn ret, nil\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 HexRange(origin H3Index, k int) ([]H3Index, error) {\n\tout := make([]C.H3Index, rangeSize(k))\n\tif rv := C.hexRange(origin, C.int(k), &out[0]); rv != 0 {\n\t\treturn nil, ErrPentagonEncountered\n\t}\n\treturn h3SliceFromC(out), nil\n}", "func HexRange(origin H3Index, k int) ([]H3Index, error) {\n\tout := make([]C.H3Index, rangeSize(k))\n\tif rv := C.hexRange(origin, C.int(k), &out[0]); rv != 0 {\n\t\treturn nil, ErrPentagonEncountered\n\t}\n\treturn h3SliceFromC(out), nil\n}" ]
[ "0.6373035", "0.63277876", "0.6205362", "0.56236786", "0.5571079", "0.53576183", "0.53054315", "0.52919", "0.5276611", "0.5271397", "0.52600247", "0.5238646", "0.5238602", "0.5228688", "0.5194242", "0.5160445", "0.5144809", "0.5142896", "0.5138408", "0.51381", "0.5088998", "0.50109017", "0.4972124", "0.49588656", "0.49501768", "0.49475312", "0.4937905", "0.49375686", "0.49373412", "0.49285215", "0.49096623", "0.4897318", "0.48949274", "0.48653495", "0.4864219", "0.48558244", "0.48404408", "0.48320666", "0.48218927", "0.48129302", "0.4796701", "0.47746623", "0.47709507", "0.47601467", "0.4740538", "0.47391415", "0.47386932", "0.47322628", "0.47317916", "0.47305715", "0.47217512", "0.4715838", "0.4708817", "0.47050193", "0.46997023", "0.4684925", "0.4684548", "0.46746695", "0.46684086", "0.46642435", "0.46461907", "0.4646128", "0.4643322", "0.46394733", "0.4636772", "0.46310622", "0.46291077", "0.46228427", "0.4621808", "0.4615101", "0.46078998", "0.4607704", "0.46031216", "0.46017057", "0.4594306", "0.4580195", "0.45796573", "0.4577974", "0.45723328", "0.4561902", "0.45530444", "0.4549679", "0.45421815", "0.45409113", "0.45319456", "0.45288837", "0.45279497", "0.4526776", "0.45214927", "0.45172405", "0.4513894", "0.45129195", "0.45106983", "0.4507274", "0.45034975", "0.45019865", "0.45007756", "0.45007756", "0.45000392", "0.4498784", "0.4498784" ]
0.0
-1
initialize the name stack
func InitNames() { C.glowInitNames(gpInitNames) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InitNames() {\n\tsyscall.Syscall(gpInitNames, 0, 0, 0, 0)\n}", "func InitNames() {\n C.glowInitNames(gpInitNames)\n}", "func (js *jsonName) Init(s string) {\n\tjs.has = true\n\tjs.name = s\n}", "func initialize() {\n\n\thead.data = \"San Francisco\"\n\thead.next = nil\n\n\tvar Oakland *Node = &Node{data: \"Oakland\", next: nil}\n\thead.next = Oakland\n\n\tvar Berkely *Node = &Node{data: \"Berkely\", next: nil}\n\tOakland.next = Berkely\n\n\tvar Fremont *Node = &Node{data: \"Fremont\", next: nil}\n\tBerkely.next = Fremont\n\n\t// remember this pattern for linked list\n\t// make the last insertion, tail = last value\n\ttail = Fremont\n\ttail.next = nil\n\tBerkely.next = tail\n}", "func (st *StackTrace) Initialize() {\n\tconst depth = 32\n\tvar counters [depth]uintptr\n\tcount := runtime.Callers(3, counters[:]) // skip extern.go, this func, Error.func\n\t*st = make(StackTrace, count)\n\tfor i := 0; i < count; i++ {\n\t\t(*st)[i] = StackFrame(counters[i])\n\t}\n}", "func initLockNames() {}", "func (es *eeStack) init(caps int) {\r\n\t((*eeValues)(es)).init(caps)\r\n}", "func (s *Syscalls) init() error {\n\tfor class, groups := range gClassMap {\n\t\tfor group, syscalls := range groups {\n\t\t\tfor _, scStr := range syscalls {\n\t\t\t\tnr, ok := gSyscallMap[scStr]\n\t\t\t\tif !ok {\n\t\t\t\t\treturn fmt.Errorf(\"No matching NR for %s\", scStr)\n\t\t\t\t}\n\n\t\t\t\tsc := &Syscall{nr, scStr, class, group}\n\n\t\t\t\ts.nr[nr] = sc\n\t\t\t\ts.name[scStr] = sc\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func init() {\n\t// @callstack callstack-init \"^\"\n}", "func (p *scopeParser) init() {\n\tp.currentScope = nil\n\tp.fileScope = &FileScope{\n\t\tVariableMap: make(map[*tree.Token]*Variable, 4),\n\t\tScopeMap: make(map[tree.Node]*Scope, 4),\n\t}\n}", "func (s *BaseAspidaListener) EnterNameMain(ctx *NameMainContext) {}", "func (s *BasePCREListener) EnterName(ctx *NameContext) {}", "func init_node(node int32){\nname_dir[node].equiv= -1\n}", "func init(){\n\tcaller=Te\n}", "func (s *BasevhdlListener) EnterName(ctx *NameContext) {}", "func (s *BasecluListener) EnterName(ctx *NameContext) {}", "func StackConstructor() MyStack {\n\treturn MyStack{}\n}", "func Constructor() MyStack {\n\treturn MyStack{queue: list.New()}\n}", "func (s *BaseSyslParserListener) EnterName_str(ctx *Name_strContext) {}", "func (s *BasePlSqlParserListener) EnterContainer_names(ctx *Container_namesContext) {}", "func push_level(p int32){\nstack= append(stack,cur_state)\ncur_state.name_field= p\ncur_state.repl_field= name_dir[p].equiv\ncur_state.byte_field= text_info[cur_state.repl_field].token\ncur_state.section_field= 0\n}", "func (q *Queue) Init(log logrus.FieldLogger, names []string, when time.Time) {\n\tn := len(names)\n\tfound := make(map[string]bool, n)\n\n\tq.lock.Lock()\n\tdefer q.lock.Unlock()\n\tdefer q.rouse()\n\n\tif q.signal == nil {\n\t\tq.signal = make(chan struct{})\n\t}\n\n\tif q.items == nil {\n\t\tq.items = make(map[string]*item, n)\n\t}\n\tif q.queue == nil {\n\t\tq.queue = make(priorityQueue, 0, n)\n\t}\n\titems := q.items\n\n\tq.log = log\n\tfor _, name := range names {\n\t\tfound[name] = true\n\t\tif _, ok := items[name]; ok {\n\t\t\tcontinue\n\t\t}\n\t\tit := &item{\n\t\t\tname: name,\n\t\t\twhen: when,\n\t\t\tindex: len(q.queue),\n\t\t}\n\t\theap.Push(&q.queue, it)\n\t\titems[name] = it\n\t\tlog.WithFields(logrus.Fields{\n\t\t\t\"when\": when,\n\t\t\t\"name\": name,\n\t\t}).Info(\"Adding name to queue\")\n\t}\n\n\tfor name, it := range items {\n\t\tif found[name] {\n\t\t\tcontinue\n\t\t}\n\t\tlog.WithField(\"name\", name).Info(\"Removing name from queue\")\n\t\theap.Remove(&q.queue, it.index)\n\t\tdelete(q.items, name)\n\t}\n}", "func (cardStack *CardStack) Init() {\n\tcardStack.Cards = make([]Card, 0)\n}", "func createStackEntry() StackEntry {\n\thost, _ := os.Hostname()\n\tpc, file, line, _ := runtime.Caller(2)\n\tfunction := runtime.FuncForPC(pc).Name()\n\t_, function = filepath.Split(function)\n\tfile = strings.TrimPrefix(file, gopathSource) // trim gopathSource from file\n\n\tdata := GetGlobalState()\n\tfor k, v := range getSystemData() {\n\t\tdata[k] = v\n\t}\n\n\tentry := StackEntry{\n\t\tHost: host,\n\t\tFile: file,\n\t\tFunc: function,\n\t\tLine: line,\n\t\tData: data,\n\t}\n\treturn entry\n}", "func (s *BaseAspidaListener) EnterName(ctx *NameContext) {}", "func Constructor() MyStack {\n\treturn MyStack{l: list.New()}\n}", "func (s *BasecookieListener) EnterName(ctx *NameContext) {}", "func newStack() *stack {\n\treturn &stack{\n\t\tns: make([]*Node, 0),\n\t}\n}", "func init() {\n\tfframes = make(map[string]Frame)\n\tfmethods = make(map[string]func(string))\n}", "func (uni *UniformMatrix3f) Init(name string) {\n\n\tuni.name = name\n}", "func (s *BaseRFC5424Listener) EnterName(ctx *NameContext) {}", "func Constructor_MyStack() MyStack {\n\treturn MyStack{}\n}", "func (s *BasecluListener) EnterName_list(ctx *Name_listContext) {}", "func (l *Logs) Init(name string) {\n\tl.funcName = name\n\tl.startTime = time.Now()\n}", "func init() {\n\tflag.StringVar(&name, \"name\", \"everyone\", \"The greeting object.\")\n}", "func newnamel(pos src.XPos, s *types.Sym) *Node {\n\tif s == nil {\n\t\tFatalf(\"newnamel nil\")\n\t}\n\n\tvar x struct {\n\t\tn Node\n\t\tm Name\n\t\tp Param\n\t}\n\tn := &x.n\n\tn.Name = &x.m\n\tn.Name.Param = &x.p\n\n\tn.Op = ONAME\n\tn.Pos = pos\n\tn.Orig = n\n\n\tn.Sym = s\n\treturn n\n}", "func (st *scopeStack) push(name ID) {\n\tids := idScope{\n\t\tID: name,\n\t\tscope: scope{},\n\t}\n\tst.stack = append(st.stack, ids)\n}", "func ConstructorStack() Stack {\n\n\treturn Stack{\n\t\tstack: []interface{}{},\n\t}\n}", "func Constructor() MyStack {\n\treturn MyStack{\n\t\twareHouse: NewMyQueue(),\n\t\tbackup: NewMyQueue(),\n\t}\n}", "func init() {\n\t// attempt to capture the hostname for the worker\n\thostname, _ = os.Hostname()\n\t// check if a hostname is set\n\tif len(hostname) == 0 {\n\t\t// default the hostname to localhost\n\t\thostname = \"localhost\"\n\t}\n}", "func (scope *Scope) initialize() {\n\tif scope.variables == nil {\n\t\tscope.variables = make(map[string]Variable, 0)\n\t}\n}", "func (g *Generator) Stack() error {\n\tif g.Files == nil {\n\t\tg.Files = make(map[string]string)\n\t}\n\tfor _, entry := range g.FileNames {\n\t\tif err := g.stack(entry); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func Constructor() MyStack {\n\treturn MyStack{current: NewQueue(), backup: NewQueue()}\n}", "func init() {\n\t//todo...\n}", "func (l *Loader) init() {\n\tif l.loading == nil {\n\t\tl.loading = stringset.New(1)\n\t\tl.sources = make(map[string]string, 1)\n\t\tl.symbols = make(map[string]*Struct, 1)\n\t}\n}", "func init() {\n\tRegistry.Add(eksinfo.New())\n\tRegistry.Add(vpcinfo.New())\n\tRegistry.Add(iamresourceusage.New())\n}", "func init() {\n\t// Providers backed by netstack.\n\tp := []provider{\n\t\t{\n\t\t\tfamily: linux.AF_INET,\n\t\t\tnetProto: ipv4.ProtocolNumber,\n\t\t},\n\t\t{\n\t\t\tfamily: linux.AF_INET6,\n\t\t\tnetProto: ipv6.ProtocolNumber,\n\t\t},\n\t\t{\n\t\t\tfamily: linux.AF_PACKET,\n\t\t},\n\t}\n\n\tfor i := range p {\n\t\tsocket.RegisterProvider(p[i].family, &p[i])\n\t}\n}", "func (e *Element) init(s *Scene) {\n\tif e.Module == nil {\n\t\te.Module = &ModuleBase{}\n\t}\n\tif e.children.IsNil() {\n\t\te.children = NChildren()\n\t}\n\n\te.Scene = s\n\ts.InitStyle(e)\n\ts.addElement(e)\n\n\te.Module.Init(e)\n\tch := e.children.Slice()\n\tfor i := 0; i < len(ch); i++ {\n\t\tch[i].Value.init(s)\n\t}\n\te.Module.PostInit()\n}", "func init() {\n\n\t// Workflow.AddCommand(workflow.Pause)\n\t// Workflow.AddCommand(workflow.Resume)\n\t// Workflow.AddCommand(workflow.Deploy)\n\t// Workflow.AddCommand(workflow.Test)\n\t// Workflow.AddCommand(workflow.Validate)\n\t// Workflow.AddCommand(workflow.List)\n\t// Workflow.AddCommand(workflow.Kill)\n\t// Workflow.AddCommand(workflow.Topup)\n\t// Workflow.AddCommand(workflow.Log)\n\t// Workflow.AddCommand(workflow.Detail)\n\n\t// RootCmd.AddCommand(Workflow)\n}", "func (s *BaseSyslParserListener) EnterAtomT_name(ctx *AtomT_nameContext) {}", "func StackConstructor() MinStack {\n\treturn MinStack{}\n}", "func newname(s *types.Sym) *Node {\n\tn := newnamel(lineno, s)\n\tn.Name.Curfn = Curfn\n\treturn n\n}", "func init() {\n\tworkflow.Register(Workflow)\n\tactivity.Register(helloworldActivity)\n}", "func initStageName(outputToLog bool) {\n\tvar stageNameSource string\n\tif outputToLog {\n\t\tdefer func() {\n\t\t\tlog.Entry().Debugf(\"Using stageName '%s' from %s\", GeneralConfig.StageName, stageNameSource)\n\t\t}()\n\t}\n\n\tif GeneralConfig.StageName != \"\" {\n\t\t// Means it was given as command line argument and has the highest precedence\n\t\tstageNameSource = \"command line arguments\"\n\t\treturn\n\t}\n\n\t// Use stageName from ENV as fall-back, for when extracting it from parametersJSON fails below\n\tprovider, err := orchestrator.NewOrchestratorSpecificConfigProvider()\n\tif err != nil {\n\t\tlog.Entry().WithError(err).Warning(\"Cannot infer stage name from CI environment\")\n\t} else {\n\t\tstageNameSource = \"env variable\"\n\t\tGeneralConfig.StageName = provider.GetStageName()\n\t}\n\n\tif len(GeneralConfig.ParametersJSON) == 0 {\n\t\treturn\n\t}\n\n\tvar params map[string]interface{}\n\terr = json.Unmarshal([]byte(GeneralConfig.ParametersJSON), &params)\n\tif err != nil {\n\t\tif outputToLog {\n\t\t\tlog.Entry().Infof(\"Failed to extract 'stageName' from parametersJSON: %v\", err)\n\t\t}\n\t\treturn\n\t}\n\n\tstageName, hasKey := params[\"stageName\"]\n\tif !hasKey {\n\t\treturn\n\t}\n\n\tif stageNameString, ok := stageName.(string); ok && stageNameString != \"\" {\n\t\tstageNameSource = \"parametersJSON\"\n\t\tGeneralConfig.StageName = stageNameString\n\t}\n}", "func (p *systemFlow) init() {\n\tp.periodList = []SystemPeriod{\n\t\tPERIOD_START,\n\t\tPERIOD_POST_START,\n\t\tPERIOD_UPDATE,\n\t\tPERIOD_POST_UPDATE,\n\t\tPERIOD_DESTROY,\n\t\tPERIOD_POST_DESTROY,\n\t}\n\tp.systemPeriod = make(map[SystemPeriod]OrderSequence)\n\tfor _, value := range p.periodList {\n\t\tp.systemPeriod[value] = OrderSequence{}\n\t\tsgFront := NewSystemGroup()\n\t\tsgFront.order = ORDER_FRONT\n\t\tsgAppend := NewSystemGroup()\n\t\tsgAppend.order = ORDER_APPEND\n\t\tp.systemPeriod[value] = append(p.systemPeriod[value], sgFront, sgAppend)\n\t}\n}", "func init() {\n\tparser.SharedParser().RegisterFabric(UpdateFabric{})\n}", "func main_init()", "func init() {\n\ttag.Register(\"tn-BW\", \"Setswana (Botswana)\")\n\ttag.Register(\"tn-ZA\", \"Setswana (South Africa)\")\n}", "func init() { fmt.Printf(\"Hello \") }", "func (s *BaseSyslParserListener) EnterApp_name(ctx *App_nameContext) {}", "func initAll()", "func Constructor0() MinStack {\n\treturn MinStack{}\n}", "func init() {\n\tgather.Register(sqsRegName, &sqsCreator{})\n}", "func Constructor() (s MyStack) {\n return\n}", "func (s *BasevhdlListener) EnterLogical_name_list(ctx *Logical_name_listContext) {}", "func Constructor() MinStack {\n\treturn MinStack{st: New(), log: New()}\n}", "func Constructor() MyStack {\n\treturn MyStack{\n\t\tqueue.New(),\n\t\tqueue.New(),\n\t}\n}", "func init() {\n\trootCmd.AddCommand(renameCmd)\n\trenameCmd.Flags().StringVarP(&mapFile, \"map\", \"m\", \"\", \"Tab separated file mapping old names to new names. 1 operation per line\")\n\trenameCmd.Flags().StringVarP(&regexRenamer, \"regex\", \"r\", \"\", \"Regex to match part of the sequence name\")\n\trenameCmd.Flags().StringVarP(&replaceGroup, \"replace\", \"p\", \"\", \"Replace matched element with this\")\n}", "func (gb *gameBuilder) registerInitHistory(h mHistory.History) {\n\tgb.registerSupply(h.Supply)\n\tgb.registerPlayers(h.PlayerOrder)\n\t//XXX: for now init draw deck is harcoded to\n\t// 7 coppers and 3 estates, but eventually\n\t// read log to get this information\n\tinitDraw := []mCard.Card{}\n\tinitDraw = append(initDraw, mCard.NewCards(\"Copper\", 7)...)\n\tinitDraw = append(initDraw, mCard.NewCards(\"Estate\", 3)...)\n\tfor _, player := range h.PlayerOrder {\n\t\tinitDraw = []mCard.Card{}\n\t\tinitDraw = append(initDraw, mCard.NewCards(\"Copper\", 7)...)\n\t\tinitDraw = append(initDraw, mCard.NewCards(\"Estate\", 3)...)\n\t\tgb.registerInitDraw(player, initDraw)\n\t}\n}", "func (h *hostNamespaces) checkInit(hostName string) {\n\th.mux.Lock()\n\tif _, found := h.HtoN[hostName]; !found {\n\t\th.HtoN[hostName] = set.NewSet()\n\t}\n\th.mux.Unlock()\n}", "func init() {\n\tlog.Println(\"main.go - init_0\")\n\tpc, file, line, ok := runtime.Caller(0)\n\tif ok {\n\t\tlog.Printf(\"[INIT] from %s, line #%d, func: %v\\n\",\n\t\t\tfile, line, runtime.FuncForPC(pc).Name())\n\t}\n}", "func init() {\n\t// Initialization goes here\n}", "func (s *BasevhdlListener) EnterName_part(ctx *Name_partContext) {}", "func (s *BasevhdlListener) EnterLogical_name(ctx *Logical_nameContext) {}", "func initEmployeeDB() {\n\n\t/* initialize linked list and hash function */\n\tedb.elist.size = 0;\n\tedb.elist.head = nil\n\tedb.elist.tail = nil\n\tif edb.emap == nil {\n\t\tedb.emap = make(map[string]*Node)\n\t}\n\tedb.ifname = \"\"\n\tedb.ofname = \"\"\n\n\t/* get the number of arguments */\n\targCount := len(os.Args[1:])\n\tif argCount == 0 {\n\t\tfmt.Print(\"Missing Employee Input DB File name...\")\n\t\treturn\n\t}\n\t/* save input file name */\n\tedb.ifname = os.Args[1]\n\t/* save output file name */\n\tif argCount == 2 {\n\t\tedb.ofname = os.Args[2]\n\t} else {\n\t\tedb.ofname = \"\"\n\t}\n}", "func (phi *Philosopher) Init(name string) {\n\tphi.name = name\n\tphi.respChannel = make(chan string)\n}", "func (f *FibonacciHeap) init() {\n\tf.min = &(Node{})\n\tf.nodes = make(map[Value]*Node)\n\tf.size = 0\n}", "func (s *Stack) init() error {\n\treturn s.db.View(func(txn *badger.Txn) error {\n\t\t// Create a new BadgerDB Iterator.\n\t\topts := badger.DefaultIteratorOptions\n\t\tit := txn.NewIterator(opts)\n\t\tdefer it.Close()\n\n\t\tif it.Rewind(); it.Valid() {\n\t\t\t// Set stack tail to the first item.\n\t\t\ts.tail = keyToID(it.Item().Key()) - 1\n\n\t\t\tfor {\n\t\t\t\tif it.Next(); it.Valid() {\n\t\t\t\t\t// Set stack head to the last item.\n\t\t\t\t\ts.head = keyToID(it.Item().Key())\n\t\t\t\t} else {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// reinitialize stack in case of database error\n\t\tif s.tail > s.head {\n\t\t\ts.tail = 0\n\t\t\ts.head = 0\n\t\t\tif err := s.db.DropAll(); err != nil {\n\t\t\t\tfmt.Printf(\"error resetting database: %s\", err)\n\t\t\t}\n\t\t}\n\n\t\treturn nil\n\t})\n}", "func init() {\n\tRegisterTSDSDBEngine(\"namespace\", new(Namespace))\n}", "func init() {\n\ttag.Register(\"om-ET\", \"Oromo (Ethiopia)\")\n\ttag.Register(\"om-KE\", \"Oromo (Kenya)\")\n}", "func PushName(name uint32) {\n\tsyscall.Syscall(gpPushName, 1, uintptr(name), 0, 0)\n}", "func init() {\n\terr := envconfig.Process(\"RPCH\", &Cfg)\n\tif err != nil {\n\t\tlog.Fatalf(\"FATAL: %v - error importing environment variables. See: %v\\n\", utils.FileLine(), err)\n\t}\n\n\tRgxFnamePrefix = regexp.MustCompile(`^[a-f0-9]+_`)\n}", "func init() {\n\tdrmaa2os.RegisterJobTracker(drmaa2os.SingularitySession, NewAllocator())\n}", "func (s *SQSLocalstack) setup() {\n\tregion := flag.String(\"r\", \"us-east-1\", \"The region of localstack. Default: us-east-1\")\n\tqueue := flag.String(\"q\", \"\", \"The name of the queue\")\n\ttimeout := flag.Int(\"t\", 5, \"How long, in seconds, that the message is hidden from others\")\n\tlocalstackURL := flag.String(\"u\", \"http://localhost:4566\", \"The Localstack url. Default : http://localhost:4566\")\n\tflag.Parse()\n\n\tif *queue == \"\" {\n\t\tfmt.Println(\"You must supply the name of a queue (-q QUEUE)\")\n\t\treturn\n\t}\n\n\tif *timeout < 0 {\n\t\t*timeout = 0\n\t}\n\n\tif *timeout > 12*60*60 {\n\t\t*timeout = 12 * 60 * 60\n\t}\n\ts.region = *region\n\ts.queueName = *queue\n\ts.timeoutSeconds = *timeout\n\ts.localstackURL = *localstackURL\n}", "func Constructor() MyStack {\n\treturn MyStack{}\n}", "func Constructor() MyStack {\n\treturn MyStack{}\n}", "func Constructor() MyStack {\n\treturn MyStack{}\n}", "func Constructor() MyStack {\n\treturn MyStack{}\n}", "func init() {\n\tcheckIsGnuTar()\n/*\n\tsher = gosimhash.New(\"./dict/jieba.dict.utf8\",\n\t\t\t\t\t\t\"./dict/hmm_model.utf8\",\n\t\t\t\t\t\t\"./dict/idf.utf8\",\n\t\t\t\t\t\"./dict/stop_words.utf8\")\n\t// defer sher.Free()*/\n}", "func (r *Root) Name() string { return \"\" }", "func init() {\n\tfor i := 0; i < int(addrModeCount); i++ {\n\t\topNameToOpCode[i] = make(map[string]byte)\n\t}\n\tfor opCode := 0; opCode < 256; opCode++ {\n\t\tinfo := opCodeDataMap[opCode]\n\t\topNameToOpCode[info.addrMode][info.opName] = byte(opCode)\n\t}\n}", "func (C *character) Init(name string, class string, lvl int, xpac int, needxp int, maxlife int, life int, manamax int, mana int, initiative int, damage int, money int, slotinv int, inventory []string, skill []string, head string, body string, foot string, hand string) {\n\tC.name = name\n\tC.class = class\n\tC.lvl = lvl\n\tC.xpac = xpac\n\tC.needxp = needxp\n\tC.maxlife = maxlife\n\tC.life = life\n\tC.manamax = manamax\n\tC.mana = mana\n\tC.initiative = initiative\n\tC.slotinv = slotinv\n\tC.inventory = inventory\n\tC.money = money\n\tC.skill = skill\n\tC.equip.head = head\n\tC.equip.body = body\n\tC.equip.foot = foot\n\tC.equip.hand = hand\n}", "func init() {}", "func init() {}", "func init() {}", "func init() {}", "func Constructor() MyStack {\n\treturn MyStack{q: newQ()}\n}", "func (shell *POSIXShell) Init() string {\n\treturn packr.NewBox(\"assets\").String(fmt.Sprintf(\"leader.%s.sh\", shell.name))\n}", "func (b *cloudBackend) parseStackName(s string) (qualifiedStackReference, error) {\n\tvar q qualifiedStackReference\n\n\tsplit := strings.Split(s, \"/\")\n\tswitch len(split) {\n\tcase 1:\n\t\tq.Name = split[0]\n\tcase 2:\n\t\tq.Owner = split[0]\n\t\tq.Name = split[1]\n\tcase 3:\n\t\tq.Owner = split[0]\n\t\tq.Project = split[1]\n\t\tq.Name = split[2]\n\tdefault:\n\t\treturn qualifiedStackReference{}, fmt.Errorf(\"could not parse stack name '%s'\", s)\n\t}\n\n\treturn q, nil\n}", "func (a *Add) Init(attrs []*onnx.AttributeProto) error {\n\ta.name = \"Add\"\n\treturn nil\n}" ]
[ "0.63717574", "0.59653115", "0.5678458", "0.5650483", "0.56482613", "0.56462455", "0.55364794", "0.5407376", "0.5403332", "0.53570443", "0.5354249", "0.5347625", "0.5310569", "0.528118", "0.52762264", "0.5262355", "0.5256867", "0.5239515", "0.5216435", "0.52063924", "0.51689655", "0.51680654", "0.5144254", "0.5122619", "0.5119727", "0.51069856", "0.51044184", "0.5101387", "0.50930786", "0.50864226", "0.508164", "0.50681764", "0.5041161", "0.5038773", "0.5021727", "0.50150496", "0.5012035", "0.49809015", "0.49756798", "0.4956839", "0.49351248", "0.49310198", "0.49170485", "0.49098322", "0.48851016", "0.48764578", "0.48762563", "0.48683658", "0.4863114", "0.48556513", "0.48505908", "0.4842897", "0.4827681", "0.48246166", "0.48213974", "0.48008025", "0.479969", "0.47962654", "0.47842202", "0.4783734", "0.47743452", "0.47690716", "0.47641143", "0.47603342", "0.47594574", "0.47570154", "0.47561774", "0.4753486", "0.4740313", "0.47350517", "0.4734203", "0.47286895", "0.47282785", "0.4724441", "0.47166896", "0.4715294", "0.47143355", "0.47098038", "0.47097057", "0.4705176", "0.47025162", "0.46990088", "0.46899757", "0.46860737", "0.46857014", "0.46857014", "0.46857014", "0.46857014", "0.4682957", "0.46749613", "0.46691197", "0.46639857", "0.46634844", "0.46634844", "0.46634844", "0.46634844", "0.46624014", "0.46516988", "0.46501362", "0.46465427" ]
0.6029284
1
simultaneously specify and enable several interleaved arrays
func InterleavedArrays(format uint32, stride int32, pointer unsafe.Pointer) { C.glowInterleavedArrays(gpInterleavedArrays, (C.GLenum)(format), (C.GLsizei)(stride), pointer) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InterleavedArrays(format uint32, stride int32, pointer unsafe.Pointer) {\n\tsyscall.Syscall(gpInterleavedArrays, 3, uintptr(format), uintptr(stride), uintptr(pointer))\n}", "func InterleavedArrays(format uint32, stride int32, pointer unsafe.Pointer) {\n C.glowInterleavedArrays(gpInterleavedArrays, (C.GLenum)(format), (C.GLsizei)(stride), pointer)\n}", "func (_m *ControllerInterface) SetArrays(_a0 map[string]*array.PowerStoreArray) {\n\t_m.Called(_a0)\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 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 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 DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\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 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 LoadArrayWithMultiVal(arr [][]int, limit int) (arra [][]int) {\n\tfor i := 1; i < limit; i++ {\n\t\tfor j := 1; j < limit; j++ {\n\t\t\tarr[i][j] = arr[0][j] * arr[i][0]\n\t\t}\n\t}\n\treturn arr\n}", "func EnableClientState(array uint32) {\n C.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func runAmplifiers(initMem interpreter.Program, settings *phaseSettings) (signal int) {\n\t// 0 -> Amp A -> Amp B -> Amp C -> Amp D -> Amp E -> (to thrusters)\n\t// 5 amps, 6 channels\n\tchs := [ampCount + 1]chan int{}\n\tfor i := range chs {\n\t\tchs[i] = make(chan int)\n\t}\n\n\tfor i := 0; i < ampCount; i++ {\n\t\tgo func(icpy int) {\n\t\t\tinterpreter.New(initMem, makeInputDevice(settings[icpy], chs[icpy]), makeOutputDevice(chs[icpy+1])).Run()\n\t\t}(i)\n\t}\n\n\tchs[0] <- initialInput\n\treturn <-chs[ampCount]\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 MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.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\tC.glowMultiDrawArraysIndirect(gpMultiDrawArraysIndirect, (C.GLenum)(mode), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\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 EnableClientState(array uint32) {\n\tsyscall.Syscall(gpEnableClientState, 1, uintptr(array), 0, 0)\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 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 (s *BaseSyslParserListener) EnterArray_of_arrays(ctx *Array_of_arraysContext) {}", "func PreMultiShiftOr(sizes *[]int, init, final *uint) {\n\tt := 0\n\tfor _, size := range *sizes {\n\t\t*init ^= 1 << t\n\t\tt += size\n\t\t*final ^= 1 << (t - 1)\n\t}\n}", "func (g *GLTF) isInterleaved(accessor Accessor) bool {\n\n\t// Get the Accessor's BufferView\n\tif accessor.BufferView == nil {\n\t\treturn false\n\t}\n\tbv := g.BufferViews[*accessor.BufferView]\n\n\t// Calculates the size in bytes of a complete attribute\n\titemSize := TypeSizes[accessor.Type]\n\titemBytes := int(gls.FloatSize) * itemSize\n\n\t// If the BufferView stride is equal to the item size, the buffer is not interleaved\n\tif bv.ByteStride == nil || *bv.ByteStride == itemBytes {\n\t\treturn false\n\t}\n\treturn true\n}", "func (r *ImageRef) ArrayJoin(images []*ImageRef, across int) error {\n\tallImages := append([]*ImageRef{r}, images...)\n\tinputs := make([]*C.VipsImage, len(allImages))\n\tfor i := range inputs {\n\t\tinputs[i] = allImages[i].image\n\t}\n\tout, err := vipsArrayJoin(inputs, across)\n\tif err != nil {\n\t\treturn err\n\t}\n\tr.setImage(out)\n\treturn nil\n}", "func (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\n}", "func (c *Container) setArray(array []uint16) {\n\tc.setArrayMaybeCopy(array, false)\n}", "func (r *Encoder) Array(data []byte) {\n\tr.VarInt(uint64(len(data)))\n\tr.Bytes(data)\n}", "func arraysTest() {\n\t// Initialization\n\tvar x [5]int = [5]int{1, 2, 3, 4, 5} //full assignment\n\tz := [...]int{1, 2, 3} //array literal, length inferred\n\n\tz[0] = 2 //asignment\n\tfmt.Println(x[1]) // arrays initialized to 1\n\n\tfor index, value := range x { //python enumerate\n\t\t_, _ = index, value //dosomething\n\t}\n}", "func DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\n}", "func rcAppendArray(p *TCompiler, code *TCode) (*value.Value, error) {\n\ta := p.regGet(code.A)\n\tb := p.regGet(code.B)\n\ta.Append(b)\n\tp.moveNext()\n\treturn nil, nil\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 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 (e *encoder) marshalArray(t reflect.Type, v reflect.Value, n nestedTypeData) error {\n\telemType := t.Elem()\n\tfor i := 0; i < t.Len(); i++ {\n\t\tif err := e.marshal(elemType, v.Index(i), n); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func mergeArrays(one []uint8, two[]uint8) []uint8 {\n var result []uint8\n for _, value := range one {\n result = append(result, value)\n }\n for _, value := range two {\n result = append(result, value)\n }\n return 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 passArray(arr [3]int) {\n\tarr[1] = 10\n\tfmt.Println(\"Array is\", arr)\n}", "func Array(){\n\t/* local variable definition */\n\tvar angka [5] int32//array\n\tangka[0] = 2\n\tangka[1] = 5\n\tfmt.Println(angka)\n\tvar arr = [] float32{1,2,3,4}//slice\n\tfmt.Println(arr)\n\tfmt.Println(arr[0])\n\tfmt.Println(angka[0])\n\t//len adalah fungsi menghitung panjang array\n\tfor j := 0; j < len(arr); j++ {\n\t\tfmt.Printf(\"Element[%d] = %f\\n\", j, arr[j] )\n\t }\n\n\t// multidimension array\n\tvar nomor [5][2] int32\n\tnomor[0][0] = 10\n\tnomor[0][1] = 11\n\tfmt.Println(nomor[0][0])\n\tfmt.Println(nomor[0][1])\n\n\ta := [3][4] int{ \n\t\t{0, 1, 2, 3} , /* initializers for row indexed by 0 */\n\t\t{4, 5, 6, 7} , /* initializers for row indexed by 1 */\n\t\t{8, 9, 10, 11}} /* initializers for row indexed by 2 */\n\t\n\tfmt.Println(a)\n\tparam := [10]int {1,2,3,4,5,6,7,8,9,10}\n\tmyFunction1(param)\n\tparam2 := []int {1,2,3}\n\tmyFunction2(param2)\n}", "func Bcm2835_gpio_set_eds_multi(Mask uint32) {\n\tcMask, _ := (C.uint32_t)(Mask), cgoAllocsUnknown\n\tC.bcm2835_gpio_set_eds_multi(cMask)\n}", "func mergeCalibrationReadArrays(first, second []apimodel.CalibrationRead) []apimodel.CalibrationRead {\n\tnewslice := make([]apimodel.CalibrationRead, len(first)+len(second))\n\tcopy(newslice, first)\n\tcopy(newslice[len(first):], second)\n\treturn newslice\n}", "func (t *Dense) doViewStackB(retVal *Dense, axisStride, batches int, ch chan int, others []*Dense, chs []chan int) {\n\tdata := retVal.bools()[:0]\n\tmask := retVal.mask[:0]\n\tif t.IsMasked() {\n\t\tfmt.Println(\"do this\")\n\t}\n\tretIsMasked := t.IsMasked()\n\tfor _, ot := range others {\n\t\tretIsMasked = retIsMasked || ot.IsMasked()\n\t}\n\tfor i := 0; i < batches; i++ {\n\t\tisMasked := t.IsMasked()\n\t\tvar j int\n\t\tfor j = 0; j < axisStride; j++ {\n\t\t\tid, ok := <-ch\n\t\t\tif !ok {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tdata = append(data, t.bools()[id])\n\t\t\tif isMasked {\n\t\t\t\tmask = append(mask, t.mask[id])\n\t\t\t}\n\t\t}\n\t\tif retIsMasked && (!isMasked) {\n\t\t\tmask = append(mask, make([]bool, j)...)\n\t\t}\n\n\t\tvar ot *Dense\n\t\tfor j, ot = range others {\n\t\t\tisMasked = ot.IsMasked()\n\t\t\tvar k int\n\t\t\tfor k = 0; k < axisStride; k++ {\n\t\t\t\tid, ok := <-chs[j]\n\t\t\t\tif !ok {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t\tdata = append(data, ot.bools()[id])\n\t\t\t\tif isMasked {\n\t\t\t\t\tmask = append(mask, ot.mask[id])\n\t\t\t\t}\n\t\t\t}\n\t\t\tif retIsMasked && (!isMasked) {\n\t\t\t\tmask = append(mask, make([]bool, k)...)\n\t\t\t}\n\t\t}\n\t}\n\tretVal.mask = mask\n}", "func (s *BaseAspidaListener) EnterArray(ctx *ArrayContext) {}", "func (self *PhysicsP2) EnableI(args ...interface{}) {\n self.Object.Call(\"enable\", args)\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 programe04() {\n\tx := []int{4, 5, 7, 8, 42}\n\tfmt.Println(x)\n\tx = append(x, 77, 88, 99, 1014)\n\tfmt.Println(x)\n\n\ty := []int{234, 456, 678, 987}\n\tx = append(x, y...)\n\tfmt.Println(x)\n}", "func SetBooleanArrayRegion(env *C.JNIEnv, array C.jbooleanArray, start, l C.jsize, buf *C.jboolean) {\n\tC._GoJniSetBooleanArrayRegion(env, array, start, l, buf)\n}", "func SetBvFromArray(model ModelT, t TermT, a []int32) int32 {\n\tcount := C.uint32_t(len(a))\n\treturn int32(C.yices_model_set_bv_from_array(ymodel(model), C.term_t(t), count, (*C.int32_t)(&a[0])))\n}", "func AppendInts(dst []byte, vals []int) []byte {\n\tmajor := majorTypeArray\n\tl := len(vals)\n\tif l == 0 {\n\t\treturn AppendArrayEnd(AppendArrayStart(dst))\n\t}\n\tif l <= additionalMax {\n\t\tlb := byte(l)\n\t\tdst = append(dst, byte(major|lb))\n\t} else {\n\t\tdst = appendCborTypePrefix(dst, major, uint64(l))\n\t}\n\tfor _, v := range vals {\n\t\tdst = AppendInt(dst, v)\n\t}\n\treturn dst\n}", "func EnableClientState(array uint32) {\n\tC.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\n}", "func TestInstructionLoadMulti(t *testing.T) {\n\tchipCfg := GetDefaultConfig()\n\tchip, _, _ := NewCHIP8(chipCfg)\n\n\t// initialize registers to 0xf0 - 0xff\n\tfor i := 0; i < 16; i++ {\n\t\tchip.Reg[i] = 0xf0 + uint8(i)\n\t}\n\n\tchip.WriteShort(0x200, 0xf555)\n\tchip.WriteShort(0x202, 0xff55)\n\n\tvar tests = []struct {\n\t\tPC uint16\n\t\tTargetAddr uint16\n\t\tValues []uint8\n\t}{\n\t\t{0x202, 0x300, []uint8{\n\t\t\t0xf0,\n\t\t\t0xf1,\n\t\t\t0xf2,\n\t\t\t0xf3,\n\t\t\t0xf4,\n\t\t\t0xf5,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t\t0x00,\n\t\t}},\n\t\t{0x204, 0x400, []uint8{\n\t\t\t0xf0,\n\t\t\t0xf1,\n\t\t\t0xf2,\n\t\t\t0xf3,\n\t\t\t0xf4,\n\t\t\t0xf5,\n\t\t\t0xf6,\n\t\t\t0xf7,\n\t\t\t0xf8,\n\t\t\t0xf9,\n\t\t\t0xfa,\n\t\t\t0xfb,\n\t\t\t0xfc,\n\t\t\t0xfd,\n\t\t\t0xfe,\n\t\t\t0xff,\n\t\t}},\n\t}\n\n\tfor i, want := range tests {\n\t\t// set RegI value\n\t\tchip.RegI = want.TargetAddr\n\n\t\t// step and check state\n\t\tchip.StepEmulation()\n\n\t\tif chip.PC != want.PC {\n\t\t\tt.Errorf(\"test %d: chip.PC = 0x%x; want 0x%x\", i, chip.PC, want.PC)\n\t\t}\n\n\t\tfor j := range want.Values {\n\t\t\tif chip.Memory[chip.RegI+uint16(j)] != want.Values[j] {\n\t\t\t\tt.Errorf(\"test %d: chip.Memory[0x%x + 0x%x] = 0x%x; want 0x%x\", i, chip.RegI, j, chip.Memory[chip.RegI+uint16(j)], want.Values[j])\n\t\t\t}\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 parMerge(a[] int, fst int, snd int, lng int, c chan bool, done chan bool) {\n <- c; <- c\n merge(a, fst, snd, lng)\n done <- true\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 TestInArray(t *testing.T) {\n\tarrays := []InArrayTest{\n\t\t{[]string{\"1\", \"2\", \"3\"}, \"2\", true},\n\t\t{[]string{\"1\", \"2\", \"3\"}, \"4\", false},\n\t}\n\n\tfor i, array := range arrays {\n\t\tif !reflect.DeepEqual(array.Result, InArray(array.Arrays, array.Value)) {\n\t\t\tt.Errorf(\"InArray(%v) failed: expected %v got %v\", i, array.Result, !array.Result)\n\t\t}\n\t}\n}", "func (e *engine) EncryptSlices(dst []byte, src ...[]byte) error {\n\tif len(dst) < e.CiphertextSizeSlices(src...) {\n\t\treturn fmt.Errorf(\"dst is too small, size it using CiphertextSizeSlices()\")\n\t}\n\tbuf, hmacSum, stream, err := e.setup(dst)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfor _, s := range src {\n\t\thmacSum.Write(s)\n\t}\n\tstream.XORKeyStream(buf, hmacSum.Sum(nil))\n\tbuf = buf[e.reg.HMACSize():]\n\tfor _, s := range src {\n\t\tstream.XORKeyStream(buf, s)\n\t\tbuf = buf[len(s):]\n\t}\n\treturn nil\n}", "func unionWithInit(b *testing.B) {\n\tif unionIntSet64Data1 == nil {\n\t\tunionIntSet64Data1, unionIntSet32Data1, unionIntMapData1 = generateSets(*max_range, *count)\n\t\tunionIntSet64Data2, unionIntSet32Data2, unionIntMapData2 = generateSets(*max_range, *count)\n\t\tb.ResetTimer()\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 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 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 GenVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpGenVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func (_m *ControllerInterface) UpdateArrays(_a0 string, _a1 fs.Interface) error {\n\tret := _m.Called(_a0, _a1)\n\n\tvar r0 error\n\tif rf, ok := ret.Get(0).(func(string, fs.Interface) error); ok {\n\t\tr0 = rf(_a0, _a1)\n\t} else {\n\t\tr0 = ret.Error(0)\n\t}\n\n\treturn r0\n}", "func init() {\n\tf := GeneralMatrices\n\tfor level := 0; level < 2; level++ {\n\t\tmf := MutateFixtures(f, f)\n\t\tf = append(f, mf...)\n\t}\n\tTestFixtures = f\n\n}", "func TestArrayFlag(t *testing.T) {\n\tp := &Srcs\n\tassert.Equal(t, \"\", p.String())\n\n\tmsg.OnErr(p.Set(\"ab\"))\n\tmsg.OnErr(p.Set(\"xyz\"))\n\taf := arrayFlag([]string{\"ab\", \"xyz\"})\n\t//assert.Equal(t, af, Srcs) // this succeeds as singe test but fails as package test for some reason.\n\tassert.Equal(t, af.String(), Srcs.String())\n}", "func BenchmarkUnionSet32(b *testing.B) {\n\tunionWithInit(b)\n\tfor n := 0; n < b.N; n++ {\n\t\tb.StopTimer()\n\t\tdata := unionIntSet32Data1.Dup()\n\t\tb.StartTimer()\n\t\tdata.UnionWith(unionIntSet32Data2)\n\t}\n}", "func processArray(name string, arr []interface{}, nm proto.Message) (reflect.Value, *adapter.ConfigErrors) {\n\tvar ce *adapter.ConfigErrors\n\tptrType := reflect.TypeOf(nm)\n\tvalType := reflect.Indirect(reflect.ValueOf(nm)).Type()\n\toutarr := reflect.MakeSlice(reflect.SliceOf(ptrType), 0, len(arr))\n\tfor idx, attr := range arr {\n\t\tdm := reflect.New(valType).Interface().(proto.Message)\n\n\t\tif cerr := updateMsg(fmt.Sprintf(\"%s[%d]\", name, idx), attr, dm, nm, false); cerr != nil {\n\t\t\tce = ce.Extend(cerr)\n\t\t\tcontinue\n\t\t}\n\n\t\toutarr = reflect.Append(outarr, reflect.ValueOf(dm))\n\t}\n\treturn outarr, ce\n}", "func (a *Alu) Init(dataBus *common.Bus, width int) {\n\ta.dataBus = dataBus\n\ta.width = width\n\tfor i := 0; i < width; i++ {\n\t\ta.mask = a.mask << 1\n\t\ta.mask = a.mask | 1\n\t}\n\ta.aluCore.Init(dataBus, width)\n\ta.accumulator.Init(dataBus, width, \"ACC=\")\n\ta.tempRegister.Init(dataBus, width, \"Temp=\")\n\ta.flagRegister.Init(dataBus, width, \"Flags=\")\n\ta.updateFlags()\n}", "func (cpu *CPU) SetRegs(regs [16]uint16) {\r\n\tfor i, v := range(regs) {\r\n\t\tcpu.regs[i] = v\r\n\t}\r\n}", "func (f *FlagSet) SetInterspersed(interspersed bool) {\n\tf.interspersed = interspersed\n}", "func extendIncludes(m *[]Includes, ext []Includes) {\n\tif ext != nil {\n\t\tif *m == nil {\n\t\t\t*m = []Includes{}\n\t\t}\n\t\t*m = append(*m, ext...)\n\t}\n}", "func DrawArraysIndirect(mode uint32, indirect unsafe.Pointer) {\n C.glowDrawArraysIndirect(gpDrawArraysIndirect, (C.GLenum)(mode), indirect)\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 (f genHelperEncoder) EncWriteArrayStart(length int) { f.e.arrayStart(length) }", "func core(out []u8, in []u8, k []u8, c []u8, h bool) {\n\tvar w [16]u32\n\tvar x [16]u32\n\tvar y [16]u32\n\tvar t [4]u32\n\n\tvar i, j, m int\n\n\tfor i = 0; i < 4; i++ {\n\t\tx[5*i] = ld32(c[4*i:])\n\t\tx[1+i] = ld32(k[4*i:])\n\t\tx[6+i] = ld32(in[4*i:])\n\t\tx[11+i] = ld32(k[16+4*i:])\n\t}\n\tfor i = 0; i < 16; i++ {\n\t\ty[i] = x[i]\n\t}\n\n\tfor i = 0; i < 20; i++ {\n\t\tfor j = 0; j < 4; j++ {\n\t\t\tfor m = 0; m < 4; m++ {\n\t\t\t\tt[m] = x[(5*j+4*m)%16]\n\t\t\t}\n\t\t\tt[1] ^= L32(t[0]+t[3], 7)\n\t\t\tt[2] ^= L32(t[1]+t[0], 9)\n\t\t\tt[3] ^= L32(t[2]+t[1], 13)\n\t\t\tt[0] ^= L32(t[3]+t[2], 18)\n\t\t\tfor m = 0; m < 4; m++ {\n\t\t\t\tw[4*j+(j+m)%4] = t[m]\n\t\t\t}\n\t\t}\n\t\tfor m = 0; m < 16; m++ {\n\t\t\tx[m] = w[m]\n\t\t}\n\t}\n\n\tif h {\n\t\tfor i = 0; i < 16; i++ {\n\t\t\tx[i] += y[i]\n\t\t}\n\t\tfor i = 0; i < 4; i++ {\n\t\t\tx[5*i] -= ld32(c[4*i:])\n\t\t\tx[6+i] -= ld32(in[4*i:])\n\t\t}\n\t\tfor i = 0; i < 4; i++ {\n\t\t\tst32(out[4*i:], x[5*i])\n\t\t\tst32(out[16+4*i:], x[6+i])\n\t\t}\n\t} else {\n\t\tfor i = 0; i < 16; i++ {\n\t\t\tst32(out[4*i:], x[i]+y[i])\n\t\t}\n\t}\n}", "func AppendInts16(dst []byte, vals []int16) []byte {\n\tmajor := majorTypeArray\n\tl := len(vals)\n\tif l == 0 {\n\t\treturn AppendArrayEnd(AppendArrayStart(dst))\n\t}\n\tif l <= additionalMax {\n\t\tlb := byte(l)\n\t\tdst = append(dst, byte(major|lb))\n\t} else {\n\t\tdst = appendCborTypePrefix(dst, major, uint64(l))\n\t}\n\tfor _, v := range vals {\n\t\tdst = AppendInt(dst, int(v))\n\t}\n\treturn dst\n}", "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tsyscall.Syscall(gpEnableVertexArrayAttrib, 2, uintptr(vaobj), uintptr(index), 0)\n}", "func setSprites(sprites []image.Image, imageSlice []image.Image, values []int) (bool, error, []image.Image) {\n\n\tfor _, value := range values {\n\t\tif value >= len(sprites) {\n\t\t\treturn false, errors.New(\"Index is to big\"), imageSlice\n\t\t}\n\n\t\timageSlice = append(imageSlice, sprites[value])\n\t}\n\n\treturn true, nil, imageSlice\n}", "func (_DevUtils *DevUtilsCaller) EncodeMultiAssetData(opts *bind.CallOpts, amounts []*big.Int, nestedAssetData [][]byte) ([]byte, error) {\n\tvar (\n\t\tret0 = new([]byte)\n\t)\n\tout := ret0\n\terr := _DevUtils.contract.Call(opts, out, \"encodeMultiAssetData\", amounts, nestedAssetData)\n\treturn *ret0, err\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 mergeExerciseArrays(first, second []apimodel.Exercise) []apimodel.Exercise {\n\tnewslice := make([]apimodel.Exercise, len(first)+len(second))\n\tcopy(newslice, first)\n\tcopy(newslice[len(first):], second)\n\treturn newslice\n}", "func AppendInts32(dst []byte, vals []int32) []byte {\n\tmajor := majorTypeArray\n\tl := len(vals)\n\tif l == 0 {\n\t\treturn AppendArrayEnd(AppendArrayStart(dst))\n\t}\n\tif l <= additionalMax {\n\t\tlb := byte(l)\n\t\tdst = append(dst, byte(major|lb))\n\t} else {\n\t\tdst = appendCborTypePrefix(dst, major, uint64(l))\n\t}\n\tfor _, v := range vals {\n\t\tdst = AppendInt(dst, int(v))\n\t}\n\treturn dst\n}", "func (f genHelperEncoder) EncWriteArrayElem() { f.e.arrayElem() }", "func (arr *FloatArray) Concat(arrays ...[]float64) {\n\tif len(arrays) == 0 {\n\t\treturn\n\t}\n\n\tfor _, a := range arrays {\n\t\t*arr = append(*arr, a...)\n\t}\n}", "func AppendBools(dst []byte, vals []bool) []byte {\n\tmajor := majorTypeArray\n\tl := len(vals)\n\tif l == 0 {\n\t\treturn AppendArrayEnd(AppendArrayStart(dst))\n\t}\n\tif l <= additionalMax {\n\t\tlb := byte(l)\n\t\tdst = append(dst, byte(major|lb))\n\t} else {\n\t\tdst = appendCborTypePrefix(dst, major, uint64(l))\n\t}\n\tfor _, v := range vals {\n\t\tdst = AppendBool(dst, v)\n\t}\n\treturn dst\n}", "func andSimdSubtask(dst, src []byte, nIter int) int {\n\tfor iter := 0; iter < nIter; iter++ {\n\t\tsimd.AndInplace(dst, src)\n\t}\n\treturn int(dst[0])\n}", "func (s *Swarm) setupInterfaces(addrs []ma.Multiaddr) error {\n\terrs := make([]error, len(addrs))\n\tvar succeeded int\n\tfor i, a := range addrs {\n\t\tif err := s.AddListenAddr(a); err != nil {\n\t\t\terrs[i] = err\n\t\t} else {\n\t\t\tsucceeded++\n\t\t}\n\t}\n\n\tfor i, e := range errs {\n\t\tif e != nil {\n\t\t\tlog.Warningf(\"listen on %s failed: %s\", addrs[i], errs[i])\n\t\t}\n\t}\n\n\tif succeeded == 0 && len(addrs) > 0 {\n\t\treturn fmt.Errorf(\"failed to listen on any addresses: %s\", errs)\n\t}\n\n\treturn nil\n}", "func InitByArray64(key ...uint64) {\n\tC.init_by_array64((*C.ulonglong)(&key[0]), C.ulonglong(len(key)))\n}", "func AndInplace(main, arg []byte) {\n\t// This takes ~6-8% longer than AndUnsafeInplace on the short-array benchmark\n\t// on my Mac.\n\tmainLen := len(main)\n\tif len(arg) != mainLen {\n\t\tpanic(\"AndInplace() requires len(arg) == len(main).\")\n\t}\n\tif mainLen < BytesPerWord {\n\t\t// It's probably possible to do better here (e.g. when mainLen is in 4..7,\n\t\t// operate on uint32s), but I won't worry about it unless/until that's\n\t\t// actually a common case.\n\t\tfor pos, argByte := range arg {\n\t\t\tmain[pos] = main[pos] & argByte\n\t\t}\n\t\treturn\n\t}\n\targData := unsafe.Pointer((*reflect.SliceHeader)(unsafe.Pointer(&arg)).Data)\n\tmainData := unsafe.Pointer((*reflect.SliceHeader)(unsafe.Pointer(&main)).Data)\n\targWordsIter := argData\n\tmainWordsIter := mainData\n\tif mainLen > 2*BytesPerWord {\n\t\tnWordMinus2 := (mainLen - BytesPerWord - 1) >> Log2BytesPerWord\n\t\tfor widx := 0; widx < nWordMinus2; widx++ {\n\t\t\tmainWord := *((*uintptr)(mainWordsIter))\n\t\t\targWord := *((*uintptr)(argWordsIter))\n\t\t\t*((*uintptr)(mainWordsIter)) = mainWord & argWord\n\t\t\tmainWordsIter = unsafe.Add(mainWordsIter, BytesPerWord)\n\t\t\targWordsIter = unsafe.Add(argWordsIter, BytesPerWord)\n\t\t}\n\t}\n\tmainWord1 := *((*uintptr)(mainWordsIter))\n\targWord1 := *((*uintptr)(argWordsIter))\n\tfinalOffset := uintptr(mainLen - BytesPerWord)\n\tmainFinalWordPtr := unsafe.Add(mainData, finalOffset)\n\targFinalWordPtr := unsafe.Add(argData, finalOffset)\n\tmainWord2 := *((*uintptr)(mainFinalWordPtr))\n\targWord2 := *((*uintptr)(argFinalWordPtr))\n\t*((*uintptr)(mainWordsIter)) = mainWord1 & argWord1\n\t*((*uintptr)(mainFinalWordPtr)) = mainWord2 & argWord2\n}", "func encodeArray(d *tree.DArray, scratch []byte) ([]byte, error) {\n\tif err := d.Validate(); err != nil {\n\t\treturn scratch, err\n\t}\n\tscratch = scratch[0:0]\n\telementType, err := DatumTypeToArrayElementEncodingType(d.ParamTyp)\n\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\theader := arrayHeader{\n\t\thasNulls: d.HasNulls,\n\t\t// TODO(justin): support multiple dimensions.\n\t\tnumDimensions: 1,\n\t\telementType: elementType,\n\t\tlength: uint64(d.Len()),\n\t\t// We don't encode the NULL bitmap in this function because we do it in lockstep with the\n\t\t// main data.\n\t}\n\tscratch, err = encodeArrayHeader(header, scratch)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tnullBitmapStart := len(scratch)\n\tif d.HasNulls {\n\t\tfor i := 0; i < numBytesInBitArray(d.Len()); i++ {\n\t\t\tscratch = append(scratch, 0)\n\t\t}\n\t}\n\tfor i, e := range d.Array {\n\t\tvar err error\n\t\tif d.HasNulls && e == tree.DNull {\n\t\t\tsetBit(scratch[nullBitmapStart:], i)\n\t\t} else {\n\t\t\tscratch, err = encodeArrayElement(scratch, e)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\t\t}\n\t}\n\treturn scratch, nil\n}", "func zSameAtNonstrided(x, y []complex128, inc int) bool {\n\tif len(x) != len(y) {\n\t\treturn false\n\t}\n\tif inc < 0 {\n\t\tinc = -inc\n\t}\n\tfor i, v := range x {\n\t\tif i%inc == 0 {\n\t\t\tcontinue\n\t\t}\n\t\tw := y[i]\n\t\tif !sameComplex128(v, w) {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func (e *Encoder) encodeArray(v Array) error {\n\t// Special case for a nil array\n\tif v == nil {\n\t\treturn e.encodePrefixed('*', \"-1\")\n\t}\n\n\t// First encode the number of elements\n\tn := len(v)\n\tif err := e.encodePrefixed('*', strconv.Itoa(n)); err != nil {\n\t\treturn err\n\t}\n\n\t// Then encode each value\n\tfor _, el := range v {\n\t\tif err := e.encodeValue(el); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func init() {\n\tfor i, _ := range fullArray {\n\t\tfullArray = append(fullArray, i)\n\t}\n}", "func EnableInterrupts(mask uintptr) {\n\tmask &= 1 << 3 // clear all bits except for the MIE bit\n\tMSTATUS.SetBits(mask) // set the MIE bit, if it was previously cleared\n}", "func TestInArray(t *testing.T) {\n\ttype args struct {\n\t\ttarget interface{}\n\t\tarr interface{}\n\t}\n\ttests := []struct {\n\t\tname string\n\t\targs args\n\t\twant bool\n\t}{\n\t\t{\n\t\t\tname: \"test-true\",\n\t\t\targs: args{\n\t\t\t\ttarget: int64(7),\n\t\t\t\tarr: []int64{1, 3, 5, 7},\n\t\t\t},\n\t\t\twant: true,\n\t\t},\n\t\t{\n\t\t\tname: \"test-false\",\n\t\t\targs: args{\n\t\t\t\ttarget: int64(10),\n\t\t\t\tarr: []int64{1, 3, 5, 7},\n\t\t\t},\n\t\t\twant: false,\n\t\t},\n\t\t{\n\t\t\tname: \"test-string\",\n\t\t\targs: args{\n\t\t\t\ttarget: \"blue\",\n\t\t\t\tarr: []string{\"red\", \"orange\", \"yellow\", \"green\", \"blue\"},\n\t\t\t},\n\t\t\twant: true,\n\t\t},\n\t\t{\n\t\t\tname: \"test-empty\",\n\t\t\targs: args{\n\t\t\t\ttarget: \"blue\",\n\t\t\t\tarr: []string{},\n\t\t\t},\n\t\t\twant: false,\n\t\t},\n\t\t{\n\t\t\tname: \"test-err-type\",\n\t\t\targs: args{\n\t\t\t\ttarget: \"blue\",\n\t\t\t\tarr: []int64{1, 2, 3, 4},\n\t\t\t},\n\t\t\twant: false,\n\t\t},\n\t}\n\tfor _, tt := range tests {\n\t\tt.Run(tt.name, func(t *testing.T) {\n\t\t\tif got := InArray(tt.args.target, tt.args.arr); got != tt.want {\n\t\t\t\tt.Errorf(\"In() = %v, want %v\", got, tt.want)\n\t\t\t}\n\t\t})\n\t}\n}", "func orIdentity(a *bmatrix) {\n\tfor i := 0; i < n; i++ {\n\t\ta[i][i] = true\n\t}\n}", "func (a *aluCore) Init(dataBus *common.Bus, width int) {\n\ta.dataBus = dataBus\n\ta.width = width\n\tfor i := 0; i < width; i++ {\n\t\ta.mask = a.mask << 1\n\t\ta.mask = a.mask | 1\n\t}\n\ta.carryMask = 1 << uint64(width)\n\ta.outputReg.Init(dataBus, width, \"ALU=\")\n\ta.mode = AluNone\n\ta.changed = true // force a render\n}", "func TestPrewriteMultiple4A(t *testing.T) {\n}" ]
[ "0.6432597", "0.6319476", "0.56165224", "0.5566762", "0.5539364", "0.5323958", "0.5323958", "0.502087", "0.4990113", "0.49731818", "0.49213466", "0.49189755", "0.48950323", "0.48914087", "0.4859467", "0.4848276", "0.4848276", "0.47889075", "0.47889075", "0.46759585", "0.46665648", "0.46497902", "0.46202824", "0.4613735", "0.45915207", "0.4564725", "0.4559895", "0.45408034", "0.45079574", "0.45068988", "0.4489661", "0.44601512", "0.44483358", "0.4445918", "0.44449443", "0.44449443", "0.4442997", "0.44331548", "0.44305637", "0.44138497", "0.44120464", "0.4398839", "0.43970245", "0.43764678", "0.4358815", "0.43533695", "0.43224412", "0.43204066", "0.43115228", "0.43050998", "0.4297991", "0.4291608", "0.42883524", "0.4282803", "0.42800403", "0.42789373", "0.42604548", "0.4257365", "0.42523333", "0.42385283", "0.42385283", "0.42377174", "0.42231897", "0.4208866", "0.42017135", "0.4195598", "0.41933003", "0.4186138", "0.4167727", "0.41627827", "0.41622645", "0.41620862", "0.41449124", "0.41433942", "0.41401413", "0.41398978", "0.41343468", "0.4122683", "0.41217026", "0.41198838", "0.41196516", "0.41128698", "0.41101995", "0.41087902", "0.4100932", "0.40979198", "0.40969077", "0.409344", "0.40911782", "0.4089179", "0.40884277", "0.40877014", "0.4073474", "0.4072019", "0.40694028", "0.40645507", "0.40635145", "0.40607607", "0.40590763", "0.4056924" ]
0.6322441
1
invalidate the content of a buffer object's data store
func InvalidateBufferData(buffer uint32) { C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 0, 0)\n}", "func (e *ObservableEditableBuffer) ResetBuffer() {\n\te.filtertagobservers = false\n\te.seq = 0\n\te.f = NewTypeBuffer([]rune{}, e)\n}", "func (speech *SpeechSync) ClearBuffer() {\n\tspeech.dataInfo.ClearBuffer()\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func UConverterFlushCache() (_swig_ret int)", "func (b *Buffer) flushCache() {\n\tif b.cdirty || len(b.c) == 0 {\n\t\tif len(b.c) == 0 {\n\t\t\tb.deleteBlock(b.cbi)\n\t\t} else {\n\t\t\tdisk.write(&b.bl[b.cbi], b.c)\n\t\t}\n\t\tb.cdirty = false\n\t}\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (s *ss) free(old ssave) {\n\t// If it was used recursively, just restore the old state.\n\tif old.validSave {\n\t\ts.ssave = old\n\t\treturn\n\t}\n\t// Don't hold on to ss structs with large buffers.\n\tif cap(s.buf) > 1024 {\n\t\treturn\n\t}\n\ts.buf = s.buf[:0]\n\ts.rs = nil\n\tssFree.Put(s)\n}", "func freeBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpInvalidateBufferSubData, 3, uintptr(buffer), uintptr(offset), uintptr(length))\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 *BaseNode) invalidateCache() {\n\tb.bytesValid = false\n\tb.hashValid = false\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 (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (ms *sender) invalidate() {\n\tms.invalid = true\n\tif ms.stream != nil {\n\t\tms.stream.Reset()\n\t\tms.stream = nil\n\t}\n}", "func (c *AdapterMemory) Clear(ctx context.Context) error {\n\treturn c.data.Clear()\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\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 (b *Buffer) Reset() {\n\tb.buf = b.buf[:0]\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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (pool *BufferPool) Recycle(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tselect {\n\tcase pool.Buffers <- buf:\n\tdefault:\n\t\t// let it go, let it go...\n\t}\n}", "func (buffer *Buffer) Reset() {\n\tbuffer.B.Reset()\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 (b *Buffer) reload() error {\n\tstat, err := os.Stat(b.filename)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfsize := uint64(stat.Size())\n\tb.capacity = fsize - metadata\n\n\tf, err := os.OpenFile(b.filename, os.O_RDWR, 0600)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tdata, err := syscall.Mmap(\n\t\tint(f.Fd()), 0, int(fsize),\n\t\tsyscall.PROT_READ|syscall.PROT_WRITE, syscall.MAP_SHARED,\n\t)\n\tif err != nil {\n\t\treturn err\n\t}\n\tb.data = data\n\n\toff := int(b.capacity)\n\tb.first = binary.GetLittleEndianUint64(b.data, off)\n\tb.last = binary.GetLittleEndianUint64(b.data, off+8)\n\tb.nextSeq = binary.GetLittleEndianUint64(b.data, off+16)\n\tb.biggest = binary.GetLittleEndianUint32(b.data, off+24)\n\tb.length = binary.GetLittleEndianUint64(b.data, off+28)\n\n\treturn nil\n}", "func (m *MsgBuffer) Reset() {\n\tm.Buffer.Reset()\n\tm.bs = m.bs[:0]\n\tm.err = nil\n}", "func (b *Buf) Reset() { b.b = b.b[:0] }", "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 (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\n}", "func (d *adapterMemoryData) Clear() error {\n\td.mu.Lock()\n\tdefer d.mu.Unlock()\n\td.data = make(map[interface{}]adapterMemoryItem)\n\treturn nil\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (b *baseKVStoreBatch) Clear() {\n\tb.mutex.Lock()\n\tdefer b.mutex.Unlock()\n\tb.writeQueue = nil\n}", "func (b *Buffer) Reset() {\n\tb.B = b.B[:0]\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\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 (c *cache) clear() {\n\tc.cursor = 0\n\tc.chunks = make(map[FileID]location)\n\tc.sums = c.sums[:0]\n}", "func (it iterator) clear(b *ringBuf) {\n\tb.buf[it] = raftpb.Entry{}\n}", "func (b *Buffer) Flush() error {\n\t// upload vertice + meta to opengl\n\tGlBindBuffer(ARRAY_BUFFER, b.GlBuffer)\n\tErrPanic()\n\tif len(b.Buf) == 0 {\n\t\treturn nil\n\t}\n\tGlBufferData(ARRAY_BUFFER, b.Buf, STATIC_DRAW)\n\tErrPanic()\n\t// FIXME: rebind shader attrs\n\tb.BufLen = len(b.Buf)\n\tb.Buf = b.Buf[:0]\n\treturn nil\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 (s *safeBuffer) Reset() {\n\ts.Lock()\n\ts.buf.Reset()\n\ts.Unlock()\n}", "func (spriteBatch *SpriteBatch) flush() {\n\tspriteBatch.arrayBuf.bufferData()\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 (tb *TransactionBuffer) Clear() {\n\ttb.mux.Lock()\n\ttb.Buffer = make([]TxPublish, 0)\n\ttb.mux.Unlock()\n}", "func (s *Store) Flush() {\n\ts.data.Reset()\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 (s *MemStore) Flush() error {\n\ts.lock.Lock()\n\tdefer s.lock.Unlock()\n\n\ts.data = make(map[interface{}]interface{})\n\treturn nil\n}", "func (b *BufferPool) Flush(interface{}) {\n\tb.Lock()\n\tb.Data = make([]byte, b.Size)\n\tb.Unlock()\n}", "func (b *ByteBuffer) Reset(buf []byte) {\n\tb.buf = buf\n\tb.off = 0\n}", "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 (b *Buffer) Reset() {\n\tb.Line = b.Line[:0]\n\tb.Val = b.Val[:0]\n}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (p *Buffer) Reset() {\n\tp.buf = p.buf[0:0] // for reading/writing\n\tp.index = 0 // for reading\n\tp.err = nil\n\tp.array_indexes = nil\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 (s *Store) Reset() {\n\ts.access.Lock()\n\tdefer s.access.Unlock()\n\n\tfor key, _ := range s.data {\n\t\tdelete(s.data, key)\n\t\ts.sendDataChanged()\n\t\ts.doKeyChanged(key)\n\t}\n\n\ts.data = make(map[string]interface{})\n}", "func (c *memoryCache) Del(key string) {\n\tdelete(c.data, key)\n}", "func (p *Buffer) Rewind() {\n\tp.index = 0\n}", "func (b *ByteBuffer) Reset() {\n\tb.B = b.B[:0]\n}", "func (b *Buffer) Reset() {\n\tb.B = b.arena\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 (e *entry) clear() {\n\te.CachedData = CachedData{}\n}", "func (b *Buffer) Reset() {\n\tb.mux.Lock()\n\tdefer b.mux.Unlock()\n\n\tb.data = make([]byte, len(b.data))\n\tb.dataSize = 0\n\tb.head, b.tail = 0, 0\n}", "func (b *Buffer) Reset() {\n\tif len(b.bufs) > 0 {\n\t\tb.curBuf = b.bufs[0]\n\t\tb.curBufLen = len(b.bufs[0])\n\t\tb.curBufIdx = 0\n\t\tb.curIdx = 0\n\t}\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 (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func (s *Storage) Free(pooled []byte) {\n\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 ClearCommitBuffer() {\n\tvar commitBuffer RootCommitBuffer\n\tcWarning := color.New(color.FgYellow).SprintFunc()\n\n\tbufferFile, err := os.Open(SilkRoot() + \"/\" + RootDirectoryName + \"/commit/buffer\")\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to open commit buffer file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\tdefer bufferFile.Close()\n\n\t// Remove all bufferFile.Changes()\n\tbyteValue, err := ioutil.ReadAll(bufferFile)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to read buffer file byte values\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\terr = json.Unmarshal(byteValue, &commitBuffer)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to create latest commit file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\tcommitBuffer.Changes = []FileChange{}\n\n\tcommitBufferJSON, err := json.MarshalIndent(commitBuffer, \" \", \"\")\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to marshal json to commit buffer\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\terr = ioutil.WriteFile(SilkRoot()+\"/.silk/commit/buffer\", []byte(string(commitBufferJSON)+\"\\n\"), 0766)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to write to commit buffer file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n}", "func (c *Driver) Invalidate(cacheName string, key interface{}) error {\n\tk := cachery.Key(key)\n\terr := c.inmemory.Invalidate(cacheName, k)\n\tif err != nil {\n\t\treturn err\n\t}\n\tmsg := message{\n\t\tSender: c.id,\n\t\tCommand: \"Invalidate\",\n\t\tCacheName: cacheName,\n\t\tKey: cachery.Key(k),\n\t}\n\treturn c.send(msg)\n}", "func (r *bufferingReaderAt) recycleBuf(b []byte) {\n\tif cap(b) != r.blockSize {\n\t\tpanic(\"trying to return a buffer not initially requested via grabBuf\")\n\t}\n\tif len(r.pool)+1 > cap(r.pool) {\n\t\tpanic(\"unexpected growth of byte buffer pool beyond capacity\")\n\t}\n\tr.pool = append(r.pool, b[:cap(b)])\n}", "func (f *FileRotator) flushBuffer() error {\n\tf.bufLock.Lock()\n\tdefer f.bufLock.Unlock()\n\tif f.bufw != nil {\n\t\treturn f.bufw.Flush()\n\t}\n\treturn nil\n}", "func (b *ChangeBuffer) emptyBuffer() {\n\tlast := b.Back()\n\tfor last != nil {\n\t\tif last.Prev() != nil {\n\t\t\tlast = last.Prev()\n\t\t\tb.Remove(last.Next())\n\t\t} else {\n\t\t\tb.Remove(last)\n\t\t\tlast = nil\n\t\t}\n\t}\n}", "func (c *Chunk) Clear() {\n\tc.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 (stmt *statement) Invalidate() {\n\tif stmt.sql != nil {\n\t\tputBuffer(stmt.sql)\n\t\tstmt.sql = nil\n\t}\n}", "func (bb *ByteBuffer) Reset() {\n\tbb.B = bb.B[:0]\n}", "func (buf *Buffer) ACK(leased *Batch) {\n\tbuf.removeLease(leased)\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 (b *Buffer) Reset() {\n\tb.start = 0\n\tb.used = 0\n}", "func (b *batch) Reset() {\n\tb.batch.Clear()\n\tb.size = 0\n}", "func (buf *Buffer) Flush(now time.Time) {\n\tbatch := buf.currentBatch\n\tif batch == nil {\n\t\treturn\n\t}\n\n\tbatch.nextSend = now // immediately make available to send\n\tbuf.unleased.PushBatch(batch)\n\tbuf.batchItemsGuess.record(batch.countedItems)\n\tbuf.currentBatch = nil\n\treturn\n}", "func (s *StreamPack) Flush() {\n\ts.Buffer.Clear()\n}", "func (m *Marshaler) reset() {\n\tm.b = m.b[:0]\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 (batch *Batch) Clear() {\n\tbatch.mutex.Lock()\n\tdefer batch.mutex.Unlock()\n\tbatch.messages = batch.messages[0:0]\n}", "func (b *batch) Reset() {\n\tb.writes = b.writes[:0]\n\tb.size = 0\n}", "func (c *AdapterMemory) clearByKey(key interface{}, force ...bool) {\n\t// Doubly check before really deleting it from cache.\n\tc.data.DeleteWithDoubleCheck(key, force...)\n\n\t// Deleting its expiration time from `expireTimes`.\n\tc.expireTimes.Delete(key)\n\n\t// Deleting it from LRU.\n\tif c.cap > 0 {\n\t\tc.lru.Remove(key)\n\t}\n}", "func (ms *MemoizeSigner) evictFromMemory() {\n\tfor dig := range ms.memory {\n\t\tdelete(ms.memory, dig)\n\t\treturn\n\t}\n}", "func (e *ObservableEditableBuffer) Set(hash []byte) {\n\te.details.Hash.Set(hash)\n}", "func CleanActionBuffer(){\n\tActionBuffer=nil //throw to garbage collector\n\tInitiateActionBuffer()\n}", "func (_this *StreamingReadBuffer) Reset() {\n\t_this.reader = nil\n\t_this.Buffer = _this.Buffer[:0]\n\t_this.minFreeBytes = 0\n\t_this.isEOF = false\n}", "func (c *doubleCacheBuffer[T]) evict(newTs uint64) {\n\tc.tail = c.head\n\tc.head = newDoubleCacheItem[T](newTs, c.maxSize/2)\n\tc.ts = c.tail.headTs\n}", "func (pb *PacketBuffer) Clear() {\n\tpb.numPackets = 0\n\tpb.offsets[0] = 0\n}", "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 *baseKVStoreBatch) Clear() {\n\tb.mutex.Lock()\n\tdefer b.mutex.Unlock()\n\tb.writeQueue = nil\n\n\tb.fillLock.Lock()\n\tdefer b.fillLock.Unlock()\n\tfor k := range b.fill {\n\t\tdelete(b.fill, k)\n\t}\n}", "func (self Source) UnqueueBuffer() Buffer {\n\treturn Buffer(C.walSourceUnqueueBuffer(C.ALuint(self)))\n}", "func PutBuffer(b *Buffer) {\n\tif b.Len() >= cachedBufferMaxSize {\n\t\t// Let big buffers die a natural death.\n\t\treturn\n\t}\n\tfreeListMu.Lock()\n\t// If buffer pool is full, let the buffer die a natural death.\n\tif freeListLen < maxFreeCount {\n\t\tb.next = freeList\n\t\tfreeList = b\n\t}\n\tfreeListMu.Unlock()\n}" ]
[ "0.6431159", "0.62961084", "0.6214611", "0.61872774", "0.6114385", "0.6106263", "0.6093866", "0.60401905", "0.59512293", "0.5912671", "0.58981407", "0.5887128", "0.5853619", "0.5850525", "0.5794216", "0.57595456", "0.5751458", "0.57296103", "0.5715251", "0.5701097", "0.56517917", "0.56343323", "0.5612532", "0.55552936", "0.5545044", "0.5532713", "0.55216193", "0.55094546", "0.5504976", "0.5478589", "0.5450228", "0.54467154", "0.5439259", "0.5439259", "0.5438344", "0.54334855", "0.54279125", "0.54278797", "0.5425371", "0.54213625", "0.54169595", "0.5403962", "0.53969", "0.5395114", "0.5393567", "0.5387954", "0.5385311", "0.53720206", "0.536653", "0.536447", "0.5334079", "0.53309166", "0.5327573", "0.5314164", "0.53054196", "0.53029567", "0.5301525", "0.5301524", "0.5284695", "0.5283469", "0.52773255", "0.52745837", "0.52702737", "0.52517414", "0.52476466", "0.52471924", "0.52443016", "0.52433366", "0.5238507", "0.52336663", "0.5218388", "0.52101046", "0.5209452", "0.52084386", "0.520691", "0.52065974", "0.5196879", "0.5193616", "0.51866454", "0.51859415", "0.51855934", "0.5181924", "0.51818496", "0.51773316", "0.51720196", "0.51498", "0.51388836", "0.5126339", "0.5124241", "0.5123942", "0.5118143", "0.51160043", "0.5115413", "0.51151824", "0.51019055", "0.5099999", "0.5093179", "0.5086208", "0.50838405" ]
0.58708185
13
invalidate a region of a buffer object's data store
func InvalidateBufferSubData(buffer uint32, offset int, length int) { C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 0, 0)\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpInvalidateBufferSubData, 3, uintptr(buffer), uintptr(offset), uintptr(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (s *ss) free(old ssave) {\n\t// If it was used recursively, just restore the old state.\n\tif old.validSave {\n\t\ts.ssave = old\n\t\treturn\n\t}\n\t// Don't hold on to ss structs with large buffers.\n\tif cap(s.buf) > 1024 {\n\t\treturn\n\t}\n\ts.buf = s.buf[:0]\n\ts.rs = nil\n\tssFree.Put(s)\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 (e *ObservableEditableBuffer) ResetBuffer() {\n\te.filtertagobservers = false\n\te.seq = 0\n\te.f = NewTypeBuffer([]rune{}, e)\n}", "func (m *dirtySeriesMap) Reallocate() {\n\tif m.initialSize > 0 {\n\t\tm.lookup = make(map[dirtySeriesMapHash]dirtySeriesMapEntry, m.initialSize)\n\t} else {\n\t\tm.lookup = make(map[dirtySeriesMapHash]dirtySeriesMapEntry)\n\t}\n}", "func (b *buffer) unpin(loc Location) {\n\tatomic.StorePointer(b.index(loc.index()), nil)\n\tatomic.AddUint32(&b.free, 1)\n}", "func freeBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (b *block) invalidate(p spi.PointSPI) {\n\tfor _, d := range b.points {\n\t\tif sfp := d.scaleFactor; sfp != nil {\n\t\t\tif sfp.Id() == p.Id() {\n\t\t\t\td.SetValue(nil)\n\t\t\t}\n\t\t}\n\t}\n}", "func (p *Buffer) Rewind() {\n\tp.index = 0\n}", "func UConverterFlushCache() (_swig_ret int)", "func (b *BaseNode) invalidateCache() {\n\tb.bytesValid = false\n\tb.hashValid = false\n}", "func (speech *SpeechSync) ClearBuffer() {\n\tspeech.dataInfo.ClearBuffer()\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (b *Buffer) reload() error {\n\tstat, err := os.Stat(b.filename)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfsize := uint64(stat.Size())\n\tb.capacity = fsize - metadata\n\n\tf, err := os.OpenFile(b.filename, os.O_RDWR, 0600)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tdata, err := syscall.Mmap(\n\t\tint(f.Fd()), 0, int(fsize),\n\t\tsyscall.PROT_READ|syscall.PROT_WRITE, syscall.MAP_SHARED,\n\t)\n\tif err != nil {\n\t\treturn err\n\t}\n\tb.data = data\n\n\toff := int(b.capacity)\n\tb.first = binary.GetLittleEndianUint64(b.data, off)\n\tb.last = binary.GetLittleEndianUint64(b.data, off+8)\n\tb.nextSeq = binary.GetLittleEndianUint64(b.data, off+16)\n\tb.biggest = binary.GetLittleEndianUint32(b.data, off+24)\n\tb.length = binary.GetLittleEndianUint64(b.data, off+28)\n\n\treturn nil\n}", "func Invalidate(cc ContractCall) {\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 (c *AdapterMemory) Clear(ctx context.Context) error {\n\treturn c.data.Clear()\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\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 *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func (ms *sender) invalidate() {\n\tms.invalid = true\n\tif ms.stream != nil {\n\t\tms.stream.Reset()\n\t\tms.stream = nil\n\t}\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 (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\n}", "func (a *allocator) Recycle() {\n\ta.base.Recycle()\n}", "func (spriteBatch *SpriteBatch) flush() {\n\tspriteBatch.arrayBuf.bufferData()\n}", "func (b *Buffer) flushCache() {\n\tif b.cdirty || len(b.c) == 0 {\n\t\tif len(b.c) == 0 {\n\t\t\tb.deleteBlock(b.cbi)\n\t\t} else {\n\t\t\tdisk.write(&b.bl[b.cbi], b.c)\n\t\t}\n\t\tb.cdirty = false\n\t}\n}", "func (m *spiralMemory) reallocate() {\n\t// add zero rows before/after the existing ones\n\tnewGrid := make([][]int, m.offset*4+1)\n\tcopy(newGrid[m.offset:], m.grid)\n\tm.grid = newGrid\n\tfor i := range m.grid {\n\t\tif i < 2 || i > m.offset*3 {\n\t\t\t// new blank row\n\t\t\tm.grid[i] = make([]int, m.offset*4+1)\n\t\t} else {\n\t\t\t// resize existing row\n\t\t\tnewRow := make([]int, m.offset*4+1)\n\t\t\t// copy existing values into the right position, leaving the existing\n\t\t\t// offset's worth of zero values\n\t\t\tcopy(newRow[m.offset:], m.grid[i])\n\t\t\tm.grid[i] = newRow\n\t\t}\n\t}\n\t// record new offset\n\tm.offset *= 2\n}", "func (stmt *statement) Invalidate() {\n\tif stmt.sql != nil {\n\t\tputBuffer(stmt.sql)\n\t\tstmt.sql = nil\n\t}\n}", "func (b *Buffer) Sync() {\n\tb.SetArea(b.Bounds())\n}", "func (d *adapterMemoryData) Clear() error {\n\td.mu.Lock()\n\tdefer d.mu.Unlock()\n\td.data = make(map[interface{}]adapterMemoryItem)\n\treturn nil\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 *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 (c *Driver) Invalidate(cacheName string, key interface{}) error {\n\tk := cachery.Key(key)\n\terr := c.inmemory.Invalidate(cacheName, k)\n\tif err != nil {\n\t\treturn err\n\t}\n\tmsg := message{\n\t\tSender: c.id,\n\t\tCommand: \"Invalidate\",\n\t\tCacheName: cacheName,\n\t\tKey: cachery.Key(k),\n\t}\n\treturn c.send(msg)\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\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 (c *Cursor) Invalidate() {\n\tc.computeMutex.Lock()\n\tdefer c.computeMutex.Unlock()\n\n\tc.ready = false\n}", "func (s *Storage) Free(pooled []byte) {\n\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 *BlockCache) Reorg(height int) {\n\tc.mutex.Lock()\n\tdefer c.mutex.Unlock()\n\n\t// Allow the caller not to have to worry about Sapling start height.\n\tif height < c.firstBlock {\n\t\theight = c.firstBlock\n\t}\n\tif height >= c.nextBlock {\n\t\t// Timing window, ignore this request\n\t\treturn\n\t}\n\t// Remove the end of the cache.\n\tc.nextBlock = height\n\tnewCacheLen := height - c.firstBlock\n\tc.starts = c.starts[:newCacheLen+1]\n\n\tif err := c.lengthsFile.Truncate(int64(4 * newCacheLen)); err != nil {\n\t\tLog.Fatal(\"truncate failed: \", err)\n\t}\n\tif err := c.blocksFile.Truncate(c.starts[newCacheLen]); err != nil {\n\t\tLog.Fatal(\"truncate failed: \", err)\n\t}\n\tc.setLatestHash()\n}", "func (pool *BufferPool) Recycle(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tselect {\n\tcase pool.Buffers <- buf:\n\tdefault:\n\t\t// let it go, let it go...\n\t}\n}", "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 (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 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 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 (b *Buffer) Remove(offset int, size int) {\n if (offset + size) > len(b.data) {\n panic(\"invalid offset & size\")\n }\n\n copy(b.data[offset:], b.data[offset+size:])\n b.size -= size\n if b.offset >= (offset + size) {\n b.offset -= size\n } else if b.offset >= offset {\n b.offset -= b.offset - offset\n if b.offset > b.size {\n b.offset = b.size\n }\n }\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 (e *T) erase() {\n\tif e.widx <= 0 {\n\t\treturn\n\t}\n\te.widx--\n\te.buf[e.widx] = 0\n}", "func (ms *MemoizeSigner) evictFromMemory() {\n\tfor dig := range ms.memory {\n\t\tdelete(ms.memory, dig)\n\t\treturn\n\t}\n}", "func (r *bufferingReaderAt) recycleBuf(b []byte) {\n\tif cap(b) != r.blockSize {\n\t\tpanic(\"trying to return a buffer not initially requested via grabBuf\")\n\t}\n\tif len(r.pool)+1 > cap(r.pool) {\n\t\tpanic(\"unexpected growth of byte buffer pool beyond capacity\")\n\t}\n\tr.pool = append(r.pool, b[:cap(b)])\n}", "func (b *Buffer) Reset() {\n\tb.B = b.arena\n}", "func (p *Buffer) release() []byte {\n\tbytes := p.buf\n\tp.buf = nil\n\tp.index = 0\n\tp.Immutable = false\n\tp.err = nil\n\tp.array_indexes = nil\n\tbuffer_pool.Put(p)\n\treturn bytes\n}", "func (c *cache) clear() {\n\tc.cursor = 0\n\tc.chunks = make(map[FileID]location)\n\tc.sums = c.sums[:0]\n}", "func (b *Buffer) ClearAt(o int) {\n\tif o < len(b.Tiles) {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (b *baseKVStoreBatch) Clear() {\n\tb.mutex.Lock()\n\tdefer b.mutex.Unlock()\n\tb.writeQueue = nil\n}", "func (ri *ReplicaDataIterator) Rewind() {\n\tri.iterator.Rewind()\n}", "func (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (c *doubleCacheBuffer[T]) evict(newTs uint64) {\n\tc.tail = c.head\n\tc.head = newDoubleCacheItem[T](newTs, c.maxSize/2)\n\tc.ts = c.tail.headTs\n}", "func (a *authorizationState) invalidate() {\n\tif a == nil {\n\t\treturn\n\t}\n\n\ta.Lock()\n\tdefer a.Unlock()\n\n\ta.valid = false\n\ta.authorizeAccountResponse = nil\n}", "func (m *ValuesResultArrayHash) Reallocate() {\n\tif m.initialSize > 0 {\n\t\tm.lookup = make(map[ValuesResultArrayHashHash]ValuesResultArrayHashEntry, m.initialSize)\n\t} else {\n\t\tm.lookup = make(map[ValuesResultArrayHashHash]ValuesResultArrayHashEntry)\n\t}\n}", "func (c *StatsTableRowCache) Invalidate(tblID int64) {\n\tc.mu.Lock()\n\t// To prevent the cache from becoming too large,\n\t// we only record the latest 100 dirty tables that have been modified.\n\tif len(c.dirtyIDs) < 100 {\n\t\tc.dirtyIDs = append(c.dirtyIDs, tblID)\n\t}\n\tc.mu.Unlock()\n}", "func (d *Display) growBuffer(newX, newY int) {\n\tif newX < 0 || newY < 0 {\n\t\tpanic(\"coordinates must be 0 or greater\")\n\t}\n\tif newX < d.width && newY < d.height {\n\t\t// Coords already within buffer\n\t\treturn\n\t}\n\n\tnewWidth, newHeight := d.width, d.height\n\tif newX >= newWidth {\n\t\tnewWidth = newX + 1\n\t}\n\tif newY >= newHeight {\n\t\tnewHeight = newY + 1\n\t}\n\n\tif newWidth > d.width {\n\t\tfor y, row := range d.buffer {\n\t\t\t// Expand each row as needed\n\t\t\tnewRow := make([]byte, newWidth)\n\t\t\tcopy(newRow, row)\n\t\t\td.buffer[y] = newRow\n\t\t}\n\t}\n\tfor y := d.height - 1; y < newHeight; y++ {\n\t\t// Append new rows as needed, of width x coord\n\t\td.buffer = append(d.buffer, make([]byte, newWidth))\n\t}\n\td.width = newWidth\n\td.height = newHeight\n}", "func free(ptr unsafe.Pointer)", "func (c *memoryCache) Del(key string) {\n\tdelete(c.data, key)\n}", "func (b *buffer) pin(loc Location, ptr unsafe.Pointer) {\n\tif !atomic.CompareAndSwapPointer(b.index(loc.index()), nil, ptr) {\n\t\tpanic(\"double pin\")\n\t}\n\t// atomic.StorePointer(b.index(loc.index()), ptr)\n\tatomic.AddUint32(&b.free, ^uint32(0))\n}", "func netApiBufferFree(buffer *wKSTAInfo102) {\n\tprocNetApiBufferFree.Call(uintptr(unsafe.Pointer(buffer))) //nolint:errcheck\n}", "func (self *nativePduBuffer) Clear() {\n\tself.start = 0\n\tself.count = 0\n}", "func Release(o *Object) {\n\to.hardReset()\n\topool.Put(o)\n}", "func (aio *AsyncIO) freeEvent(re *runningEvent, iocb *iocb, err error) error {\n\t// help gc free memory early\n\tre.data = nil\n\n\t// remove the iocb from running pool\n\taio.running.Remove(pointer2string(unsafe.Pointer(re.iocb)))\n\n\t// put the iocb back into the available pool\n\taio.available.Set(pointer2string(unsafe.Pointer(re.iocb)), re.iocb)\n\n\t// update the stat in request pool\n\tri, ok := aio.request.Get(int2string(int64(re.reqID)))\n\tif !ok {\n\t\treturn ErrReqIDNotFound\n\t}\n\tr, ok := ri.(*requestState)\n\tif !ok {\n\t\treturn ErrReqIDNotFound\n\t}\n\tr.done = true\n\tr.bytes = int64(re.wrote)\n\tif err != nil {\n\t\tr.err = err\n\t}\n\n\treturn nil\n}", "func (m *mmapData) free() error {\n\treturn syscallMunmap(m.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 (it iterator) clear(b *ringBuf) {\n\tb.buf[it] = raftpb.Entry{}\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func (v Chunk) Retain() {\n\tv.buf.Retain()\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 (m *RecurrenceRange) SetBackingStore(value ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStore)() {\n m.backingStore = value\n}", "func (s *MemStore) Flush() error {\n\ts.lock.Lock()\n\tdefer s.lock.Unlock()\n\n\ts.data = make(map[interface{}]interface{})\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 clearAllocation(allocationID string) {\n\tcachedAllocations.Remove(allocationID)\n}", "func (ma *markAllocator) put(mark uint32) {\n\tma.lock.Lock()\n\tdefer ma.lock.Unlock()\n\tma.marks = append(ma.marks, mark)\n}", "func (b *Buffer) Flush() error {\n\t// upload vertice + meta to opengl\n\tGlBindBuffer(ARRAY_BUFFER, b.GlBuffer)\n\tErrPanic()\n\tif len(b.Buf) == 0 {\n\t\treturn nil\n\t}\n\tGlBufferData(ARRAY_BUFFER, b.Buf, STATIC_DRAW)\n\tErrPanic()\n\t// FIXME: rebind shader attrs\n\tb.BufLen = len(b.Buf)\n\tb.Buf = b.Buf[:0]\n\treturn nil\n}", "func (b *Buffer) Reset() {\n\tb.start = 0\n\tb.used = 0\n}", "func (c *Conn) sendInvalidate(msg []byte) error {\n\tswitch err := c.writeToKernel(msg); err {\n\tcase syscall.ENOENT:\n\t\treturn ErrNotCached\n\tdefault:\n\t\treturn err\n\t}\n}", "func (b *baseKVStoreBatch) Clear() {\n\tb.mutex.Lock()\n\tdefer b.mutex.Unlock()\n\tb.writeQueue = nil\n\n\tb.fillLock.Lock()\n\tdefer b.fillLock.Unlock()\n\tfor k := range b.fill {\n\t\tdelete(b.fill, k)\n\t}\n}", "func (buffer *Buffer) Reset() {\n\tbuffer.B.Reset()\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 (b *batch) Reset() {\n\tb.batch.Clear()\n\tb.size = 0\n}", "func (b *ByteBuffer) Reset(buf []byte) {\n\tb.buf = buf\n\tb.off = 0\n}", "func (c *Caching) Invalidate(ip string) {\n\tc.m.Lock()\n\tdefer c.m.Unlock()\n\n\tdelete(c.results, ip)\n}", "func TestReallocate(t *testing.T) {\n\t_, storage, backing, si, destroyFunc := newStorage(t)\n\tdefer destroyFunc()\n\tif err := si.Create(context.TODO(), key(), validNewRangeAllocation(), nil, 0); err != nil {\n\t\tt.Fatalf(\"unexpected error: %v\", err)\n\t}\n\n\t// Allocate a port inside the valid port range\n\tif err := storage.Allocate(30100); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Try to allocate the same port in the local bitmap\n\t// The local bitmap stores the offset of the port\n\t// offset = port - base (30100 - 30000 = 100)\n\tok, err := backing.Allocate(100)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\t// It should not allocate the port because it was already allocated\n\tif ok {\n\t\tt.Fatal(\"Expected allocation to fail\")\n\t}\n\t// Try to allocate the port again should fail\n\tif err := storage.Allocate(30100); err != portallocator.ErrAllocated {\n\t\tt.Fatal(err)\n\t}\n\n\t// Release the port\n\tif err := storage.Release(30100); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Try to allocate the port again should succeed because we've released it\n\tif err := storage.Allocate(30100); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n}", "func (c *AdapterMemory) clearByKey(key interface{}, force ...bool) {\n\t// Doubly check before really deleting it from cache.\n\tc.data.DeleteWithDoubleCheck(key, force...)\n\n\t// Deleting its expiration time from `expireTimes`.\n\tc.expireTimes.Delete(key)\n\n\t// Deleting it from LRU.\n\tif c.cap > 0 {\n\t\tc.lru.Remove(key)\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}" ]
[ "0.6540778", "0.63262284", "0.63032913", "0.6283142", "0.5975635", "0.5975635", "0.56049734", "0.5571924", "0.5565431", "0.55641973", "0.5540733", "0.55034137", "0.550213", "0.5496075", "0.54930866", "0.5422246", "0.5381801", "0.5379293", "0.52749485", "0.52730536", "0.5268382", "0.52658916", "0.52636254", "0.5262394", "0.5256308", "0.5241669", "0.52391857", "0.52256674", "0.5225086", "0.52220756", "0.52161145", "0.520675", "0.51984304", "0.5190411", "0.5187351", "0.518392", "0.51827675", "0.51800054", "0.517967", "0.5173012", "0.5169407", "0.5163539", "0.5161636", "0.51511943", "0.51419336", "0.5099442", "0.5087478", "0.50866073", "0.5076799", "0.5076312", "0.5075112", "0.5073381", "0.50625384", "0.50406444", "0.50319284", "0.50107855", "0.500837", "0.4985256", "0.49813086", "0.49782455", "0.49665174", "0.49648052", "0.49607816", "0.49601927", "0.49538702", "0.49469104", "0.49374044", "0.4929443", "0.49272633", "0.49198294", "0.4912558", "0.49092582", "0.4903975", "0.49033663", "0.49025983", "0.4900729", "0.48922426", "0.48841467", "0.487457", "0.4871749", "0.48703405", "0.48686436", "0.48660445", "0.48608062", "0.4857083", "0.4854229", "0.48521394", "0.48469403", "0.48430893", "0.48375782", "0.48217407", "0.48141733", "0.48123848", "0.48098832", "0.48042658", "0.4801531", "0.47880933", "0.47834018", "0.47834018" ]
0.59145784
7
invalidate the content of some or all of a framebuffer's attachments
func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) { C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateFramebuffer, 3, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateNamedFramebufferSubData, 7, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateNamedFramebufferData, 3, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateSubFramebuffer, 7, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\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 (fb *FrameBuffer) Flush() error {\n\tfb.file.Seek(0, 0)\n\t_, err := fb.file.Write(fb.buf)\n\treturn err\n}", "func (f *Faces) Reset(c ui.Config) {\n\tf.config = c\n\tf.init()\n\tfor pk, p := range f.pathCache {\n\t\tif !p.active {\n\t\t\tdelete(f.pathCache, pk)\n\t\t\tcontinue\n\t\t}\n\t\tp.active = false\n\t\tf.pathCache[pk] = p\n\t}\n\tfor lk, l := range f.layoutCache {\n\t\tif !l.active {\n\t\t\tdelete(f.layoutCache, lk)\n\t\t\tcontinue\n\t\t}\n\t\tl.active = false\n\t\tf.layoutCache[lk] = l\n\t}\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 InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (f *Flash) Clear() {\n\tfor k := range f.v {\n\t\tif !f.changed {\n\t\t\tf.changed = true\n\t\t}\n\t\tf.v.Del(k)\n\t}\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 (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 (n *BufferView) UnfocusBuffers() {\n\t// clear focus from buffers\n\tfor _, buffPane := range n.buffers {\n\t\tbuffPane.SetFocus(false)\n\t}\n}", "func (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\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 (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 (a *Agent) flush() {\n\tif len(a.Buf) != 0 {\n\t\ta.Sketch.insert(agentConfig, a.Buf)\n\t\ta.Buf = nil\n\t}\n\n\tif len(a.CountBuf) != 0 {\n\t\ta.Sketch.insertCounts(agentConfig, a.CountBuf)\n\t\ta.CountBuf = nil\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 (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func (b *Buffer) Flush() error {\n\t// upload vertice + meta to opengl\n\tGlBindBuffer(ARRAY_BUFFER, b.GlBuffer)\n\tErrPanic()\n\tif len(b.Buf) == 0 {\n\t\treturn nil\n\t}\n\tGlBufferData(ARRAY_BUFFER, b.Buf, STATIC_DRAW)\n\tErrPanic()\n\t// FIXME: rebind shader attrs\n\tb.BufLen = len(b.Buf)\n\tb.Buf = b.Buf[:0]\n\treturn nil\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 (b *block) invalidate(p spi.PointSPI) {\n\tfor _, d := range b.points {\n\t\tif sfp := d.scaleFactor; sfp != nil {\n\t\t\tif sfp.Id() == p.Id() {\n\t\t\t\td.SetValue(nil)\n\t\t\t}\n\t\t}\n\t}\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func DeleteFramebuffer(v Framebuffer) {\n\tgl.DeleteFramebuffers(1, &v.Value)\n}", "func (f *fragment) InvalidateChecksums() {\n\tf.mu.Lock()\n\tf.checksums = make(map[int][]byte)\n\tf.mu.Unlock()\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (pp *PostProcessor) EndRender() {\n\t// Now resolve multisampled color-buffer into intermediate FBO to store to texture\n\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, pp.msFrameBuffer)\n\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, pp.frameBuffer)\n\tgl.BlitFramebuffer(0, 0, int32(pp.width), int32(pp.height), 0, 0, int32(pp.width), int32(pp.height), gl.COLOR_BUFFER_BIT, gl.NEAREST)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0) // Binds both READ and WRITE framebuffer to default framebuffer\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 0, 0)\n}", "func (spriteBatch *SpriteBatch) flush() {\n\tspriteBatch.arrayBuf.bufferData()\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 InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\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 (m *Mailer) ClearFiles() {\n\tm.AttachList.FileContent = map[string]string{}\n\tm.AttachList.Filenames = []string{}\n}", "func UConverterFlushCache() (_swig_ret int)", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (c *Context) EraseDrawableList() {\n\tc.primitivesToDraw = make(map[uint32][]Drawable)\n}", "func (b *Buffer) flushCache() {\n\tif b.cdirty || len(b.c) == 0 {\n\t\tif len(b.c) == 0 {\n\t\t\tb.deleteBlock(b.cbi)\n\t\t} else {\n\t\t\tdisk.write(&b.bl[b.cbi], b.c)\n\t\t}\n\t\tb.cdirty = false\n\t}\n}", "func (b *endpointBuffers) flushBuffers(\n\tconn net.Conn, pkt *transport.TransportPacket) error {\n\n\tvbs := make([]*c.VbKeyVersions, 0, len(b.vbs))\n\tfor _, vb := range b.vbs {\n\t\tvbs = append(vbs, vb)\n\t}\n\tb.vbs = make(map[string]*c.VbKeyVersions)\n\n\tif err := pkt.Send(conn, vbs); err != nil {\n\t\treturn err\n\t}\n\treturn nil\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 (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 (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\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 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 (x *fastReflection_EvidenceList) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"tendermint.types.EvidenceList.evidence\":\n\t\tx.Evidence = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: tendermint.types.EvidenceList\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message tendermint.types.EvidenceList does not contain field %s\", fd.FullName()))\n\t}\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func (f *Frame) Reset(num int) {\n\tf.Magic = 0\n\tf.Descriptor.Checksum = 0\n\tf.Descriptor.ContentSize = 0\n\t_ = f.Blocks.closeW(f, num)\n\tf.Checksum = 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 (v view) Clear() {\n\tfor i := 0; i < len(v.screen); i++ {\n\t\tv.screen[i].Clear()\n\t}\n}", "func (debugging *debuggingOpenGL) FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tdebugging.recordEntry(\"FramebufferRenderbuffer\", target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.gl.FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.recordExit(\"FramebufferRenderbuffer\")\n}", "func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"cosmos.distribution.v1beta1.MsgUpdateParams.authority\":\n\t\tx.Authority = \"\"\n\tcase \"cosmos.distribution.v1beta1.MsgUpdateParams.params\":\n\t\tx.Params = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.distribution.v1beta1.MsgUpdateParams\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.distribution.v1beta1.MsgUpdateParams does not contain field %s\", fd.FullName()))\n\t}\n}", "func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.distribution.v1beta1.MsgUpdateParamsResponse\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.distribution.v1beta1.MsgUpdateParamsResponse does not contain field %s\", fd.FullName()))\n\t}\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\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 (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 FramebufferRenderbuffer(target, attachment, rbTarget Enum, rb Renderbuffer) {\n\tgl.FramebufferRenderbuffer(uint32(target), uint32(attachment), uint32(rbTarget), rb.Value)\n}", "func ClearCommitBuffer() {\n\tvar commitBuffer RootCommitBuffer\n\tcWarning := color.New(color.FgYellow).SprintFunc()\n\n\tbufferFile, err := os.Open(SilkRoot() + \"/\" + RootDirectoryName + \"/commit/buffer\")\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to open commit buffer file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\tdefer bufferFile.Close()\n\n\t// Remove all bufferFile.Changes()\n\tbyteValue, err := ioutil.ReadAll(bufferFile)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to read buffer file byte values\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\terr = json.Unmarshal(byteValue, &commitBuffer)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to create latest commit file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\tcommitBuffer.Changes = []FileChange{}\n\n\tcommitBufferJSON, err := json.MarshalIndent(commitBuffer, \" \", \"\")\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to marshal json to commit buffer\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\terr = ioutil.WriteFile(SilkRoot()+\"/.silk/commit/buffer\", []byte(string(commitBufferJSON)+\"\\n\"), 0766)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to write to commit buffer file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n}", "func FramebufferRenderbuffer(target Enum, attachment Enum, renderbuffertarget Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tcrenderbuffertarget, _ := (C.GLenum)(renderbuffertarget), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glFramebufferRenderbuffer(ctarget, cattachment, crenderbuffertarget, crenderbuffer)\n}", "func (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\n}", "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 UnpatchAll() {\n\tfor funcAddr, funcBytes := range patchRecord {\n\t\tcopyToLocation(funcAddr, funcBytes)\n\t\tdelete(patchRecord, funcAddr)\n\t}\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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 (f *FileRotator) flushBuffer() error {\n\tf.bufLock.Lock()\n\tdefer f.bufLock.Unlock()\n\tif f.bufw != nil {\n\t\treturn f.bufw.Flush()\n\t}\n\treturn nil\n}", "func (f *Frame) Reset(r image.Rectangle, b *image.RGBA, ft *font.Font) {\n\tf.r = r\n\tf.b = b\n\tf.SetFont(ft)\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func (tr *trooper) detach() {\n\tif tr.neo != nil {\n\t\ttr.demerge() // will re-enter detach.\n\t\treturn\n\t}\n\tfor _, b := range tr.bits {\n\t\tif b.detach() {\n\t\t\ttr.healthChanged(tr.health())\n\t\t\treturn\n\t\t}\n\t}\n}", "func (x *fastReflection_Evidence) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"tendermint.types.Evidence.duplicate_vote_evidence\":\n\t\tx.Sum = nil\n\tcase \"tendermint.types.Evidence.light_client_attack_evidence\":\n\t\tx.Sum = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: tendermint.types.Evidence\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message tendermint.types.Evidence does not contain field %s\", fd.FullName()))\n\t}\n}", "func (t *Text) Dirty() {\n\tt.dirty = true\n\tt.Start, t.End = 0, 0\n\tt.Scene.Resize.Notify()\n}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 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 (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (e *ObservableEditableBuffer) ResetBuffer() {\n\te.filtertagobservers = false\n\te.seq = 0\n\te.f = NewTypeBuffer([]rune{}, e)\n}", "func (m *MockMatcher) Flush() {\r\n\tm.Matchers = []MatchFunc{}\r\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 (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func Flush() {\n\tgl.Flush()\n}", "func (m *MockMatcher) Flush() {\n\tm.Matchers = []MatchFunc{}\n}", "func (p *Patch) ClearPatchData() {\n\tfor i, patchPart := range p.Patches {\n\t\t// If the patch isn't stored externally, no need to do anything.\n\t\tif patchPart.PatchSet.PatchFileId != \"\" {\n\t\t\tp.Patches[i].PatchSet.Patch = \"\"\n\t\t}\n\t}\n}", "func (p *Patch) ClearPatchData() {\n\tfor i, patchPart := range p.Patches {\n\t\t// If the patch isn't stored externally, no need to do anything.\n\t\tif patchPart.PatchSet.PatchFileId != \"\" {\n\t\t\tp.Patches[i].PatchSet.Patch = \"\"\n\t\t}\n\t}\n}", "func (Screen *ScreenManager) Flush() {\n\tfor idx, str := range strings.Split(Screen.Buffer.String(), \"\\n\") {\n\t\tif idx > Screen.Height() {\n\t\t\treturn\n\t\t}\n\t\tif idx > 0 {\n\t\t\tScreen.OutStream.WriteString(\"\\n\" + str)\n\t\t} else {\n\t\t\tScreen.OutStream.WriteString(str)\n\t\t}\n\t}\n\n\tScreen.OutStream.Flush()\n\tScreen.Buffer.Reset()\n}", "func (honest *Honest) flushUpdates() {\n\n\thonest.blockUpdates = honest.blockUpdates[:0]\n}" ]
[ "0.684292", "0.6738991", "0.6663649", "0.6554966", "0.65495056", "0.64778996", "0.64778996", "0.6452918", "0.64107835", "0.64107835", "0.6217793", "0.6217793", "0.5660155", "0.55788666", "0.5505714", "0.54811406", "0.54708076", "0.5326192", "0.52395916", "0.51981556", "0.514816", "0.51272833", "0.5125133", "0.5124668", "0.5123622", "0.511963", "0.5114546", "0.51029646", "0.5081288", "0.5080423", "0.504778", "0.50307524", "0.5030704", "0.5015163", "0.50036055", "0.49876666", "0.49839398", "0.49794057", "0.49423823", "0.49398428", "0.49336034", "0.49317464", "0.4925459", "0.49213713", "0.49213713", "0.4920314", "0.4891514", "0.4888687", "0.4877022", "0.48710203", "0.48639005", "0.48523307", "0.4849539", "0.4845353", "0.4835035", "0.4823432", "0.4818013", "0.48122144", "0.47907728", "0.47784773", "0.4773332", "0.47667235", "0.47538856", "0.4747044", "0.47374937", "0.47303492", "0.47303492", "0.47259378", "0.47125077", "0.4709614", "0.47091657", "0.47051695", "0.46862513", "0.46862182", "0.46822762", "0.4682145", "0.4663837", "0.4663837", "0.46492466", "0.46480677", "0.4642918", "0.4639345", "0.46333277", "0.4632253", "0.46273676", "0.46243876", "0.4623744", "0.4623744", "0.4618947", "0.46177799", "0.46039632", "0.46021312", "0.46014014", "0.459571", "0.45930287", "0.45921552", "0.45921552", "0.4583094", "0.45810026" ]
0.6264575
11
invalidate the content of some or all of a framebuffer's attachments
func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) { C.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateFramebuffer, 3, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateNamedFramebufferSubData, 7, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateNamedFramebufferData, 3, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateSubFramebuffer, 7, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\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 (fb *FrameBuffer) Flush() error {\n\tfb.file.Seek(0, 0)\n\t_, err := fb.file.Write(fb.buf)\n\treturn err\n}", "func (f *Faces) Reset(c ui.Config) {\n\tf.config = c\n\tf.init()\n\tfor pk, p := range f.pathCache {\n\t\tif !p.active {\n\t\t\tdelete(f.pathCache, pk)\n\t\t\tcontinue\n\t\t}\n\t\tp.active = false\n\t\tf.pathCache[pk] = p\n\t}\n\tfor lk, l := range f.layoutCache {\n\t\tif !l.active {\n\t\t\tdelete(f.layoutCache, lk)\n\t\t\tcontinue\n\t\t}\n\t\tl.active = false\n\t\tf.layoutCache[lk] = l\n\t}\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 InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (f *Flash) Clear() {\n\tfor k := range f.v {\n\t\tif !f.changed {\n\t\t\tf.changed = true\n\t\t}\n\t\tf.v.Del(k)\n\t}\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 (n *BufferView) UnfocusBuffers() {\n\t// clear focus from buffers\n\tfor _, buffPane := range n.buffers {\n\t\tbuffPane.SetFocus(false)\n\t}\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 (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\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 (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 (a *Agent) flush() {\n\tif len(a.Buf) != 0 {\n\t\ta.Sketch.insert(agentConfig, a.Buf)\n\t\ta.Buf = nil\n\t}\n\n\tif len(a.CountBuf) != 0 {\n\t\ta.Sketch.insertCounts(agentConfig, a.CountBuf)\n\t\ta.CountBuf = nil\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 (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func (b *Buffer) Flush() error {\n\t// upload vertice + meta to opengl\n\tGlBindBuffer(ARRAY_BUFFER, b.GlBuffer)\n\tErrPanic()\n\tif len(b.Buf) == 0 {\n\t\treturn nil\n\t}\n\tGlBufferData(ARRAY_BUFFER, b.Buf, STATIC_DRAW)\n\tErrPanic()\n\t// FIXME: rebind shader attrs\n\tb.BufLen = len(b.Buf)\n\tb.Buf = b.Buf[:0]\n\treturn nil\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 (b *block) invalidate(p spi.PointSPI) {\n\tfor _, d := range b.points {\n\t\tif sfp := d.scaleFactor; sfp != nil {\n\t\t\tif sfp.Id() == p.Id() {\n\t\t\t\td.SetValue(nil)\n\t\t\t}\n\t\t}\n\t}\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func DeleteFramebuffer(v Framebuffer) {\n\tgl.DeleteFramebuffers(1, &v.Value)\n}", "func (f *fragment) InvalidateChecksums() {\n\tf.mu.Lock()\n\tf.checksums = make(map[int][]byte)\n\tf.mu.Unlock()\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (pp *PostProcessor) EndRender() {\n\t// Now resolve multisampled color-buffer into intermediate FBO to store to texture\n\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, pp.msFrameBuffer)\n\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, pp.frameBuffer)\n\tgl.BlitFramebuffer(0, 0, int32(pp.width), int32(pp.height), 0, 0, int32(pp.width), int32(pp.height), gl.COLOR_BUFFER_BIT, gl.NEAREST)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0) // Binds both READ and WRITE framebuffer to default framebuffer\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 0, 0)\n}", "func (spriteBatch *SpriteBatch) flush() {\n\tspriteBatch.arrayBuf.bufferData()\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 InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\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 (m *Mailer) ClearFiles() {\n\tm.AttachList.FileContent = map[string]string{}\n\tm.AttachList.Filenames = []string{}\n}", "func UConverterFlushCache() (_swig_ret int)", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (c *Context) EraseDrawableList() {\n\tc.primitivesToDraw = make(map[uint32][]Drawable)\n}", "func (b *Buffer) flushCache() {\n\tif b.cdirty || len(b.c) == 0 {\n\t\tif len(b.c) == 0 {\n\t\t\tb.deleteBlock(b.cbi)\n\t\t} else {\n\t\t\tdisk.write(&b.bl[b.cbi], b.c)\n\t\t}\n\t\tb.cdirty = false\n\t}\n}", "func (b *endpointBuffers) flushBuffers(\n\tconn net.Conn, pkt *transport.TransportPacket) error {\n\n\tvbs := make([]*c.VbKeyVersions, 0, len(b.vbs))\n\tfor _, vb := range b.vbs {\n\t\tvbs = append(vbs, vb)\n\t}\n\tb.vbs = make(map[string]*c.VbKeyVersions)\n\n\tif err := pkt.Send(conn, vbs); err != nil {\n\t\treturn err\n\t}\n\treturn nil\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 (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 (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\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 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 (x *fastReflection_EvidenceList) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"tendermint.types.EvidenceList.evidence\":\n\t\tx.Evidence = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: tendermint.types.EvidenceList\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message tendermint.types.EvidenceList does not contain field %s\", fd.FullName()))\n\t}\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func (f *Frame) Reset(num int) {\n\tf.Magic = 0\n\tf.Descriptor.Checksum = 0\n\tf.Descriptor.ContentSize = 0\n\t_ = f.Blocks.closeW(f, num)\n\tf.Checksum = 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 (v view) Clear() {\n\tfor i := 0; i < len(v.screen); i++ {\n\t\tv.screen[i].Clear()\n\t}\n}", "func (debugging *debuggingOpenGL) FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tdebugging.recordEntry(\"FramebufferRenderbuffer\", target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.gl.FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.recordExit(\"FramebufferRenderbuffer\")\n}", "func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"cosmos.distribution.v1beta1.MsgUpdateParams.authority\":\n\t\tx.Authority = \"\"\n\tcase \"cosmos.distribution.v1beta1.MsgUpdateParams.params\":\n\t\tx.Params = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.distribution.v1beta1.MsgUpdateParams\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.distribution.v1beta1.MsgUpdateParams does not contain field %s\", fd.FullName()))\n\t}\n}", "func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.distribution.v1beta1.MsgUpdateParamsResponse\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.distribution.v1beta1.MsgUpdateParamsResponse does not contain field %s\", fd.FullName()))\n\t}\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\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 (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 FramebufferRenderbuffer(target, attachment, rbTarget Enum, rb Renderbuffer) {\n\tgl.FramebufferRenderbuffer(uint32(target), uint32(attachment), uint32(rbTarget), rb.Value)\n}", "func ClearCommitBuffer() {\n\tvar commitBuffer RootCommitBuffer\n\tcWarning := color.New(color.FgYellow).SprintFunc()\n\n\tbufferFile, err := os.Open(SilkRoot() + \"/\" + RootDirectoryName + \"/commit/buffer\")\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to open commit buffer file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\tdefer bufferFile.Close()\n\n\t// Remove all bufferFile.Changes()\n\tbyteValue, err := ioutil.ReadAll(bufferFile)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to read buffer file byte values\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\terr = json.Unmarshal(byteValue, &commitBuffer)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to create latest commit file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\tcommitBuffer.Changes = []FileChange{}\n\n\tcommitBufferJSON, err := json.MarshalIndent(commitBuffer, \" \", \"\")\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to marshal json to commit buffer\")\n\t\tfmt.Print(\"\\n\")\n\t}\n\n\terr = ioutil.WriteFile(SilkRoot()+\"/.silk/commit/buffer\", []byte(string(commitBufferJSON)+\"\\n\"), 0766)\n\tif err != nil {\n\t\tfmt.Println(cWarning(\"\\n\\tError\") + \": unable to write to commit buffer file\")\n\t\tfmt.Print(\"\\n\")\n\t}\n}", "func FramebufferRenderbuffer(target Enum, attachment Enum, renderbuffertarget Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tcrenderbuffertarget, _ := (C.GLenum)(renderbuffertarget), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glFramebufferRenderbuffer(ctarget, cattachment, crenderbuffertarget, crenderbuffer)\n}", "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 (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\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 UnpatchAll() {\n\tfor funcAddr, funcBytes := range patchRecord {\n\t\tcopyToLocation(funcAddr, funcBytes)\n\t\tdelete(patchRecord, funcAddr)\n\t}\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 (f *FileRotator) flushBuffer() error {\n\tf.bufLock.Lock()\n\tdefer f.bufLock.Unlock()\n\tif f.bufw != nil {\n\t\treturn f.bufw.Flush()\n\t}\n\treturn nil\n}", "func (f *Frame) Reset(r image.Rectangle, b *image.RGBA, ft *font.Font) {\n\tf.r = r\n\tf.b = b\n\tf.SetFont(ft)\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func (tr *trooper) detach() {\n\tif tr.neo != nil {\n\t\ttr.demerge() // will re-enter detach.\n\t\treturn\n\t}\n\tfor _, b := range tr.bits {\n\t\tif b.detach() {\n\t\t\ttr.healthChanged(tr.health())\n\t\t\treturn\n\t\t}\n\t}\n}", "func (x *fastReflection_Evidence) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"tendermint.types.Evidence.duplicate_vote_evidence\":\n\t\tx.Sum = nil\n\tcase \"tendermint.types.Evidence.light_client_attack_evidence\":\n\t\tx.Sum = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: tendermint.types.Evidence\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message tendermint.types.Evidence does not contain field %s\", fd.FullName()))\n\t}\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 (t *Text) Dirty() {\n\tt.dirty = true\n\tt.Start, t.End = 0, 0\n\tt.Scene.Resize.Notify()\n}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 0\n}", "func (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (e *ObservableEditableBuffer) ResetBuffer() {\n\te.filtertagobservers = false\n\te.seq = 0\n\te.f = NewTypeBuffer([]rune{}, e)\n}", "func (m *MockMatcher) Flush() {\r\n\tm.Matchers = []MatchFunc{}\r\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 (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func Flush() {\n\tgl.Flush()\n}", "func (m *MockMatcher) Flush() {\n\tm.Matchers = []MatchFunc{}\n}", "func (p *Patch) ClearPatchData() {\n\tfor i, patchPart := range p.Patches {\n\t\t// If the patch isn't stored externally, no need to do anything.\n\t\tif patchPart.PatchSet.PatchFileId != \"\" {\n\t\t\tp.Patches[i].PatchSet.Patch = \"\"\n\t\t}\n\t}\n}", "func (p *Patch) ClearPatchData() {\n\tfor i, patchPart := range p.Patches {\n\t\t// If the patch isn't stored externally, no need to do anything.\n\t\tif patchPart.PatchSet.PatchFileId != \"\" {\n\t\t\tp.Patches[i].PatchSet.Patch = \"\"\n\t\t}\n\t}\n}", "func (Screen *ScreenManager) Flush() {\n\tfor idx, str := range strings.Split(Screen.Buffer.String(), \"\\n\") {\n\t\tif idx > Screen.Height() {\n\t\t\treturn\n\t\t}\n\t\tif idx > 0 {\n\t\t\tScreen.OutStream.WriteString(\"\\n\" + str)\n\t\t} else {\n\t\t\tScreen.OutStream.WriteString(str)\n\t\t}\n\t}\n\n\tScreen.OutStream.Flush()\n\tScreen.Buffer.Reset()\n}", "func (f *FileBlob) Free() {\n\tf.blob = nil\n}" ]
[ "0.68448377", "0.6739778", "0.66656774", "0.6555456", "0.6550924", "0.64785826", "0.64785826", "0.6453567", "0.62670827", "0.62670827", "0.62186563", "0.62186563", "0.56610215", "0.5580716", "0.5507069", "0.54841954", "0.5473034", "0.5325019", "0.5241207", "0.5198889", "0.5149313", "0.51272136", "0.51266545", "0.51259077", "0.5124649", "0.5122016", "0.5114033", "0.5101873", "0.50836474", "0.5081213", "0.50487053", "0.50343627", "0.5030779", "0.50162625", "0.500793", "0.4988236", "0.49844983", "0.49810088", "0.49450868", "0.49398112", "0.49350777", "0.49317968", "0.49282202", "0.49235648", "0.49235648", "0.49215296", "0.48899427", "0.48894373", "0.48772788", "0.48720983", "0.48636207", "0.48508438", "0.48503476", "0.48447108", "0.48332906", "0.4824771", "0.4819971", "0.48124778", "0.4792871", "0.47794142", "0.47757283", "0.47684112", "0.4755758", "0.47468644", "0.47376233", "0.4732151", "0.4732151", "0.4726672", "0.4713202", "0.47110274", "0.47090757", "0.47065467", "0.46885845", "0.4685465", "0.46846768", "0.46819803", "0.46649915", "0.46649915", "0.46499103", "0.46484286", "0.46441078", "0.46411973", "0.46335417", "0.46321777", "0.46265012", "0.46265012", "0.46255416", "0.46238053", "0.46199703", "0.46193245", "0.46054506", "0.4602078", "0.46010628", "0.45982534", "0.4594612", "0.45920137", "0.45920137", "0.45837787", "0.45804086" ]
0.64124924
9
invalidate the content of a region of some or all of a framebuffer's attachments
func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) { C.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateNamedFramebufferSubData, 7, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateSubFramebuffer, 7, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateFramebuffer, 3, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateNamedFramebufferData, 3, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (b *block) invalidate(p spi.PointSPI) {\n\tfor _, d := range b.points {\n\t\tif sfp := d.scaleFactor; sfp != nil {\n\t\t\tif sfp.Id() == p.Id() {\n\t\t\t\td.SetValue(nil)\n\t\t\t}\n\t\t}\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 (f *fragment) InvalidateChecksums() {\n\tf.mu.Lock()\n\tf.checksums = make(map[int][]byte)\n\tf.mu.Unlock()\n}", "func FlushMappedBufferRange(target uint32, offset int, length int) {\n C.glowFlushMappedBufferRange(gpFlushMappedBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (f *Faces) Reset(c ui.Config) {\n\tf.config = c\n\tf.init()\n\tfor pk, p := range f.pathCache {\n\t\tif !p.active {\n\t\t\tdelete(f.pathCache, pk)\n\t\t\tcontinue\n\t\t}\n\t\tp.active = false\n\t\tf.pathCache[pk] = p\n\t}\n\tfor lk, l := range f.layoutCache {\n\t\tif !l.active {\n\t\t\tdelete(f.layoutCache, lk)\n\t\t\tcontinue\n\t\t}\n\t\tl.active = false\n\t\tf.layoutCache[lk] = l\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 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 (fb *FrameBuffer) Flush() error {\n\tfb.file.Seek(0, 0)\n\t_, err := fb.file.Write(fb.buf)\n\treturn err\n}", "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 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 (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 (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpInvalidateBufferSubData, 3, uintptr(buffer), uintptr(offset), uintptr(length))\n}", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\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 (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 (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func FlushMappedBufferRange(target uint32, offset int, length int) {\n\tsyscall.Syscall(gpFlushMappedBufferRange, 3, uintptr(target), uintptr(offset), uintptr(length))\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 FlushMappedBufferRange(target uint32, offset int, length int) {\n\tC.glowFlushMappedBufferRange(gpFlushMappedBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func FlushMappedBufferRange(target uint32, offset int, length int) {\n\tC.glowFlushMappedBufferRange(gpFlushMappedBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (c *Context) EraseDrawableList() {\n\tc.primitivesToDraw = make(map[uint32][]Drawable)\n}", "func (pp *PostProcessor) EndRender() {\n\t// Now resolve multisampled color-buffer into intermediate FBO to store to texture\n\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, pp.msFrameBuffer)\n\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, pp.frameBuffer)\n\tgl.BlitFramebuffer(0, 0, int32(pp.width), int32(pp.height), 0, 0, int32(pp.width), int32(pp.height), gl.COLOR_BUFFER_BIT, gl.NEAREST)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0) // Binds both READ and WRITE framebuffer to default framebuffer\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 (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 (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (a *Agent) flush() {\n\tif len(a.Buf) != 0 {\n\t\ta.Sketch.insert(agentConfig, a.Buf)\n\t\ta.Buf = nil\n\t}\n\n\tif len(a.CountBuf) != 0 {\n\t\ta.Sketch.insertCounts(agentConfig, a.CountBuf)\n\t\ta.CountBuf = nil\n\t}\n}", "func (b *Buffer) ClearAt(o int) {\n\tif o < len(b.Tiles) {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (bm Bitmap) Free(off uint64) {\n\tblockIndex := off / ItemsPerBitmap\n\tbyteIndex := (off / 8) % 4096\n\tbitIndex := off % 8\n\tbm[blockIndex][byteIndex] = bm[blockIndex][byteIndex] & ^(1 << bitIndex)\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 (n *BufferView) UnfocusBuffers() {\n\t// clear focus from buffers\n\tfor _, buffPane := range n.buffers {\n\t\tbuffPane.SetFocus(false)\n\t}\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 FlushMappedNamedBufferRange(buffer uint32, offset int, length int) {\n\tC.glowFlushMappedNamedBufferRange(gpFlushMappedNamedBufferRange, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func FlushMappedNamedBufferRange(buffer uint32, offset int, length int) {\n\tC.glowFlushMappedNamedBufferRange(gpFlushMappedNamedBufferRange, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (f *Flash) Clear() {\n\tfor k := range f.v {\n\t\tif !f.changed {\n\t\t\tf.changed = true\n\t\t}\n\t\tf.v.Del(k)\n\t}\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 (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 UnpatchAll() {\n\tfor funcAddr, funcBytes := range patchRecord {\n\t\tcopyToLocation(funcAddr, funcBytes)\n\t\tdelete(patchRecord, funcAddr)\n\t}\n}", "func (spriteBatch *SpriteBatch) flush() {\n\tspriteBatch.arrayBuf.bufferData()\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\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 FlushMappedNamedBufferRange(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpFlushMappedNamedBufferRange, 3, uintptr(buffer), uintptr(offset), uintptr(length))\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 (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 InvalidateTexImage(texture uint32, level int32) {\n\tsyscall.Syscall(gpInvalidateTexImage, 2, uintptr(texture), uintptr(level), 0)\n}", "func (v view) Clear() {\n\tfor i := 0; i < len(v.screen); i++ {\n\t\tv.screen[i].Clear()\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 (t *Text) Dirty() {\n\tt.dirty = true\n\tt.Start, t.End = 0, 0\n\tt.Scene.Resize.Notify()\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 (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\n\t)\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 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 (b *Buffer) Flush() error {\n\t// upload vertice + meta to opengl\n\tGlBindBuffer(ARRAY_BUFFER, b.GlBuffer)\n\tErrPanic()\n\tif len(b.Buf) == 0 {\n\t\treturn nil\n\t}\n\tGlBufferData(ARRAY_BUFFER, b.Buf, STATIC_DRAW)\n\tErrPanic()\n\t// FIXME: rebind shader attrs\n\tb.BufLen = len(b.Buf)\n\tb.Buf = b.Buf[:0]\n\treturn nil\n}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (imd *IMDraw) Clear() {\n\timd.tri.SetLen(0)\n\timd.batch.Dirty()\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\tsyscall.Syscall12(gpClearTexSubImage, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func (i *Image) restore() error {\n\tw, h := i.image.Size()\n\tif i.screen {\n\t\t// The screen image should also be recreated because framebuffer might\n\t\t// be changed.\n\t\ti.image = graphics.NewScreenFramebufferImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.volatile {\n\t\ti.image = graphics.NewImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.stale {\n\t\t// TODO: panic here?\n\t\treturn errors.New(\"restorable: pixels must not be stale when restoring\")\n\t}\n\tgimg := graphics.NewImage(w, h)\n\tif i.basePixels != nil {\n\t\tgimg.ReplacePixels(i.basePixels, 0, 0, w, h)\n\t} else {\n\t\t// Clear the image explicitly.\n\t\tpix := make([]uint8, w*h*4)\n\t\tgimg.ReplacePixels(pix, 0, 0, w, h)\n\t}\n\tfor _, c := range i.drawImageHistory {\n\t\t// All dependencies must be already resolved.\n\t\tif c.image.hasDependency() {\n\t\t\tpanic(\"not reached\")\n\t\t}\n\t\tvs := []float32{}\n\t\tfor _, v := range c.vertices {\n\t\t\tvs = append(vs, v...)\n\t\t}\n\t\tgimg.DrawImage(c.image.image, vs, c.colorm, c.mode, c.filter)\n\t}\n\ti.image = gimg\n\n\tvar err error\n\ti.basePixels, err = gimg.Pixels()\n\tif err != nil {\n\t\treturn err\n\t}\n\ti.drawImageHistory = nil\n\ti.stale = false\n\treturn nil\n}", "func (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\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\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 FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func DeleteFramebuffer(v Framebuffer) {\n\tgl.DeleteFramebuffers(1, &v.Value)\n}", "func (spriteBatch *SpriteBatch) ClearDrawRange() {\n\tspriteBatch.rangeMin = -1\n\tspriteBatch.rangeMax = -1\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 (g *Gui) flush() error {\n\t// termbox.Clear(termbox.Attribute(g.FgColor), termbox.Attribute(g.BgColor))\n\tw, h := g.screen.Size() // TODO: merge with maxX, maxY below\n\tfor row := 0; row < h; row++ {\n\t\tfor col := 0; col < w; col++ {\n\t\t\tg.screen.SetContent(col, row, ' ', nil, g.Style)\n\t\t}\n\t}\n\n\tmaxX, maxY := g.screen.Size()\n\t// if GUI's size has changed, we need to redraw all views\n\tif maxX != g.maxX || maxY != g.maxY {\n\t\tfor _, v := range g.views {\n\t\t\tv.tainted = true\n\t\t}\n\t}\n\tg.maxX, g.maxY = maxX, maxY\n\n\tfor _, m := range g.managers {\n\t\tif err := m.Layout(g); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tfor _, v := range g.views {\n\t\tif v.Frame {\n\t\t\t// var fgColor, bgColor Attribute\n\t\t\tst := g.Style\n\t\t\tif g.Highlight && v == g.currentView {\n\t\t\t\tst = g.SelStyle\n\t\t\t}\n\n\t\t\tif err := g.drawFrameEdges(v, st); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := g.drawFrameCorners(v, st); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif v.Title != \"\" {\n\t\t\t\tif err := g.drawTitle(v, st); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif err := g.draw(v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tg.screen.Show()\n\treturn nil\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 (c *cbox) reset(cellCount int) {\n\tc.trashc()\n\tc.ccnt = 0 // only spot where this is reset to 0\n\tif cellCount > c.cmax {\n\t\tcellCount = c.cmax\n\t}\n\tfor cnt := 0; cnt < cellCount; cnt++ {\n\t\tc.attach()\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 (d *Device) FlushMappedRanges(r ...MappedMemoryRange) error {\n\n\td.PhysicalDevice.VKPhysicalDeviceProperties.Limits.Deref()\n\n\tatomSize := d.PhysicalDevice.VKPhysicalDeviceProperties.Limits.NonCoherentAtomSize\n\n\tranges := make([]vk.MappedMemoryRange, len(r))\n\tfor i := range r {\n\t\tranges[i] = r[i].VKMappedMemoryRange()\n\n\t\t// we need to make sure the range is a mltiple of atomSize\n\t\tm := (ranges[i].Size % atomSize)\n\t\tranges[i].Size = ranges[i].Size - m + atomSize\n\n\t}\n\n\treturn vk.Error(vk.FlushMappedMemoryRanges(d.VKDevice, uint32(len(ranges)), ranges))\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func (d *Display) growBuffer(newX, newY int) {\n\tif newX < 0 || newY < 0 {\n\t\tpanic(\"coordinates must be 0 or greater\")\n\t}\n\tif newX < d.width && newY < d.height {\n\t\t// Coords already within buffer\n\t\treturn\n\t}\n\n\tnewWidth, newHeight := d.width, d.height\n\tif newX >= newWidth {\n\t\tnewWidth = newX + 1\n\t}\n\tif newY >= newHeight {\n\t\tnewHeight = newY + 1\n\t}\n\n\tif newWidth > d.width {\n\t\tfor y, row := range d.buffer {\n\t\t\t// Expand each row as needed\n\t\t\tnewRow := make([]byte, newWidth)\n\t\t\tcopy(newRow, row)\n\t\t\td.buffer[y] = newRow\n\t\t}\n\t}\n\tfor y := d.height - 1; y < newHeight; y++ {\n\t\t// Append new rows as needed, of width x coord\n\t\td.buffer = append(d.buffer, make([]byte, newWidth))\n\t}\n\td.width = newWidth\n\td.height = newHeight\n}", "func (t *Tile) Refine() {\n\tnorm := []uint8{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15}\n\tgray := []uint8{0, 1, 3, 2, 6, 7, 5, 4, 12, 13, 15, 14, 10, 11, 9, 8}\n\tseqs := [2][]uint8{norm, gray}\n\n\tx := t.IP.x\n\ty := t.IP.y\n\tv := t.a[x][y] + x + y\n\n\tif v&0x8 != 0 {\n\t\tfor i := 0; i < 16; i += 1 {\n\t\t\tfor j := 0; j < 8; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[i][15-j]\n\t\t\t\tt.a[i][15-j] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tif v&0x4 != 0 {\n\t\tfor i := 0; i < 8; i += 1 {\n\t\t\tfor j := 0; j < 16; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[15-i][j]\n\t\t\t\tt.a[15-i][j] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tif v&0x2 != 0 {\n\t\tfor i := 1; i < 16; i += 1 {\n\t\t\tfor j := 0; j < i; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[j][i]\n\t\t\t\tt.a[j][i] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tseq := seqs[v%2]\n\tvar status [16][16]uint8\n\n\tfor i := 0; i < 16; i += 1 {\n\t\tfor j := 0; j < 16; j += 1 {\n\t\t\tk := getIndex(seq, t.a[i][j])\n\t\tbacktrace:\n\t\t\tif t.notFixed(uint8(i), uint8(j)) {\n\t\t\t\tfor ; status[i][j] < 16; status[i][j] += 1 {\n\t\t\t\t\tif !t.Fitted(uint8(i), uint8(j), uint8(seq[k])) {\n\t\t\t\t\t\tk = (k + 1) % 16\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tt.a[i][j] = seq[k] + 16\n\t\t\t\t\tbreak\n\t\t\t\t}\n\n\t\t\t\t// no cadidate, need backtrace\n\t\t\t\tif status[i][j] == 16 {\n\t\t\t\t\tstatus[i][j] = 0\n\t\t\t\t\ti, j = t.prevCell(i, j)\n\n\t\t\t\t\tk = getIndex(seq, t.a[i][j]-16)\n\t\t\t\t\tk = (k + 1) % 16\n\t\t\t\t\tt.a[i][j] = seq[k]\n\t\t\t\t\tgoto backtrace\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i := 0; i < 16; i += 1 {\n\t\tfor j := 0; j < 16; j += 1 {\n\t\t\tt.a[i][j] = t.a[i][j] - 16\n\t\t}\n\t}\n}", "func (debugging *debuggingOpenGL) DeleteFramebuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteFramebuffers\", buffers)\n\tdebugging.gl.DeleteFramebuffers(buffers)\n\tdebugging.recordExit(\"DeleteFramebuffers\")\n}" ]
[ "0.6822423", "0.66477346", "0.6568386", "0.6559423", "0.6542912", "0.63519734", "0.6277841", "0.6277841", "0.6161295", "0.6161295", "0.6093057", "0.6093057", "0.5715403", "0.5618743", "0.55588067", "0.547038", "0.54432386", "0.5265134", "0.51767373", "0.5125759", "0.51059806", "0.51059806", "0.50943", "0.5090025", "0.50864136", "0.5077996", "0.5054083", "0.50530815", "0.5048036", "0.50167334", "0.5006745", "0.5001776", "0.49898747", "0.49512646", "0.49512646", "0.49323028", "0.49298295", "0.4913155", "0.49116862", "0.49081883", "0.49068406", "0.49068406", "0.488149", "0.48708248", "0.48704216", "0.48434514", "0.48364556", "0.48330384", "0.4829017", "0.4822073", "0.48174885", "0.48159245", "0.48075277", "0.48074535", "0.47993565", "0.47993565", "0.47980726", "0.47893643", "0.47867486", "0.47802263", "0.4769513", "0.47670403", "0.47652656", "0.47619313", "0.47572395", "0.47546613", "0.4750252", "0.4749103", "0.47269747", "0.47151056", "0.47132778", "0.47023633", "0.4701824", "0.46938542", "0.4692434", "0.46888506", "0.46725503", "0.46640438", "0.46582496", "0.46456787", "0.46289024", "0.46115232", "0.4610736", "0.4610736", "0.46088463", "0.46068636", "0.4602278", "0.46018255", "0.4601327", "0.4601327", "0.4584415", "0.45766807", "0.45700377", "0.45642766", "0.45595008", "0.4556696", "0.4554474", "0.45479345", "0.45461118" ]
0.6447339
6
invalidate the content of a region of some or all of a framebuffer's attachments
func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) { C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateNamedFramebufferSubData, 7, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateSubFramebuffer, 7, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateFramebuffer, 3, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateNamedFramebufferSubData(gpInvalidateNamedFramebufferSubData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateNamedFramebufferData, 3, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateNamedFramebufferData(gpInvalidateNamedFramebufferData, (C.GLuint)(framebuffer), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (b *block) invalidate(p spi.PointSPI) {\n\tfor _, d := range b.points {\n\t\tif sfp := d.scaleFactor; sfp != nil {\n\t\t\tif sfp.Id() == p.Id() {\n\t\t\t\td.SetValue(nil)\n\t\t\t}\n\t\t}\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 (f *fragment) InvalidateChecksums() {\n\tf.mu.Lock()\n\tf.checksums = make(map[int][]byte)\n\tf.mu.Unlock()\n}", "func FlushMappedBufferRange(target uint32, offset int, length int) {\n C.glowFlushMappedBufferRange(gpFlushMappedBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (f *Faces) Reset(c ui.Config) {\n\tf.config = c\n\tf.init()\n\tfor pk, p := range f.pathCache {\n\t\tif !p.active {\n\t\t\tdelete(f.pathCache, pk)\n\t\t\tcontinue\n\t\t}\n\t\tp.active = false\n\t\tf.pathCache[pk] = p\n\t}\n\tfor lk, l := range f.layoutCache {\n\t\tif !l.active {\n\t\t\tdelete(f.layoutCache, lk)\n\t\t\tcontinue\n\t\t}\n\t\tl.active = false\n\t\tf.layoutCache[lk] = l\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 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 (fb *FrameBuffer) Flush() error {\n\tfb.file.Seek(0, 0)\n\t_, err := fb.file.Write(fb.buf)\n\treturn err\n}", "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 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 (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 (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpInvalidateBufferSubData, 3, uintptr(buffer), uintptr(offset), uintptr(length))\n}", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\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 (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 (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func FlushMappedBufferRange(target uint32, offset int, length int) {\n\tsyscall.Syscall(gpFlushMappedBufferRange, 3, uintptr(target), uintptr(offset), uintptr(length))\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 FlushMappedBufferRange(target uint32, offset int, length int) {\n\tC.glowFlushMappedBufferRange(gpFlushMappedBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func FlushMappedBufferRange(target uint32, offset int, length int) {\n\tC.glowFlushMappedBufferRange(gpFlushMappedBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (c *Context) EraseDrawableList() {\n\tc.primitivesToDraw = make(map[uint32][]Drawable)\n}", "func (pp *PostProcessor) EndRender() {\n\t// Now resolve multisampled color-buffer into intermediate FBO to store to texture\n\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, pp.msFrameBuffer)\n\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, pp.frameBuffer)\n\tgl.BlitFramebuffer(0, 0, int32(pp.width), int32(pp.height), 0, 0, int32(pp.width), int32(pp.height), gl.COLOR_BUFFER_BIT, gl.NEAREST)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0) // Binds both READ and WRITE framebuffer to default framebuffer\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 (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 (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (a *Agent) flush() {\n\tif len(a.Buf) != 0 {\n\t\ta.Sketch.insert(agentConfig, a.Buf)\n\t\ta.Buf = nil\n\t}\n\n\tif len(a.CountBuf) != 0 {\n\t\ta.Sketch.insertCounts(agentConfig, a.CountBuf)\n\t\ta.CountBuf = nil\n\t}\n}", "func (b *Buffer) ClearAt(o int) {\n\tif o < len(b.Tiles) {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (bm Bitmap) Free(off uint64) {\n\tblockIndex := off / ItemsPerBitmap\n\tbyteIndex := (off / 8) % 4096\n\tbitIndex := off % 8\n\tbm[blockIndex][byteIndex] = bm[blockIndex][byteIndex] & ^(1 << bitIndex)\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 (n *BufferView) UnfocusBuffers() {\n\t// clear focus from buffers\n\tfor _, buffPane := range n.buffers {\n\t\tbuffPane.SetFocus(false)\n\t}\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 FlushMappedNamedBufferRange(buffer uint32, offset int, length int) {\n\tC.glowFlushMappedNamedBufferRange(gpFlushMappedNamedBufferRange, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func FlushMappedNamedBufferRange(buffer uint32, offset int, length int) {\n\tC.glowFlushMappedNamedBufferRange(gpFlushMappedNamedBufferRange, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (f *Flash) Clear() {\n\tfor k := range f.v {\n\t\tif !f.changed {\n\t\t\tf.changed = true\n\t\t}\n\t\tf.v.Del(k)\n\t}\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 (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 UnpatchAll() {\n\tfor funcAddr, funcBytes := range patchRecord {\n\t\tcopyToLocation(funcAddr, funcBytes)\n\t\tdelete(patchRecord, funcAddr)\n\t}\n}", "func (spriteBatch *SpriteBatch) flush() {\n\tspriteBatch.arrayBuf.bufferData()\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\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 FlushMappedNamedBufferRange(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpFlushMappedNamedBufferRange, 3, uintptr(buffer), uintptr(offset), uintptr(length))\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 (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 InvalidateTexImage(texture uint32, level int32) {\n\tsyscall.Syscall(gpInvalidateTexImage, 2, uintptr(texture), uintptr(level), 0)\n}", "func (v view) Clear() {\n\tfor i := 0; i < len(v.screen); i++ {\n\t\tv.screen[i].Clear()\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 (t *Text) Dirty() {\n\tt.dirty = true\n\tt.Start, t.End = 0, 0\n\tt.Scene.Resize.Notify()\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 (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\n\t)\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 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 (b *Buffer) Flush() error {\n\t// upload vertice + meta to opengl\n\tGlBindBuffer(ARRAY_BUFFER, b.GlBuffer)\n\tErrPanic()\n\tif len(b.Buf) == 0 {\n\t\treturn nil\n\t}\n\tGlBufferData(ARRAY_BUFFER, b.Buf, STATIC_DRAW)\n\tErrPanic()\n\t// FIXME: rebind shader attrs\n\tb.BufLen = len(b.Buf)\n\tb.Buf = b.Buf[:0]\n\treturn nil\n}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (imd *IMDraw) Clear() {\n\timd.tri.SetLen(0)\n\timd.batch.Dirty()\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\tsyscall.Syscall12(gpClearTexSubImage, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func (i *Image) restore() error {\n\tw, h := i.image.Size()\n\tif i.screen {\n\t\t// The screen image should also be recreated because framebuffer might\n\t\t// be changed.\n\t\ti.image = graphics.NewScreenFramebufferImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.volatile {\n\t\ti.image = graphics.NewImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.stale {\n\t\t// TODO: panic here?\n\t\treturn errors.New(\"restorable: pixels must not be stale when restoring\")\n\t}\n\tgimg := graphics.NewImage(w, h)\n\tif i.basePixels != nil {\n\t\tgimg.ReplacePixels(i.basePixels, 0, 0, w, h)\n\t} else {\n\t\t// Clear the image explicitly.\n\t\tpix := make([]uint8, w*h*4)\n\t\tgimg.ReplacePixels(pix, 0, 0, w, h)\n\t}\n\tfor _, c := range i.drawImageHistory {\n\t\t// All dependencies must be already resolved.\n\t\tif c.image.hasDependency() {\n\t\t\tpanic(\"not reached\")\n\t\t}\n\t\tvs := []float32{}\n\t\tfor _, v := range c.vertices {\n\t\t\tvs = append(vs, v...)\n\t\t}\n\t\tgimg.DrawImage(c.image.image, vs, c.colorm, c.mode, c.filter)\n\t}\n\ti.image = gimg\n\n\tvar err error\n\ti.basePixels, err = gimg.Pixels()\n\tif err != nil {\n\t\treturn err\n\t}\n\ti.drawImageHistory = nil\n\ti.stale = false\n\treturn nil\n}", "func (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\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\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 FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func DeleteFramebuffer(v Framebuffer) {\n\tgl.DeleteFramebuffers(1, &v.Value)\n}", "func (spriteBatch *SpriteBatch) ClearDrawRange() {\n\tspriteBatch.rangeMin = -1\n\tspriteBatch.rangeMax = -1\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 (g *Gui) flush() error {\n\t// termbox.Clear(termbox.Attribute(g.FgColor), termbox.Attribute(g.BgColor))\n\tw, h := g.screen.Size() // TODO: merge with maxX, maxY below\n\tfor row := 0; row < h; row++ {\n\t\tfor col := 0; col < w; col++ {\n\t\t\tg.screen.SetContent(col, row, ' ', nil, g.Style)\n\t\t}\n\t}\n\n\tmaxX, maxY := g.screen.Size()\n\t// if GUI's size has changed, we need to redraw all views\n\tif maxX != g.maxX || maxY != g.maxY {\n\t\tfor _, v := range g.views {\n\t\t\tv.tainted = true\n\t\t}\n\t}\n\tg.maxX, g.maxY = maxX, maxY\n\n\tfor _, m := range g.managers {\n\t\tif err := m.Layout(g); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tfor _, v := range g.views {\n\t\tif v.Frame {\n\t\t\t// var fgColor, bgColor Attribute\n\t\t\tst := g.Style\n\t\t\tif g.Highlight && v == g.currentView {\n\t\t\t\tst = g.SelStyle\n\t\t\t}\n\n\t\t\tif err := g.drawFrameEdges(v, st); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := g.drawFrameCorners(v, st); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif v.Title != \"\" {\n\t\t\t\tif err := g.drawTitle(v, st); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif err := g.draw(v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tg.screen.Show()\n\treturn nil\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 (c *cbox) reset(cellCount int) {\n\tc.trashc()\n\tc.ccnt = 0 // only spot where this is reset to 0\n\tif cellCount > c.cmax {\n\t\tcellCount = c.cmax\n\t}\n\tfor cnt := 0; cnt < cellCount; cnt++ {\n\t\tc.attach()\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 (d *Device) FlushMappedRanges(r ...MappedMemoryRange) error {\n\n\td.PhysicalDevice.VKPhysicalDeviceProperties.Limits.Deref()\n\n\tatomSize := d.PhysicalDevice.VKPhysicalDeviceProperties.Limits.NonCoherentAtomSize\n\n\tranges := make([]vk.MappedMemoryRange, len(r))\n\tfor i := range r {\n\t\tranges[i] = r[i].VKMappedMemoryRange()\n\n\t\t// we need to make sure the range is a mltiple of atomSize\n\t\tm := (ranges[i].Size % atomSize)\n\t\tranges[i].Size = ranges[i].Size - m + atomSize\n\n\t}\n\n\treturn vk.Error(vk.FlushMappedMemoryRanges(d.VKDevice, uint32(len(ranges)), ranges))\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func (d *Display) growBuffer(newX, newY int) {\n\tif newX < 0 || newY < 0 {\n\t\tpanic(\"coordinates must be 0 or greater\")\n\t}\n\tif newX < d.width && newY < d.height {\n\t\t// Coords already within buffer\n\t\treturn\n\t}\n\n\tnewWidth, newHeight := d.width, d.height\n\tif newX >= newWidth {\n\t\tnewWidth = newX + 1\n\t}\n\tif newY >= newHeight {\n\t\tnewHeight = newY + 1\n\t}\n\n\tif newWidth > d.width {\n\t\tfor y, row := range d.buffer {\n\t\t\t// Expand each row as needed\n\t\t\tnewRow := make([]byte, newWidth)\n\t\t\tcopy(newRow, row)\n\t\t\td.buffer[y] = newRow\n\t\t}\n\t}\n\tfor y := d.height - 1; y < newHeight; y++ {\n\t\t// Append new rows as needed, of width x coord\n\t\td.buffer = append(d.buffer, make([]byte, newWidth))\n\t}\n\td.width = newWidth\n\td.height = newHeight\n}", "func (t *Tile) Refine() {\n\tnorm := []uint8{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15}\n\tgray := []uint8{0, 1, 3, 2, 6, 7, 5, 4, 12, 13, 15, 14, 10, 11, 9, 8}\n\tseqs := [2][]uint8{norm, gray}\n\n\tx := t.IP.x\n\ty := t.IP.y\n\tv := t.a[x][y] + x + y\n\n\tif v&0x8 != 0 {\n\t\tfor i := 0; i < 16; i += 1 {\n\t\t\tfor j := 0; j < 8; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[i][15-j]\n\t\t\t\tt.a[i][15-j] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tif v&0x4 != 0 {\n\t\tfor i := 0; i < 8; i += 1 {\n\t\t\tfor j := 0; j < 16; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[15-i][j]\n\t\t\t\tt.a[15-i][j] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tif v&0x2 != 0 {\n\t\tfor i := 1; i < 16; i += 1 {\n\t\t\tfor j := 0; j < i; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[j][i]\n\t\t\t\tt.a[j][i] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tseq := seqs[v%2]\n\tvar status [16][16]uint8\n\n\tfor i := 0; i < 16; i += 1 {\n\t\tfor j := 0; j < 16; j += 1 {\n\t\t\tk := getIndex(seq, t.a[i][j])\n\t\tbacktrace:\n\t\t\tif t.notFixed(uint8(i), uint8(j)) {\n\t\t\t\tfor ; status[i][j] < 16; status[i][j] += 1 {\n\t\t\t\t\tif !t.Fitted(uint8(i), uint8(j), uint8(seq[k])) {\n\t\t\t\t\t\tk = (k + 1) % 16\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tt.a[i][j] = seq[k] + 16\n\t\t\t\t\tbreak\n\t\t\t\t}\n\n\t\t\t\t// no cadidate, need backtrace\n\t\t\t\tif status[i][j] == 16 {\n\t\t\t\t\tstatus[i][j] = 0\n\t\t\t\t\ti, j = t.prevCell(i, j)\n\n\t\t\t\t\tk = getIndex(seq, t.a[i][j]-16)\n\t\t\t\t\tk = (k + 1) % 16\n\t\t\t\t\tt.a[i][j] = seq[k]\n\t\t\t\t\tgoto backtrace\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i := 0; i < 16; i += 1 {\n\t\tfor j := 0; j < 16; j += 1 {\n\t\t\tt.a[i][j] = t.a[i][j] - 16\n\t\t}\n\t}\n}", "func (debugging *debuggingOpenGL) DeleteFramebuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteFramebuffers\", buffers)\n\tdebugging.gl.DeleteFramebuffers(buffers)\n\tdebugging.recordExit(\"DeleteFramebuffers\")\n}" ]
[ "0.6822423", "0.66477346", "0.6568386", "0.6559423", "0.6542912", "0.6447339", "0.6447339", "0.63519734", "0.6161295", "0.6161295", "0.6093057", "0.6093057", "0.5715403", "0.5618743", "0.55588067", "0.547038", "0.54432386", "0.5265134", "0.51767373", "0.5125759", "0.51059806", "0.51059806", "0.50943", "0.5090025", "0.50864136", "0.5077996", "0.5054083", "0.50530815", "0.5048036", "0.50167334", "0.5006745", "0.5001776", "0.49898747", "0.49512646", "0.49512646", "0.49323028", "0.49298295", "0.4913155", "0.49116862", "0.49081883", "0.49068406", "0.49068406", "0.488149", "0.48708248", "0.48704216", "0.48434514", "0.48364556", "0.48330384", "0.4829017", "0.4822073", "0.48174885", "0.48159245", "0.48075277", "0.48074535", "0.47993565", "0.47993565", "0.47980726", "0.47893643", "0.47867486", "0.47802263", "0.4769513", "0.47670403", "0.47652656", "0.47619313", "0.47572395", "0.47546613", "0.4750252", "0.4749103", "0.47269747", "0.47151056", "0.47132778", "0.47023633", "0.4701824", "0.46938542", "0.4692434", "0.46888506", "0.46725503", "0.46640438", "0.46582496", "0.46456787", "0.46289024", "0.46115232", "0.4610736", "0.4610736", "0.46088463", "0.46068636", "0.4602278", "0.46018255", "0.4601327", "0.4601327", "0.4584415", "0.45766807", "0.45700377", "0.45642766", "0.45595008", "0.4556696", "0.4554474", "0.45479345", "0.45461118" ]
0.6277841
9
invalidate the entirety a texture image
func InvalidateTexImage(texture uint32, level int32) { C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateTexImage(texture uint32, level int32) {\n\tsyscall.Syscall(gpInvalidateTexImage, 2, uintptr(texture), uintptr(level), 0)\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\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 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 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 (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\tsyscall.Syscall9(gpInvalidateTexSubImage, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), 0)\n}", "func (tex *Image) Free() {\n\tC.sfSprite_destroy(tex.sprite)\n\tC.sfTexture_destroy(tex.tex)\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 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 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 (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 (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 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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func (self *TileSprite) SetTintedTextureA(member *Canvas) {\n self.Object.Set(\"tintedTexture\", member)\n}", "func (self *TileSprite) SetRefreshTextureA(member bool) {\n self.Object.Set(\"refreshTexture\", member)\n}", "func (self *TileSprite) SetTexture(texture *Texture) {\n self.Object.Call(\"setTexture\", texture)\n}", "func (self *Graphics) UpdateCachedSpriteTexture() {\n self.Object.Call(\"updateCachedSpriteTexture\")\n}", "func (this *RectangleShape) SetTexture(texture *Texture, resetRect bool) {\n\tC.sfRectangleShape_setTexture(this.cptr, texture.cptr, goBool2C(resetRect))\n\tthis.texture = texture\n}", "func DeleteTexture(v Texture) {\n\tgl.DeleteTextures(1, &v.Value)\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 InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\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\tsyscall.Syscall12(gpClearTexSubImage, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\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 (cache *FrameCache) DropTextureForKey(key FrameCacheKey) {\n\tif tex, existing := cache.textures[key]; existing {\n\t\ttex.Dispose()\n\t\tdelete(cache.textures, key)\n\t}\n\tif pal, existing := cache.palettes[key]; existing {\n\t\tpal.Dispose()\n\t\tdelete(cache.palettes, key)\n\t}\n}", "func (obj *Device) UpdateTexture(sourceTexture, destTexture *BaseTexture) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.UpdateTexture,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(sourceTexture)),\n\t\tuintptr(unsafe.Pointer(destTexture)),\n\t)\n\treturn toErr(ret)\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (spriteBatch *SpriteBatch) SetTexture(newtexture ITexture) {\n\tspriteBatch.texture = newtexture\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 (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func OverwriteImage(buff draw.Image, img image.Image, x, y int) {\n\tdraw.Draw(buff, buff.Bounds(),\n\t\timg, image.Point{-x, -y}, draw.Src)\n}", "func updateTextureVbo(data []float32, vbo uint32) {\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferSubData(gl.ARRAY_BUFFER, 0, len(data)*4, gl.Ptr(data))\n\tgl.BindBuffer(gl.ARRAY_BUFFER, 0)\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 (i *ImageBuf) ResetSubImage(filename string, subimage, miplevel int, cache *ImageCache, config *ImageSpec) error {\n\tc_str := C.CString(filename)\n\tdefer C.free(unsafe.Pointer(c_str))\n\n\tvar cachePtr unsafe.Pointer = nil\n\tif cache != nil {\n\t\tcachePtr = cache.ptr\n\t}\n\n\tvar specPtr unsafe.Pointer = nil\n\tif config != nil {\n\t\tspecPtr = config.ptr\n\t}\n\n\tC.ImageBuf_reset_subimage(i.ptr, c_str, C.int(subimage), C.int(miplevel), cachePtr, specPtr)\n\terr := i.LastError()\n\truntime.KeepAlive(i)\n\treturn err\n}", "func (self *TileSprite) SetTilingTextureA(member *PIXITexture) {\n self.Object.Set(\"tilingTexture\", member)\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\tC.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 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\tC.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 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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\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 (me *Image) Free() {\n\timages.checkin(&imageKey{path: me.key.path, width: me.Width(), height: me.Height()})\n\tme.img = nil\n\tme.key.path = \"\"\n}", "func (t *Texture) Dispose() *Texture {\n\tt.p.Call(\"dispose\")\n\treturn t\n}", "func (f *Font) Release() {\n\tf.texture.Delete()\n\tgl.DeleteLists(f.listbase, len(f.config.Glyphs))\n\tf.config = nil\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 MakeEmpty() Texture {\n\treturn Texture{0, gl.TEXTURE_2D, 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 drawImageWithWrap(screen *ebiten.Image, spriteRender *c.SpriteRender) {\n\tsprite := spriteRender.SpriteSheet.Sprites[spriteRender.SpriteNumber]\n\ttexture := spriteRender.SpriteSheet.Texture\n\ttextureWidth, textureHeight := texture.Image.Size()\n\n\tstartX := int(math.Floor(float64(sprite.X) / float64(textureWidth)))\n\tstartY := int(math.Floor(float64(sprite.Y) / float64(textureHeight)))\n\n\tstopX := int(math.Ceil(float64(sprite.X+sprite.Width) / float64(textureWidth)))\n\tstopY := int(math.Ceil(float64(sprite.Y+sprite.Height) / float64(textureHeight)))\n\n\tcurrentX := 0\n\tfor indX := startX; indX < stopX; indX++ {\n\t\tleft := m.Max(0, sprite.X-indX*textureWidth)\n\t\tright := m.Min(textureWidth, sprite.X+sprite.Width-indX*textureWidth)\n\n\t\tcurrentY := 0\n\t\tfor indY := startY; indY < stopY; indY++ {\n\t\t\ttop := m.Max(0, sprite.Y-indY*textureHeight)\n\t\t\tbottom := m.Min(textureHeight, sprite.Y+sprite.Height-indY*textureHeight)\n\n\t\t\top := spriteRender.Options\n\t\t\top.GeoM.Translate(float64(currentX), float64(currentY))\n\t\t\tscreen.DrawImage(texture.Image.SubImage(image.Rect(left, top, right, bottom)).(*ebiten.Image), &op)\n\n\t\t\tcurrentY += bottom - top\n\t\t}\n\t\tcurrentX += right - left\n\t}\n}", "func (w *windowImpl) DeleteTexture(t *textureImpl) {\n\tif w.textures == nil {\n\t\treturn\n\t}\n\tdelete(w.textures, t)\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 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 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 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 InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (f *Font) Destroy() {\n\tf.Owner.gfx.DeleteTexture(f.Texture)\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 InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateSubFramebuffer, 7, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", 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 (gl *WebGL) UnbindTexture(target GLEnum) {\n\tgl.context.Call(\"bindTexture\", target, nil)\n}", "func (t Texture3D) Destroy() {\n\tgl.DeleteTextures(1, &t.id)\n}", "func (self *TileSprite) OnTextureUpdate(event interface{}) {\n self.Object.Call(\"onTextureUpdate\", event)\n}", "func (self *TileSprite) SetTextureI(args ...interface{}) {\n self.Object.Call(\"setTexture\", args)\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 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 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 (self *TileSprite) TintedTexture() *Canvas{\n return &Canvas{self.Object.Get(\"tintedTexture\")}\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 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 (i *Image) restore() error {\n\tw, h := i.image.Size()\n\tif i.screen {\n\t\t// The screen image should also be recreated because framebuffer might\n\t\t// be changed.\n\t\ti.image = graphics.NewScreenFramebufferImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.volatile {\n\t\ti.image = graphics.NewImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.stale {\n\t\t// TODO: panic here?\n\t\treturn errors.New(\"restorable: pixels must not be stale when restoring\")\n\t}\n\tgimg := graphics.NewImage(w, h)\n\tif i.basePixels != nil {\n\t\tgimg.ReplacePixels(i.basePixels, 0, 0, w, h)\n\t} else {\n\t\t// Clear the image explicitly.\n\t\tpix := make([]uint8, w*h*4)\n\t\tgimg.ReplacePixels(pix, 0, 0, w, h)\n\t}\n\tfor _, c := range i.drawImageHistory {\n\t\t// All dependencies must be already resolved.\n\t\tif c.image.hasDependency() {\n\t\t\tpanic(\"not reached\")\n\t\t}\n\t\tvs := []float32{}\n\t\tfor _, v := range c.vertices {\n\t\t\tvs = append(vs, v...)\n\t\t}\n\t\tgimg.DrawImage(c.image.image, vs, c.colorm, c.mode, c.filter)\n\t}\n\ti.image = gimg\n\n\tvar err error\n\ti.basePixels, err = gimg.Pixels()\n\tif err != nil {\n\t\treturn err\n\t}\n\ti.drawImageHistory = nil\n\ti.stale = false\n\treturn nil\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 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 (t *SinglePixelTexture) Draw(renderer *sdl.Renderer) {\n\trenderer.Copy(t.Texture, nil, &t.Rect)\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 (ld *LEDraw) Clear() {\n\tif ld.Image == nil {\n\t\tld.Init()\n\t}\n\tld.Paint.Clear(&ld.Render)\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateFramebuffer, 3, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func (self *Graphics) GenerateTexture() *Texture{\n return &Texture{self.Object.Call(\"generateTexture\")}\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 *GameObjectCreator) RenderTexture2O(width int, height int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height)}\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 ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\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 (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 (self *TileSprite) LoadTexture(key interface{}) {\n self.Object.Call(\"loadTexture\", key)\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 (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 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}" ]
[ "0.6743091", "0.6742461", "0.6200847", "0.61716896", "0.61586803", "0.57621473", "0.5760824", "0.5758504", "0.56996214", "0.5698484", "0.5684085", "0.5684085", "0.5672862", "0.5637319", "0.5628318", "0.5628318", "0.56129223", "0.560826", "0.5604292", "0.5582529", "0.5514876", "0.54785424", "0.5458858", "0.5450442", "0.53948987", "0.538892", "0.53883666", "0.53708273", "0.5358579", "0.5341845", "0.53397053", "0.5318405", "0.5287308", "0.52475625", "0.5247243", "0.52181536", "0.521763", "0.5214974", "0.52063406", "0.52045965", "0.52045965", "0.5200267", "0.51707137", "0.51707137", "0.51691073", "0.515266", "0.5136055", "0.512005", "0.5115581", "0.5114766", "0.5114766", "0.5110057", "0.5092537", "0.50894153", "0.5086514", "0.5085", "0.5070703", "0.5065954", "0.50619894", "0.50604486", "0.505531", "0.505531", "0.50551397", "0.5053573", "0.50337934", "0.5026971", "0.50222874", "0.50222874", "0.5006109", "0.500441", "0.50042135", "0.49953094", "0.49828422", "0.49828422", "0.49787116", "0.49729028", "0.49547362", "0.4945952", "0.49422574", "0.49318254", "0.4915176", "0.49062544", "0.490516", "0.49036226", "0.4901567", "0.48840985", "0.4882265", "0.48717013", "0.48708043", "0.4867895", "0.48593965", "0.48585647", "0.4857141", "0.48548338", "0.48532587", "0.48490062", "0.48490062", "0.4847885", "0.48463032" ]
0.62057275
3
invalidate a region of a texture image
func InvalidateTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32) { 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)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func InvalidateTexImage(texture uint32, level int32) {\n\tsyscall.Syscall(gpInvalidateTexImage, 2, uintptr(texture), uintptr(level), 0)\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (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 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 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 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 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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\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 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 (this *RectangleShape) SetTexture(texture *Texture, resetRect bool) {\n\tC.sfRectangleShape_setTexture(this.cptr, texture.cptr, goBool2C(resetRect))\n\tthis.texture = texture\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\tsyscall.Syscall12(gpClearTexSubImage, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func (self *TileSprite) SetRefreshTextureA(member bool) {\n self.Object.Set(\"refreshTexture\", member)\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, 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 (self *TileSprite) SetTexture(texture *Texture) {\n self.Object.Call(\"setTexture\", texture)\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\tC.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 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\tC.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 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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (self *TileSprite) SetTintedTextureA(member *Canvas) {\n self.Object.Set(\"tintedTexture\", member)\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 (spriteBatch *SpriteBatch) SetTexture(newtexture ITexture) {\n\tspriteBatch.texture = newtexture\n}", "func (obj *Device) UpdateTexture(sourceTexture, destTexture *BaseTexture) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.UpdateTexture,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(sourceTexture)),\n\t\tuintptr(unsafe.Pointer(destTexture)),\n\t)\n\treturn toErr(ret)\n}", "func (i *ImageBuf) ResetSubImage(filename string, subimage, miplevel int, cache *ImageCache, config *ImageSpec) error {\n\tc_str := C.CString(filename)\n\tdefer C.free(unsafe.Pointer(c_str))\n\n\tvar cachePtr unsafe.Pointer = nil\n\tif cache != nil {\n\t\tcachePtr = cache.ptr\n\t}\n\n\tvar specPtr unsafe.Pointer = nil\n\tif config != nil {\n\t\tspecPtr = config.ptr\n\t}\n\n\tC.ImageBuf_reset_subimage(i.ptr, c_str, C.int(subimage), C.int(miplevel), cachePtr, specPtr)\n\terr := i.LastError()\n\truntime.KeepAlive(i)\n\treturn err\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 (tex *Image) Free() {\n\tC.sfSprite_destroy(tex.sprite)\n\tC.sfTexture_destroy(tex.tex)\n}", "func OverwriteImage(buff draw.Image, img image.Image, x, y int) {\n\tdraw.Draw(buff, buff.Bounds(),\n\t\timg, image.Point{-x, -y}, draw.Src)\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\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 DeleteTexture(v Texture) {\n\tgl.DeleteTextures(1, &v.Value)\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 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 (self *Graphics) UpdateCachedSpriteTexture() {\n self.Object.Call(\"updateCachedSpriteTexture\")\n}", "func (spriteBatch *SpriteBatch) ClearDrawRange() {\n\tspriteBatch.rangeMin = -1\n\tspriteBatch.rangeMax = -1\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateSubFramebuffer, 7, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\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 (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 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 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 (this *RectangleShape) SetTextureRect(rect IntRect) {\n\tC.sfRectangleShape_setTextureRect(this.cptr, rect.toC())\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n C.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\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 InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tC.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (b *block) invalidate(p spi.PointSPI) {\n\tfor _, d := range b.points {\n\t\tif sfp := d.scaleFactor; sfp != nil {\n\t\t\tif sfp.Id() == p.Id() {\n\t\t\t\td.SetValue(nil)\n\t\t\t}\n\t\t}\n\t}\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\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 updateTextureVbo(data []float32, vbo uint32) {\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferSubData(gl.ARRAY_BUFFER, 0, len(data)*4, gl.Ptr(data))\n\tgl.BindBuffer(gl.ARRAY_BUFFER, 0)\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 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 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 *TileSprite) OnTextureUpdate(event interface{}) {\n self.Object.Call(\"onTextureUpdate\", event)\n}", "func InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateFramebuffer, 3, uintptr(target), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func (w *windowImpl) DeleteTexture(t *textureImpl) {\n\tif w.textures == nil {\n\t\treturn\n\t}\n\tdelete(w.textures, t)\n}", "func (gl *WebGL) UnbindTexture(target GLEnum) {\n\tgl.context.Call(\"bindTexture\", target, nil)\n}", "func (img *Image) Unmap() error {\n\treturn devUnmap(img)\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpInvalidateBufferSubData, 3, uintptr(buffer), uintptr(offset), uintptr(length))\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 (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 (m MappedImageSurface) Unmap() error {\n\terr := m.Err()\n\tmismux.Lock()\n\tdefer mismux.Unlock()\n\tfrom := mis[m.id()]\n\tC.cairo_surface_unmap_image(from, m.s)\n\tm.s = nil\n\treturn err\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 *TileSprite) SetTilingTextureA(member *PIXITexture) {\n self.Object.Set(\"tilingTexture\", member)\n}", "func (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\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 ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func (t *Tile) Refine() {\n\tnorm := []uint8{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15}\n\tgray := []uint8{0, 1, 3, 2, 6, 7, 5, 4, 12, 13, 15, 14, 10, 11, 9, 8}\n\tseqs := [2][]uint8{norm, gray}\n\n\tx := t.IP.x\n\ty := t.IP.y\n\tv := t.a[x][y] + x + y\n\n\tif v&0x8 != 0 {\n\t\tfor i := 0; i < 16; i += 1 {\n\t\t\tfor j := 0; j < 8; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[i][15-j]\n\t\t\t\tt.a[i][15-j] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tif v&0x4 != 0 {\n\t\tfor i := 0; i < 8; i += 1 {\n\t\t\tfor j := 0; j < 16; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[15-i][j]\n\t\t\t\tt.a[15-i][j] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tif v&0x2 != 0 {\n\t\tfor i := 1; i < 16; i += 1 {\n\t\t\tfor j := 0; j < i; j += 1 {\n\t\t\t\ttemp := t.a[i][j]\n\t\t\t\tt.a[i][j] = t.a[j][i]\n\t\t\t\tt.a[j][i] = temp\n\t\t\t}\n\t\t}\n\t}\n\n\tseq := seqs[v%2]\n\tvar status [16][16]uint8\n\n\tfor i := 0; i < 16; i += 1 {\n\t\tfor j := 0; j < 16; j += 1 {\n\t\t\tk := getIndex(seq, t.a[i][j])\n\t\tbacktrace:\n\t\t\tif t.notFixed(uint8(i), uint8(j)) {\n\t\t\t\tfor ; status[i][j] < 16; status[i][j] += 1 {\n\t\t\t\t\tif !t.Fitted(uint8(i), uint8(j), uint8(seq[k])) {\n\t\t\t\t\t\tk = (k + 1) % 16\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tt.a[i][j] = seq[k] + 16\n\t\t\t\t\tbreak\n\t\t\t\t}\n\n\t\t\t\t// no cadidate, need backtrace\n\t\t\t\tif status[i][j] == 16 {\n\t\t\t\t\tstatus[i][j] = 0\n\t\t\t\t\ti, j = t.prevCell(i, j)\n\n\t\t\t\t\tk = getIndex(seq, t.a[i][j]-16)\n\t\t\t\t\tk = (k + 1) % 16\n\t\t\t\t\tt.a[i][j] = seq[k]\n\t\t\t\t\tgoto backtrace\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i := 0; i < 16; i += 1 {\n\t\tfor j := 0; j < 16; j += 1 {\n\t\t\tt.a[i][j] = t.a[i][j] - 16\n\t\t}\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 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 (tx *TextureBase) Delete(sc *Scene) {\n\tif tx.Tex != nil {\n\t\ttx.Tex.Delete()\n\t}\n\ttx.Tex = nil\n}", "func (cache *FrameCache) DropTextureForKey(key FrameCacheKey) {\n\tif tex, existing := cache.textures[key]; existing {\n\t\ttex.Dispose()\n\t\tdelete(cache.textures, key)\n\t}\n\tif pal, existing := cache.palettes[key]; existing {\n\t\tpal.Dispose()\n\t\tdelete(cache.palettes, key)\n\t}\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func (self *TileSprite) SetTextureI(args ...interface{}) {\n self.Object.Call(\"setTexture\", args)\n}", "func (t *SinglePixelTexture) Draw(renderer *sdl.Renderer) {\n\trenderer.Copy(t.Texture, nil, &t.Rect)\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 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 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 (me *Image) Free() {\n\timages.checkin(&imageKey{path: me.key.path, width: me.Width(), height: me.Height()})\n\tme.img = nil\n\tme.key.path = \"\"\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 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 (f *Font) Release() {\n\tf.texture.Delete()\n\tgl.DeleteLists(f.listbase, len(f.config.Glyphs))\n\tf.config = nil\n}", "func (t *Texture) Dispose() *Texture {\n\tt.p.Call(\"dispose\")\n\treturn 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 TextureBufferRange(texture uint32, internalformat uint32, buffer uint32, offset int, size int) {\n\tC.glowTextureBufferRange(gpTextureBufferRange, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func TextureBufferRange(texture uint32, internalformat uint32, buffer uint32, offset int, size int) {\n\tC.glowTextureBufferRange(gpTextureBufferRange, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\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 InvalidateFramebuffer(target uint32, numAttachments int32, attachments *uint32) {\n\tC.glowInvalidateFramebuffer(gpInvalidateFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)))\n}" ]
[ "0.6771784", "0.67017794", "0.6551989", "0.6234568", "0.6210605", "0.6210605", "0.59059966", "0.58877206", "0.5837811", "0.5821742", "0.56010014", "0.5569015", "0.5484221", "0.5434558", "0.5401425", "0.53949165", "0.53861105", "0.53861105", "0.5382014", "0.5382014", "0.53571576", "0.53571576", "0.5326184", "0.53254366", "0.5293014", "0.52843046", "0.5235449", "0.5204586", "0.5174797", "0.5167824", "0.5163778", "0.5149411", "0.51093274", "0.50775486", "0.50775486", "0.50695354", "0.50656253", "0.5061947", "0.50590956", "0.5053495", "0.5037971", "0.50322974", "0.5027663", "0.5018782", "0.5018782", "0.50118655", "0.50076544", "0.4998723", "0.49986225", "0.49986225", "0.4991006", "0.4991006", "0.49564248", "0.4938319", "0.4936395", "0.49102324", "0.48995095", "0.4854848", "0.4850735", "0.48494563", "0.48473674", "0.48434868", "0.48411533", "0.48400107", "0.48376802", "0.48333478", "0.48313567", "0.48288503", "0.48269752", "0.48251107", "0.4823686", "0.48115242", "0.48096317", "0.48063385", "0.4799822", "0.47803956", "0.47660968", "0.47617203", "0.47502849", "0.47502849", "0.47400594", "0.47347203", "0.47178063", "0.47111633", "0.47025084", "0.47004285", "0.46952203", "0.46873945", "0.46873945", "0.46819943", "0.46819943", "0.4680204", "0.46769705", "0.46710107", "0.46693146", "0.46693146", "0.4660679", "0.4660679", "0.4657988" ]
0.60835135
7
determine if a name corresponds to a buffer object
func IsBuffer(buffer uint32) bool { ret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (a *Asset) IsBuffered() bool {\n\treturn isBufferName(a.OutName)\n}", "func IsBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func IsBuffer(buffer uint32) bool {\n ret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n return ret == TRUE\n}", "func IsBuffer(b Buffer) bool {\n\treturn gl.IsBuffer(b.Value)\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpUnmapNamedBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func (e *ObservableEditableBuffer) Name() string {\n\treturn e.details.Name\n}", "func (s *server) bytestreamBlobName(bytestream string) (*pb.Digest, bool, error) {\n\tmatches := s.bytestreamRe.FindStringSubmatch(bytestream)\n\tif matches == nil {\n\t\treturn nil, false, status.Errorf(codes.InvalidArgument, \"invalid ResourceName: %s\", bytestream)\n\t}\n\tsize, _ := strconv.Atoi(matches[3])\n\treturn &pb.Digest{\n\t\tHash: matches[2],\n\t\tSizeBytes: int64(size),\n\t}, matches[1] == \"compressed-blobs/zstd\", nil\n}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func IsBuffer(buffer Uint) Boolean {\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\t__ret := C.glIsBuffer(cbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func (g *grpc) objectNamed(name string) generator.Object {\n\tg.gen.RecordTypeUse(name)\n\treturn g.gen.ObjectNamed(name)\n}", "func (b *Buffer) GetName() string {\n\treturn b.name\n}", "func IsValidObjectName(object string) bool {\n\tif strings.TrimSpace(object) == \"\" {\n\t\treturn false\n\t}\n\tif len(object) > 1024 || len(object) == 0 {\n\t\treturn false\n\t}\n\tif !utf8.ValidString(object) {\n\t\treturn false\n\t}\n\treturn true\n}", "func (g *Name) UnmarshalFromBuffer(buffer *binutils.Buffer) (err error) {\n\tvar dataBytes []byte\n\tif err = buffer.ReadBytes(&dataBytes, grammemeNameLength); err != nil {\n\t\treturn err\n\t}\n\n\t*g = Name(dataBytes)\n\t// if empty name reduce to empty string\n\tif *g == \" \" {\n\t\t*g = \"\"\n\t}\n\n\treturn err\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 isNamedType(t types.Type, path, name string) bool {\n\tn, ok := t.(*types.Named)\n\tif !ok {\n\t\treturn false\n\t}\n\tobj := n.Obj()\n\treturn obj.Name() == name && obj.Pkg() != nil && obj.Pkg().Path() == path\n}", "func (lg *logger) checkBuffer() string {\n\n\tif len(lg.buffer.Data) > 0 {\n\t\tjsn, err := json.Marshal(lg.buffer.Data)\n\t\tlg.buffer.Data = make(dataMap)\n\t\tif err != nil {\n\t\t\treturn fmt.Sprintf(\"formatErr: %v\", err)\n\t\t}\n\t\treturn string(jsn)\n\t}\n\n\tlg.buffer.Tags = make(tagMap)\n\treturn \"\"\n\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tsyscall.Syscall(gpNamedFramebufferReadBuffer, 2, uintptr(framebuffer), uintptr(src), 0)\n}", "func (d *dubbogo) objectNamed(name string) generator.Object {\n d.gen.RecordTypeUse(name)\n return d.gen.ObjectNamed(name)\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (*Component_Memory) IsYANGGoStruct() {}", "func (i *ImageBuf) Name() string {\n\tret := C.GoString(C.ImageBuf_name(i.ptr))\n\truntime.KeepAlive(i)\n\treturn ret\n}", "func (*NamedType) isType() {}", "func IsNameChar(r byte) bool {\n\treturn false ||\n\t\t'a' <= r && r <= 'z' ||\n\t\t'A' <= r && r <= 'Z' ||\n\t\t'0' <= r && r <= '9' ||\n\t\tr == '.' || r == '_' ||\n\t\tr == '-' || r == '*' ||\n\t\tr == '?' || r == ':' ||\n\t\tr == '[' || r == ']' ||\n\t\tr == '^' || r == '$' ||\n\t\tr == '<' || r == '>' ||\n\t\tr == '&' || r == '#' ||\n\t\tr == '/' || r == '%' ||\n\t\tr == '@'\n}", "func (me TdtypeType) IsFrame() bool { return me.String() == \"frame\" }", "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 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 (*Component_Backplane) IsYANGGoStruct() {}", "func (*Component_Transceiver) IsYANGGoStruct() {}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func (*Object) Name() string { return \"object\" }", "func (bo *BytesObj) IsObject() bool {\n\tif bo == nil {\n\t\treturn false\n\t}\n\treturn bo.tp&isObj == isObj\n}", "func (e *editor) indexOfBuffer(element *buffer) int {\n\tfor k, v := range e.buffers {\n\t\tif element == v {\n\t\t\treturn k\n\t\t}\n\t}\n\treturn -1 //not found.\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\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 isNamedParam(str string) bool {\n\treturn namedParamRegx.MatchString(str)\n}", "func nameChar(c byte) bool {\n\treturn 'a' <= c && c <= 'z' || 'A' <= c && c <= 'Z' || c == '_' || c > 127 ||\n\t\tc == '-' || '0' <= c && c <= '9'\n}", "func nameChar(c byte) bool {\n\treturn 'a' <= c && c <= 'z' || 'A' <= c && c <= 'Z' || c == '_' || c > 127 ||\n\t\tc == '-' || '0' <= c && c <= '9'\n}", "func (o *GstObj) SetName(name string) bool {\n\ts := C.CString(name)\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_object_set_name(o.g(), (*C.gchar)(s)) != 0\n}", "func check(t *testing.T, testname string, buf *Buffer, s string) {\n\tbytes := buf.Bytes()\n\tstr := buf.String()\n\tif buf.Len() != len(bytes) {\n\t\tt.Errorf(\"%s: buf.Len() == %d, len(buf.Bytes()) == %d\", testname, buf.Len(), len(bytes))\n\t}\n\n\tif buf.Len() != len(str) {\n\t\tt.Errorf(\"%s: buf.Len() == %d, len(buf.String()) == %d\", testname, buf.Len(), len(str))\n\t}\n\n\tif buf.Len() != len(s) {\n\t\tt.Errorf(\"%s: buf.Len() == %d, len(s) == %d\", testname, buf.Len(), len(s))\n\t}\n\n\tif string(bytes) != s {\n\t\tt.Errorf(\"%s: string(buf.Bytes()) == %q, s == %q\", testname, string(bytes), s)\n\t}\n}", "func (e *Event) HasName(name string) bool {\n\ts := (*C.gchar)(C.CString(name))\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_event_has_name(e.g(), s) != 0\n}", "func (*Device) IsYANGGoStruct() {}", "func (*Device) IsYANGGoStruct() {}", "func (*Device) IsYANGGoStruct() {}", "func (*Device) IsYANGGoStruct() {}", "func (*Device) IsYANGGoStruct() {}", "func (*Device) IsYANGGoStruct() {}", "func (*Device) IsYANGGoStruct() {}", "func (bm BitMap) Name() string { return bm.name }", "func isKnown(typeURL string, nodeId string, names []string) bool {\n\tstId := streamId{\n\t\tTypeUrl: typeURL,\n\t\tNodeId: nodeId,\n\t}\n\n\tswitch typeURL {\n\tcase \"type.googleapis.com/envoy.api.v2.Cluster\":\n\t\t// either the key (unique name) or the value (name known to EDS) will work\n\t\tret := true\n\t\tfor _, n := range names {\n\t\t\tfoundMatch := false\n\t\t\tfor k, v := range streamCache[stId] {\n\t\t\t\tif n == k || n == v {\n\t\t\t\t\tfoundMatch = true\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t\tret = ret && foundMatch\n\t\t\t// no need to check other names if that one wasn't found\n\t\t\tif !ret {\n\t\t\t\treturn ret\n\t\t\t}\n\t\t}\n\t\treturn ret\n\tcase \"type.googleapis.com/envoy.api.v2.Listener\":\n\t\tret := true\n\t\tfor _, n := range names {\n\t\t\t_, ok := streamCache[stId][n]\n\t\t\tret = ret && ok\n\t\t}\n\t\treturn ret\n\tdefault:\n\t\tfmt.Println(\"isKnown: unknown typeURL\", typeURL)\n\t}\n\treturn true\n}", "func iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func (arg1 *UConverter) IsAmbiguous() (_swig_ret UBool)", "func isBlock(name string, arch arch) bool {\n\tfor _, b := range genericBlocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\tfor _, b := range arch.blocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (*Component_Port) IsYANGGoStruct() {}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (*Component_Fan) IsYANGGoStruct() {}", "func (*Component_Fabric) IsYANGGoStruct() {}", "func (*Component_Transceiver_Channel) IsYANGGoStruct() {}", "func nameStart(c byte) bool {\n\treturn 'a' <= c && c <= 'z' || 'A' <= c && c <= 'Z' || c == '_' || c > 127\n}", "func nameStart(c byte) bool {\n\treturn 'a' <= c && c <= 'z' || 'A' <= c && c <= 'Z' || c == '_' || c > 127\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpNamedBufferSubData, 4, uintptr(buffer), uintptr(offset), uintptr(size), uintptr(data), 0, 0)\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (*Component_Port_BreakoutMode) IsYANGGoStruct() {}", "func (s *JSONStructFinder) isExported(nodeType *ast.TypeSpec) bool {\n\tfirstRune, _ := utf8.DecodeRuneInString(nodeType.Name.Name)\n\treturn unicode.IsUpper(firstRune)\n}", "func (*OpenconfigPlatform_Components_Component_Backplane) IsYANGGoStruct() {}", "func CompareByMarshall(a interface{}, b interface{}) bool {\n\taBytes, err := json.Marshal(a)\n\tif err != nil {\n\t\treturn true\n\t}\n\n\tbBytes, err := json.Marshal(b)\n\tif err != nil {\n\t\treturn true\n\t}\n\n\tif bytes.Compare(aBytes, bBytes) != 0 {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (*NamedTypeDummy) isType() {}", "func (*ReadStakingDataRequest_CandidateByName) Descriptor() ([]byte, []int) {\n\treturn file_proto_api_read_state_proto_rawDescGZIP(), []int{2, 4}\n}", "func (m *CardMutation) Name() (r string, exists bool) {\n\tv := m.name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowNamedBufferSubData(gpNamedBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowNamedBufferSubData(gpNamedBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func (cc *CloneCommand) NameIsID() bool {\n\treturn cc.RepositoryName == \"\"\n}", "func isExported(name string) bool {\n rune, _ := utf8.DecodeRuneInString(name)\n return unicode.IsUpper(rune)\n}", "func Is(any *any.Any, pb proto.Message) bool {\n\taname, err := AnyMessageName(any)\n\tif err != nil {\n\t\treturn false\n\t}\n\n\treturn aname == proto.MessageName(pb)\n}", "func (p *ProtobufSerializer) Name() string {\n\treturn \"protobuf\"\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func isValidName(name string) bool { return name != \"_\" && name != \"this\" }", "func (me TAttlistSupplMeshNameType) IsProtocol() bool { return me.String() == \"Protocol\" }", "func (o *ConnectorTypeAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *ConnectorTypeAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (*OpenconfigQos_Qos_Queues_Queue_Red) IsYANGGoStruct() {}", "func (*Component_Transceiver_PreFecBer) IsYANGGoStruct() {}", "func IsExportedName(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func (bl *LogBuffer) Name() string {\n\treturn bl.logger.Name()\n}", "func (o *ObjectRef) IsInstanceOf(env *Env, className string) (bool, error) {\n\tclass, err := env.callFindClass(className)\n\tif err != nil {\n\t\treturn false, err\n\t}\n\treturn toBool(isInstanceOf(env.jniEnv, o.jobject, class)), nil\n}", "func (*Component_Chassis) IsYANGGoStruct() {}", "func isClass(ln []byte) bool { return (ln[0] == 'C') }", "func isServerClientBodyInSingleBufferDirective(directive string) bool {\n\tif isEqualString(directive, ServerClientBodyInSingleBufferDirective) {\n\t\treturn true\n\t}\n\treturn false\n}", "func isZoneInfoFile(buf []byte) bool {\n\treturn bytes.Index(buf, []byte(zoneInfoFileHeaderSignatureString)) != -1\n}", "func (util copyHandlerUtil) matchBlobNameAgainstPattern(pattern string, blobName string, recursive bool) bool {\n\tif recursive {\n\t\treturn util.blobNameMatchesThePattern(pattern, blobName)\n\t}\n\treturn util.blobNameMatchesThePatternComponentWise(pattern, blobName)\n}", "func (*DeviceGroup_DeviceGroup) IsYANGGoStruct() {}", "func (me TdtypeType) IsPacket() bool { return me.String() == \"packet\" }", "func (*Component_Storage) IsYANGGoStruct() {}" ]
[ "0.58095646", "0.5707791", "0.56482685", "0.55564255", "0.5483852", "0.5476433", "0.5455121", "0.54406893", "0.53823435", "0.5381958", "0.53701556", "0.53518474", "0.5342713", "0.5336536", "0.5293513", "0.5249319", "0.5236945", "0.5214685", "0.51958483", "0.5146106", "0.51134235", "0.51134235", "0.5112981", "0.51047415", "0.5090112", "0.50799274", "0.5076719", "0.5065733", "0.5065733", "0.5063734", "0.50619066", "0.504726", "0.50373214", "0.50373214", "0.50299233", "0.5021453", "0.5015128", "0.4965075", "0.49536303", "0.49536303", "0.49522838", "0.49429646", "0.49429646", "0.49391854", "0.49099115", "0.48950404", "0.48895186", "0.48895186", "0.48895186", "0.48895186", "0.48895186", "0.48895186", "0.48895186", "0.48880798", "0.48866454", "0.48807773", "0.48752257", "0.48591107", "0.4846117", "0.4845331", "0.48437467", "0.48374772", "0.48216596", "0.48134425", "0.48127636", "0.48127636", "0.4806179", "0.4781308", "0.47799334", "0.477784", "0.477456", "0.47702035", "0.47624168", "0.4757965", "0.47555238", "0.47554687", "0.47554687", "0.4752005", "0.47439024", "0.47438195", "0.47430453", "0.47385305", "0.47228307", "0.4720682", "0.47176164", "0.47176164", "0.47108507", "0.4707424", "0.46980536", "0.46962726", "0.46953428", "0.46895233", "0.46880373", "0.46869597", "0.46831512", "0.46821567", "0.46798113", "0.467587", "0.46709016" ]
0.53153306
15
determine if a name corresponds to a framebuffer object
func IsFramebuffer(framebuffer uint32) bool { ret := C.glowIsFramebuffer(gpIsFramebuffer, (C.GLuint)(framebuffer)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func IsFramebuffer(framebuffer uint32) bool {\n ret := C.glowIsFramebuffer(gpIsFramebuffer, (C.GLuint)(framebuffer))\n return ret == TRUE\n}", "func IsFramebuffer(framebuffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsFramebuffer, 1, uintptr(framebuffer), 0, 0)\n\treturn ret != 0\n}", "func IsFramebuffer(fb Framebuffer) bool {\n\treturn gl.IsFramebuffer(fb.Value)\n}", "func IsFramebuffer(framebuffer Uint) Boolean {\n\tcframebuffer, _ := (C.GLuint)(framebuffer), cgoAllocsUnknown\n\t__ret := C.glIsFramebuffer(cframebuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func CheckNamedFramebufferStatus(framebuffer uint32, target uint32) uint32 {\n\tret, _, _ := syscall.Syscall(gpCheckNamedFramebufferStatus, 2, uintptr(framebuffer), uintptr(target), 0)\n\treturn (uint32)(ret)\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpNamedFramebufferRenderbuffer, 4, uintptr(framebuffer), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func CheckNamedFramebufferStatus(framebuffer uint32, target uint32) uint32 {\n\tret := C.glowCheckNamedFramebufferStatus(gpCheckNamedFramebufferStatus, (C.GLuint)(framebuffer), (C.GLenum)(target))\n\treturn (uint32)(ret)\n}", "func CheckNamedFramebufferStatus(framebuffer uint32, target uint32) uint32 {\n\tret := C.glowCheckNamedFramebufferStatus(gpCheckNamedFramebufferStatus, (C.GLuint)(framebuffer), (C.GLenum)(target))\n\treturn (uint32)(ret)\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tsyscall.Syscall(gpNamedFramebufferReadBuffer, 2, uintptr(framebuffer), uintptr(src), 0)\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func IsRenderbuffer(renderbuffer uint32) bool {\n ret := C.glowIsRenderbuffer(gpIsRenderbuffer, (C.GLuint)(renderbuffer))\n return ret == TRUE\n}", "func IsBuffer(buffer uint32) bool {\n ret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n return ret == TRUE\n}", "func BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tsyscall.Syscall12(gpBlitNamedFramebuffer, 12, uintptr(readFramebuffer), uintptr(drawFramebuffer), uintptr(srcX0), uintptr(srcY0), uintptr(srcX1), uintptr(srcY1), uintptr(dstX0), uintptr(dstY0), uintptr(dstX1), uintptr(dstY1), uintptr(mask), uintptr(filter))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitNamedFramebuffer(gpBlitNamedFramebuffer, (C.GLuint)(readFramebuffer), (C.GLuint)(drawFramebuffer), (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 BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitNamedFramebuffer(gpBlitNamedFramebuffer, (C.GLuint)(readFramebuffer), (C.GLuint)(drawFramebuffer), (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 (DrawTexture) IsDrawAction() {}", "func (bm BitMap) Name() string { return bm.name }", "func (me TdtypeType) IsFrame() bool { return me.String() == \"frame\" }", "func (self *Graphics) Exists() bool{\n return self.Object.Get(\"exists\").Bool()\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) InCamera() bool{\n return self.Object.Get(\"inCamera\").Bool()\n}", "func (me TxsdFeBlendTypeMode) IsScreen() bool { return me.String() == \"screen\" }", "func (s *server) bytestreamBlobName(bytestream string) (*pb.Digest, bool, error) {\n\tmatches := s.bytestreamRe.FindStringSubmatch(bytestream)\n\tif matches == nil {\n\t\treturn nil, false, status.Errorf(codes.InvalidArgument, \"invalid ResourceName: %s\", bytestream)\n\t}\n\tsize, _ := strconv.Atoi(matches[3])\n\treturn &pb.Digest{\n\t\tHash: matches[2],\n\t\tSizeBytes: int64(size),\n\t}, matches[1] == \"compressed-blobs/zstd\", nil\n}", "func IsBuffer(buffer uint32) bool {\n\tret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func IsBuffer(buffer uint32) bool {\n\tret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func (f *Framebuffer) Object() interface{} {\n\treturn f.o\n}", "func IsRenderbuffer(renderbuffer uint32) bool {\n\tret := C.glowIsRenderbuffer(gpIsRenderbuffer, (C.GLuint)(renderbuffer))\n\treturn ret == TRUE\n}", "func IsRenderbuffer(renderbuffer uint32) bool {\n\tret := C.glowIsRenderbuffer(gpIsRenderbuffer, (C.GLuint)(renderbuffer))\n\treturn ret == TRUE\n}", "func IsRenderbuffer(renderbuffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsRenderbuffer, 1, uintptr(renderbuffer), 0, 0)\n\treturn ret != 0\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tsyscall.Syscall6(gpNamedFramebufferTextureLayer, 5, uintptr(framebuffer), uintptr(attachment), uintptr(texture), uintptr(level), uintptr(layer), 0)\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffers, 3, uintptr(framebuffer), uintptr(n), uintptr(unsafe.Pointer(bufs)))\n}", "func IsQuery(id uint32) bool {\n ret := C.glowIsQuery(gpIsQuery, (C.GLuint)(id))\n return ret == TRUE\n}", "func (self *Graphics) Name() string{\n return self.Object.Get(\"name\").String()\n}", "func IsRenderbuffer(renderbuffer Uint) Boolean {\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\t__ret := C.glIsRenderbuffer(crenderbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func (renderbuffer Renderbuffer) IsRenderbuffer() bool {\n\treturn gl.IsRenderbuffer(uint32(renderbuffer))\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpNamedRenderbufferStorage, 4, uintptr(renderbuffer), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\n}", "func (e *Event) HasName(name string) bool {\n\ts := (*C.gchar)(C.CString(name))\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_event_has_name(e.g(), s) != 0\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (*Component_Fabric) IsYANGGoStruct() {}", "func IsBuffer(buffer Uint) Boolean {\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\t__ret := C.glIsBuffer(cbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpUnmapNamedBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\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 NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tC.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tC.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CheckFramebufferStatus(target uint32) uint32 {\n ret := C.glowCheckFramebufferStatus(gpCheckFramebufferStatus, (C.GLenum)(target))\n return (uint32)(ret)\n}", "func (f Frame) name() string {\n\tfn := runtime.FuncForPC(f.pc())\n\tif fn == nil {\n\t\treturn \"unknown\"\n\t}\n\treturn fn.Name()\n}", "func (self *Graphics) Fresh() bool{\n return self.Object.Get(\"fresh\").Bool()\n}", "func (self *TileSprite) FrameName() string{\n return self.Object.Get(\"frameName\").String()\n}", "func NeedFrame(name string) bool {\n\t_, ok := noFrameWindowFuncs[strings.ToLower(name)]\n\treturn !ok\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func (self *Graphics) FixedToCamera() bool{\n return self.Object.Get(\"fixedToCamera\").Bool()\n}", "func iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func (*Object) Name() string { return \"object\" }", "func (*Component_Backplane) IsYANGGoStruct() {}", "func (self *Graphics) Contains(child *DisplayObject) bool{\n return self.Object.Call(\"contains\", child).Bool()\n}", "func (debugging *debuggingOpenGL) CheckFramebufferStatus(target uint32) uint32 {\n\tdebugging.recordEntry(\"CheckFramebufferStatus\", target)\n\tresult := debugging.gl.CheckFramebufferStatus(target)\n\tdebugging.recordExit(\"CheckFramebufferStatus\")\n\treturn result\n}", "func IsRenderbuffer(rb Renderbuffer) bool {\n\treturn gl.IsRenderbuffer(rb.Value)\n}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func NamedFramebufferParameteri(framebuffer uint32, pname uint32, param int32) {\n\tsyscall.Syscall(gpNamedFramebufferParameteri, 3, uintptr(framebuffer), uintptr(pname), uintptr(param))\n}", "func (*NamedType) isType() {}", "func (g *Game) nameOf(x, y int) string {\n\treturn fmt.Sprintf(\"%s%d\", string('a'+x), y+1)\n}", "func (t *ByteEntity) ScreenName() (string, bool) {\n\treturn t.screenName, t.screenNameIsSet\n}", "func (self *Tween) FrameBased() bool{\n return self.Object.Get(\"frameBased\").Bool()\n}", "func (self *Graphics) IsMask() bool{\n return self.Object.Get(\"isMask\").Bool()\n}", "func (*OpenconfigPlatform_Components_Component_Fabric) IsYANGGoStruct() {}", "func IsValidObjectName(object string) bool {\n\tif strings.TrimSpace(object) == \"\" {\n\t\treturn false\n\t}\n\tif len(object) > 1024 || len(object) == 0 {\n\t\treturn false\n\t}\n\tif !utf8.ValidString(object) {\n\t\treturn false\n\t}\n\treturn true\n}", "func (i *ImageBuf) Name() string {\n\tret := C.GoString(C.ImageBuf_name(i.ptr))\n\truntime.KeepAlive(i)\n\treturn ret\n}", "func GetActiveSubroutineName(program uint32, shadertype uint32, index uint32, bufsize int32, length *int32, name *int8) {\n C.glowGetActiveSubroutineName(gpGetActiveSubroutineName, (C.GLuint)(program), (C.GLenum)(shadertype), (C.GLuint)(index), (C.GLsizei)(bufsize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func (o *ObjectRef) IsInstanceOf(env *Env, className string) (bool, error) {\n\tclass, err := env.callFindClass(className)\n\tif err != nil {\n\t\treturn false, err\n\t}\n\treturn toBool(isInstanceOf(env.jniEnv, o.jobject, class)), nil\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 (*Component_Fan) IsYANGGoStruct() {}", "func (self *Graphics) InWorld() bool{\n return self.Object.Get(\"inWorld\").Bool()\n}", "func (o *Ga4ghTumourboard) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (f frame) name() string {\n\tfn := runtime.FuncForPC(f.pc())\n\tif fn == nil {\n\t\treturn \"unknown\"\n\t}\n\treturn fn.Name()\n}", "func (*OpenconfigPlatform_Components_Component_Backplane) IsYANGGoStruct() {}", "func (self *Graphics) Alive() bool{\n return self.Object.Get(\"alive\").Bool()\n}", "func IsBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func (f *Filter) Match(buf []byte) bool {\n cbuf := (*C.char)(unsafe.Pointer(&buf[0]))\n blen := C.uint(len(buf))\n\n if C.bpf_filter(f.program.bf_insns, cbuf, blen, blen) > 0 {\n return true\n }\n\n return false\n}", "func (*OpenconfigPlatform_Components_Component_Fan) IsYANGGoStruct() {}", "func isNamedType(t types.Type, path, name string) bool {\n\tn, ok := t.(*types.Named)\n\tif !ok {\n\t\treturn false\n\t}\n\tobj := n.Obj()\n\treturn obj.Name() == name && obj.Pkg() != nil && obj.Pkg().Path() == path\n}", "func (arg1 *UConverter) IsAmbiguous() (_swig_ret UBool)", "func isBlock(name string, arch arch) bool {\n\tfor _, b := range genericBlocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\tfor _, b := range arch.blocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (c *Container) isBitmap() bool {\n\tif c == nil {\n\t\tpanic(\"calling isBitmap on nil container\")\n\t}\n\treturn c.typeID == ContainerBitmap\n}", "func LoadName(name uint32) {\n C.glowLoadName(gpLoadName, (C.GLuint)(name))\n}", "func (a *Asset) IsBuffered() bool {\n\treturn isBufferName(a.OutName)\n}", "func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tC.glowNamedFramebufferTextureLayer(gpNamedFramebufferTextureLayer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(layer))\n}", "func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tC.glowNamedFramebufferTextureLayer(gpNamedFramebufferTextureLayer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(layer))\n}", "func (me TshapeEnumType) IsRectangle() bool { return me == \"rectangle\" }" ]
[ "0.65359837", "0.6146991", "0.5986482", "0.59707755", "0.5905901", "0.58175486", "0.5786624", "0.5786624", "0.56857234", "0.56857234", "0.56761026", "0.5631176", "0.561058", "0.5592658", "0.5566512", "0.55430293", "0.55430293", "0.5542829", "0.5542829", "0.547708", "0.547708", "0.5386641", "0.5375421", "0.53313637", "0.527166", "0.52618587", "0.52618587", "0.51437294", "0.51222634", "0.5112247", "0.5107537", "0.5107537", "0.5103292", "0.502165", "0.502165", "0.50103384", "0.50075424", "0.49771488", "0.4966214", "0.49636692", "0.4961306", "0.49185368", "0.49133155", "0.49087378", "0.4907206", "0.49039236", "0.48898047", "0.48875797", "0.4880035", "0.48576123", "0.48576123", "0.48435095", "0.48435095", "0.48299685", "0.48286107", "0.48256752", "0.48230016", "0.4811696", "0.48039073", "0.48027655", "0.4800727", "0.48001602", "0.47887474", "0.478828", "0.47879884", "0.47826198", "0.4779286", "0.4774663", "0.47716802", "0.47702658", "0.47697", "0.4753499", "0.4746469", "0.47438174", "0.4743716", "0.4737591", "0.473431", "0.4727984", "0.47239122", "0.47168675", "0.47168675", "0.47152513", "0.47010383", "0.46970057", "0.46920332", "0.46895394", "0.4685116", "0.467621", "0.46737617", "0.46731022", "0.46682927", "0.46612105", "0.46609408", "0.46588632", "0.46526444", "0.46514776", "0.46484917", "0.46484917", "0.46472064" ]
0.59171134
5
determine if a name corresponds to a display list
func IsList(list uint32) bool { ret := C.glowIsList(gpIsList, (C.GLuint)(list)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func IsInList(a string, list []Client) bool {\n\tfor _, b := range list {\n\t\tif b.Name == a {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *Job) HasDisplayname() bool {\n\tif o != nil && o.Displayname != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (me TxsdSelectionAnswerTypeSequenceStyleSuggestion) IsList() bool { return me.String() == \"list\" }", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func (me TxsdPresentationAttributesGraphicsDisplay) IsListItem() bool {\n\treturn me.String() == \"list-item\"\n}", "func inList(s string, list []string) bool {\n\treturn indexList(s, list) != -1\n}", "func (os Outputs) Present(name string) bool {\n\tfor _, o := range os {\n\t\t// Check legacy name\n\t\tm, err := path.Match(name, o.Name)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\n\t\t// Check extended name\n\t\tm, err = path.Match(name, o.Name+\"-\"+o.MonitorID)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func entityInLabDef(entityName string, ld *models.Lesson) bool {\n\n\tfor i := range ld.Endpoints {\n\t\tif entityName == ld.Endpoints[i].Name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (x *RpcExector) showGroupName() bool {\n\tval, ok := os.LookupEnv(\"SUPERVISOR_GROUP_DISPLAY\")\n\tif !ok {\n\t\treturn false\n\t}\n\n\tval = strings.ToLower(val)\n\treturn val == \"yes\" || val == \"true\" || val == \"y\" || val == \"t\" || val == \"1\"\n}", "func (l *Location) listExists(cmd *Command) bool {\n\tcmd.Respond(\"Visible exits:\\n%s\", l.Exits().String())\n\treturn true\n}", "func (me TAttlistAuthorListType) IsAuthors() bool { return me.String() == \"authors\" }", "func (m *List) GetDisplayName()(*string) {\n return m.displayName\n}", "func isUsableNameGroup(names, patterns []string, name string) error {\n\tname = strings.TrimSpace(strings.ToLower(name))\n\tif utf8.RuneCountInString(name) == 0 {\n\t\treturn ErrNameEmpty\n\t}\n\n\tfor i := range names {\n\t\tif name == names[i] {\n\t\t\treturn ErrNameReserved{name}\n\t\t}\n\t}\n\n\tfor _, pat := range patterns {\n\t\tif pat[0] == '*' && strings.HasSuffix(name, pat[1:]) ||\n\t\t\t(pat[len(pat)-1] == '*' && strings.HasPrefix(name, pat[:len(pat)-1])) {\n\t\t\treturn ErrNamePatternNotAllowed{pat}\n\t\t}\n\t}\n\n\treturn nil\n}", "func HasHumanName(addr string) bool {\n\t_, ok := humanNames[strings.ToLower(addr)]\n\treturn ok\n}", "func (o *Tier) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (d UserData) HasDisplayName() bool {\n\treturn d.ModelData.Has(models.NewFieldName(\"DisplayName\", \"display_name\"))\n}", "func isPresent(value string, list LWWNodeSlice) bool {\n\tfor _, element := range list {\n\t\tif element.Value == value {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *RoleWithAccess) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isFoundationIDInList(foundationSFID string, projectsSFIDs []string) bool {\n\tfor _, projectSFID := range projectsSFIDs {\n\t\tif projectSFID == foundationSFID {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (m *List) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (t *VLStr) IsList() bool {\n\treturn true\n}", "func (o *DeviceClient) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (os Outputs) Present(name string) bool {\n\tfor _, o := range os {\n\t\tm, err := path.Match(name, o.Name)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *RoleAssignment) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (t *VLStrStr) IsList() bool {\n\treturn true\n}", "func (list *ServiceList) contains(name string) bool {\n\tfor _, service := range list.Items {\n\t\tif *dcl.SelfLinkToName(service.Name) == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *Job) GetDisplaynameOk() (*string, bool) {\n\tif o == nil || o.Displayname == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Displayname, true\n}", "func (i *Item) DisplayName() string {\n\tresult := i.spec.Category\n\tif len(i.spec.Place) > 0 {\n\t\tresult += \", \"\n\t\tresult += i.spec.Place\n\t}\n\treturn result\n}", "func Contain(list []string, str string) bool {\n\tfor _, s := range list {\n\t\tif s == str {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (me TAttlistDescriptorNameType) IsGeographic() bool { return me.String() == \"Geographic\" }", "func (t *VLIntStr) IsList() bool {\n\treturn true\n}", "func isAllowed(candidate string, list []string) bool {\n\tfor _, t := range list {\n\t\tif t == candidate {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func isLabel(input string) bool {\n\tif len(input) > 0 {\n\t\tfor _, t := range labelList {\n\t\t\tif t == input {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\treturn false\n}", "func SInList(val string, list []string) bool {\n\tfor _, sval := range list {\n\t\tif val == sval {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (me TAttlistAuthorListType) IsEditors() bool { return me.String() == \"editors\" }", "func (x *CtlCommand) showGroupName() bool {\n\tval, ok := os.LookupEnv(\"SUPERVISOR_GROUP_DISPLAY\")\n\tif !ok {\n\t\treturn false\n\t}\n\n\tval = strings.ToLower(val)\n\treturn val == \"yes\" || val == \"true\" || val == \"y\" || val == \"t\" || val == \"1\"\n}", "func (x *CtlCommand) showGroupName() bool {\n\tval, ok := os.LookupEnv(\"SUPERVISOR_GROUP_DISPLAY\")\n\tif !ok {\n\t\treturn false\n\t}\n\n\tval = strings.ToLower(val)\n\treturn val == \"yes\" || val == \"true\" || val == \"y\" || val == \"t\" || val == \"1\"\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func isNulName(name string) bool {\n\tif len(name) != 3 {\n\t\treturn false\n\t}\n\tif name[0] != 'n' && name[0] != 'N' {\n\t\treturn false\n\t}\n\tif name[1] != 'u' && name[1] != 'U' {\n\t\treturn false\n\t}\n\tif name[2] != 'l' && name[2] != 'L' {\n\t\treturn false\n\t}\n\treturn true\n}", "func (es ExternalServices) DisplayNames() []string {\n\tnames := make([]string, len(es))\n\tfor i := range es {\n\t\tnames[i] = es[i].DisplayName\n\t}\n\treturn names\n}", "func (t *VLDblStr) IsList() bool {\n\treturn true\n}", "func (i List) CheckByName(name string) bool {\n\tfor _, ipSet := range i.IPSets {\n\t\tif ipSet.Name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *MicrosoftGraphEducationSchool) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func InList(a string, list []string) bool {\n\tcheck := 0\n\tfor _, b := range list {\n\t\tif b == a {\n\t\t\tcheck += 1\n\t\t}\n\t}\n\tif check != 0 {\n\t\treturn true\n\t}\n\treturn false\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func (m *UserMutation) DisplayName() (r string, exists bool) {\n\tv := m.display_name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func (request *Request) UserInList(list []string) bool {\n\tfor _, name := range list {\n\t\tif name == request.UserName || name == request.UserID {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func Matches(entry Entry, name string) bool {\n\tif entry == nil {\n\t\treturn false\n\t}\n\tsplittedName := strings.Split(name, \"*\")\n\tif len(splittedName) == 1 {\n\t\tif entry.Name() == name {\n\t\t\treturn true\n\t\t}\n\t} else if len(splittedName) == 2 {\n\t\tif strings.HasPrefix(entry.Name(), splittedName[0]) && strings.HasSuffix(entry.Name(), splittedName[1]) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (s StringList) Has(i string) bool {\n\tfor _, obj := range s {\n\t\tif obj == i {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func InSlice(mineral Mineral, minerals []Mineral) bool {\n\tisIt := false\n\tfor _, m := range minerals {\n\t\tif m.Name == mineral.Name {\n\t\t\tisIt = true\n\t\t}\n\t}\n\n\treturn isIt\n}", "func InSlice(mineral Mineral, minerals []Mineral) bool {\n\tisIt := false\n\tfor _, m := range minerals {\n\t\tif m.Name == mineral.Name {\n\t\t\tisIt = true\n\t\t}\n\t}\n\n\treturn isIt\n}", "func (me TxsdTimeImpactSimpleContentExtensionMetric) IsLabor() bool { return me.String() == \"labor\" }", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (e DirectoryEntry) IsString() bool { return ((e.Name & 0x80000000) >> 31) > 0 }", "func (o *ShowSystem) HasName() bool {\n\tif o != nil && !IsNil(o.Name) {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func DisplayName(value string) *SimpleElement { return newSEString(\"displayName\", value) }", "func (me TAttlistLocationLabelType) IsTable() bool { return me.String() == \"table\" }", "func isListItem(opt *Options, line string) bool {\n\tb := []rune(line)\n\n\tbulletMarker := []rune(opt.BulletListMarker)[0]\n\n\tvar hasNumber bool\n\tvar hasMarker bool\n\tvar hasSpace bool\n\n\tfor i := 0; i < len(b); i++ {\n\t\t// A marker followed by a space qualifies as a list item\n\t\tif hasMarker && hasSpace {\n\t\t\tif b[i] == bulletMarker {\n\t\t\t\t// But if another BulletListMarker is found, it\n\t\t\t\t// might be a HorizontalRule\n\t\t\t\treturn false\n\t\t\t}\n\n\t\t\tif !unicode.IsSpace(b[i]) {\n\t\t\t\t// Now we have some text\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\n\t\tif hasMarker {\n\t\t\tif unicode.IsSpace(b[i]) {\n\t\t\t\thasSpace = true\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// A marker like \"1.\" that is not immediately followed by a space\n\t\t\t// is probably a false positive\n\t\t\treturn false\n\t\t}\n\n\t\tif b[i] == bulletMarker {\n\t\t\thasMarker = true\n\t\t\tcontinue\n\t\t}\n\n\t\tif hasNumber && b[i] == '.' {\n\t\t\thasMarker = true\n\t\t\tcontinue\n\t\t}\n\t\tif unicode.IsDigit(b[i]) {\n\t\t\thasNumber = true\n\t\t\tcontinue\n\t\t}\n\n\t\tif unicode.IsSpace(b[i]) {\n\t\t\tcontinue\n\t\t}\n\n\t\t// If we encouter any other character\n\t\t// before finding an indicator, its\n\t\t// not a list item\n\t\treturn false\n\t}\n\treturn false\n}", "func (o LookupConnectivityTestResultOutput) DisplayName() pulumi.StringOutput {\n\treturn o.ApplyT(func(v LookupConnectivityTestResult) string { return v.DisplayName }).(pulumi.StringOutput)\n}", "func (o LakeOutput) DisplayName() pulumi.StringOutput {\n\treturn o.ApplyT(func(v *Lake) pulumi.StringOutput { return v.DisplayName }).(pulumi.StringOutput)\n}", "func detailPrintHelper(v string, a []string) bool {\n\tfor _, i := range a {\n\t\tif i == v {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func ctrlGroupname(groupname string) bool {\n\tfor i := 0; i < len(GroupName); i++ {\n\t\tif GroupName[i] == groupname {\n\t\t\tfmt.Print(\"This group exist.\") // **\n\t\t\treturn false\n\t\t}\n\t}\n\tif strings.Contains(groupname, \"*\") {\n\t\tfmt.Print(\"You can not create a group with '*' charachter in it.\")\n\t\treturn false\n\t}\n\treturn true\n}", "func (s *BasevhdlListener) EnterLogical_name_list(ctx *Logical_name_listContext) {}", "func (me TAttlistKeywordListOwner) IsHhs() bool { return me.String() == \"HHS\" }", "func (me TAttlistKeywordListOwner) IsNlm() bool { return me.String() == \"NLM\" }", "func ListContains(list []string, str string) bool {\n\tfor i := range list {\n\t\tif list[i] == str {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *MicrosoftGraphSharedPcConfiguration) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *User) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *User) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isExported(name string) bool {\n rune, _ := utf8.DecodeRuneInString(name)\n return unicode.IsUpper(rune)\n}", "func isValuePresentInTheList(strArr []string, str string) bool {\n\tfor _, s := range strArr {\n\t\tif strings.Contains(s, str) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsList(list uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsList, 1, uintptr(list), 0, 0)\n\treturn ret != 0\n}", "func (t *VLStrInt) IsList() bool {\n\treturn true\n}", "func (pt AuthProviderType) Display() string {\n\tswitch pt {\n\tcase AuthProviderTypeAnonymous:\n\t\treturn \"Anonymous\"\n\tcase AuthProviderTypeUserPassword:\n\t\treturn \"User/Password\"\n\tcase AuthProviderTypeAPIKey:\n\t\treturn \"ApiKey\"\n\tcase AuthProviderTypeApple:\n\t\treturn \"Apple\"\n\tcase AuthProviderTypeGoogle:\n\t\treturn \"Google\"\n\tcase AuthProviderTypeFacebook:\n\t\treturn \"Facebook\"\n\tcase AuthProviderTypeCustomToken:\n\t\treturn \"Custom JWT\"\n\tcase AuthProviderTypeCustomFunction:\n\t\treturn \"Custom Function\"\n\tdefault:\n\t\treturn \"Unknown\"\n\t}\n}", "func (o *MailFolder) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (t *Link) IsNameString(index int) (ok bool) {\n\treturn t.name[index].stringName != nil\n\n}", "func (o *DisplayInfo) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (me TAttlistKeywordListOwner) IsNasa() bool { return me.String() == \"NASA\" }", "func (o *MicrosoftGraphMailSearchFolder) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isExported(name string) bool {\n\ts, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(s)\n}", "func (t *VLDbl) IsList() bool {\n\treturn true\n}", "func Is(name string) bool {\n\treturn contains(name, All)\n}", "func (me TAttlistOtherIDSource) IsArpl() bool { return me.String() == \"ARPL\" }", "func (o LookupWorkstationResultOutput) DisplayName() pulumi.StringOutput {\n\treturn o.ApplyT(func(v LookupWorkstationResult) string { return v.DisplayName }).(pulumi.StringOutput)\n}", "func (s UserSet) DisplayName() string {\n\tres, _ := s.RecordCollection.Get(models.NewFieldName(\"DisplayName\", \"display_name\")).(string)\n\treturn res\n}", "func stringInList(s string, list []string) bool {\n\tfor _, i := range list {\n\t\tif s == i {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o LookupAnnotationSpecSetResultOutput) DisplayName() pulumi.StringOutput {\n\treturn o.ApplyT(func(v LookupAnnotationSpecSetResult) string { return v.DisplayName }).(pulumi.StringOutput)\n}", "func (me TAttlistLocationLabelType) IsPart() bool { return me.String() == \"part\" }", "func StringInList(list []string, match string) bool {\n\tfor _, i := range list {\n\t\tif i == match {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (me TAttlistUrlType) IsSummary() bool { return me.String() == \"summary\" }", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "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 (me TxsdPresentationAttributesGraphicsDisplay) IsTable() bool { return me.String() == \"table\" }", "func checkIfPresent(a string, list []string) bool {\n\tfor _, b := range list {\n\t\tif b == a {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *SchemaDefinitionRestDto) HasDisplayName() bool {\n\tif o != nil && o.DisplayName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o LookupEntryResultOutput) DisplayName() pulumi.StringOutput {\n\treturn o.ApplyT(func(v LookupEntryResult) string { return v.DisplayName }).(pulumi.StringOutput)\n}", "func (s serverImpl) isCreatorAllowListed(ctx types.Context, allowlist []string, designer sdk.Address) bool {\n\tfor _, addr := range allowlist {\n\t\tctx.GasMeter().ConsumeGas(gasCostPerIteration, \"credit class creators allowlist\")\n\t\tallowListedAddr, _ := sdk.AccAddressFromBech32(addr)\n\t\tif designer.Equals(allowListedAddr) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func Contains(list []string, wanted string) bool {\n\tfor _, found := range list {\n\t\tif found == wanted {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsAbbreviated(item string) bool {\n\t// if we have direct hit, then return true.\n\tif _, ok := abbreviations[item]; ok {\n\t\treturn ok\n\t}\n\n\n\t// We need to attempt indirect hit with combo map.\n\t// and return optimistic truthy value if any is found.\n\tif _, ok := suffixes[item]; ok {\n\t\treturn ok\n\t}\n\n\t\n\treturn false\n}", "func contains(list []string, target string) bool {\n\tfor _, s := range list {\n\t\tif s == target {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}" ]
[ "0.5739352", "0.57390684", "0.57381266", "0.5698177", "0.5638775", "0.5573461", "0.5487408", "0.54286337", "0.53456706", "0.53454715", "0.5342233", "0.5340279", "0.53320843", "0.53261995", "0.5317661", "0.5313707", "0.53026736", "0.5279862", "0.527687", "0.52686745", "0.52519953", "0.52506787", "0.5242591", "0.5238895", "0.52374667", "0.52353626", "0.5222108", "0.520688", "0.52045894", "0.5186011", "0.51766306", "0.5174522", "0.51632434", "0.51479584", "0.51382834", "0.5136185", "0.51309663", "0.51309663", "0.512614", "0.5121125", "0.5120391", "0.51122236", "0.51083684", "0.5102399", "0.50561684", "0.5052334", "0.50450367", "0.5044271", "0.503875", "0.5028041", "0.5025603", "0.5025603", "0.50189775", "0.5013366", "0.5011074", "0.50093615", "0.49844143", "0.49837625", "0.49790928", "0.49748132", "0.49590063", "0.495409", "0.4947841", "0.49440068", "0.49423042", "0.49405164", "0.4936222", "0.49312568", "0.49233618", "0.49233618", "0.4921931", "0.4919855", "0.49183536", "0.4914083", "0.4905025", "0.48885208", "0.48869547", "0.48845825", "0.4876299", "0.48737687", "0.48734584", "0.48655242", "0.48532537", "0.48527128", "0.48491985", "0.48481724", "0.48462752", "0.48453626", "0.48445246", "0.48409358", "0.48391068", "0.48347768", "0.4832203", "0.482964", "0.4828754", "0.4827582", "0.48267934", "0.4822186", "0.48179713", "0.48143363", "0.4814205" ]
0.0
-1
Determines if a name corresponds to a program object
func IsProgram(program uint32) bool { ret := C.glowIsProgram(gpIsProgram, (C.GLuint)(program)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CheckIsLeagueExecutable(name string) bool {\r\n\treturn strings.HasSuffix(strings.TrimSpace(strings.ToLower(name)), \"leagueclient.exe\")\r\n}", "func iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func (program Program) IsProgram() bool {\n\treturn gl.IsProgram(uint32(program))\n}", "func IsProgram(p Program) bool {\n\treturn gl.IsProgram(p.Value)\n}", "func IsProgram(program uint32) bool {\n ret := C.glowIsProgram(gpIsProgram, (C.GLuint)(program))\n return ret == TRUE\n}", "func IsProgram(program uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsProgram, 1, uintptr(program), 0, 0)\n\treturn ret != 0\n}", "func programName() string {\n\treturn filepath.Base(os.Args[0])\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func ProgramName() string {\n\t_, progName := filepath.Split(os.Args[0])\n\treturn progName\n}", "func (p pkgInfo) IsCommand() bool { return p.Name == \"main\" }", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func isMain(graph *graph.DependencyGraph, pkg string) bool {\n\tfor _, name := range graph.PackageNames[pkg] {\n\t\tif name == \"main\" {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func isExported(name string) bool {\n rune, _ := utf8.DecodeRuneInString(name)\n return unicode.IsUpper(rune)\n}", "func objectNameAndCommandLine(env *cmdline.Env, args []string) (string, string, error) {\n\tif len(args) < 1 {\n\t\treturn \"\", \"\", errors.New(\"object name missing\")\n\t}\n\tname := args[0]\n\targs = args[1:]\n\t// For compatibility with tools like rsync. Because object names\n\t// don't look like traditional hostnames, tools that work with rsh and\n\t// ssh can't work directly with vsh. This trick makes the following\n\t// possible:\n\t// $ VSH_NAME=<object name> rsync -avh -e vsh /foo/* v23:/foo/\n\t// The \"v23\" host will be substituted with <object name>.\n\tif envName := env.Vars[\"VSH_NAME\"]; envName != \"\" && name == \"v23\" {\n\t\tname = envName\n\t}\n\tcmd := strings.Join(args, \" \")\n\treturn name, cmd, nil\n}", "func IsProgram(program Uint) Boolean {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\t__ret := C.glIsProgram(cprogram)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func ValidObjectType(t string) bool {\n\n\tvar m = map[string]int{\n\t\t\"attack-pattern\": 1,\n\t\t\"campaign\": 1,\n\t\t\"course-of-action\": 1,\n\t\t\"grouping\": 1,\n\t\t\"identity\": 1,\n\t\t\"indicator\": 1,\n\t\t\"infrastructure\": 1,\n\t\t\"intrusion-set\": 1,\n\t\t\"language-content\": 1,\n\t\t\"location\": 1,\n\t\t\"malware\": 1,\n\t\t\"malware-analysis\": 1,\n\t\t\"marking-definition\": 1,\n\t\t\"note\": 1,\n\t\t\"observed-data\": 1,\n\t\t\"opinion\": 1,\n\t\t\"relationship\": 1,\n\t\t\"report\": 1,\n\t\t\"sighting\": 1,\n\t\t\"threat-actor\": 1,\n\t\t\"tool\": 1,\n\t\t\"vulnerability\": 1,\n\t}\n\n\tif _, ok := m[t]; ok {\n\t\treturn true\n\t}\n\treturn false\n}", "func IsValidObjectName(object string) bool {\n\tif strings.TrimSpace(object) == \"\" {\n\t\treturn false\n\t}\n\tif len(object) > 1024 || len(object) == 0 {\n\t\treturn false\n\t}\n\tif !utf8.ValidString(object) {\n\t\treturn false\n\t}\n\treturn true\n}", "func isCommand(name string) bool {\n\tfor _, cmd := range []string{\"_hooks\", \"_forward\"} {\n\t\tif strings.Compare(name, cmd) == 0 {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (*Object) Name() string { return \"object\" }", "func ObjName(iface interface{}) string {\n\treturn filepath.Base(reflect.TypeOf(iface).PkgPath()) +\n\t\t\".\" + reflect.TypeOf(iface).Name()\n}", "func isProc(path string) bool {\n\tbasename := filepath.Base(path)\n\t_, err := strconv.Atoi(basename)\n\tif err != nil {\n\t\treturn false\n\t}\n\treturn true\n}", "func (p *PKGBUILD) Contains(name string) bool {\n\tcb := atom.NamedCheckAll(\n\t\tatom.NewNameMatcher(atom.VarArray, atom.VarString, atom.Function),\n\t\tatom.CheckName(name),\n\t)\n\t_, ok := p.info.FilterFirst(cb)\n\treturn ok\n}", "func (*OpenconfigOfficeAp_System_Processes) IsYANGGoStruct() {}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\ts, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(s)\n}", "func (*OpenconfigSystem_System_Processes) IsYANGGoStruct() {}", "func issafepoint(prog *obj.Prog) bool {\n\treturn prog.As == obj.ATEXT || prog.As == obj.ACALL\n}", "func (obj *application) Name() string {\n\treturn obj.name\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func IsBuiltInDriver(name string) bool {\n\tn := strings.ToLower(name)\n\t_, ok := initializers[n]\n\treturn ok\n}", "func isSelf(e *evtx.GoEvtxMap) bool {\n\tif pguid, err := e.GetString(&pathSysmonParentProcessGUID); err == nil {\n\t\tif pguid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\tif guid, err := e.GetString(&pathSysmonProcessGUID); err == nil {\n\t\tif guid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\tif sguid, err := e.GetString(&pathSysmonSourceProcessGUID); err == nil {\n\t\tif sguid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (s *System) IsPublic() bool { return s.Name == PublicSystem.Name || s.Name == PublicCDSystem.Name }", "func (*OpenconfigSystem_System_Processes_Process) IsYANGGoStruct() {}", "func (Functions) CommandName(obj interface{}) string {\n\treturn nameOptions{}.convert(nameOf(obj))\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func IsExportedName(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func (*OpenconfigOfficeAp_System_Processes_Process) IsYANGGoStruct() {}", "func MainOrg(stub shim.ChaincodeStubInterface) (bool, error) {\n\terr := cid.AssertAttributeValue(stub, MAINORG, \"true\")\n\tif err != nil {\n\t\treturn false, err\n\t}\n\treturn true, nil\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func (te *TreeEntry) IsExecutable() bool {\n\treturn te.gogitTreeEntry.Mode == filemode.Executable\n}", "func isSelf(e *evtx.GoEvtxMap) bool {\n\tif pguid, err := e.GetString(&sysmonParentProcessGUID); err == nil {\n\t\tif pguid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\tif guid, err := e.GetString(&sysmonProcessGUID); err == nil {\n\t\tif guid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func TestIsValidObjectName(t *testing.T) {\n\ttestCases := []struct {\n\t\tobjectName string\n\t\tshouldPass bool\n\t}{\n\t\t// cases which should pass the test.\n\t\t// passing in valid object name.\n\t\t{\"object\", true},\n\t\t{\"The Shining Script <v1>.pdf\", true},\n\t\t{\"Cost Benefit Analysis (2009-2010).pptx\", true},\n\t\t{\"117Gn8rfHL2ACARPAhaFd0AGzic9pUbIA/5OCn5A\", true},\n\t\t{\"SHØRT\", true},\n\t\t{\"There are far too many object names, and far too few bucket names!\", true},\n\t\t// cases for which test should fail.\n\t\t// passing invalid object names.\n\t\t{\"\", false},\n\t\t{string([]byte{0xff, 0xfe, 0xfd}), false},\n\t}\n\n\tfor i, testCase := range testCases {\n\t\tisValidObjectName := IsValidObjectName(testCase.objectName)\n\t\tif testCase.shouldPass && !isValidObjectName {\n\t\t\tt.Errorf(\"Test case %d: Expected \\\"%s\\\" to be a valid object name\", i+1, testCase.objectName)\n\t\t}\n\t\tif !testCase.shouldPass && isValidObjectName {\n\t\t\tt.Errorf(\"Test case %d: Expected object name \\\"%s\\\" to be invalid\", i+1, testCase.objectName)\n\t\t}\n\t}\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 Is(name string) bool {\n\treturn strings.HasPrefix(name, Prefix)\n}", "func (o *ShowSystem) HasName() bool {\n\tif o != nil && !IsNil(o.Name) {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func Which(name string) (string, bool) {\n\tdefaultPath := \":/bin:/usr/bin:/sbin:/usr/sbin\"\n\n\t_, err := os.Stat(name)\n\tif err == nil {\n\t\treturn name, true\n\t}\n\n\tvar searchPath string\n\tval, exists := os.LookupEnv(\"PATH\")\n\tif !exists {\n\t\tsearchPath = defaultPath\n\t} else {\n\t\tsearchPath = val\n\t}\n\n\tfor _, p := range strings.Split(searchPath, \":\") {\n\t\ttryPath := path.Join(p, name)\n\t\t_, err := os.Stat(tryPath)\n\t\tif err == nil {\n\t\t\treturn tryPath, true\n\t\t}\n\t}\n\n\treturn \"\", false\n}", "func execObjectString(_ int, p *gop.Context) {\n\targs := p.GetArgs(2)\n\tret := types.ObjectString(args[0].(types.Object), args[1].(types.Qualifier))\n\tp.Ret(2, ret)\n}", "func IsMetaPackage(name string) bool {\n\treturn name == \"std\" || name == \"cmd\" || name == \"all\"\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func programName(filename string) string {\n\tfilename = filepath.Base(filename)\n\text := filepath.Ext(filename)\n\treturn filename[:len(filename)-len(ext)]\n}", "func (*InstSExt) isInst() {}", "func osByName(name string) OsType {\n\tfor _, os := range OsTypeList {\n\t\tif os.Name == name {\n\t\t\treturn os\n\t\t}\n\t}\n\n\treturn NoOsType\n}", "func exported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func (p *parser) evalName(x *ebnf.Name) bool {\n\tdbg.Println(\"evalName:\", exprString(x))\n\tprod := p.grammar[x.String]\n\treturn p.evalProd(prod)\n}", "func IsBuiltin(name string) bool {\n\t_, ok := builtinsMap[name]\n\treturn ok\n}", "func IsProgramPipeline(pipeline uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsProgramPipeline, 1, uintptr(pipeline), 0, 0)\n\treturn ret != 0\n}", "func IsExported(name string) bool {\n\tch, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(ch)\n}", "func IsProgramPipeline(pipeline uint32) bool {\n ret := C.glowIsProgramPipeline(gpIsProgramPipeline, (C.GLuint)(pipeline))\n return ret == TRUE\n}", "func isNamedType(t types.Type, path, name string) bool {\n\tn, ok := t.(*types.Named)\n\tif !ok {\n\t\treturn false\n\t}\n\tobj := n.Obj()\n\treturn obj.Name() == name && obj.Pkg() != nil && obj.Pkg().Path() == path\n}", "func (processExecutableNameDetector) Detect(ctx context.Context) (*Resource, error) {\n\texecutableName := filepath.Base(commandArgs()[0])\n\n\treturn NewWithAttributes(semconv.SchemaURL, semconv.ProcessExecutableNameKey.String(executableName)), nil\n}", "func (o *ObjectRef) IsInstanceOf(env *Env, className string) (bool, error) {\n\tclass, err := env.callFindClass(className)\n\tif err != nil {\n\t\treturn false, err\n\t}\n\treturn toBool(isInstanceOf(env.jniEnv, o.jobject, class)), nil\n}", "func ProcName(_ int, procName string) string { return procName }", "func ProcName(_ int, procName string) string { return procName }", "func (mt MapType) canStoreProgram() bool {\n\treturn mt == ProgramArray\n}", "func IsExecutable(reader io.Reader, closeAfterCheck bool) bool {\n\tbuf, err := chunk(reader, 4, closeAfterCheck)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tif len(buf) < 4 {\n\t\treturn false\n\t}\n\tle := binary.LittleEndian.Uint32(buf)\n\tbe := binary.BigEndian.Uint32(buf)\n\n\treturn string(buf) == elf.ELFMAG || // elf - linux format exec file\n\t// .exe windows\n\t\tstring(buf[:2]) == \"MZ\" ||\n\t// shebang\n\t\tstring(buf[:2]) == \"#!\" ||\n\t// mach-o - mac format exec file\n\t\tmacho.Magic32 == le || macho.Magic32 == be || macho.Magic64 == le || macho.Magic64 == be || macho.MagicFat == le || macho.MagicFat == be\n}", "func (p *TProgram) IsUniqueTypename(caftype ICafType) bool{\n\tret := p.ProgramTypenameCount(p, caftype)\n\tfor _,v := range p.Includes_ {\n\t\tret += p.ProgramTypenameCount(v, caftype);\n\t}\n\treturn 0 == ret;\n}", "func isExecutableScript(item *DisplayItem) bool {\n\tif item.info.Mode()&0111 != 0 && item.info.Mode().IsRegular() {\n\t\treturn true\n\t}\n\treturn false\n}", "func (i *Instance) MatchName(name string) bool {\n\tif i.Name == name || i.Cluster.Name == name {\n\t\treturn true\n\t}\n\tif IsValidIP(name) && i.IP == name {\n\t\treturn true\n\t}\n\n\tre, err := regexp.CompilePOSIX(name)\n\tif err != nil {\n\t\treturn false\n\t}\n\tif re.MatchString(i.Name) || re.MatchString(i.Cluster.Name) {\n\t\treturn true\n\t}\n\treturn false\n}", "func isSelfPackage(packageName string) bool {\n\treturn packageName == \"pie\"\n}", "func Intern(name string) *Object {\n\tsym, ok := symtab[name]\n\tif !ok {\n\t\tsym = new(Object)\n\t\tsym.text = name\n\t\tif IsValidKeywordName(name) {\n\t\t\tsym.Type = KeywordType\n\t\t} else if IsValidTypeName(name) {\n\t\t\tsym.Type = TypeType\n\t\t} else if IsValidSymbolName(name) {\n\t\t\tsym.Type = SymbolType\n\t\t} else {\n\t\t\tpanic(\"invalid symbol/type/keyword name passed to intern: \" + name)\n\t\t}\n\t\tsymtab[name] = sym\n\t}\n\treturn sym\n}", "func GetConsoleInputExeName(buflen DWORD, buffer LPWSTR) bool {\n\tret1 := syscall3(getConsoleInputExeName, 2,\n\t\tuintptr(buflen),\n\t\tuintptr(unsafe.Pointer(buffer)),\n\t\t0)\n\treturn ret1 != 0\n}", "func goNameOfStr(n string) (retVal string) {\n\tvar ok bool\n\tdefer func() {\n\t\tretVal = reqPtr(retVal)\n\t}()\n\tif retVal, ok = ctypes2GoTypes[n]; ok {\n\t\treturn retVal\n\t}\n\tif retVal, ok = enumMappings[n]; ok {\n\t\treturn retVal\n\t}\n\tif retVal, ok = builtins[n]; ok {\n\t\treturn retVal\n\t}\n\tif retVal, ok = nonPrimitives[n]; ok {\n\t\treturn retVal\n\t}\n\n\treturn \"\"\n}", "func IsCorp(hostname string) bool {\n\treturn (hostname == \"avellanos\" || hostname == \"montero\" || hostname == \"monygham\")\n}", "func main() {\n\n\tfmt.Println(\"Hello\")\n\tworkingmyassoff.Working(\"SId\")\n\n\tconst name string = \"Sid\"\n\n\tworkingmyassoff.IsthisWorking(name == \"Sid\")\n\n\tworkingmyassoff.IsthisWorking(name == \"Owl\")\n}", "func (m *ToolMutation) ToolName() (r string, exists bool) {\n\tv := m._Tool_Name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func sameObj(x, y types.Object) bool {\n\tif x == y {\n\t\treturn true\n\t}\n\tif _, ok := x.(*types.PkgName); ok {\n\t\tif _, ok := y.(*types.PkgName); ok {\n\t\t\treturn x.Pkg() == y.Pkg()\n\t\t}\n\t}\n\treturn false\n}", "func IsBuiltIn(kind string) bool {\n\t_, ok := types[kind]\n\treturn ok\n}", "func IsCommand(cmd string) bool {\n for val := range DaemonizedCommands() {\n if val == cmd {\n return true\n }\n }\n for val := range InfoCommands() {\n if val == cmd {\n return true\n }\n }\n\n return false\n}", "func isReservedWord(s string) bool {\n\tswitch s {\n\tcase \"abstract\", \"as\", \"base\", \"bool\", \"break\", \"byte\", \"case\", \"catch\", \"char\", \"checked\", \"class\", \"const\",\n\t\t\"continue\", \"decimal\", \"default\", \"delegate\", \"do\", \"double\", \"else\", \"enum\", \"event\", \"explicit\", \"extern\",\n\t\t\"false\", \"finally\", \"fixed\", \"float\", \"for\", \"foreach\", \"goto\", \"if\", \"implicit\", \"in\", \"int\", \"interface\",\n\t\t\"internal\", \"is\", \"lock\", \"long\", \"namespace\", \"new\", \"null\", \"object\", \"operator\", \"out\", \"override\",\n\t\t\"params\", \"private\", \"protected\", \"public\", \"readonly\", \"ref\", \"return\", \"sbyte\", \"sealed\", \"short\",\n\t\t\"sizeof\", \"stackalloc\", \"static\", \"string\", \"struct\", \"switch\", \"this\", \"throw\", \"true\", \"try\", \"typeof\",\n\t\t\"uint\", \"ulong\", \"unchecked\", \"unsafe\", \"ushort\", \"using\", \"virtual\", \"void\", \"volatile\", \"while\":\n\t\treturn true\n\t// Treat contextual keywords as keywords, as we don't validate the context around them.\n\tcase \"add\", \"alias\", \"ascending\", \"async\", \"await\", \"by\", \"descending\", \"dynamic\", \"equals\", \"from\", \"get\",\n\t\t\"global\", \"group\", \"into\", \"join\", \"let\", \"nameof\", \"on\", \"orderby\", \"partial\", \"remove\", \"select\", \"set\",\n\t\t\"unmanaged\", \"value\", \"var\", \"when\", \"where\", \"yield\":\n\t\treturn true\n\tdefault:\n\t\treturn false\n\t}\n}", "func exportedFrom(obj types.Object, pkg *types.Package) bool {\n\tswitch obj := obj.(type) {\n\tcase *types.Func:\n\t\treturn obj.Exported() && obj.Pkg() == pkg ||\n\t\t\tobj.Type().(*types.Signature).Recv() != nil\n\tcase *types.Var:\n\t\treturn obj.Exported() && obj.Pkg() == pkg ||\n\t\t\tobj.IsField()\n\tcase *types.TypeName, *types.Const:\n\t\treturn true\n\t}\n\treturn false // Nil, Builtin, Label, or PkgName\n}", "func (ap *ActivePipelines) Contains(n string) bool {\n\tfor _, pipeline := range ap.GetAll() {\n\t\tif pipeline.Name == n {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func isOwnedByJob(ownerKinds []string) bool {\n\tif len(ownerKinds) == 1 && ownerKinds[0] == \"Job\" {\n\t\treturn true\n\t}\n\treturn false\n}", "func (o *OsInstallAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (e *TarantoolEngine) name() string {\n\treturn \"Tarantool\"\n}", "func (*InstZExt) isInst() {}", "func isPublic(name string) bool {\n\tup := bytes.ToUpper([]byte(name))\n\treturn []byte(name)[0] == up[0]\n}", "func isExec(sect *pe.Section) bool {\n\tconst codeMask = 0x00000020\n\treturn sect.Characteristics&codeMask != 0\n}", "func IsExported(name string) bool {\n\tif r := name[0]; r < utf8.RuneSelf {\n\t\treturn 'A' <= r && r <= 'Z'\n\t}\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}" ]
[ "0.5884721", "0.5820072", "0.55430114", "0.5430011", "0.5352018", "0.53036135", "0.51930034", "0.5168736", "0.51669437", "0.515422", "0.514221", "0.51074106", "0.5089718", "0.5015285", "0.4948159", "0.49452102", "0.4925528", "0.4921279", "0.48879972", "0.48698437", "0.48688304", "0.48575717", "0.48532426", "0.4853019", "0.4853019", "0.4853019", "0.4853019", "0.4846603", "0.48286653", "0.48209393", "0.48190808", "0.48117262", "0.48117262", "0.48117262", "0.48117262", "0.48117262", "0.48117262", "0.48117262", "0.48117262", "0.48092216", "0.4802274", "0.47966543", "0.47937253", "0.47781068", "0.47715572", "0.47694302", "0.47558254", "0.47497898", "0.47474858", "0.47395715", "0.47171485", "0.47154555", "0.47152162", "0.47137725", "0.47036842", "0.4701221", "0.4701098", "0.47004658", "0.46956635", "0.46855202", "0.46810094", "0.46590507", "0.46559983", "0.46481436", "0.46454924", "0.46401605", "0.46336767", "0.462997", "0.46228355", "0.46224418", "0.4618269", "0.46174216", "0.46159828", "0.46159828", "0.461356", "0.4607336", "0.46068192", "0.46019065", "0.45936272", "0.45889178", "0.4586559", "0.4586193", "0.45771113", "0.45750284", "0.45731324", "0.4562707", "0.4561119", "0.4559667", "0.45560992", "0.4538985", "0.45377862", "0.45342347", "0.4526745", "0.45249963", "0.45210734", "0.4520867", "0.45203334", "0.45194232", "0.451801" ]
0.50218266
14
determine if a name corresponds to a program pipeline object
func IsProgramPipeline(pipeline uint32) bool { ret := C.glowIsProgramPipeline(gpIsProgramPipeline, (C.GLuint)(pipeline)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func IsProgramPipeline(pipeline uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsProgramPipeline, 1, uintptr(pipeline), 0, 0)\n\treturn ret != 0\n}", "func IsProgramPipeline(pipeline uint32) bool {\n ret := C.glowIsProgramPipeline(gpIsProgramPipeline, (C.GLuint)(pipeline))\n return ret == TRUE\n}", "func (ap *ActivePipelines) Contains(n string) bool {\n\tfor _, pipeline := range ap.GetAll() {\n\t\tif pipeline.Name == n {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (ap *ActivePipelines) GetByName(n string) *gaia.Pipeline {\n\tfor _, pipeline := range ap.GetAll() {\n\t\tif pipeline.Name == n {\n\t\t\treturn &pipeline\n\t\t}\n\t}\n\n\treturn nil\n}", "func ExistPipeline(db gorp.SqlExecutor, projectID int64, name string) (bool, error) {\n\tquery := `SELECT COUNT(id) FROM pipeline WHERE pipeline.project_id = $1 AND pipeline.name = $2`\n\n\tvar nb int64\n\terr := db.QueryRow(query, projectID, name).Scan(&nb)\n\tif err != nil {\n\t\treturn false, err\n\t}\n\tif nb != 0 {\n\t\treturn true, nil\n\t}\n\treturn false, nil\n}", "func iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func CheckIsLeagueExecutable(name string) bool {\r\n\treturn strings.HasSuffix(strings.TrimSpace(strings.ToLower(name)), \"leagueclient.exe\")\r\n}", "func (ap *ActivePipelines) ReplaceByName(n string, p gaia.Pipeline) bool {\n\tfor index, pipeline := range ap.GetAll() {\n\t\tif pipeline.Name == n {\n\t\t\t// We can safely ignore the error here, since it wouldn't even\n\t\t\t// come this far if it didn't find what to update.\n\t\t\t_ = ap.Update(index, p)\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func isnamedPipePath(p string) bool {\n\treturn strings.HasPrefix(p, `\\\\.\\pipe\\`)\n}", "func (p *literalProcessor) name() string { return \"\" }", "func (o *LogsPipelineProcessor) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func ValidateProgramPipeline(pipeline uint32) {\n C.glowValidateProgramPipeline(gpValidateProgramPipeline, (C.GLuint)(pipeline))\n}", "func ValidateProgramPipeline(pipeline uint32) {\n\tsyscall.Syscall(gpValidateProgramPipeline, 1, uintptr(pipeline), 0, 0)\n}", "func IsCurrentStage(s []Stage, name string) bool {\n\tif len(s) == 0 {\n\t\treturn false\n\t}\n\treturn s[len(s)-1].Name == name\n}", "func isMain(graph *graph.DependencyGraph, pkg string) bool {\n\tfor _, name := range graph.PackageNames[pkg] {\n\t\tif name == \"main\" {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func PipelineRcName(name string, version uint64) string {\n\t// k8s won't allow RC names that contain upper-case letters\n\t// or underscores\n\t// TODO: deal with name collision\n\tname = strings.Replace(name, \"_\", \"-\", -1)\n\treturn fmt.Sprintf(\"pipeline-%s-v%d\", strings.ToLower(name), version)\n}", "func isProc(path string) bool {\n\tbasename := filepath.Base(path)\n\t_, err := strconv.Atoi(basename)\n\tif err != nil {\n\t\treturn false\n\t}\n\treturn true\n}", "func (program Program) IsProgram() bool {\n\treturn gl.IsProgram(uint32(program))\n}", "func (o *LogsPipelineProcessor) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func IsProgram(p Program) bool {\n\treturn gl.IsProgram(p.Value)\n}", "func (p pkgInfo) IsCommand() bool { return p.Name == \"main\" }", "func isCommand(name string) bool {\n\tfor _, cmd := range []string{\"_hooks\", \"_forward\"} {\n\t\tif strings.Compare(name, cmd) == 0 {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o ImagePipelineOutput) Name() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *ImagePipeline) pulumi.StringPtrOutput { return v.Name }).(pulumi.StringPtrOutput)\n}", "func ProgramName() string {\n\t_, progName := filepath.Split(os.Args[0])\n\treturn progName\n}", "func (os Outputs) Present(name string) bool {\n\tfor _, o := range os {\n\t\t// Check legacy name\n\t\tm, err := path.Match(name, o.Name)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\n\t\t// Check extended name\n\t\tm, err = path.Match(name, o.Name+\"-\"+o.MonitorID)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (ts TaskSpec) OutputByName(name string) (TaskOutputSpec, bool) {\n\tfor _, x := range ts.Outputs {\n\t\tif x.Name == name {\n\t\t\treturn x, true\n\t\t}\n\t}\n\treturn TaskOutputSpec{}, false\n}", "func IsMetaPackage(name string) bool {\n\treturn name == \"std\" || name == \"cmd\" || name == \"all\"\n}", "func (me TxsdTimeImpactSimpleContentExtensionMetric) IsLabor() bool { return me.String() == \"labor\" }", "func (p *PKGBUILD) Contains(name string) bool {\n\tcb := atom.NamedCheckAll(\n\t\tatom.NewNameMatcher(atom.VarArray, atom.VarString, atom.Function),\n\t\tatom.CheckName(name),\n\t)\n\t_, ok := p.info.FilterFirst(cb)\n\treturn ok\n}", "func isExported(name string) bool {\n rune, _ := utf8.DecodeRuneInString(name)\n return unicode.IsUpper(rune)\n}", "func ProcName(_ int, procName string) string { return procName }", "func ProcName(_ int, procName string) string { return procName }", "func GetRealPipelineName(name string, pType gaia.PipelineType) string {\n\treturn strings.TrimSuffix(name, typeDelimiter+pType.String())\n}", "func (os Outputs) Present(name string) bool {\n\tfor _, o := range os {\n\t\tm, err := path.Match(name, o.Name)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsBuiltInDriver(name string) bool {\n\tn := strings.ToLower(name)\n\t_, ok := initializers[n]\n\treturn ok\n}", "func exported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func (cc *CloneCommand) NameIsID() bool {\n\treturn cc.RepositoryName == \"\"\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func isExported(name string) bool {\n\tr, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(r)\n}", "func programName() string {\n\treturn filepath.Base(os.Args[0])\n}", "func isExported(name string) bool {\n\ts, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(s)\n}", "func IsProgram(program uint32) bool {\n ret := C.glowIsProgram(gpIsProgram, (C.GLuint)(program))\n return ret == TRUE\n}", "func isSelfPackage(packageName string) bool {\n\treturn packageName == \"pie\"\n}", "func (m *ToolMutation) ToolName() (r string, exists bool) {\n\tv := m._Tool_Name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func name(r Runner) string {\n\tif nr, ok := r.(NamedRunner); ok {\n\t\treturn nr.Name()\n\t}\n\treturn \"\"\n}", "func (me TAttlistSupplMeshNameType) IsProtocol() bool { return me.String() == \"Protocol\" }", "func (info *PipelineInfo) IsDeployOnlyPipeline() bool {\n\treturn info.PipelineArguments.ToEnvironment != \"\" && info.PipelineArguments.FromEnvironment == \"\"\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func (es *Connection) PipelineExists(id string) (bool, error) {\n\tstatus, _, err := es.apiCall(\"GET\", \"_ingest\", \"pipeline\", id, \"\", nil, nil)\n\tif status == 404 {\n\t\treturn false, nil\n\t}\n\treturn status == 200, err\n}", "func HasStage(s []Stage, name string) (int, bool) {\n\tfor i, stage := range s {\n\t\t// Stage name is case-insensitive by design\n\t\tif strings.EqualFold(stage.Name, name) {\n\t\t\treturn i, true\n\t\t}\n\t}\n\treturn -1, false\n}", "func ValidateProgramPipeline(pipeline uint32) {\n\tC.glowValidateProgramPipeline(gpValidateProgramPipeline, (C.GLuint)(pipeline))\n}", "func ValidateProgramPipeline(pipeline uint32) {\n\tC.glowValidateProgramPipeline(gpValidateProgramPipeline, (C.GLuint)(pipeline))\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func isExported(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func ValidatePipelineName(pipelineName string) error {\n\tif pipelineName == \"\" {\n\t\treturn util.NewInvalidInputError(\"pipeline's name cannot be empty\")\n\t}\n\tif len(pipelineName) > 128 {\n\t\treturn util.NewInvalidInputError(\"pipeline's name must contain no more than 128 characters\")\n\t}\n\tif matched, err := regexp.MatchString(pipelineNamePattern, pipelineName); err != nil {\n\t\treturn util.NewInternalServerError(\n\t\t\terr, \"failed to compile pattern '%s'\", pipelineNamePattern)\n\t} else if !matched {\n\t\treturn util.NewInvalidInputError(\"pipeline's name must contain only lowercase alphanumeric characters or '-' and must start with alphanumeric characters\")\n\t}\n\treturn nil\n}", "func (task *Task) GetPipelineCode() (PipelineCode, bool) {\n\tif task.Tmall != nil || task.Taobao != nil {\n\t\treturn \"taobao.com\", true\n\t}\n\n\treturn PipelineCode(task.Hostname), false\n}", "func GetNamedPipeClientComputerName(pipe HANDLE, clientComputerName LPWSTR, clientComputerNameLength ULONG) bool {\n\tret1 := syscall3(getNamedPipeClientComputerName, 3,\n\t\tuintptr(pipe),\n\t\tuintptr(unsafe.Pointer(clientComputerName)),\n\t\tuintptr(clientComputerNameLength))\n\treturn ret1 != 0\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func NameArg(p cli.Params) cobra.PositionalArgs {\n\n\treturn func(cmd *cobra.Command, args []string) error {\n\t\tif len(args) == 0 {\n\t\t\treturn errNoPipeline\n\t\t}\n\n\t\tc, err := p.Clients()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tname, ns := args[0], p.Namespace()\n\t\t_, err = c.Tekton.TektonV1alpha1().Pipelines(ns).Get(name, metav1.GetOptions{})\n\t\tif err != nil {\n\t\t\treturn errInvalidPipeline\n\t\t}\n\n\t\treturn nil\n\t}\n\n}", "func (o LookupPipelineResultOutput) Name() pulumi.StringOutput {\n\treturn o.ApplyT(func(v LookupPipelineResult) string { return v.Name }).(pulumi.StringOutput)\n}", "func (o LookupPipelineResultOutput) Name() pulumi.StringOutput {\n\treturn o.ApplyT(func(v LookupPipelineResult) string { return v.Name }).(pulumi.StringOutput)\n}", "func objectNameAndCommandLine(env *cmdline.Env, args []string) (string, string, error) {\n\tif len(args) < 1 {\n\t\treturn \"\", \"\", errors.New(\"object name missing\")\n\t}\n\tname := args[0]\n\targs = args[1:]\n\t// For compatibility with tools like rsync. Because object names\n\t// don't look like traditional hostnames, tools that work with rsh and\n\t// ssh can't work directly with vsh. This trick makes the following\n\t// possible:\n\t// $ VSH_NAME=<object name> rsync -avh -e vsh /foo/* v23:/foo/\n\t// The \"v23\" host will be substituted with <object name>.\n\tif envName := env.Vars[\"VSH_NAME\"]; envName != \"\" && name == \"v23\" {\n\t\tname = envName\n\t}\n\tcmd := strings.Join(args, \" \")\n\treturn name, cmd, nil\n}", "func ParseVideoPipeline(name string) VideoPipeline {\n\tswitch {\n\tdefault:\n\t\treturn VideoPipelineDefault\n\tcase name == string(VideoPipelineLowPower):\n\t\treturn VideoPipelineLowPower\n\tcase name == string(VideoPipelineVAAPI):\n\t\treturn VideoPipelineVAAPI\n\t}\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func (r *subprocess) isContext(n ast.Node, ctx *gosec.Context) bool {\n\tselector, indent, err := gosec.GetCallInfo(n, ctx)\n\tif err != nil {\n\t\treturn false\n\t}\n\tif selector == \"exec\" && indent == \"CommandContext\" {\n\t\treturn true\n\t}\n\treturn false\n}", "func (ap *ActivePipelines) Replace(p gaia.Pipeline) bool {\n\tap.Lock()\n\tdefer ap.Unlock()\n\n\t// Search for the id\n\tvar i = -1\n\tfor id, pipeline := range ap.Pipelines {\n\t\tif pipeline.Name == p.Name {\n\t\t\ti = id\n\t\t\tbreak\n\t\t}\n\t}\n\n\t// We got it?\n\tif i == -1 {\n\t\treturn false\n\t}\n\n\t// Yes\n\tap.Pipelines[i] = p\n\treturn true\n}", "func IsStandardFinalizerName(str string) bool {\n\treturn standardFinalizers.Has(str)\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (ts TaskSpec) InputByName(name string) (TaskInputSpec, bool) {\n\tfor _, x := range ts.Inputs {\n\t\tif x.Name == name {\n\t\t\treturn x, true\n\t\t}\n\t}\n\treturn TaskInputSpec{}, false\n}", "func IsCorp(hostname string) bool {\n\treturn (hostname == \"avellanos\" || hostname == \"montero\" || hostname == \"monygham\")\n}", "func GetPipeline(email Email) Pipeline {\n\tif email.From == \"[email protected]\" {\n\t\treturn PipeA\n\t}\n\treturn PipeB\n}", "func isValidName(name string) bool { return name != \"_\" && name != \"this\" }", "func IsExportedName(name string) bool {\n\trune, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(rune)\n}", "func IsJobNameUnique(repository JobSpecRepository) survey.Validator {\n\treturn func(val interface{}) error {\n\t\tif str, ok := val.(string); ok {\n\t\t\tif _, err := repository.GetByName(str); err == nil {\n\t\t\t\treturn fmt.Errorf(\"job with the provided name already exists\")\n\t\t\t}\n\t\t} else {\n\t\t\t// otherwise we cannot convert the value into a string and cannot find a job name\n\t\t\treturn fmt.Errorf(\"invalid type of job name %v\", reflect.TypeOf(val).Name())\n\t\t}\n\t\t// the input is fine\n\t\treturn nil\n\t}\n}", "func IsProgram(program uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsProgram, 1, uintptr(program), 0, 0)\n\treturn ret != 0\n}", "func OpenByName(r *regexp.Regexp) (ps []Process, harderror error, softerrors []error) {\n\tprocs, harderror, softerrors := OpenAll()\n\tif harderror != nil {\n\t\treturn nil, harderror, nil\n\t}\n\n\tmatchs := make([]Process, 0)\n\n\tfor _, p := range procs {\n\t\tname, err, softs := p.Name()\n\t\tif err != nil {\n\t\t\tsofterrors = append(softerrors, err)\n\t\t}\n\t\tif softs != nil {\n\t\t\tsofterrors = append(softerrors, softs...)\n\t\t}\n\n\t\tif r.MatchString(name) {\n\t\t\tmatchs = append(matchs, p)\n\t\t} else {\n\t\t\tp.Close()\n\t\t}\n\t}\n\n\treturn matchs, nil, softerrors\n}", "func NameArg(args []string, p cli.Params, file string) (*v1beta1.Pipeline, error) {\n\tpipelineErr := &v1beta1.Pipeline{}\n\tif len(args) == 0 && file == \"\" {\n\t\treturn pipelineErr, errNoPipeline\n\t}\n\n\tc, err := p.Clients()\n\tif err != nil {\n\t\treturn pipelineErr, err\n\t}\n\n\tif file == \"\" {\n\t\tname, ns := args[0], p.Namespace()\n\t\t// get pipeline by pipeline name passed as arg[0] from namespace\n\t\tpipelineNs, err := getPipelineV1beta1(pipelineGroupResource, c, name, ns)\n\t\tif err != nil {\n\t\t\treturn pipelineErr, fmt.Errorf(errInvalidPipeline, name, ns)\n\t\t}\n\t\treturn pipelineNs, nil\n\t}\n\n\t// file does not equal \"\" so the pipeline is parsed from local or remote file\n\tpipelineFile, err := parsePipeline(file, c.HTTPClient)\n\tif err != nil {\n\t\treturn pipelineErr, err\n\t}\n\n\treturn pipelineFile, nil\n}", "func containsCommand(components []string) bool {\n\tfor _, comp := range components {\n\t\tif isCommand(comp) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (g *generator) Name() string {\n\treturn \"schemapatch\"\n}", "func exportedFrom(obj types.Object, pkg *types.Package) bool {\n\tswitch obj := obj.(type) {\n\tcase *types.Func:\n\t\treturn obj.Exported() && obj.Pkg() == pkg ||\n\t\t\tobj.Type().(*types.Signature).Recv() != nil\n\tcase *types.Var:\n\t\treturn obj.Exported() && obj.Pkg() == pkg ||\n\t\t\tobj.IsField()\n\tcase *types.TypeName, *types.Const:\n\t\treturn true\n\t}\n\treturn false // Nil, Builtin, Label, or PkgName\n}", "func (e *TarantoolEngine) name() string {\n\treturn \"Tarantool\"\n}", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func IsResourceTypeNameAvail(w http.ResponseWriter, r *http.Request) (interface{}, error) {\n\ttypename := r.Form.Get(\"typename\")\n\texists := false\n\tdb := GetDBHandle()\n\terr := db.QueryRow(\"SELECT exists (SELECT resourcetype FROM resourcetypes WHERE resourcetype=$1)\", typename).Scan(&exists)\n\n\treturn exists, err\n}", "func IsExported(name string) bool {\n\tch, _ := utf8.DecodeRuneInString(name)\n\treturn unicode.IsUpper(ch)\n}", "func (o *LogsPipelineProcessor) GetName() string {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret\n\t}\n\treturn *o.Name\n}", "func isContainer(mode string) bool {\n\tparts := strings.SplitN(mode, \":\", 2)\n\treturn len(parts) > 1 && parts[0] == \"container\"\n}", "func isSelf(e *evtx.GoEvtxMap) bool {\n\tif pguid, err := e.GetString(&pathSysmonParentProcessGUID); err == nil {\n\t\tif pguid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\tif guid, err := e.GetString(&pathSysmonProcessGUID); err == nil {\n\t\tif guid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\tif sguid, err := e.GetString(&pathSysmonSourceProcessGUID); err == nil {\n\t\tif sguid == selfGUID {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o LaunchOutput) Name() pulumi.StringOutput {\n\treturn o.ApplyT(func(v *Launch) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput)\n}", "func (p *Pipeline) RBACName() string {\n\treturn \"pipelines\"\n}", "func isOwnedByJob(ownerKinds []string) bool {\n\tif len(ownerKinds) == 1 && ownerKinds[0] == \"Job\" {\n\t\treturn true\n\t}\n\treturn false\n}" ]
[ "0.6325196", "0.6267771", "0.5848094", "0.5819732", "0.5615766", "0.555063", "0.54052204", "0.5222975", "0.5158938", "0.51357687", "0.51293266", "0.5092916", "0.5084024", "0.5072239", "0.5052269", "0.5038778", "0.50297457", "0.5006188", "0.49929217", "0.4952545", "0.49442524", "0.49307817", "0.492223", "0.49201742", "0.48998824", "0.48929438", "0.48611298", "0.48525038", "0.48479483", "0.48383936", "0.4824005", "0.4810409", "0.4810409", "0.48053256", "0.47813168", "0.47690538", "0.47453365", "0.47448626", "0.47445196", "0.47445196", "0.47445196", "0.47445196", "0.47427908", "0.47410214", "0.47309455", "0.47307938", "0.47250217", "0.47194725", "0.4717596", "0.47149622", "0.47135207", "0.4710013", "0.46814895", "0.46809846", "0.46809846", "0.46713758", "0.46713758", "0.46713758", "0.46713758", "0.46713758", "0.46713758", "0.46713758", "0.46713758", "0.46598038", "0.46580207", "0.46564054", "0.46560803", "0.46555296", "0.46517518", "0.46517518", "0.46454665", "0.4644325", "0.4638581", "0.46305725", "0.4626186", "0.45998722", "0.45942855", "0.45746538", "0.4573789", "0.4568281", "0.45653465", "0.4562698", "0.45576352", "0.45490068", "0.45469058", "0.45431194", "0.4539976", "0.4527149", "0.4523929", "0.45057553", "0.45020956", "0.44988722", "0.4493328", "0.44929585", "0.4492437", "0.4491138", "0.44887102", "0.4488626", "0.44866097" ]
0.5878413
3
determine if a name corresponds to a query object
func IsQuery(id uint32) bool { ret := C.glowIsQuery(gpIsQuery, (C.GLuint)(id)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func isQuery(slct string) bool {\n\ts := strings.ToUpper(strings.TrimSpace(slct))\n\thas := strings.Contains\n\tif strings.HasPrefix(s, \"SELECT\") && !has(s, \"INTO\") {\n\t\treturn true\n\t}\n\tif strings.HasPrefix(s, \"SHOW\") && (has(s, \"CREATE\") || has(s, \"DATABASES\") || has(s, \"TABLES\")) {\n\t\treturn true\n\t}\n\tif strings.HasPrefix(s, \"DESCRIBE\") {\n\t\treturn true\n\t}\n\treturn false\n}", "func Find(name string) (string, bool) { q, ok := queries[name]; return q, ok }", "func (o *EventsScalarQuery) HasName() bool {\n\treturn o != nil && o.Name != nil\n}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (m *MongoSearchSuite) TestPatientNameStringQueryObject(c *C) {\n\tq := Query{\"Patient\", \"name=Peters\"}\n\n\to := m.MongoSearcher.createQueryObject(q)\n\tc.Assert(o, DeepEquals, bson.M{\n\t\t\"$or\": []bson.M{\n\t\t\tbson.M{\"name.text\": bson.RegEx{Pattern: \"^Peters\", Options: \"i\"}},\n\t\t\tbson.M{\"name.family\": bson.RegEx{Pattern: \"^Peters\", Options: \"i\"}},\n\t\t\tbson.M{\"name.given\": bson.RegEx{Pattern: \"^Peters\", Options: \"i\"}},\n\t\t},\n\t})\n}", "func (native *OpenGL) IsQuery(id uint32) bool {\n\treturn gl.IsQuery(id)\n}", "func (q *QueryString) Contains(name string) bool {\n\t_, ok := q.fields[name]\n\treturn ok\n}", "func (m Message) IsQuery() bool {\n\treturn m.Y == \"q\"\n}", "func (qs DaytypeQS) NameEq(v string) DaytypeQS {\n\treturn qs.filter(`\"name\" =`, v)\n}", "func (h *dnsHeader) isAQuery() bool {\n\treturn h.flags&dnsQR != dnsQR\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func isAnswerToQuery(sec section.WithSig, q section.Section) bool {\n\tswitch sec := sec.(type) {\n\tcase *section.Assertion:\n\t\tif q, ok := q.(*query.Name); ok {\n\t\t\tif q.Name == fmt.Sprintf(\"%s.%s\", sec.SubjectName, sec.SubjectZone) {\n\t\t\t\tfor _, oType := range q.Types {\n\t\t\t\t\tif _, ok := object.ContainsType(sec.Content, oType); ok {\n\t\t\t\t\t\treturn true\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false\n\tcase *section.Shard:\n\t\tif q, ok := q.(*query.Name); ok {\n\t\t\tif name, ok := getSubjectName(q.Name, sec.SubjectZone); ok {\n\t\t\t\treturn sec.InRange(name)\n\t\t\t}\n\t\t}\n\t\treturn false\n\tcase *section.Zone:\n\t\tif q, ok := q.(*query.Name); ok {\n\t\t\tif _, ok := getSubjectName(q.Name, sec.SubjectZone); ok {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t\treturn false\n\tcase *section.AddrAssertion:\n\t\t//TODO CFE implement the host address and network address case if delegation is a response\n\t\t//or not.\n\t\t_, ok := q.(*query.Address)\n\t\treturn ok\n\tdefault:\n\t\tlog.Error(\"Not supported message section with sig. This case must be prevented beforehand\")\n\t}\n\treturn true\n}", "func IsQuery(id uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsQuery, 1, uintptr(id), 0, 0)\n\treturn ret != 0\n}", "func (qs InstantprofileQS) NameEq(v string) InstantprofileQS {\n\treturn qs.filter(`\"name\" =`, v)\n}", "func doesQueryExistAlreadyInDatabase(query string, db models.Datastore) bool {\n\treturn db.GetSetQuery(query) != nil\n}", "func (q *DistanceFeatureQuery) QueryName(queryName string) *DistanceFeatureQuery {\n\tq.queryName = queryName\n\treturn q\n}", "func (r *QueryRequest) isSimpleQuery() bool {\n\treturn r.PreparedStatement != nil && r.PreparedStatement.isSimpleQuery()\n}", "func (qs GroupQuerySet) NameEq(name string) GroupQuerySet {\n\treturn qs.w(qs.db.Where(\"name = ?\", name))\n}", "func HasKeyValueViaName(iName string) bool {\n\tif has, err := Engine.Where(\"name = ?\", iName).Get(new(KeyValue)); err != nil {\n\t\treturn false\n\t} else {\n\t\tif has {\n\t\t\treturn true\n\t\t}\n\t\treturn false\n\t}\n}", "func (pq *PersonQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := pq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn pq.sqlExist(ctx)\n}", "func Name(v string) predicate.User {\n\treturn predicate.User(sql.FieldEQ(FieldName, v))\n}", "func Name(v string) predicate.User {\n\treturn predicate.User(sql.FieldEQ(FieldName, v))\n}", "func (dbh *DBHandler) NameExists(name string) bool {\n\tresult, err := dbh.Connection.Query(`SELECT * FROM users WHERE nickname = ?;`, name)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tdefer result.Close()\n\tif result.Next() {\n\t\treturn true\n\t}\n\treturn false\n}", "func NameEQ(v string) predicate.User {\n\treturn predicate.User(sql.FieldEQ(FieldName, v))\n}", "func NameEQ(v string) predicate.User {\n\treturn predicate.User(sql.FieldEQ(FieldName, v))\n}", "func (this *dataStore) namedStmt(queryName string, obj interface{}) (*namedStmt, error) {\r\n\r\n\tvar modelName string\r\n\r\n\tif mnString, ok := obj.(string); !ok {\r\n\t\tmodelName = strings.TrimPrefix(fmt.Sprintf(`%T`, obj), `*`)\r\n\t} else {\r\n\t\tmodelName = mnString\r\n\t}\r\n\r\n\tif stmt, ok := this.namedStmts[modelName][queryName]; !ok {\r\n\t\treturn nil, fmt.Errorf(`statement %q for %q not found`, queryName, modelName)\r\n\t} else {\r\n\t\treturn stmt, nil\r\n\t}\r\n}", "func IsEmptyQuery(query string) bool {\n\treturn \"query () { { } }\" == query\n}", "func (p *Oracle) ObjectQuery() string {\n\treturn `SELECT * FROM %s WHERE 1=0`\n}", "func ExistExamplByName(name string) (bool, error) {\n\tvar example Example\n\terr := db.Select(\"id\").Where(\"name = ? AND deleted_on = ? \", name, 0).First(&example).Error\n\tif err != nil && err != gorm.ErrRecordNotFound {\n\t\treturn false, err\n\t}\n\n\tif example.ID > 0 {\n\t\treturn true, nil\n\t}\n\n\treturn false, nil\n}", "func (c *CleaningroomClient) QueryCleanername(cl *Cleaningroom) *CleanernameQuery {\n\tquery := &CleanernameQuery{config: c.config}\n\tquery.path = func(ctx context.Context) (fromV *sql.Selector, _ error) {\n\t\tid := cl.ID\n\t\tstep := sqlgraph.NewStep(\n\t\t\tsqlgraph.From(cleaningroom.Table, cleaningroom.FieldID, id),\n\t\t\tsqlgraph.To(cleanername.Table, cleanername.FieldID),\n\t\t\tsqlgraph.Edge(sqlgraph.M2O, true, cleaningroom.CleanernameTable, cleaningroom.CleanernameColumn),\n\t\t)\n\t\tfromV = sqlgraph.Neighbors(cl.driver.Dialect(), step)\n\t\treturn fromV, nil\n\t}\n\treturn query\n}", "func (q *QueryString) Predicate(name string) (p Predicate, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = rec.(error)\n\t\t}\n\t}()\n\n\traw, ok := q.fields[name]\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"field not found: %q\", name)\n\t}\n\n\tp, raw = parsePredicate(raw)\n\tif len(raw) != 0 {\n\t\tp = nil\n\t\terr = UnexpectedEndOfPredicate\n\t}\n\n\treturn\n}", "func (o *DnsEventAllOf) HasQuery() bool {\n\tif o != nil && o.Query != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *EventsScalarQuery) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (*RegDBService) NameExists(name string) (bool, error) {\n\tvar reg []Registration\n\terr := rdb.Raw(\"select * from ((select name from account) union (select name from registration)) user where name = ?\", name).Find(&reg).Error\n\tif err != nil {\n\t\treturn false, err\n\t}\n\tif len(reg) != 0 {\n\t\treturn true, rerr.MSG_2002\n\t}\n\treturn false, err\n}", "func NameContains(v string) predicate.User {\n\treturn predicate.User(sql.FieldContains(FieldName, v))\n}", "func NameContains(v string) predicate.User {\n\treturn predicate.User(sql.FieldContains(FieldName, v))\n}", "func Name(v string) predicate.Location {\n\treturn predicate.Location(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t},\n\t)\n}", "func (roq *RestaurantOwnerQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := roq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn roq.sqlExist(ctx)\n}", "func (r repo) matches(query []string) bool {\n\tname := strings.ToLower(r.Name)\n\tfor _, q := range query {\n\t\tif !strings.Contains(name, q) {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func (q VariadicQuery) GetName() string {\n\treturn \"\"\n}", "func NameEQ(v string) predicate.Book {\n\treturn predicate.Book(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func (d UserData) HasName() bool {\n\treturn d.ModelData.Has(models.NewFieldName(\"Name\", \"name\"))\n}", "func (c *Context) QueryBool(name string) bool {\n\tb, _ := strconv.ParseBool(c.Query(name))\n\treturn b\n}", "func Name(v string) predicate.Book {\n\treturn predicate.Book(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func (wtq *WorkerTypeQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := wtq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn wtq.sqlExist(ctx)\n}", "func (db *DB) Named(query string, arg interface{}) (string, interface{}, error) {\n\treturn sqlx.Named(query, arg)\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func hasValidSavedQuery(query interface{}) error {\n\tqueryConverted := query.(map[string]interface{})\n\tlistQueryTypes := []string{\"count/entity\", \"count/event\", \"count/entity/total\", \"aggregation\", \"top_values\"}\n\tif !stringInSlice(queryConverted[\"type\"].(string), listQueryTypes) {\n\t\treturn errors.New(\"Saved Query Validator: this dictionary don't have query type valid.\")\n\t}\n\treturn nil\n}", "func (q *ParentIdQuery) QueryName(queryName string) *ParentIdQuery {\n\tq.queryName = queryName\n\treturn q\n}", "func (pi *PackageIndexer) Query(name string) string {\n\t// query indexer for package \n\tif _, ok := pi.packs[name]; ok {\t\t\t\t\t\t\t\n return OK \t\t\t\t\t\t\t\t\t\t\t\t\n }\n\n return FAIL\t\t\t\t\t\t\t\t\t\t\t\t\t\n}", "func NameEQ(v string) predicate.Location {\n\treturn predicate.Location(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t},\n\t)\n}", "func (ctx *Context) Query(name string) string {\n\treturn ctx.QueryParams().Get(name)\n}", "func (r Response) IsYnQuery() bool {\n\treturn r.Act == ActYnQuery\n}", "func matchesQuery(query map[string]interface{}, candidate interface{}) bool {\n\tvals := reflect.ValueOf(candidate)\n\tfor i := 0; i < vals.NumField(); i++ {\n\t\tfield := vals.Field(i)\n\t\tfieldName := vals.Type().Field(i).Tag.Get(\"json\")\n\t\tif queryVal, ok := query[fieldName]; ok {\n\t\t\t// If we run into a slice, we make sure that all values in the query slice exist in the candidate slice\n\t\t\t// TODO: make this cleaner and not O(N^2) (sort of). We just hope members lists are short for now.\n\t\t\tif field.Kind() == reflect.Slice {\n\t\t\t\tcfield := reflect.ValueOf(queryVal)\n\t\t\tcandidateLoop:\n\t\t\t\tfor i := 0; i < cfield.Len(); i++ {\n\t\t\t\t\tfor j := 0; j < field.Len(); j++ {\n\t\t\t\t\t\tif field.Index(j).Interface() == cfield.Index(i).Interface() {\n\t\t\t\t\t\t\tcontinue candidateLoop\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn false\n\t\t\t\t}\n\t\t\t} else if queryVal != field.Interface() {\n\t\t\t\treturn false\n\t\t\t}\n\t\t}\n\t}\n\treturn true\n}", "func NameEQ(v string) predicate.AllocationStrategy {\n\treturn predicate.AllocationStrategy(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func (rdq *ResultsDefinitionQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := rdq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn rdq.sqlExist(ctx)\n}", "func (req fedSearchRequest) nameOnly() bool {\n\treturn req.Name != \"\" && req.RoutingNumber == \"\" && req.City == \"\" &&\n\t\treq.State == \"\" && req.PostalCode == \"\"\n}", "func isKeyword(in string) bool {\n\tswitch strings.ToUpper(in) {\n\tcase \"SELECT\", \"INSERT\", \"UPDATE\", \"DELETE\":\n\t\treturn true\n\tcase \"FROM\", \"WHERE\", \"AND\", \"OR\", \"IS\", \"NOT\", \"IN\":\n\t\treturn true\n\tcase \"INNER\", \"JOIN\":\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (nvp *NameValues) Exists(name string) bool {\n\n\tif !nvp.prepared {\n\t\tnvp.prepare()\n\t}\n\n\tname = strings.ToLower(name)\n\t_, exists := nvp.Pair[name]\n\treturn exists\n}", "func QueryVerify(name string) bool {\n\tcount, err := dbmap.SelectInt(\"select count(1) from cr_image where Image_name = ?\", name)\n\tif err != nil {\n\t\tlog.Fatalln(\"Verify failed\", err)\n\t\treturn false\n\t}\n\tif count < 1 {\n\t\treturn true\n\t}\n\treturn false\n}", "func (q *PersonQuery) FindByName(v string) *PersonQuery {\n\treturn q.Where(kallax.Eq(Schema.Person.Name, v))\n}", "func (rq *RemedyQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := rq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn rq.sqlExist(ctx)\n}", "func NameEQ(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func NameEQ(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func NameEQ(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func IsQuery(id uint32) bool {\n ret := C.glowIsQuery(gpIsQuery, (C.GLuint)(id))\n return ret == TRUE\n}", "func (qs SysDBQuerySet) ShowNameEq(showName string) SysDBQuerySet {\n\treturn qs.w(qs.db.Where(\"show_name = ?\", showName))\n}", "func (o *AuthorDto) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *DnsEventAllOf) GetQueryOk() (*string, bool) {\n\tif o == nil || o.Query == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Query, true\n}", "func (s *Space) HasSameName(spaceId, name string) (has bool, err error) {\n\tdb := G.DB()\n\tvar rs *mysql.ResultSet\n\trs, err = db.Query(db.AR().From(Table_Space_Name).Where(map[string]interface{}{\n\t\t\"space_id <>\": spaceId,\n\t\t\"name\": name,\n\t\t\"is_delete\": Space_Delete_False,\n\t}).Limit(0, 1))\n\tif err != nil {\n\t\treturn\n\t}\n\tif rs.Len() > 0 {\n\t\thas = true\n\t}\n\treturn\n}", "func Is(name string) bool {\n\treturn contains(name, All)\n}", "func (hq *HarborQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := hq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn hq.sqlExist(ctx)\n}", "func QueryHasParam(request *http.Request, paramName string) bool {\n\t_, ok := request.URL.Query()[paramName]\n\n\treturn ok\n}", "func (o *QueryLambdaSql) GetQueryOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Query, true\n}", "func (*NamedType) isType() {}", "func (client *Client) Query(name string) *Query {\n\ttarget := client.Target(\"query\", name)\n\tif target == nil {\n\t\treturn nil\n\t}\n\n\treturn target.(*Query)\n}", "func (daq *DrugAllergyQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := daq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn daq.sqlExist(ctx)\n}", "func userExist(name string) User {\n\n\tu := User{}\n\tfmt.Println(name)\n\tfmt.Println(reflect.TypeOf(name))\n\n\tvar theQuery = \"SELECT * FROM users WHERE name=$1\"\n\n\trow := db.QueryRow(theQuery, name)\n\terr := row.Scan(&u.ID, &u.Name, &u.Score);\n\n\tif err != nil && err != sql.ErrNoRows {\n\t\tfmt.Println(err.Error())\t\n\t}\n\n\treturn u\n\n}", "func (o *MonitorSearchResult) HasQuery() bool {\n\tif o != nil && o.Query != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (o *FiltersApiLog) HasQueryApiNames() bool {\n\tif o != nil && o.QueryApiNames != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func IsAlias(name, alias string) bool {\n\td := registry.Driver(name)\n\tfor _, da := range d.Alias {\n\t\tif da == alias {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func Name(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func Name(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func Name(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.EQ(s.C(FieldName), v))\n\t})\n}", "func (wq *WordQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := wq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn wq.sqlExist(ctx)\n}", "func (o *FiltersApiLog) HasQueryCallNames() bool {\n\tif o != nil && o.QueryCallNames != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (ids WorkloadEndpointIdentifiers) NameMatches(name string) (bool, error) {\n\t// Extract the required segments for this orchestrator type.\n\treq, err := ids.getSegments()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\t// Extract the parameters from the name.\n\tparts := ExtractDashSeparatedParms(name, len(req))\n\tif len(parts) == 0 {\n\t\treturn false, nil\n\t}\n\n\t// Check each name segment for a non-match.\n\tfor i, r := range req {\n\t\tif r.value != \"\" && r.value != parts[i] {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func (b *Filter) Query(word string) bool {\n\thashedWord := hashWord(word)\n\twordAsInts := getIntsFromHash(hashedWord)\n\tmappedInts := b.mapToRange(wordAsInts)\n\n\tfor _, n := range mappedInts {\n\t\tif b.bitmap[n] == false {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func (r Response) IsWhQuery() bool {\n\treturn r.Act == ActWhQuery\n}", "func (d *Doctorinfo) QueryPrename() *PrenameQuery {\n\treturn (&DoctorinfoClient{config: d.config}).QueryPrename(d)\n}", "func (vq *VehicleQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := vq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn vq.sqlExist(ctx)\n}", "func (rq *RentQuery) Exist(ctx context.Context) (bool, error) {\n\tif err := rq.prepareQuery(ctx); err != nil {\n\t\treturn false, err\n\t}\n\treturn rq.sqlExist(ctx)\n}", "func (d *Database) AnotherExistsWithSameName(tx *sqlx.Tx) (exists bool, err error) {\n\ttx.QueryRowx(\"SELECT id FROM \\\"database\\\" WHERE name = $1 AND owner != $2\", d.Name, d.Owner).Scan(&d.Id)\n\treturn true, nil\n}", "func NameContains(v string) predicate.Location {\n\treturn predicate.Location(func(s *sql.Selector) {\n\t\ts.Where(sql.Contains(s.C(FieldName), v))\n\t},\n\t)\n}", "func HasKeyValueExpireViaName(iName string) bool {\n\tif has, err := Engine.Where(\"name = ?\", iName).Get(new(KeyValueExpire)); err != nil {\n\t\treturn false\n\t} else {\n\t\tif has {\n\t\t\treturn true\n\t\t}\n\t\treturn false\n\t}\n}", "func NameContains(v string) predicate.User {\n\treturn predicate.User(func(s *sql.Selector) {\n\t\ts.Where(sql.Contains(s.C(FieldName), v))\n\t})\n}" ]
[ "0.64505905", "0.6264815", "0.62556034", "0.5931015", "0.5874682", "0.57733893", "0.57722104", "0.57283306", "0.5649658", "0.5603658", "0.56005394", "0.553219", "0.55095875", "0.54462713", "0.5436877", "0.5433772", "0.5389541", "0.53888893", "0.53841645", "0.5379617", "0.5327105", "0.5327105", "0.52830726", "0.52813196", "0.52813196", "0.52651036", "0.5255634", "0.52353", "0.52282196", "0.5228181", "0.5177188", "0.51762855", "0.51737994", "0.51558346", "0.51551485", "0.5152612", "0.5152612", "0.5144084", "0.5141797", "0.513093", "0.5127687", "0.5123397", "0.51199126", "0.5118125", "0.5115668", "0.5104021", "0.51037735", "0.51033854", "0.51030743", "0.50976014", "0.5094273", "0.50871223", "0.5084737", "0.50846905", "0.5084625", "0.5078994", "0.5077821", "0.5051125", "0.50505775", "0.50494826", "0.50494075", "0.50480705", "0.50426316", "0.5040105", "0.5040105", "0.5040105", "0.5039148", "0.50345373", "0.5032501", "0.5032419", "0.50226504", "0.50149065", "0.5007564", "0.50029844", "0.50022835", "0.50013494", "0.4992497", "0.49897248", "0.49848402", "0.49821535", "0.49800292", "0.49766138", "0.49761486", "0.49715978", "0.4968649", "0.4968649", "0.4968649", "0.4968218", "0.49662364", "0.49589583", "0.4951309", "0.49424204", "0.49373823", "0.49326566", "0.49324617", "0.49277648", "0.49252123", "0.49245164", "0.49240938" ]
0.5081415
56
determine if a name corresponds to a renderbuffer object
func IsRenderbuffer(renderbuffer uint32) bool { ret := C.glowIsRenderbuffer(gpIsRenderbuffer, (C.GLuint)(renderbuffer)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (a *Asset) IsBuffered() bool {\n\treturn isBufferName(a.OutName)\n}", "func IsBuffer(buffer uint32) bool {\n ret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n return ret == TRUE\n}", "func IsRenderbuffer(renderbuffer uint32) bool {\n ret := C.glowIsRenderbuffer(gpIsRenderbuffer, (C.GLuint)(renderbuffer))\n return ret == TRUE\n}", "func (renderbuffer Renderbuffer) IsRenderbuffer() bool {\n\treturn gl.IsRenderbuffer(uint32(renderbuffer))\n}", "func IsBuffer(buffer Uint) Boolean {\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\t__ret := C.glIsBuffer(cbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func IsRenderbuffer(renderbuffer Uint) Boolean {\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\t__ret := C.glIsRenderbuffer(crenderbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func IsRenderbuffer(renderbuffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsRenderbuffer, 1, uintptr(renderbuffer), 0, 0)\n\treturn ret != 0\n}", "func IsBuffer(buffer uint32) bool {\n\tret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func IsBuffer(buffer uint32) bool {\n\tret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func IsRendered(wid fyne.Widget) bool {\n\trenderersLock.RLock()\n\t_, found := renderers[wid]\n\trenderersLock.RUnlock()\n\treturn found\n}", "func IsRenderbuffer(rb Renderbuffer) bool {\n\treturn gl.IsRenderbuffer(rb.Value)\n}", "func IsBuffer(b Buffer) bool {\n\treturn gl.IsBuffer(b.Value)\n}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\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 (DrawTexture) IsDrawAction() {}", "func (self *Graphics) Exists() bool{\n return self.Object.Get(\"exists\").Bool()\n}", "func (self *Graphics) Name() string{\n return self.Object.Get(\"name\").String()\n}", "func IsBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpUnmapNamedBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func DetectRendererType(filename string, input io.Reader) string {\n\tbuf, err := io.ReadAll(input)\n\tif err != nil {\n\t\treturn \"\"\n\t}\n\tfor _, renderer := range renderers {\n\t\tif detector, ok := renderer.(RendererContentDetector); ok && detector.CanRender(filename, bytes.NewReader(buf)) {\n\t\t\treturn renderer.Name()\n\t\t}\n\t}\n\treturn \"\"\n}", "func (o *ViewTag) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func IsValidObjectName(object string) bool {\n\tif strings.TrimSpace(object) == \"\" {\n\t\treturn false\n\t}\n\tif len(object) > 1024 || len(object) == 0 {\n\t\treturn false\n\t}\n\tif !utf8.ValidString(object) {\n\t\treturn false\n\t}\n\treturn true\n}", "func hasRendererParam(handlerType reflect.Type) bool {\n\t//if the handler doesn't take arguments, false\n\tif handlerType.NumIn() == 0 {\n\t\treturn false\n\t}\n\n\t//if the first argument is not a pointer, false\n\tp1 := handlerType.In(0)\n\tif p1.Kind() != reflect.Ptr {\n\t\treturn false\n\t}\n\t//but if the first argument is a renderer, true\n\tif p1.Elem() == rendererType {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isNamedType(t types.Type, path, name string) bool {\n\tn, ok := t.(*types.Named)\n\tif !ok {\n\t\treturn false\n\t}\n\tobj := n.Obj()\n\treturn obj.Name() == name && obj.Pkg() != nil && obj.Pkg().Path() == path\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpNamedFramebufferRenderbuffer, 4, uintptr(framebuffer), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (e *ObservableEditableBuffer) Name() string {\n\treturn e.details.Name\n}", "func (e *Event) HasName(name string) bool {\n\ts := (*C.gchar)(C.CString(name))\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_event_has_name(e.g(), s) != 0\n}", "func (self *TileSprite) Renderable() bool{\n return self.Object.Get(\"renderable\").Bool()\n}", "func (me TdtypeType) IsFrame() bool { return me.String() == \"frame\" }", "func (o *GstObj) SetName(name string) bool {\n\ts := C.CString(name)\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_object_set_name(o.g(), (*C.gchar)(s)) != 0\n}", "func GetDebugRenderable(rName string) (Renderable, bool) {\n\tr, ok := debugMap.Load(rName)\n\tif r == nil {\n\t\treturn nil, false\n\t}\n\treturn r.(Renderable), ok\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpNamedRenderbufferStorage, 4, uintptr(renderbuffer), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\n}", "func (self *Graphics) InCamera() bool{\n return self.Object.Get(\"inCamera\").Bool()\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tC.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tC.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (e *editor) indexOfBuffer(element *buffer) int {\n\tfor k, v := range e.buffers {\n\t\tif element == v {\n\t\t\treturn k\n\t\t}\n\t}\n\treturn -1 //not found.\n}", "func IsResourceTypeNameAvail(w http.ResponseWriter, r *http.Request) (interface{}, error) {\n\ttypename := r.Form.Get(\"typename\")\n\texists := false\n\tdb := GetDBHandle()\n\terr := db.QueryRow(\"SELECT exists (SELECT resourcetype FROM resourcetypes WHERE resourcetype=$1)\", typename).Scan(&exists)\n\n\treturn exists, err\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func IsTag(name string) bool {\n\treturn plumbing.ReferenceName(name).IsTag()\n}", "func (*Object) Name() string { return \"object\" }", "func (g *grpc) objectNamed(name string) generator.Object {\n\tg.gen.RecordTypeUse(name)\n\treturn g.gen.ObjectNamed(name)\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (self *Graphics) Contains(child *DisplayObject) bool{\n return self.Object.Call(\"contains\", child).Bool()\n}", "func (h *Helper) IsShapeUsedInCRDs(shapeName string) bool {\n\tcrds, _ := h.GetCRDs()\n\tfor _, crd := range crds {\n\t\tif crd.HasShapeAsMember(shapeName) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (*Component_Backplane) IsYANGGoStruct() {}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (p Page) CompareName(comparator string) bool {\n\treturn p.PageName == comparator\n}", "func (o *Object) Name() string {\n\tif !o.Boundary {\n\t\tif o.ID < 0 || o.ID > 1188 {\n\t\t\treturn \"nil\"\n\t\t}\n\t\treturn ObjectDefs[o.ID].Name\n\t}\n\tif o.ID < 0 || o.ID >= len(BoundaryDefs) {\n\t\treturn \"nil\"\n\t}\n\treturn BoundaryDefs[o.ID].Name\n}", "func HasObject(ctx context.Context, objs Objects, kind, name string) (bool, error) {\n\tfor _, obj := range objs {\n\t\tobjKind := ObjectKind(obj)\n\t\tobjName, err := ObjectName(obj)\n\t\tif err != nil {\n\t\t\treturn false, fmt.Errorf(\"failed to get resource name: %v\", err)\n\t\t}\n\t\tif objKind == kind && objName == name {\n\t\t\treturn true, nil\n\t\t}\n\t}\n\treturn false, nil\n}", "func (bm BitMap) Name() string { return bm.name }", "func (o *RackUnitPersonality) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (*NamedType) isType() {}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tsyscall.Syscall(gpNamedFramebufferReadBuffer, 2, uintptr(framebuffer), uintptr(src), 0)\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (d *dubbogo) objectNamed(name string) generator.Object {\n d.gen.RecordTypeUse(name)\n return d.gen.ObjectNamed(name)\n}", "func (s SourceFilesystems) IsAsset(filename string) bool {\n\treturn s.Assets.Contains(filename)\n}", "func (o *ComponentReferenceDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func isBlock(name string, arch arch) bool {\n\tfor _, b := range genericBlocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\tfor _, b := range arch.blocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (me TshapeEnumType) IsRectangle() bool { return me == \"rectangle\" }", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\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 IsNameChar(r byte) bool {\n\treturn false ||\n\t\t'a' <= r && r <= 'z' ||\n\t\t'A' <= r && r <= 'Z' ||\n\t\t'0' <= r && r <= '9' ||\n\t\tr == '.' || r == '_' ||\n\t\tr == '-' || r == '*' ||\n\t\tr == '?' || r == ':' ||\n\t\tr == '[' || r == ']' ||\n\t\tr == '^' || r == '$' ||\n\t\tr == '<' || r == '>' ||\n\t\tr == '&' || r == '#' ||\n\t\tr == '/' || r == '%' ||\n\t\tr == '@'\n}", "func (t *ByteEntity) ScreenName() (string, bool) {\n\treturn t.screenName, t.screenNameIsSet\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (arg1 *UConverter) IsAmbiguous() (_swig_ret UBool)", "func IsNameOnly(ref Named) bool {\n\tif _, ok := ref.(NamedTagged); ok {\n\t\treturn false\n\t}\n\tif _, ok := ref.(Canonical); ok {\n\t\treturn false\n\t}\n\treturn true\n}", "func (DrawText) IsDrawAction() {}", "func (s *JSONStructFinder) isExported(nodeType *ast.TypeSpec) bool {\n\tfirstRune, _ := utf8.DecodeRuneInString(nodeType.Name.Name)\n\treturn unicode.IsUpper(firstRune)\n}", "func (r ReferenceName) IsTag() bool {\n\treturn strings.HasPrefix(string(r), refTagPrefix)\n}", "func (rc *RenderComponent) Name() string {\n\treturn RenderComponentName\n}", "func (self *Graphics) AutoCull() bool{\n return self.Object.Get(\"autoCull\").Bool()\n}", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func (*Component_Fabric) IsYANGGoStruct() {}", "func iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func getAssetByName(assetName string){\n\n}", "func (rs *RenderSystem) Name() string {\n\treturn \"RenderSystem\"\n}", "func (b *Buffer) GetName() string {\n\treturn b.name\n}", "func (o *EquipmentBaseSensor) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowNamedBufferSubData(gpNamedBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowNamedBufferSubData(gpNamedBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func (bo *BytesObj) IsObject() bool {\n\tif bo == nil {\n\t\treturn false\n\t}\n\treturn bo.tp&isObj == isObj\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func (*Component_Memory) IsYANGGoStruct() {}", "func GetTypeByName(typeName string) (tagType TagTypePrimitive, found bool) {\n\ttagType, found = typeNamesR[typeName]\n\treturn tagType, found\n}", "func (self *Graphics) InWorld() bool{\n return self.Object.Get(\"inWorld\").Bool()\n}", "func (o *ParameterContextDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *ShowSystem) HasName() bool {\n\tif o != nil && !IsNil(o.Name) {\n\t\treturn true\n\t}\n\n\treturn false\n}" ]
[ "0.58870584", "0.57849795", "0.577472", "0.56628656", "0.560375", "0.55894476", "0.55118024", "0.5496084", "0.5496084", "0.54501754", "0.5399621", "0.5397151", "0.53742254", "0.5339484", "0.5333023", "0.5333023", "0.52892894", "0.5272635", "0.52490485", "0.52354866", "0.5181813", "0.51678514", "0.51621294", "0.51488054", "0.5148051", "0.51145667", "0.5108015", "0.5087296", "0.50710857", "0.506121", "0.5047726", "0.5041774", "0.5031963", "0.5023633", "0.50150204", "0.49976987", "0.49964043", "0.49964043", "0.49880874", "0.49867263", "0.49832335", "0.49553806", "0.4954888", "0.49527785", "0.49310616", "0.49148864", "0.4912909", "0.49046788", "0.49045515", "0.49045515", "0.49043494", "0.48935118", "0.4891918", "0.48895472", "0.48818952", "0.48775953", "0.4871365", "0.48704743", "0.48701105", "0.48692477", "0.4853311", "0.48474267", "0.48413762", "0.48386464", "0.48365048", "0.48363578", "0.4831576", "0.4831576", "0.48303616", "0.48303616", "0.48285505", "0.48250422", "0.48053503", "0.48053503", "0.4803267", "0.48004055", "0.47984597", "0.47977978", "0.47965187", "0.47937563", "0.47908002", "0.47758582", "0.4771204", "0.47710323", "0.47633854", "0.4761445", "0.47606447", "0.47588074", "0.4758448", "0.4752027", "0.4752027", "0.47514734", "0.4751357", "0.4751357", "0.47476637", "0.47371015", "0.47323585", "0.47221512", "0.47126555" ]
0.53453535
14
determine if a name corresponds to a sampler object
func IsSampler(sampler uint32) bool { ret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func IsSampler(sampler uint32) bool {\n ret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n return ret == TRUE\n}", "func IsSampler(sampler uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsSampler, 1, uintptr(sampler), 0, 0)\n\treturn ret != 0\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func (o *Tier) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (o *StorageSasExpander) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *SecurityMonitoringRuleCase) HasName() bool {\n\treturn o != nil && o.Name != nil\n}", "func (o *Ga4ghChemotherapy) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (ids WorkloadEndpointIdentifiers) NameMatches(name string) (bool, error) {\n\t// Extract the required segments for this orchestrator type.\n\treq, err := ids.getSegments()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\t// Extract the parameters from the name.\n\tparts := ExtractDashSeparatedParms(name, len(req))\n\tif len(parts) == 0 {\n\t\treturn false, nil\n\t}\n\n\t// Check each name segment for a non-match.\n\tfor i, r := range req {\n\t\tif r.value != \"\" && r.value != parts[i] {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (o *EquipmentBaseSensor) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *LogsPipelineProcessor) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *StorageNetAppCloudTargetAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (*NamedType) isType() {}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func (i InjectWrapper) MustGetNamedObject(sample interface{}, name string) interface{} {\n\tsampleType := reflect.TypeOf(sample)\n\tif sampleType.Kind() != reflect.Ptr {\n\t\tpanic(fmt.Sprintf(\"Sample must be interface, found %T\", sample))\n\t}\n\tfor _, obj := range i.objects {\n\t\tif reflect.TypeOf(obj.Value) == sampleType && obj.Name == name {\n\t\t\treturn obj.Value\n\t\t}\n\t}\n\tpanic(fmt.Sprintf(\"Object not found: %s.%T\", name, sample))\n}", "func (o *RackUnitPersonality) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func name(r Runner) string {\n\tif nr, ok := r.(NamedRunner); ok {\n\t\treturn nr.Name()\n\t}\n\treturn \"\"\n}", "func (o *CloudInstanceTypeAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (r *Recorder) Name(name string) *Recorder {\n\tr.filters = append(r.filters, func(v interface{}) bool {\n\t\trecorder := convert(v)\n\t\tif recorder == nil {\n\t\t\treturn false\n\t\t}\n\t\tshared.Debugf(\"%s == %s -> %t\\n\",\n\t\t\tname,\n\t\t\taws.StringValue(recorder.Name),\n\t\t\tname == aws.StringValue(recorder.Name),\n\t\t)\n\t\treturn name == aws.StringValue(recorder.Name)\n\t})\n\treturn r\n}", "func isTemplateBeingUsed(sd *defs, st *defs, tmplName string) bool {\n for _, def := range *st {\n if def.attrExist(\"use\") && def[\"use\"].Has(tmplName){\n return true\n }\n }\n for _, def := range *sd {\n if def.attrExist(\"use\") && def[\"use\"].Has(tmplName){\n return true\n }\n }\n return false\n}", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func (*NamedTypeDummy) isType() {}", "func (o *BulletinDTO) HasSourceName() bool {\n\tif o != nil && o.SourceName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func (*Object) Name() string { return \"object\" }", "func isRegistered(c *checkers.Checker, name string) bool {\n\tif c == nil {\n\t\treturn false\n\t}\n\n\tfor _, info := range c.Info() {\n\t\tif info.Name == name && info.Prefix == \"std\" {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (o *Workloadv1Location) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (s *Sampler) Sample() bool {\n\ts.skipped++\n\tif s.skipped == s.n {\n\t\ts.skipped = 0\n\t\treturn true\n\t}\n\treturn false\n}", "func (e *Event) HasName(name string) bool {\n\ts := (*C.gchar)(C.CString(name))\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_event_has_name(e.g(), s) != 0\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func isRegistered(sample string, stringArray []string) bool {\n\tfor _, value := range stringArray {\n\t\tif ok := strings.Compare(sample, value); ok == 0 {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func isValidName(name string) bool { return name != \"_\" && name != \"this\" }", "func (o *Ga4ghFeature) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (g *grpc) objectNamed(name string) generator.Object {\n\tg.gen.RecordTypeUse(name)\n\treturn g.gen.ObjectNamed(name)\n}", "func (obj *script) Name() string {\n\treturn obj.name\n}", "func (r *Registry) Contains(name string) bool {\n\tr.mtx.RLock()\n\t_, found := r.metricNames[name]\n\tr.mtx.RUnlock()\n\treturn found\n}", "func (d *dubbogo) objectNamed(name string) generator.Object {\n d.gen.RecordTypeUse(name)\n return d.gen.ObjectNamed(name)\n}", "func (o *MonitorSearchResult) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (me TxsdTimeImpactSimpleContentExtensionMetric) IsLabor() bool { return me.String() == \"labor\" }", "func (g *Group) Contains(target Target) bool {\n\tfor _, current := range g.targets {\n\t\tif target.name == current.name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *ApplianceImageBundleAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *Ga4ghTumourboard) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func GiveName(m map[string]string) (string, bool) {\n\tval, exist := m[FirstName]\n\treturn val, exist\n}", "func IsMock(name string) bool {\n\treturn name == Mock\n}", "func (me TEventType) IsHITCreated() bool { return me.String() == \"HITCreated\" }", "func (t *Link) IsNameString(index int) (ok bool) {\n\treturn t.name[index].stringName != nil\n\n}", "func (o *TransactionSplit) HasSourceName() bool {\n\tif o != nil && o.SourceName.IsSet() {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (self *Graphics) Exists() bool{\n return self.Object.Get(\"exists\").Bool()\n}", "func (d *dubbogo) typeName(str string) string {\n return d.gen.TypeName(d.objectNamed(str))\n}", "func (r *reducer) name() string { return r.stmt.Source.(*Measurement).Name }", "func (o *ActionDTO) HasSourceName() bool {\n\tif o != nil && o.SourceName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (p *iexporter) exportName(obj types.Object) (res string) {\n\tif name := p.tparamNames[obj]; name != \"\" {\n\t\treturn name\n\t}\n\treturn obj.Name()\n}", "func (o *RuleSetWarning) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *SLOCorrectionResponseAttributesModifier) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (t *Sampler) Sample() bool {\n\tif t.sampleEvery == 0 {\n\t\treturn false\n\t}\n\treturn (t.numTried.Inc()-1)%t.sampleEvery == 0\n}", "func (s *Secret) HasName(name string) bool {\n\treturn strings.EqualFold(s.Name, name)\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (o *EmbeddedUnitModel) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (me TReviewPolicyLevel) IsHit() bool { return me.String() == \"HIT\" }", "func (p *literalProcessor) name() string { return \"\" }", "func (me TSearchHITsSortProperty) IsReward() bool { return me.String() == \"Reward\" }", "func Is(name string) bool {\n\treturn strings.HasPrefix(name, Prefix)\n}", "func (*InstSExt) isInst() {}", "func seen(p *profile.Profile, fname string) bool {\n\tlocIDs := map[*profile.Location]bool{}\n\tfor _, loc := range p.Location {\n\t\tfor _, l := range loc.Line {\n\t\t\tif strings.Contains(l.Function.Name, fname) {\n\t\t\t\tlocIDs[loc] = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t}\n\tfor _, sample := range p.Sample {\n\t\tfor _, loc := range sample.Location {\n\t\t\tif locIDs[loc] {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\treturn false\n}", "func HasLabel(obj metav1.Object, lab string) bool {\n\tlabels := obj.GetLabels()\n\tif labels == nil {\n\t\treturn false\n\t}\n\t_, ok := labels[lab]\n\treturn ok\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *ResourceProperties) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func TestIsValidObjectName(t *testing.T) {\n\ttestCases := []struct {\n\t\tobjectName string\n\t\tshouldPass bool\n\t}{\n\t\t// cases which should pass the test.\n\t\t// passing in valid object name.\n\t\t{\"object\", true},\n\t\t{\"The Shining Script <v1>.pdf\", true},\n\t\t{\"Cost Benefit Analysis (2009-2010).pptx\", true},\n\t\t{\"117Gn8rfHL2ACARPAhaFd0AGzic9pUbIA/5OCn5A\", true},\n\t\t{\"SHØRT\", true},\n\t\t{\"There are far too many object names, and far too few bucket names!\", true},\n\t\t// cases for which test should fail.\n\t\t// passing invalid object names.\n\t\t{\"\", false},\n\t\t{string([]byte{0xff, 0xfe, 0xfd}), false},\n\t}\n\n\tfor i, testCase := range testCases {\n\t\tisValidObjectName := IsValidObjectName(testCase.objectName)\n\t\tif testCase.shouldPass && !isValidObjectName {\n\t\t\tt.Errorf(\"Test case %d: Expected \\\"%s\\\" to be a valid object name\", i+1, testCase.objectName)\n\t\t}\n\t\tif !testCase.shouldPass && isValidObjectName {\n\t\t\tt.Errorf(\"Test case %d: Expected object name \\\"%s\\\" to be invalid\", i+1, testCase.objectName)\n\t\t}\n\t}\n}", "func (t *Link) IsNameLangString(index int) (ok bool) {\n\treturn t.name[index].langString != nil\n\n}", "func (p *PropertyGenerator) hasMemberName(i int) string {\n\tif len(p.Kinds) == 1 && p.Kinds[0].Nilable {\n\t\tpanic(\"PropertyGenerator.hasMemberName called for nilable single value\")\n\t}\n\treturn fmt.Sprintf(\"has%sMember\", p.Kinds[i].Name.CamelName)\n}", "func (checker *CheckerType) Name() string {\n return \"Checker\"\n}", "func (jl *JMXCheckLoader) Name() string {\n\treturn \"jmx\"\n}", "func (s Sampling) Sampler() trace.Sampler {\n\tif s == Disabled {\n\t\treturn trace.NeverSample()\n\t}\n\treturn trace.ProbabilitySampler(float64(s))\n}", "func (self *Graphics) Name() string{\n return self.Object.Get(\"name\").String()\n}", "func (me TisoLanguageCodes) IsSk() bool { return me.String() == \"SK\" }", "func (CheckHandler) Name() string {\n\treturn NameCheck\n}", "func (m *ToolMutation) ToolName() (r string, exists bool) {\n\tv := m._Tool_Name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func isNamedParam(str string) bool {\n\treturn namedParamRegx.MatchString(str)\n}", "func (o *BaseItem) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isNamedType(t types.Type, path, name string) bool {\n\tn, ok := t.(*types.Named)\n\tif !ok {\n\t\treturn false\n\t}\n\tobj := n.Obj()\n\treturn obj.Name() == name && obj.Pkg() != nil && obj.Pkg().Path() == path\n}", "func (o *SdwanRouterNode) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (r *rateSampler) Sample(spn ddtrace.Span) bool {\n\tif r.rate == 1 {\n\t\t// fast path\n\t\treturn true\n\t}\n\ts, ok := spn.(*span)\n\tif !ok {\n\t\treturn false\n\t}\n\tr.RLock()\n\tdefer r.RUnlock()\n\treturn sampledByRate(s.TraceID, r.rate)\n}", "func (p ByName) Name() string { return p.name }", "func (o *SyntheticsBrowserTest) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (Functions) NameOf(obj interface{}) string {\n\treturn nameOf(obj)\n}", "func (o *Ga4ghTumourboard) HasTypeOfSampleAnalyzed() bool {\n\tif o != nil && o.TypeOfSampleAnalyzed != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *GstObj) SetName(name string) bool {\n\ts := C.CString(name)\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_object_set_name(o.g(), (*C.gchar)(s)) != 0\n}", "func (*SimpleMetric) IsMetric() {}", "func (o *IamServiceProviderAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *OnpremUpgradePhase) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isBasicResource(name v1.ResourceName) bool {\n\tswitch name {\n\tcase v1.ResourceCPU, v1.ResourceMemory, v1.ResourcePods:\n\t\treturn true\n\tdefault:\n\t\treturn false\n\t}\n}", "func (o *WorkflowServiceItemActionInstance) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (g Gen) Sample() (interface{}, bool) {\n\treturn g(DefaultGenParameters()).Retrieve()\n}", "func (o *CreateTemplateRequestEntity) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *ShowSystem) HasName() bool {\n\tif o != nil && !IsNil(o.Name) {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (_f8 *FakeInterfacer) NamedInterfaceCalledWith(a interface{}) (found bool) {\n\tfor _, call := range _f8.NamedInterfaceCalls {\n\t\tif reflect.DeepEqual(call.Parameters.A, a) {\n\t\t\tfound = true\n\t\t\tbreak\n\t\t}\n\t}\n\n\treturn\n}", "func (self *TileSprite) Name() string{\n return self.Object.Get(\"name\").String()\n}", "func (m *ResourceMutation) Name() (r string, exists bool) {\n\tv := m.name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}" ]
[ "0.6225702", "0.6128229", "0.5949357", "0.52864945", "0.5223594", "0.5162394", "0.5154328", "0.5135758", "0.5113274", "0.508851", "0.5068044", "0.5050293", "0.5030305", "0.5021834", "0.49990904", "0.49654078", "0.4927609", "0.49073908", "0.49024493", "0.48917592", "0.48848966", "0.48841897", "0.4870917", "0.48617437", "0.48582593", "0.48543864", "0.48536912", "0.48525852", "0.48446277", "0.4836844", "0.48361766", "0.48342752", "0.48247343", "0.48107043", "0.48066574", "0.4805438", "0.48015144", "0.47996306", "0.4793342", "0.47931713", "0.47893146", "0.4789056", "0.47876233", "0.47863775", "0.47757664", "0.47750813", "0.4772598", "0.47571775", "0.4751003", "0.47436133", "0.4736645", "0.47337353", "0.47325692", "0.47297433", "0.47269744", "0.47245285", "0.4724516", "0.4722041", "0.47216836", "0.47202536", "0.47181216", "0.469394", "0.46883002", "0.46784025", "0.46732217", "0.4673183", "0.4668544", "0.46677962", "0.46661603", "0.4665416", "0.466424", "0.4661692", "0.46598312", "0.46585998", "0.46585235", "0.46573672", "0.46567163", "0.46554935", "0.46549654", "0.46489045", "0.46457115", "0.4645612", "0.4645345", "0.464038", "0.46247217", "0.46226266", "0.46191314", "0.46185207", "0.46183452", "0.4611378", "0.460774", "0.46072403", "0.46070364", "0.46045208", "0.46041802", "0.46026653", "0.4594418", "0.4592335", "0.45921776" ]
0.57800925
4
Determines if a name corresponds to a shader object
func IsShader(shader uint32) bool { ret := C.glowIsShader(gpIsShader, (C.GLuint)(shader)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func IsShader(shader uint32) bool {\n ret := C.glowIsShader(gpIsShader, (C.GLuint)(shader))\n return ret == TRUE\n}", "func (sh *ShaderStd) Name() string { return sh.MtlName }", "func (shader Shader) IsShader() bool {\n\treturn gl.IsShader(uint32(shader))\n}", "func IsShader(shader uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsShader, 1, uintptr(shader), 0, 0)\n\treturn ret != 0\n}", "func IsShader(s Shader) bool {\n\treturn gl.IsShader(s.Value)\n}", "func IsShader(shader Uint) Boolean {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\t__ret := C.glIsShader(cshader)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func (am *Manager) GetShader(name string) (uint32, bool) {\n\tif shader, ok := am.Shaders[name]; ok {\n\t\treturn shader, true\n\t}\n\n\tif am.Parent != nil {\n\t\treturn am.Parent.GetShader(name)\n\t}\n\n\treturn 0, false\n}", "func (self *TileSprite) Shader() *AbstractFilter{\n return &AbstractFilter{self.Object.Get(\"shader\")}\n}", "func LoadName(name uint32) {\n C.glowLoadName(gpLoadName, (C.GLuint)(name))\n}", "func (DrawTexture) IsDrawAction() {}", "func (sm *shaderManager) GetShaderProgram(id uint32) (Shader, bool) {\n\tsm.programLock.RLock()\n\tdefer sm.programLock.RUnlock()\n\tfor _, shader := range sm.shaders {\n\t\tif shader.ProgramID() == id {\n\t\t\treturn shader, true\n\t\t}\n\t}\n\n\treturn nil, false\n}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func IsSampler(sampler uint32) bool {\n ret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n return ret == TRUE\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func (gl *WebGL) ShaderSource(shader WebGLShader, source string) {\n\tgl.context.Call(\"shaderSource\", shader, source)\n}", "func (s *Shader) ID() uint32 {\n\treturn s.program.obj\n}", "func LoadName(name uint32) {\n\tC.glowLoadName(gpLoadName, (C.GLuint)(name))\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\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 IsQuery(id uint32) bool {\n ret := C.glowIsQuery(gpIsQuery, (C.GLuint)(id))\n return ret == TRUE\n}", "func (me TshapeEnumType) IsSphere() bool { return me == \"sphere\" }", "func (*Object) Name() string { return \"object\" }", "func (sm *shaderManager) GetShader(key string) (Shader, bool) {\n\n\tsm.programLock.RLock()\n\tdefer sm.programLock.RUnlock()\n\tprogram, status := sm.shaders[key]\n\n\treturn program, status\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\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 (s *Shader) Use() {\n\tgl.UseProgram(s.programID)\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 (p *literalProcessor) name() string { return \"\" }", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func Trace(ray *Ray, samp *TraceSample) bool {\n\n\t// This is the only time that ShaderContext should be created manually, note we set task here.\n\tsg := &ShaderContext{\n\t\tRo: ray.P,\n\t\tRd: ray.D,\n\t\tX: ray.X,\n\t\tY: ray.Y,\n\t\tSx: ray.Sx,\n\t\tSy: ray.Sy,\n\t\tLevel: ray.Level,\n\t\tLambda: ray.Lambda,\n\t\tI: ray.I,\n\t\tTime: ray.Time,\n\t\ttask: ray.Task,\n\t\tImage: image,\n\t\tScramble: ray.Scramble,\n\t\tTransform: m.Matrix4Identity,\n\t\tInvTransform: m.Matrix4Identity,\n\t}\n\n\tif TraceProbe(ray, sg) {\n\n\t\tif sg.Shader == nil { // can't do much with no material\n\t\t\treturn false\n\t\t}\n\n\t\tray.DifferentialTransfer(sg)\n\n\t\tsg.ApplyTransform()\n\n\t\tsg.Shader.Eval(sg)\n\n\t\tif samp != nil {\n\t\t\tsamp.Colour = sg.OutRGB\n\t\t\tsamp.Point = sg.P\n\t\t\tsamp.ElemID = sg.ElemID\n\t\t\tsamp.Geom = sg.Geom\n\t\t}\n\n\t\treturn true\n\t}\n\treturn false\n}", "func (m *ToolMutation) ToolName() (r string, exists bool) {\n\tv := m._Tool_Name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func getAssetByName(assetName string){\n\n}", "func IsBuffer(buffer uint32) bool {\n ret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n return ret == TRUE\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 IsProgram(program uint32) bool {\n ret := C.glowIsProgram(gpIsProgram, (C.GLuint)(program))\n return ret == TRUE\n}", "func IsTexture(texture uint32) bool {\n ret := C.glowIsTexture(gpIsTexture, (C.GLuint)(texture))\n return ret == TRUE\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 ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func (self *Graphics) Name() string{\n return self.Object.Get(\"name\").String()\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 (shader Shader) Delete() {\n\tgl.DeleteShader(uint32(shader))\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 iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func (g *Game) nameOf(x, y int) string {\n\treturn fmt.Sprintf(\"%s%d\", string('a'+x), y+1)\n}", "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func (g *grpc) objectNamed(name string) generator.Object {\n\tg.gen.RecordTypeUse(name)\n\treturn g.gen.ObjectNamed(name)\n}", "func (m *ResourceMutation) Name() (r string, exists bool) {\n\tv := m.name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func (g grass) Name() string {\n\tswitch g {\n\tcase 0:\n\t\treturn \"Grass\"\n\tcase 1:\n\t\treturn \"Fern\"\n\t}\n\tpanic(\"unknown grass type\")\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 (o *GstObj) SetName(name string) bool {\n\ts := C.CString(name)\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_object_set_name(o.g(), (*C.gchar)(s)) != 0\n}", "func (w *Wish) HasShade(s string) bool {\n\treturn w.Shades.Index(s) > -1\n}", "func (m *StreetMutation) Name() (r string, exists bool) {\n\tv := m.name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func IsVertexArray(array uint32) bool {\n ret := C.glowIsVertexArray(gpIsVertexArray, (C.GLuint)(array))\n return ret == TRUE\n}", "func (m *StatisticMutation) StatisticName() (r string, exists bool) {\n\tv := m._StatisticName\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\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 DeleteShader(shader uint32) {\n C.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func (me TxsdFeBlendTypeMode) IsLighten() bool { return me.String() == \"lighten\" }", "func (s SourceFilesystems) IsAsset(filename string) bool {\n\treturn s.Assets.Contains(filename)\n}", "func IsQuery(id uint32) bool {\n\tret := C.glowIsQuery(gpIsQuery, (C.GLuint)(id))\n\treturn ret == TRUE\n}", "func IsQuery(id uint32) bool {\n\tret := C.glowIsQuery(gpIsQuery, (C.GLuint)(id))\n\treturn ret == TRUE\n}", "func (self *Graphics) InWorld() bool{\n return self.Object.Get(\"inWorld\").Bool()\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 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 ShaderSource(s Shader, src string) {\n\tglsource, free := gl.Strs(src + \"\\x00\")\n\tgl.ShaderSource(s.Value, 1, glsource, nil)\n\tfree()\n}", "func IsSampler(sampler uint32) bool {\n\tret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n\treturn ret == TRUE\n}", "func IsSampler(sampler uint32) bool {\n\tret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n\treturn ret == TRUE\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 isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func (self *Graphics) Exists() bool{\n return self.Object.Get(\"exists\").Bool()\n}", "func IsTransformFeedback(id uint32) bool {\n ret := C.glowIsTransformFeedback(gpIsTransformFeedback, (C.GLuint)(id))\n return ret == TRUE\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 (native *OpenGL) IsQuery(id uint32) bool {\n\treturn gl.IsQuery(id)\n}", "func IsTexture(t Texture) bool {\n\treturn gl.IsTexture(t.Value)\n}", "func (g *Graph) NodeByName(name string, index int) (node Node, found bool) {\n\tfor _, op := range g.Operations {\n\t\tif op.Spec.Name == name {\n\t\t\tn := op.Output(index)\n\t\t\treturn n, true\n\t\t}\n\t}\n\n\treturn\n}", "func IsIdentifier(name string) bool {\n\treturn token.IsIdentifier(name)\n}", "func IsCompressedWriteResourceName(name string) bool {\n\treturn strings.Contains(name, \"compressed-blobs/zstd\")\n}", "func (Functions) NameOf(obj interface{}) string {\n\treturn nameOf(obj)\n}", "func IsValidObjectName(object string) bool {\n\tif strings.TrimSpace(object) == \"\" {\n\t\treturn false\n\t}\n\tif len(object) > 1024 || len(object) == 0 {\n\t\treturn false\n\t}\n\tif !utf8.ValidString(object) {\n\t\treturn false\n\t}\n\treturn true\n}", "func ObjectLabel(identifier uint32, name uint32, length int32, label *int8) {\n C.glowObjectLabel(gpObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetShaderi(s Shader, pname Enum) int {\n\tvar result int32\n\tgl.GetShaderiv(s.Value, uint32(pname), &result)\n\treturn int(result)\n}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\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 (_ EntityHeadLook) Name() string { return \"*EntityHeadLook\" }", "func (m *SeriesMutation) Name() (r string, exists bool) {\n\tv := m.name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func GetActiveSubroutineUniformName(program uint32, shadertype uint32, index uint32, bufsize int32, length *int32, name *int8) {\n C.glowGetActiveSubroutineUniformName(gpGetActiveSubroutineUniformName, (C.GLuint)(program), (C.GLenum)(shadertype), (C.GLuint)(index), (C.GLsizei)(bufsize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (me TxsdFeBlendTypeMode) IsNormal() bool { return me.String() == \"normal\" }", "func ShadeModel(mode uint32) {\n C.glowShadeModel(gpShadeModel, (C.GLenum)(mode))\n}", "func (ids WorkloadEndpointIdentifiers) NameMatches(name string) (bool, error) {\n\t// Extract the required segments for this orchestrator type.\n\treq, err := ids.getSegments()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\t// Extract the parameters from the name.\n\tparts := ExtractDashSeparatedParms(name, len(req))\n\tif len(parts) == 0 {\n\t\treturn false, nil\n\t}\n\n\t// Check each name segment for a non-match.\n\tfor i, r := range req {\n\t\tif r.value != \"\" && r.value != parts[i] {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func testVertex(name string, interested_item string) bool {\n\t// fmt.Println(\"name:\", name, \"interested_item\", interested_item)\n\n\tif name == interested_item {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (*NamedType) isType() {}", "func ValidObjectType(t string) bool {\n\n\tvar m = map[string]int{\n\t\t\"attack-pattern\": 1,\n\t\t\"campaign\": 1,\n\t\t\"course-of-action\": 1,\n\t\t\"grouping\": 1,\n\t\t\"identity\": 1,\n\t\t\"indicator\": 1,\n\t\t\"infrastructure\": 1,\n\t\t\"intrusion-set\": 1,\n\t\t\"language-content\": 1,\n\t\t\"location\": 1,\n\t\t\"malware\": 1,\n\t\t\"malware-analysis\": 1,\n\t\t\"marking-definition\": 1,\n\t\t\"note\": 1,\n\t\t\"observed-data\": 1,\n\t\t\"opinion\": 1,\n\t\t\"relationship\": 1,\n\t\t\"report\": 1,\n\t\t\"sighting\": 1,\n\t\t\"threat-actor\": 1,\n\t\t\"tool\": 1,\n\t\t\"vulnerability\": 1,\n\t}\n\n\tif _, ok := m[t]; ok {\n\t\treturn true\n\t}\n\treturn false\n}", "func IsProgramPipeline(pipeline uint32) bool {\n ret := C.glowIsProgramPipeline(gpIsProgramPipeline, (C.GLuint)(pipeline))\n return ret == TRUE\n}", "func (self *Graphics) DestroyPhase() bool{\n return self.Object.Get(\"destroyPhase\").Bool()\n}", "func (self *Graphics) AutoCull() bool{\n return self.Object.Get(\"autoCull\").Bool()\n}" ]
[ "0.61987984", "0.60917497", "0.5879628", "0.58257455", "0.5635945", "0.551476", "0.5453865", "0.53777456", "0.5326302", "0.5275029", "0.5170252", "0.50690496", "0.50681496", "0.49970964", "0.49844897", "0.49804762", "0.49802765", "0.49486783", "0.494003", "0.49345624", "0.4916431", "0.48912716", "0.48771578", "0.4868621", "0.48657534", "0.4864518", "0.4854254", "0.48521733", "0.48337147", "0.4821807", "0.48096287", "0.4779754", "0.47686344", "0.4765623", "0.4749528", "0.4745804", "0.47368804", "0.4711382", "0.4707941", "0.46778482", "0.46778482", "0.46776423", "0.46717638", "0.46611556", "0.466081", "0.46586892", "0.46565956", "0.46539602", "0.46387887", "0.463706", "0.4632869", "0.463078", "0.46245748", "0.46067658", "0.4602704", "0.45922145", "0.45919234", "0.4586754", "0.45811924", "0.45784354", "0.45784354", "0.45765355", "0.45760182", "0.45722494", "0.45679858", "0.45672068", "0.45672068", "0.45586154", "0.45365813", "0.453222", "0.45247087", "0.4522135", "0.45190644", "0.45176634", "0.45029527", "0.44934434", "0.4492898", "0.44784436", "0.44762793", "0.4475708", "0.44736016", "0.44705528", "0.44597337", "0.44455394", "0.44455394", "0.44448203", "0.44429132", "0.4440016", "0.44389242", "0.44383648", "0.4436449", "0.44348323", "0.4433088", "0.44298804", "0.44290113", "0.4428091", "0.442563", "0.44256216", "0.44227692" ]
0.5678232
5
determine if a name corresponds to a sync object
func IsSync(sync uintptr) bool { ret := C.glowIsSync(gpIsSync, (C.GLsync)(sync)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func isSyncResource(obj client.Object) bool {\n\tif v, ok := obj.GetAnnotations()[syncAnnotation]; ok {\n\t\tb, err := strconv.ParseBool(v)\n\t\tif b && err == nil {\n\t\t\treturn true\n\t\t}\n\t\tif err != nil {\n\t\t\tlog.Error(\"value format of annotation %v failed: %v, got value: %v%\", syncAnnotation, err, v)\n\t\t}\n\t}\n\n\treturn false\n}", "func (se *SubscriptionExtension) IsObjectOwnedBySynchronizer(obj metav1.Object, syncid *types.NamespacedName) bool {\n\tif obj == nil {\n\t\t// return false to let caller skip\n\t\treturn false\n\t}\n\n\tobjanno := obj.GetAnnotations()\n\tif objanno != nil {\n\t\t_, ok := objanno[dplv1.AnnotationManagedCluster]\n\t\treturn !ok\n\t}\n\n\t// nil annotation owned by sub sync, though not by any sub\n\treturn true\n}", "func (msg *Message) IsSync() bool {\n\treturn msg.Header.Sync\n}", "func IsSync(sync uintptr) bool {\n\tret, _, _ := syscall.Syscall(gpIsSync, 1, uintptr(sync), 0, 0)\n\treturn ret != 0\n}", "func isOwner(owner *unstructured.Unstructured, obj interface{}) bool {\n\tif obj == nil {\n\t\treturn false\n\t}\n\tvar owners []metav1.OwnerReference\n\tobjMeta, ok := obj.(*metav1.ObjectMeta)\n\tif ok {\n\t\towners = objMeta.GetOwnerReferences()\n\t} else {\n\t\tif objUnstructured, ok := obj.(*unstructured.Unstructured); ok {\n\t\t\towners = objUnstructured.GetOwnerReferences()\n\t\t} else {\n\t\t\tklog.Error(\"Failed to get owners\")\n\t\t\treturn false\n\t\t}\n\t}\n\n\tfor _, ownerRef := range owners {\n\t\tif _, ok := owner.Object[\"metadata\"]; !ok {\n\t\t\tklog.Error(\"no meta\")\n\t\t\tcontinue\n\t\t}\n\t\tmeta, ok := owner.Object[\"metadata\"].(map[string]interface{})\n\t\tif !ok || meta == nil {\n\t\t\tklog.Error(\"no meta map\")\n\t\t\tcontinue\n\t\t}\n\t\tname, ok := meta[\"name\"].(string)\n\t\tif !ok || name == \"\" {\n\t\t\tklog.Error(\"failed to get name\")\n\t\t\tcontinue\n\t\t}\n\t\tif ownerRef.Kind == owner.Object[\"kind\"] && ownerRef.Name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsBranchInSync(branchName string) bool {\n\tif HasTrackingBranch(branchName) {\n\t\tlocalSha := GetBranchSha(branchName)\n\t\tremoteSha := GetBranchSha(GetTrackingBranchName(branchName))\n\t\treturn localSha == remoteSha\n\t}\n\treturn true\n}", "func IsSync(sync unsafe.Pointer) bool {\n ret := C.glowIsSync(gpIsSync, (C.GLsync)(sync))\n return ret == TRUE\n}", "func (cc *CloneCommand) NameIsID() bool {\n\treturn cc.RepositoryName == \"\"\n}", "func IsRecordSync(mode string) bool {\n\treturn mode == RecordAtProxySync || mode == RecordAtNodeSync\n}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func needSync(pvc *corev1.PersistentVolumeClaim) bool {\n\twithNFS, withNFSProvisioner := false, false\n\tif value, ok := pvc.Annotations[api.StorageClassTypeAnnotation]; ok {\n\t\twithNFS = strings.Contains(value, \"nfs\")\n\t}\n\tif value, ok := pvc.Annotations[api.StorageProvisionerAnnotation]; ok {\n\t\twithNFSProvisioner = strings.Contains(value, \"nfs\")\n\t}\n\treturn withNFS && withNFSProvisioner\n}", "func (s *Synchronizer) IsManaged(object meta.Object) bool {\n\towner := meta.GetControllerOf(object)\n\tif owner == nil {\n\t\t// Ignore unmanaged service catalog resources\n\t\treturn false\n\t}\n\n\t// Try to retrieve the resource that is shadowing the service catalog resource\n\tswitch owner.Kind {\n\tcase templates.BindingKind:\n\t\t_, err := s.templateSDK.GetBindingFromCache(object.GetNamespace(), owner.Name)\n\t\tif err != nil {\n\t\t\tglog.V(4).Infof(\"ignoring orphaned object '%s' of %s '%s'\", object.GetSelfLink(), owner.Kind, owner.Name)\n\t\t\treturn false\n\t\t}\n\t\treturn true\n\tcase templates.InstanceKind:\n\t\t_, err := s.templateSDK.GetInstanceFromCache(object.GetNamespace(), owner.Name)\n\t\tif err != nil {\n\t\t\tglog.V(4).Infof(\"ignoring orphaned object '%s' of %s '%s'\", object.GetSelfLink(), owner.Kind, owner.Name)\n\t\t\treturn false\n\t\t}\n\t\treturn true\n\tcase \"ServiceBinding\":\n\t\t// Lookup the binding that owns the resource\n\t\tsvcBnd, err := s.svcatSDK.GetBindingFromCache(object.GetNamespace(), owner.Name)\n\t\tif err != nil {\n\t\t\tglog.V(4).Infof(\"ignoring orphaned object '%s' of %s '%s'\", object.GetSelfLink(), owner.Kind, owner.Name)\n\t\t\treturn false\n\t\t}\n\n\t\t// The binding must be owned by the templates controller\n\t\treturn s.IsManaged(svcBnd)\n\t}\n\n\treturn false\n}", "func (o *objectSet) nameEquals(name string) *object.K8sObject {\n\tfor k, v := range o.objMap {\n\t\t_, _, objName := object.FromHash(k)\n\t\tif objName == name {\n\t\t\treturn v\n\t\t}\n\t}\n\treturn nil\n}", "func (j Job) IsSyncMode() bool {\n\treturn !j.Process.Async\n}", "func isComponentStatusSynced(componentStatus string) bool {\n\treturn componentStatus == \"Synced\"\n}", "func syncOnlyChangedObjects(option controllerContextType) bool {\n\tskipUpdate := os.Getenv(\"CATTLE_SYNC_ONLY_CHANGED_OBJECTS\")\n\tif skipUpdate == \"\" {\n\t\treturn false\n\t}\n\tparts := strings.Split(skipUpdate, \",\")\n\n\tfor _, part := range parts {\n\t\tif controllerContextType(part) == option {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsMock(name string) bool {\n\treturn name == Mock\n}", "func (c KubernetesDefaultRouter) isOwnedByCanary(obj interface{}, name string) (bool, bool) {\n\tobject, ok := obj.(metav1.Object)\n\tif !ok {\n\t\treturn false, false\n\t}\n\n\townerRef := metav1.GetControllerOf(object)\n\tif ownerRef == nil {\n\t\treturn false, false\n\t}\n\n\tif ownerRef.Kind != flaggerv1.CanaryKind {\n\t\treturn false, false\n\t}\n\n\treturn true, ownerRef.Name == name\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsResync(ctx context.Context) (resyncType ResyncType, verboseSBRefresh bool) {\n\tresyncArgs, isResync := ctx.Value(resyncCtxKey).(*resyncOpt)\n\tif !isResync {\n\t\treturn NotResync, false\n\t}\n\treturn resyncArgs.resyncType, resyncArgs.verboseSBRefresh\n}", "func isCurUserObject(objectType string, curUser string, object string) bool {\n\tif objectType != commonpb.ObjectType_User.String() {\n\t\treturn false\n\t}\n\treturn curUser == object\n}", "func TestImplementationsExistForSync(srcPrefix, dstPrefix string) error {\n\t//For now sync is allowed only from S3 to K8s\n\tswitch srcPrefix {\n\tcase K8S:\n\t\tif dstPrefix != S3 {\n\t\t\treturn fmt.Errorf(srcPrefix + \"-->\" + dstPrefix + \" not implemented\")\n\t\t}\n\tcase S3:\n\t\tif dstPrefix != K8S {\n\t\t\treturn fmt.Errorf(srcPrefix + \"-->\" + dstPrefix + \" not implemented\")\n\t\t}\n\t//case \"abs\":\n\t//case \"gcs\":\n\tdefault:\n\t\treturn fmt.Errorf(srcPrefix + \"-->\" + dstPrefix + \" not implemented\")\n\t}\n\n\treturn nil\n}", "func (g ServerGroup) IsArangosync() bool {\n\tswitch g {\n\tcase ServerGroupSyncMasters, ServerGroupSyncWorkers:\n\t\treturn true\n\tdefault:\n\t\treturn false\n\t}\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func sameObj(x, y types.Object) bool {\n\tif x == y {\n\t\treturn true\n\t}\n\tif _, ok := x.(*types.PkgName); ok {\n\t\tif _, ok := y.(*types.PkgName); ok {\n\t\t\treturn x.Pkg() == y.Pkg()\n\t\t}\n\t}\n\treturn false\n}", "func IsSyncCmd() *cobra.Command {\n\tcmd := &cobra.Command{\n\t\tUse: \"is_sync\",\n\t\tShort: \"Get blockchain synchronization status\",\n\t\tRun: isSync,\n\t}\n\treturn cmd\n}", "func IsSyncCmd() *cobra.Command {\n\tcmd := &cobra.Command{\n\t\tUse: \"is_sync\",\n\t\tShort: \"Get blockchain synchronization status\",\n\t\tRun: isSync,\n\t}\n\treturn cmd\n}", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func IsHelmRequestSynced(hr *appv1.HelmRequest) bool {\n\tcurrent := GenUniqueHash(hr)\n\tif current == hr.Status.LastSpecHash {\n\t\treturn true\n\t}\n\n\t// This is for old and exist HelmRequest, they are already synced.\n\t// we don't want the algorithm change to cause them to be upgrade again\n\tonlySpec := GenHashStr(hr.Spec)\n\tif onlySpec == hr.Status.LastSpecHash {\n\t\tif hr.Annotations == nil || hr.Annotations[util.KubectlCaptainSync] == \"\" {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (l *loadBalancer) inSync() bool {\n\treturn reflect.DeepEqual(l.CertificateARNs(), l.stack.CertificateARNs) &&\n\t\tl.stack.CWAlarmConfigHash == l.cwAlarms.Hash() &&\n\t\tl.wafWebACLID == l.stack.WAFWebACLID\n}", "func (sm *SyncManager) isSyncCandidate(peer *peer.Peer) bool {\n\t// The peer is not a candidate for sync if it's not a full node.\n\tif peer.Services()&pact.SFNodeNetwork != pact.SFNodeNetwork {\n\t\treturn false\n\t}\n\n\t// Candidate if all checks passed.\n\treturn true\n}", "func (se *SubscriptionExtension) IsObjectOwnedByHost(obj metav1.Object, host types.NamespacedName, syncid *types.NamespacedName) bool {\n\towned := se.IsObjectOwnedBySynchronizer(obj, syncid)\n\n\tif !owned {\n\t\tklog.V(5).Info(\"Resource\", obj, \" is not owned by \", syncid)\n\t\treturn owned\n\t}\n\n\tobjhost := utils.GetHostSubscriptionFromObject(obj)\n\tif objhost == nil {\n\t\treturn false\n\t}\n\n\treturn objhost.Namespace == host.Namespace && objhost.Name == host.Name\n}", "func (o *GstObj) SetName(name string) bool {\n\ts := C.CString(name)\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_object_set_name(o.g(), (*C.gchar)(s)) != 0\n}", "func (f *Folders) IsFolderInSync(id string) (bool, error) {\n\tfc := f.Get(id)\n\tif fc == nil {\n\t\treturn false, fmt.Errorf(\"Unknown id\")\n\t}\n\treturn (*fc).IsInSync()\n}", "func (s *FederationSyncController) isSynced() bool {\n\tif !s.informer.ClustersSynced() {\n\t\tglog.V(2).Infof(\"Cluster list not synced\")\n\t\treturn false\n\t}\n\tif !s.placementPlugin.HasSynced() {\n\t\tglog.V(2).Infof(\"Placement not synced\")\n\t\treturn false\n\t}\n\tif !s.versionManager.HasSynced() {\n\t\tglog.V(2).Infof(\"Version manager not synced\")\n\t\treturn false\n\t}\n\n\t// TODO(marun) set clusters as ready in the test fixture?\n\tclusters, err := s.informer.GetReadyClusters()\n\tif err != nil {\n\t\truntime.HandleError(fmt.Errorf(\"Failed to get ready clusters: %v\", err))\n\t\treturn false\n\t}\n\tif !s.informer.GetTargetStore().ClustersSynced(clusters) {\n\t\treturn false\n\t}\n\treturn true\n}", "func (o *ConnectorTypeAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *ConnectorTypeAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *VersionedConnection) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *Object) IsSameAs(a interface{}) bool {\n\tsame := false\n\te := a.(*Object)\n\tif e.Bucket.Name == o.Bucket.Name {\n\t\tsame = true\n\t}\n\treturn same\n}", "func (o *CloudInstanceTypeAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o SyncCallbackOption) IsOption() {}", "func Is(name string) bool {\n\treturn strings.HasPrefix(name, Prefix)\n}", "func (e DirectoryEntry) IsString() bool { return ((e.Name & 0x80000000) >> 31) > 0 }", "func isMultipartObject(storage StorageAPI, bucket, object string) bool {\n\t_, err := storage.StatFile(bucket, pathJoin(object, multipartMetaFile))\n\tif err != nil {\n\t\tif err == errFileNotFound {\n\t\t\treturn false\n\t\t}\n\t\terrorIf(err, \"Failed to stat file \"+bucket+pathJoin(object, multipartMetaFile))\n\t\treturn false\n\t}\n\treturn true\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func (h *Helper) HasConflictingTypeName(typeName string) bool {\n\t// First grab the set of CRD struct names and the names of their Spec and\n\t// Status structs\n\tcleanTypeName := names.New(typeName).Camel\n\tcrdNames := h.GetCRDNames()\n\tcrdResourceNames := []string{}\n\tcrdSpecNames := []string{}\n\tcrdStatusNames := []string{}\n\n\tfor _, crdName := range crdNames {\n\t\tif h.IsIgnoredResource(crdName.Original) {\n\t\t\tcontinue\n\t\t}\n\t\tcleanResourceName := crdName.Camel\n\t\tcrdResourceNames = append(crdResourceNames, cleanResourceName)\n\t\tcrdSpecNames = append(crdSpecNames, cleanResourceName+\"Spec\")\n\t\tcrdStatusNames = append(crdStatusNames, cleanResourceName+\"Status\")\n\t}\n\treturn (inStrings(cleanTypeName, crdResourceNames) ||\n\t\tinStrings(cleanTypeName, crdSpecNames) ||\n\t\tinStrings(cleanTypeName, crdStatusNames))\n}", "func (s *FederationSyncController) isSynced() bool {\n\tif !s.informer.ClustersSynced() {\n\t\tglog.V(2).Infof(\"Cluster list not synced\")\n\t\treturn false\n\t}\n\tclusters, err := s.informer.GetReadyClusters()\n\tif err != nil {\n\t\truntime.HandleError(fmt.Errorf(\"Failed to get ready clusters: %v\", err))\n\t\treturn false\n\t}\n\tif !s.informer.GetTargetStore().ClustersSynced(clusters) {\n\t\treturn false\n\t}\n\treturn true\n}", "func (c *Controller) isTrackedObject(objectMeta *metaV1.ObjectMeta) bool {\n\treturn chop.Config().IsWatchedNamespace(objectMeta.Namespace) && chopModels.IsCHOPGeneratedObject(objectMeta)\n}", "func (*Object) Name() string { return \"object\" }", "func shouldSyncTask(syncVariantsTasks []patch.VariantTasks, bv, task string) bool {\n\tfor _, vt := range syncVariantsTasks {\n\t\tif vt.Variant != bv {\n\t\t\tcontinue\n\t\t}\n\t\tif utility.StringSliceContains(vt.Tasks, task) {\n\t\t\treturn true\n\t\t}\n\t\tfor _, dt := range vt.DisplayTasks {\n\t\t\tif utility.StringSliceContains(dt.ExecTasks, task) {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\treturn false\n}", "func isValidSyncJSON(s string) error {\n\tvar js map[string]interface{}\n\tif json.Unmarshal([]byte(s), &js) == nil {\n\t\t//TODO check if data is valid sync data\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"Invalid JSON\")\n\t}\n}", "func (c SyncCommand) CommandName() string {\n\treturn \"etcd:sync\"\n}", "func (cmd *Command) HasName(name string) bool {\n\tfor _, n := range cmd.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (o *StorageNetAppCifsShareAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func IsSyncEvent(ocspi, ncspi *apis.CStorPoolInstance) bool {\n\treturn ncspi.ResourceVersion == ocspi.ResourceVersion\n}", "func (me TactionType) IsContactSender() bool { return me.String() == \"contact-sender\" }", "func isManagedResource(obj client.Object) bool {\n\tlabelValue := obj.GetLabels()[managedByOperatorLabel]\n\treturn labelValue == managedByOperatorLabelValue\n}", "func IsSynced(path string) bool {\n\tvar file File\n\terr := dbAccess.SelectOne(&file, \"select * from files where path = ?\", path)\n\tif err != nil {\n\t\treturn true\n\t}\n\treturn file.Synced\n\n}", "func (o *GstObj) SyncValues(t ClockTime) bool {\n\treturn C.gst_object_sync_values(o.g(), C.GstClockTime(t)) != 0\n}", "func isCommand(name string) bool {\n\tfor _, cmd := range []string{\"_hooks\", \"_forward\"} {\n\t\tif strings.Compare(name, cmd) == 0 {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (s *Synchronizer) SynchronizeInstance(key string) (bool, runtime.Object, error) {\n\t//\n\t// Get shadow instance\n\t//\n\n\t// Convert the namespace/name string into a distinct namespace and name\n\tnamespace, name, err := cache.SplitMetaNamespaceKey(key)\n\tif err != nil {\n\t\tutil.HandleError(fmt.Errorf(\"invalid resource key: %s\", key))\n\t\treturn false, nil, nil\n\t}\n\n\ttinst, err := s.templateSDK.GetInstanceFromCache(namespace, name)\n\tif err != nil {\n\t\tif apierrors.IsNotFound(err) {\n\t\t\tutil.HandleError(fmt.Errorf(\"instance '%s' in work queue no longer exists\", key))\n\t\t\treturn false, nil, nil\n\t\t}\n\n\t\treturn false, nil, err\n\t}\n\n\tif tinst.Name == \"\" {\n\t\t// We choose to absorb the error here as the worker would requeue the\n\t\t// resource otherwise. Instead, the next time the resource is updated\n\t\t// the resource will be queued again.\n\t\tutil.HandleError(fmt.Errorf(\"%s: instance name must be specified\", key))\n\t\treturn false, nil, nil\n\t}\n\n\t//\n\t// Sync shadow to service catalog instance\n\t//\n\n\t// Get the corresponding service instance from the service catalog\n\tinst, err := s.templateSDK.GetManagedServiceInstance(tinst)\n\tif sdkerrors.IsUnmanagedResource(err) {\n\t\tmsg := fmt.Sprintf(MessageResourceExists, inst.Name)\n\t\treturn false, tinst, fmt.Errorf(msg)\n\t} else if apierrors.IsNotFound(err) {\n\t\ttemplate, err := s.resolver.ResolveInstanceTemplate(tinst)\n\t\tif err != nil {\n\t\t\t// TODO: Update status to unresolvable\n\t\t\treturn false, tinst, err\n\t\t}\n\n\t\t// Apply changes from the template to the instance\n\t\ttinst, err = builder.ApplyInstanceTemplate(tinst, template)\n\t\tif err != nil {\n\t\t\treturn false, tinst, err\n\t\t}\n\t\ttinst, err = s.templateSDK.Templates().TemplatedInstances(tinst.Namespace).Update(tinst)\n\t\tif err != nil {\n\t\t\treturn false, tinst, err\n\t\t}\n\n\t\t// Convert the templated resource into a service catalog resource\n\t\tinst, err = builder.BuildServiceInstance(tinst)\n\t\tif err != nil {\n\t\t\treturn false, tinst, err\n\t\t}\n\t\tinst, err = s.svcatSDK.ServiceCatalog().ServiceInstances(tinst.Namespace).Create(inst)\n\t}\n\n\t// If an error occurs during Get/Create, we'll requeue the item so we can\n\t// attempt processing again later. This could have been caused by a\n\t// temporary network failure, or any other transient reason.\n\tif err != nil {\n\t\treturn false, tinst, err\n\t}\n\n\t// TODO: Detect when the plan must be re-resolved\n\n\t// If this number of the replicas on the TemplatedInstance resource is specified, and the\n\t// number does not equal the current desired replicas on the Deployment, we\n\t// should update the Deployment resource.\n\tif tinst.Spec.Parameters != nil && (inst.Spec.Parameters == nil || string(tinst.Spec.Parameters.Raw) != string(inst.Spec.Parameters.Raw)) {\n\t\tglog.V(4).Infof(\"Syncing instance %s back to service instance %s\", tinst.SelfLink, inst.SelfLink)\n\t\tinst = builder.RefreshServiceInstance(tinst, inst)\n\t\tinst, err = s.svcatSDK.ServiceCatalog().ServiceInstances(inst.Namespace).Update(inst)\n\t}\n\n\t// If an error occurs during Update, we'll requeue the item so we can\n\t// attempt processing again later. This could have been caused by a\n\t// temporary network failure, or any other transient reason.\n\tif err != nil {\n\t\treturn false, tinst, err\n\t}\n\n\t//\n\t// Update shadow instance status with the service instance state\n\t//\n\t// Finally, we update the status block of the TemplatedInstance resource to reflect the\n\t// current state of the world\n\terr = s.updateInstanceStatus(tinst, inst)\n\tif err != nil {\n\t\treturn false, tinst, err\n\t}\n\n\treturn true, tinst, nil\n}", "func (o *ControllerServiceReferencingComponentDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (n ACName) Equals(o ACName) bool {\n\treturn strings.ToLower(string(n)) == strings.ToLower(string(o))\n}", "func (a *account) callNeedsToSync() bool {\n\ta.mu.Lock()\n\tdefer a.mu.Unlock()\n\treturn a.syncAt.Before(time.Now())\n}", "func (api *PublicHostManagerDebugAPI) Syncing() bool {\n\treturn api.shm.b.Syncing()\n}", "func (o *DnsZoneDataData) HasSmartParentName() bool {\n\tif o != nil && o.SmartParentName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (r *ReconcileGitTrack) ignoreObject(u *unstructured.Unstructured, owner farosv1alpha1.GitTrackInterface) (bool, string, error) {\n\tgvr, namespaced, err := utils.GetAPIResource(r.restMapper, u.GetObjectKind().GroupVersionKind())\n\tif err != nil {\n\t\treturn false, \"\", err\n\t}\n\n\t// Ignore namespaced objects not in the namespace managed by the controller\n\tif namespaced && r.namespace != \"\" && r.namespace != u.GetNamespace() {\n\t\tr.log.V(1).Info(\"Object not in namespace\", \"object namespace\", u.GetNamespace(), \"managed namespace\", r.namespace)\n\t\treturn true, fmt.Sprintf(\"namespace `%s` is not managed by this Faros\", u.GetNamespace()), nil\n\t}\n\t// Ignore GVKs in the ignoredGVKs set\n\tif _, ok := r.ignoredGVRs[gvr]; ok {\n\t\tr.log.V(1).Info(\"Object group version ignored globally\", \"group version resource\", gvr.String())\n\t\treturn true, fmt.Sprintf(\"resource `%s.%s/%s` ignored globally by flag\", gvr.Resource, gvr.Group, gvr.Version), nil\n\t}\n\n\townerNamespace := owner.GetNamespace()\n\t_, ownerIsGittrack := owner.(*farosv1alpha1.GitTrack)\n\t_, ownerIsClusterGittrack := owner.(*farosv1alpha1.ClusterGitTrack)\n\tif namespaced {\n\t\t// prevent a gittrack in a namespace from handling objects which are in a different namespace\n\t\tif ownerIsGittrack && ownerNamespace != u.GetNamespace() {\n\t\t\treturn true, fmt.Sprintf(\"namespace `%s` is not managed by this GitTrack\", u.GetNamespace()), nil\n\t\t} else if ownerIsClusterGittrack && r.clusterGitTrackMode == farosflags.CGTMExcludeNamespaced {\n\t\t\treturn true, \"namespaced resources cannot be managed by ClusterGitTrack\", nil\n\t\t}\n\t} else if ownerIsGittrack {\n\t\t// cluster scoped object managed from namespaced gittrack. Disallow\n\t\treturn true, \"a GitTrack cannot manage a cluster-scoped resource\", nil\n\t}\n\n\treturn false, \"\", nil\n}", "func isNamedType(t types.Type, path, name string) bool {\n\tn, ok := t.(*types.Named)\n\tif !ok {\n\t\treturn false\n\t}\n\tobj := n.Obj()\n\treturn obj.Name() == name && obj.Pkg() != nil && obj.Pkg().Path() == path\n}", "func (d *Data) SyncPending() bool {\n\tif manager == nil {\n\t\treturn false\n\t}\n\tr, err := manager.repoFromUUID(d.rootUUID)\n\tif err != nil {\n\t\treturn false\n\t}\n\t// Check if this data instance has any subscriptions and if so, are there messages in the channel.\n\tfor _, subs := range r.subs {\n\t\tfor _, sub := range subs {\n\t\t\tif sub.Notify == d.dataUUID && len(sub.Ch) > 0 {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\treturn false\n}", "func (os Outputs) Connected(name string) bool {\n\tfor _, o := range os {\n\t\tif !o.Connected {\n\t\t\tcontinue\n\t\t}\n\n\t\t// Check legacy name\n\t\tm, err := path.Match(name, o.Name)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\n\t\t// Check extended name\n\t\tm, err = path.Match(name, o.Name+\"-\"+o.MonitorID)\n\t\tif err != nil {\n\t\t\treturn false\n\t\t}\n\t\tif m {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (t *Link) IsNameString(index int) (ok bool) {\n\treturn t.name[index].stringName != nil\n\n}", "func (o *DhcpRangeDataData) HasSmartParentName() bool {\n\tif o != nil && o.SmartParentName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (r *gatewayReconciler) hasMatchingController(obj client.Object) bool {\n\tlog := r.log.WithFields(logrus.Fields{\n\t\t\"namespace\": obj.GetNamespace(),\n\t\t\"name\": obj.GetName(),\n\t})\n\n\tgw, ok := obj.(*gatewayapi_v1alpha1.Gateway)\n\tif !ok {\n\t\tlog.Info(\"invalid object, bypassing reconciliation.\")\n\t\treturn false\n\t}\n\n\tmatches, err := r.hasContourOwnedClass(gw)\n\tif err != nil {\n\t\tlog.Error(err)\n\t\treturn false\n\t}\n\tif matches {\n\t\tlog.Info(\"enqueueing gateway\")\n\t\treturn true\n\t}\n\n\tlog.Info(\"configured controllerName doesn't match an existing GatewayClass\")\n\treturn false\n}", "func (s *PublicHarmonyAPI) Syncing() (interface{}, error) {\n\t// TODO(ricl): port\n\treturn false, nil\n}", "func (n Name) Equal(other Name) bool {\n\treturn string(n) == string(other)\n}", "func (me TxsdContactType) IsPerson() bool { return me.String() == \"person\" }", "func (o *MonitorSearchResult) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *ComponentReferenceDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (r *gatewayReconciler) hasMatchingController(obj client.Object) bool {\n\tlog := r.log.WithFields(logrus.Fields{\n\t\t\"namespace\": obj.GetNamespace(),\n\t\t\"name\": obj.GetName(),\n\t})\n\n\tgw, ok := obj.(*gatewayapi_v1beta1.Gateway)\n\tif !ok {\n\t\tlog.Debugf(\"unexpected object type %T, bypassing reconciliation.\", obj)\n\t\treturn false\n\t}\n\n\tgc := &gatewayapi_v1beta1.GatewayClass{}\n\tif err := r.client.Get(context.Background(), types.NamespacedName{Name: string(gw.Spec.GatewayClassName)}, gc); err != nil {\n\t\tlog.WithError(err).Errorf(\"failed to get gatewayclass %s\", gw.Spec.GatewayClassName)\n\t\treturn false\n\t}\n\tif gc.Spec.ControllerName != r.gatewayClassControllerName {\n\t\tlog.Debugf(\"gateway's class controller is not %s; bypassing reconciliation\", r.gatewayClassControllerName)\n\t\treturn false\n\t}\n\n\treturn true\n}", "func (o *SyntheticMonitorUpdate) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (i *identifier) nameEquals(other *identifier) bool {\n\treturn i.name == other.name && i.parent == other.parent && i.pkg == other.pkg\n}", "func (o *EventsScalarQuery) HasName() bool {\n\treturn o != nil && o.Name != nil\n}", "func (r *restoreRunner) SameSpec(object runtime.Object) bool {\n\treturn false\n}", "func IsValidObjectName(object string) bool {\n\tif strings.TrimSpace(object) == \"\" {\n\t\treturn false\n\t}\n\tif len(object) > 1024 || len(object) == 0 {\n\t\treturn false\n\t}\n\tif !utf8.ValidString(object) {\n\t\treturn false\n\t}\n\treturn true\n}", "func (sm *SyncManager) isSyncCandidate(peer *peer.Peer) bool {\n\tservices := peer.Services()\n\tfor _, flag := range sm.cfg.CandidateFlags {\n\t\tif services&flag != flag {\n\t\t\treturn false\n\t\t}\n\t}\n\t// Candidate if all checks passed.\n\treturn true\n}", "func (Master) IsAnAPIObject() {}", "func (rp *ResourceProperty) IsSynced() (bool, error) {\n\treturn rp.PropertyIsSyncedFunc()\n}", "func (d *Data) SyncedNames() []dvid.InstanceName {\n\treturn d.syncNames\n}", "func (node *hostNode) Syncing() bool {\n\treturn node.syncProtocol.syncing()\n}", "func IsObjectInOtherNamespace(namespace string) (bool, error) {\n\twatchNamespace, err := k8sutil.GetWatchNamespace()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\tif namespace != watchNamespace {\n\t\treturn true, nil\n\t}\n\treturn false, nil\n}", "func TestSetterSync(t *testing.T) {\n\tvar n Setter = name.New(\"base\")\n\tif _, ok := n.(name.Setter); !ok {\n\t\tt.Fatalf(\"asyncpi/name.Setter and asyncpi/internal/name.Setter out of sync\")\n\t}\n}", "func (p PersistentVolumeClaim) NameMatches(def client.ResourceDefinition, name string) bool {\n\treturn def.PersistentVolumeClaim != nil && def.PersistentVolumeClaim.Name == name\n}", "func (o *WorkflowBuildTaskMeta) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func IsClockSyncCmd() *cobra.Command {\n\tcmd := &cobra.Command{\n\t\tUse: \"is_clock_sync\",\n\t\tShort: \"Get ntp clock synchronization status\",\n\t\tRun: isClockSync,\n\t}\n\treturn cmd\n}", "func IsClockSyncCmd() *cobra.Command {\n\tcmd := &cobra.Command{\n\t\tUse: \"is_clock_sync\",\n\t\tShort: \"Get ntp clock synchronization status\",\n\t\tRun: isClockSync,\n\t}\n\treturn cmd\n}", "func (syncStatus *clusterCacheSync) synced(clusterRetryTimeout time.Duration) bool {\n\tsyncTime := syncStatus.syncTime\n\n\tif syncTime == nil {\n\t\treturn false\n\t}\n\tif syncStatus.syncError != nil {\n\t\treturn time.Now().Before(syncTime.Add(clusterRetryTimeout))\n\t}\n\tif syncStatus.resyncTimeout == 0 {\n\t\t// cluster resync timeout has been disabled\n\t\treturn true\n\t}\n\treturn time.Now().Before(syncTime.Add(syncStatus.resyncTimeout))\n}", "func SyncIsAvailable() bool {\n\treturn bool(C.obx_has_feature(C.OBXFeature_Sync))\n}", "func (ids WorkloadEndpointIdentifiers) NameMatches(name string) (bool, error) {\n\t// Extract the required segments for this orchestrator type.\n\treq, err := ids.getSegments()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\t// Extract the parameters from the name.\n\tparts := ExtractDashSeparatedParms(name, len(req))\n\tif len(parts) == 0 {\n\t\treturn false, nil\n\t}\n\n\t// Check each name segment for a non-match.\n\tfor i, r := range req {\n\t\tif r.value != \"\" && r.value != parts[i] {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func isOwnedByJob(ownerKinds []string) bool {\n\tif len(ownerKinds) == 1 && ownerKinds[0] == \"Job\" {\n\t\treturn true\n\t}\n\treturn false\n}" ]
[ "0.63812995", "0.57971066", "0.5670115", "0.5649096", "0.5639601", "0.5593221", "0.5404589", "0.53668195", "0.53643936", "0.53286886", "0.53199124", "0.5313464", "0.52523345", "0.5228489", "0.5222134", "0.51968783", "0.5143813", "0.51406914", "0.5106199", "0.51034564", "0.50796914", "0.5074419", "0.50690514", "0.50603557", "0.5059127", "0.5025333", "0.5025333", "0.50099814", "0.50048435", "0.49908176", "0.49893472", "0.4986976", "0.4970776", "0.49638915", "0.49557266", "0.49434656", "0.49434656", "0.49402174", "0.49395922", "0.4938169", "0.4932783", "0.49310356", "0.49119473", "0.490684", "0.49055776", "0.49052206", "0.48942187", "0.48841003", "0.48825112", "0.4878176", "0.4875431", "0.48669818", "0.48658404", "0.4840958", "0.48387975", "0.48323834", "0.48203737", "0.48118526", "0.4806339", "0.48048788", "0.480427", "0.47979182", "0.4797671", "0.47966886", "0.47808948", "0.4779094", "0.4773178", "0.476626", "0.47616178", "0.4756637", "0.47517103", "0.47461423", "0.4741861", "0.47309104", "0.47266108", "0.47252446", "0.47225454", "0.47210535", "0.47171703", "0.47083658", "0.47037795", "0.46902144", "0.46894655", "0.4686462", "0.46725136", "0.46701035", "0.46672755", "0.4663395", "0.46529847", "0.4652979", "0.46490777", "0.4638279", "0.463441", "0.46329263", "0.46329263", "0.46321833", "0.46301004", "0.462985", "0.4627611" ]
0.5275863
13
determine if a name corresponds to a texture
func IsTexture(texture uint32) bool { ret := C.glowIsTexture(gpIsTexture, (C.GLuint)(texture)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func IsTexture(texture uint32) bool {\n ret := C.glowIsTexture(gpIsTexture, (C.GLuint)(texture))\n return ret == TRUE\n}", "func IsTexture(texture uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsTexture, 1, uintptr(texture), 0, 0)\n\treturn ret != 0\n}", "func IsTexture(t Texture) bool {\n\treturn gl.IsTexture(t.Value)\n}", "func (texture Texture) IsTexture() bool {\n\treturn gl.IsTexture(uint32(texture))\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 (DrawTexture) IsDrawAction() {}", "func AreTexturesResident(n int32, textures *uint32, residences *bool) bool {\n ret := C.glowAreTexturesResident(gpAreTexturesResident, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(textures)), (*C.GLboolean)(unsafe.Pointer(residences)))\n return ret == TRUE\n}", "func IsTexture(texture Uint) Boolean {\n\tctexture, _ := (C.GLuint)(texture), cgoAllocsUnknown\n\t__ret := C.glIsTexture(ctexture)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func AreTexturesResident(n int32, textures *uint32, residences *bool) bool {\n\tret, _, _ := syscall.Syscall(gpAreTexturesResident, 3, uintptr(n), uintptr(unsafe.Pointer(textures)), uintptr(unsafe.Pointer(residences)))\n\treturn ret != 0\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func LoadName(name uint32) {\n C.glowLoadName(gpLoadName, (C.GLuint)(name))\n}", "func AreTexturesResident(n int32, textures *uint32, residences *bool) bool {\n\tret := C.glowAreTexturesResident(gpAreTexturesResident, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(textures)), (*C.GLboolean)(unsafe.Pointer(residences)))\n\treturn ret == TRUE\n}", "func IsSampler(sampler uint32) bool {\n ret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n return ret == TRUE\n}", "func (bm Blendmap) Texture() *gl.Texture {\n\treturn bm.Map.id\n}", "func getAssetByName(assetName string){\n\n}", "func (a *TorrentImages) HaveImage(name string) bool {\n\t_, found := a.imageName[name]\n\treturn found\n}", "func imageExistsByName(name string) (bool, error) {\n\timages, err := getImages()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\tfor _, image := range images {\n\t\tfor _, tag := range image.RepoTags {\n\t\t\tif tag == name {\n\t\t\t\treturn true, nil\n\t\t\t}\n\t\t}\n\t}\n\treturn false, nil\n}", "func (f *Font) GetTexture() *Texture { return f.texture }", "func (self *TileSprite) TextureDebug() bool{\n return self.Object.Get(\"textureDebug\").Bool()\n}", "func (self *TileSprite) RefreshTexture() bool{\n return self.Object.Get(\"refreshTexture\").Bool()\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 (self *TileSprite) LoadTexture(key interface{}) {\n self.Object.Call(\"loadTexture\", key)\n}", "func (gstr *GlyphString) GetTexture() *Texture { return gstr.font.GetTexture() }", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func (self *TileSprite) Texture() *Texture{\n return &Texture{self.Object.Get(\"texture\")}\n}", "func (t *Three) Texture() *Texture {\n\tp := t.ctx.Get(\"Texture\")\n\treturn TextureFromJSObject(p)\n}", "func IsResourceTypeNameAvail(w http.ResponseWriter, r *http.Request) (interface{}, error) {\n\ttypename := r.Form.Get(\"typename\")\n\texists := false\n\tdb := GetDBHandle()\n\terr := db.QueryRow(\"SELECT exists (SELECT resourcetype FROM resourcetypes WHERE resourcetype=$1)\", typename).Scan(&exists)\n\n\treturn exists, err\n}", "func isAnImage(fileName string) bool {\n\treturn stringInSlice(strings.ToLower(filepath.Ext(fileName)), []string{\".jpg\", \".jpeg\", \".png\", \".gif\"})\n}", "func (ids WorkloadEndpointIdentifiers) NameMatches(name string) (bool, error) {\n\t// Extract the required segments for this orchestrator type.\n\treq, err := ids.getSegments()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\t// Extract the parameters from the name.\n\tparts := ExtractDashSeparatedParms(name, len(req))\n\tif len(parts) == 0 {\n\t\treturn false, nil\n\t}\n\n\t// Check each name segment for a non-match.\n\tfor i, r := range req {\n\t\tif r.value != \"\" && r.value != parts[i] {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func (am *Manager) LoadTexture(name string) (*Texture, error) {\n\tif tex, ok := am.GetTexture(name); ok {\n\t\treturn tex, nil\n\t}\n\n\tvar (\n\t\terr error\n\t\tf *os.File\n\t)\n\n\tif f, err = os.Open(\"assets/textures/\" + name); err != nil {\n\t\treturn nil, err\n\t}\n\tdefer f.Close()\n\n\tvar img image.Image\n\n\tif img, _, err = image.Decode(f); err != nil {\n\t\treturn nil, err\n\t}\n\n\tvar tex *Texture\n\n\tif tex, err = NewTextureFromImage(name, img); err != nil {\n\t\treturn nil, err\n\t}\n\n\tam.AddTexture(tex)\n\n\treturn tex, nil\n}", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func (am *AssetManager) LoadTexture(name, iname string) {\n\tif strings.Contains(name, \".png\") {\n\t\tpic, err := LoadPng(am.texturesDir + name)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tam.Textures[iname] = pic\n\t} else {\n\t\tlog.Fatal(\"unable to find texture \" + (am.modelsDir + name))\n\t}\n}", "func LoadName(name uint32) {\n\tC.glowLoadName(gpLoadName, (C.GLuint)(name))\n}", "func (s SourceFilesystems) IsAsset(filename string) bool {\n\treturn s.Assets.Contains(filename)\n}", "func (self *TileSprite) Exists() bool{\n return self.Object.Get(\"exists\").Bool()\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\n}", "func (self *TileSprite) Name() string{\n return self.Object.Get(\"name\").String()\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func nameMatch(path, pattern string) (bool, error) {\n\tbase := filepath.Base(path)\n\n\treturn filepath.Match(pattern, base)\n}", "func ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func (self *TileSprite) LoadTexture1O(key interface{}, frame interface{}) {\n self.Object.Call(\"loadTexture\", key, frame)\n}", "func (fnt *Font) Texture() *Texture {\n\treturn fnt.texture\n}", "func tagsContainName(Name string, Tags []interfaces.TagInformation) bool {\n\tfor _, Tag := range Tags {\n\t\tif Tag.Name == Name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsSampler(sampler uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsSampler, 1, uintptr(sampler), 0, 0)\n\treturn ret != 0\n}", "func (o *ApplianceImageBundleAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (c *FontTextureAtlas) Find(word string) (metrics *FontTextureMetrics, ok bool) {\n\tif v, ok := c.fontDictionary[word]; ok {\n\t\treturn v, true\n\t}\n\treturn nil, false\n}", "func matchGlyph(gid fonts.GID, value uint16) bool { return gid == fonts.GID(value) }", "func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tsyscall.Syscall6(gpNamedFramebufferTextureLayer, 5, uintptr(framebuffer), uintptr(attachment), uintptr(texture), uintptr(level), uintptr(layer), 0)\n}", "func isImage(extName string) bool {\n\tfor i := 0; i < len(supportImageExtNames); i++ {\n\t\tif supportImageExtNames[i] == extName {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func ActiveTexture(texture Enum) {\n\tgl.ActiveTexture(uint32(texture))\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func IsSampler(sampler uint32) bool {\n\tret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n\treturn ret == TRUE\n}", "func IsSampler(sampler uint32) bool {\n\tret := C.glowIsSampler(gpIsSampler, (C.GLuint)(sampler))\n\treturn ret == TRUE\n}", "func (c *Button) loadTextureFromTTF() {\n\tvar err error\n\tc.font = engosdl.GetFontManager().CreateFont(c.GetName(), c.FontFile, c.FontSize)\n\tc.texture = c.font.GetTextureFromFont(c.Message, c.Color)\n\t_, _, c.width, c.height, err = c.texture.Query()\n\tif err != nil {\n\t\tengosdl.Logger.Error().Err(err).Msg(\"Query error\")\n\t\tpanic(err)\n\t}\n\tc.GetEntity().GetTransform().SetDim(engosdl.NewVector(float64(c.width), float64(c.height)))\n}", "func SkinExistsGP(index int) bool {\n\te, err := SkinExists(boil.GetDB(), index)\n\tif err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n\n\treturn e\n}", "func LoadImageAsTexture(name string, path string) error {\n\tif Textures == nil {\n\t\tlog.Print(\"Initialize resource manager\")\n\t\tTextures = make(map[string]*ebiten.Image)\n\t}\n\timg, err := LoadImage(path)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tTextures[name] = img\n\treturn nil\n}", "func (me TunitsEnumType) IsPixels() bool { return me == \"pixels\" }", "func (t *Link) IsNameIRI(index int) (ok bool) {\n\treturn t.name[index].IRI != nil\n\n}", "func matchHostname(image, hostname string) bool {\n\tref, err := reference.ParseNamed(image)\n\tif err != nil {\n\t\treturn false\n\t}\n\thName, _ := reference.SplitHostname(ref)\n\treturn hName == hostname\n}", "func (self *GameObjectCreator) RenderTexture() *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\")}\n}", "func IsCompressedWriteResourceName(name string) bool {\n\treturn strings.Contains(name, \"compressed-blobs/zstd\")\n}", "func findTableByName(name string) (Table, bool) {\n\tfor i := range tables {\n\t\tif name == tables[i].Name {\n\t\t\treturn tables[i], true\n\t\t}\n\t}\n\treturn Table{}, false\n}", "func (e *Event) HasName(name string) bool {\n\ts := (*C.gchar)(C.CString(name))\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_event_has_name(e.g(), s) != 0\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, destroy)\n}", "func canBeUsedInImageTag(str string) bool {\n\treg := fmt.Sprintf(\"[0-9a-zA-Z,-,_,.]{%d}\", len(str))\n\tcanBeUesed, _ := regexp.MatchString(reg, str)\n\tif !canBeUesed {\n\t\tlog.Infof(\"[%s] can't be used in image tag\", str)\n\t}\n\treturn canBeUesed\n}", "func (self *Graphics) Exists() bool{\n return self.Object.Get(\"exists\").Bool()\n}", "func isBlock(name string, arch arch) bool {\n\tfor _, b := range genericBlocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\tfor _, b := range arch.blocks {\n\t\tif b.name == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsCustomResource(resourceName string) bool {\n\t// hack: we assume anything which is not cpu/memory to be a gpu.\n\t// we are not getting anything more that a map string->limits from the user\n\treturn resourceName != ResourceNameCores && resourceName != ResourceNameMemory\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 (am *Manager) AddTexture(t *Texture) error {\n\tif _, ok := am.Textures[t.Name]; ok {\n\t\treturn fmt.Errorf(\"asset.Manager.AddTexture error: texture %s already exists\", t.Name)\n\t}\n\n\tam.Textures[t.Name] = t\n\n\treturn nil\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func (self *TileSprite) Renderable() bool{\n return self.Object.Get(\"renderable\").Bool()\n}", "func ActiveTexture(texture uint32) {\n\tsyscall.Syscall(gpActiveTexture, 1, uintptr(texture), 0, 0)\n}", "func (me TshapeEnumType) IsRectangle() bool { return me == \"rectangle\" }", "func IsQEMU(name string) bool {\n\treturn name == QEMU2 || name == QEMU\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func (v *testVolume) isLabel(label uint64, body *testBody) bool {\n\tnx := v.size[0]\n\tnxy := nx * v.size[1]\n\tfor _, span := range body.voxelSpans {\n\t\tz, y, x0, x1 := span.Unpack()\n\t\tp := (z*nxy + y*nx) * 8\n\t\tfor i := p + x0*8; i <= p+x1*8; i += 8 {\n\t\t\tcurLabel := binary.LittleEndian.Uint64(v.data[i : i+8])\n\t\t\tif curLabel != label {\n\t\t\t\treturn false\n\t\t\t}\n\t\t}\n\t}\n\treturn true\n}", "func (self templateEngine) hasTemplate(name string) bool {\n return CheckFile(self.templateFilepath(name))\n}", "func (o *ResourceEntry) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func BindTexture(target Enum, t Texture) {\n\tgl.BindTexture(uint32(target), t.Value)\n}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (m *ResourceMutation) Name() (r string, exists bool) {\n\tv := m.name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func SkinExists(exec boil.Executor, index int) (bool, error) {\n\tvar exists bool\n\tsql := \"select exists(select 1 from `skin` where `index`=? limit 1)\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, index)\n\t}\n\n\trow := exec.QueryRow(sql, index)\n\n\terr := row.Scan(&exists)\n\tif err != nil {\n\t\treturn false, errors.Wrap(err, \"models: unable to check if skin exists\")\n\t}\n\n\treturn exists, nil\n}", "func (o *BulkCreatePayloadAuthentications) GetResourceNameOk() (*string, bool) {\n\tif o == nil || o.ResourceName == nil {\n\t\treturn nil, false\n\t}\n\treturn o.ResourceName, true\n}", "func isTemplateBeingUsed(sd *defs, st *defs, tmplName string) bool {\n for _, def := range *st {\n if def.attrExist(\"use\") && def[\"use\"].Has(tmplName){\n return true\n }\n }\n for _, def := range *sd {\n if def.attrExist(\"use\") && def[\"use\"].Has(tmplName){\n return true\n }\n }\n return false\n}", "func GetTypeByName(typeName string) (tagType TagTypePrimitive, found bool) {\n\ttagType, found = typeNamesR[typeName]\n\treturn tagType, found\n}", "func useRawNames(tfs shim.Schema) bool {\n\tif tfs == nil || tfs.Type() != shim.TypeMap {\n\t\treturn false\n\t}\n\t_, hasResourceElem := tfs.Elem().(shim.Resource)\n\treturn !hasResourceElem\n}", "func (t *Link) IsNameLangString(index int) (ok bool) {\n\treturn t.name[index].langString != nil\n\n}", "func (o *Volume) HasSubregionName() bool {\n\tif o != nil && o.SubregionName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *Volume) HasSubregionName() bool {\n\tif o != nil && o.SubregionName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (me TAttlistLocationLabelType) IsFigure() bool { return me.String() == \"figure\" }", "func (self *TileSprite) InWorld() bool{\n return self.Object.Get(\"inWorld\").Bool()\n}", "func (o *StorageNetAppCloudTargetAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func GetRandomTexture() (rune, rune) {\n\trandomTexture := textures[rand.Intn(len(textures))]\n\treturn randomTexture.leftRune, randomTexture.rightRune\n}", "func (c Command) HasName(name string) bool {\n\tfor _, n := range c.Names() {\n\t\tif n == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (me TAttlistDescriptorNameType) IsGeographic() bool { return me.String() == \"Geographic\" }", "func (nu UnitNameInfo) IsTemplate() bool {\n\treturn len(nu.Template) > 0 && !nu.IsInstance()\n}" ]
[ "0.6506235", "0.6324817", "0.6290457", "0.6051746", "0.60405356", "0.59020525", "0.5821584", "0.58060527", "0.55988795", "0.5555456", "0.5422459", "0.5422343", "0.53182197", "0.53151083", "0.5294126", "0.5269514", "0.5241979", "0.52382743", "0.5235356", "0.52039367", "0.5142217", "0.5141453", "0.51274556", "0.5123452", "0.5103133", "0.50778866", "0.5062699", "0.5058153", "0.50421137", "0.5033351", "0.49826297", "0.4975742", "0.4960969", "0.49587354", "0.49410972", "0.49211457", "0.49164316", "0.48996195", "0.48736668", "0.48695064", "0.48692095", "0.48673242", "0.48363924", "0.4816882", "0.4808314", "0.47960037", "0.47950542", "0.47939813", "0.47936022", "0.47807536", "0.4774455", "0.47580805", "0.4755368", "0.4755368", "0.474697", "0.47324312", "0.47319096", "0.47317111", "0.47249976", "0.47238708", "0.4722404", "0.47178093", "0.4713649", "0.4703159", "0.47005776", "0.4700463", "0.46878457", "0.46766898", "0.46650285", "0.46641695", "0.46641695", "0.46634457", "0.46570328", "0.4655786", "0.46450645", "0.46442974", "0.4640781", "0.46342137", "0.4633589", "0.463206", "0.4613976", "0.461375", "0.46053824", "0.4591996", "0.45900357", "0.45875698", "0.45856577", "0.4584817", "0.45837784", "0.45823383", "0.45806214", "0.45806214", "0.4577737", "0.45772058", "0.4576567", "0.457412", "0.4569373", "0.4563585", "0.4563198" ]
0.5839103
7
determine if a name corresponds to a transform feedback object
func IsTransformFeedback(id uint32) bool { ret := C.glowIsTransformFeedback(gpIsTransformFeedback, (C.GLuint)(id)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (me TxsdNodeRoleSimpleContentExtensionCategory) IsName() bool { return me.String() == \"name\" }", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (o *LogsPipelineProcessor) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func (m *MetricFilter) TransformationName(name string) *MetricFilter {\n\tm.filterList = append(m.filterList, func(v interface{}) bool {\n\t\tfilter := convert(v)\n\t\tif filter == nil ||\n\t\t\tlen(filter.MetricTransformations) == 0 {\n\t\t\treturn false\n\t\t}\n\t\tshared.Debugf(\"%s == %s -> %t\\n\",\n\t\t\tname,\n\t\t\taws.StringValue(filter.MetricTransformations[0].MetricName),\n\t\t\tname == aws.StringValue(filter.MetricTransformations[0].MetricName),\n\t\t)\n\t\treturn name == aws.StringValue(filter.MetricTransformations[0].MetricName)\n\t})\n\treturn m\n}", "func (m *MetricFilter) TName(name string) *MetricFilter {\n\treturn m.TransformationName(name)\n}", "func (me TxsdTimeImpactSimpleContentExtensionMetric) IsLabor() bool { return me.String() == \"labor\" }", "func (f *FieldAssignment) IsTransform() bool {\n\tfromI := strings.Index(f.FromIdentifier, \".\") + 1\n\ttoI := strings.Index(f.ToIdentifier, \".\") + 1\n\n\t// make sure FromIdentifier and ToIdentifier have valid prefixes\n\tif (f.FromIdentifier[:fromI] != \"in.\" && f.FromIdentifier[:fromI] != \"inOriginal.\") || f.ToIdentifier[:toI] != \"out.\" {\n\t\tpanic(\"isTransform check called on unexpected input fromIdentifer \" + f.FromIdentifier + \" toIdentifer \" + f.ToIdentifier)\n\t}\n\n\t// it's a transform when FromIdentifier != ToIdentifier (after removing prefix)\n\treturn f.FromIdentifier[fromI:] != f.ToIdentifier[toI:]\n}", "func (me TxsdAnimateTransformTypeType) IsTranslate() bool { return me.String() == \"translate\" }", "func (o *Ga4ghFeature) GetNameOk() (string, bool) {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.Name, true\n}", "func (me TAttlistLocationLabelType) IsFigure() bool { return me.String() == \"figure\" }", "func (o *ParameterContextDTO) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (r *AttachmentOriginal) HasName() bool {\n\treturn r.hasName\n}", "func (o *View) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *ViewTag) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (me TAttlistAbstractTextNlmCategory) IsObjective() bool { return me.String() == \"OBJECTIVE\" }", "func (o *CreateEventPayloadActions) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *ContentProvider2) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (me TxsdSystemCategory) IsTarget() bool { return me.String() == \"target\" }", "func (l *Lexer) isName(char rune) bool {\n\treturn (char >= 'a' && char <= 'z') || (char >= 'A' && char <= 'Z') ||\n\t\t(char >= '0' && char <= '9') || char == '_' || char == '!' || char == '?'\n}", "func Name(name string) bool {\n\treturn nameMap[strings.ToLower(strings.TrimSpace(name))]\n}", "func (o *ContentProviderReadDetailed) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o TransformationOutput) Name() pulumi.StringOutput {\n\treturn o.ApplyT(func(v *Transformation) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput)\n}", "func (o *ParameterContextDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *EventSubcategory) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *SyntheticsBrowserTest) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *Ga4ghTumourboard) GetNameOk() (string, bool) {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.Name, true\n}", "func (me TxsdActuate) IsOther() bool { return me == \"other\" }", "func (me TxsdAnimateTransformTypeType) IsSkewX() bool { return me.String() == \"skewX\" }", "func (o *KanbanViewView) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *WorkflowSolutionActionDefinition) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *CreateInstance) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *AuthorDto) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func isName(ch rune) bool {\n\treturn isNameStart(ch) || isDigit(ch) || ch == '-' || ch == ':' || ch == '.'\n}", "func (o *ComponentReferenceDTO) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *Ga4ghChemotherapy) GetNameOk() (string, bool) {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.Name, true\n}", "func (me TrestrictionType) IsNeedToKnow() bool { return me.String() == \"need-to-know\" }", "func (o *AuthorDto) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (self *ComponentScaleMinMax) CheckTransform(wt *Matrix) {\n self.Object.Call(\"checkTransform\", wt)\n}", "func (me TxsdImpactSimpleContentExtensionType) IsExtortion() bool { return me.String() == \"extortion\" }", "func (o *DisplayInfo) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *ActionDTO) GetSourceNameOk() (*string, bool) {\n\tif o == nil || o.SourceName == nil {\n\t\treturn nil, false\n\t}\n\treturn o.SourceName, true\n}", "func (o *OutputProblemAllOf) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *ActionDTO) HasSourceName() bool {\n\tif o != nil && o.SourceName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *EquipmentBaseSensor) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *WorkflowServiceItemActionInstance) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *CreateTemplateRequestEntity) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *SecurityMonitoringRuleCase) HasName() bool {\n\treturn o != nil && o.Name != nil\n}", "func (o *MicrosoftGraphItemReference) GetNameOk() (string, bool) {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.Name, true\n}", "func (o *TenantExternalView) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (DrawText) IsDrawAction() {}", "func (r *PackageAggRow) HasValidName() bool { return r.Data.Name != nil }", "func (o *LogsPipelineProcessor) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *Tier) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *StorageSasExpander) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *RuleSetWarning) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *WorkflowBuildTaskMeta) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (ts TaskSpec) OutputByName(name string) (TaskOutputSpec, bool) {\n\tfor _, x := range ts.Outputs {\n\t\tif x.Name == name {\n\t\t\treturn x, true\n\t\t}\n\t}\n\treturn TaskOutputSpec{}, false\n}", "func (o *WorkbookChart) GetNameOk() (string, bool) {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.Name, true\n}", "func (o *EventTypeIn) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (DrawTexture) IsDrawAction() {}", "func (m *ToolMutation) ToolName() (r string, exists bool) {\n\tv := m._Tool_Name\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func (o *WorkflowCatalogServiceRequest) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *Tag) GetNameOk() (string, bool) {\n\tif o == nil || o.Name == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.Name, true\n}", "func (o *WorkflowWorkflowDefinitionAllOf) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *CreateTemplateRequestEntity) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (c gosundheitCheck) Name() string { return c.name }", "func (o *ControllerServiceReferencingComponentDTO) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *RelatedAssetSerializerWithPermission) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *SecurityMonitoringRuleCase) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *ViewSampleProject) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *Tier) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (me TxsdActuate) IsOther() bool { return me.String() == \"other\" }", "func isValidName(name string) bool { return name != \"_\" && name != \"this\" }", "func (o *BulletinDTO) GetSourceNameOk() (*string, bool) {\n\tif o == nil || o.SourceName == nil {\n\t\treturn nil, false\n\t}\n\treturn o.SourceName, true\n}", "func (o *StorageNetAppCloudTargetAllOf) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *ComponentReferenceDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *ControllerServiceReferencingComponentDTO) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *DnsViewparamDataData) GetViewNameOk() (*string, bool) {\n\tif o == nil || o.ViewName == nil {\n\t\treturn nil, false\n\t}\n\treturn o.ViewName, true\n}", "func (o *SyntheticMonitorUpdate) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *ViewMilestone) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *ConnectorTypeAllOf) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *ConnectorTypeAllOf) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (me TAttlistDescriptorNameType) IsGeographic() bool { return me.String() == \"Geographic\" }", "func (o *SLOCorrectionResponseAttributesModifier) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *StorageNetAppCloudTargetAllOf) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *SearchSLOResponseDataAttributesFacets) HasCreatorName() bool {\n\tif o != nil && o.CreatorName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *Content) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (o *GovChainMetadata) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (me TxsdPremiseSequenceChoiceChoicePremiseNumberRangeNumberRangeOccurence) IsBeforeName() bool {\r\n\treturn me == \"BeforeName\"\r\n}", "func (me TxsdShow) IsOther() bool { return me == \"other\" }", "func (o *Ga4ghFeature) GetReferenceNameOk() (string, bool) {\n\tif o == nil || o.ReferenceName == nil {\n\t\tvar ret string\n\t\treturn ret, false\n\t}\n\treturn *o.ReferenceName, true\n}", "func (ts TaskSpec) InputByName(name string) (TaskInputSpec, bool) {\n\tfor _, x := range ts.Inputs {\n\t\tif x.Name == name {\n\t\t\treturn x, true\n\t\t}\n\t}\n\treturn TaskInputSpec{}, false\n}", "func (e *errorT) Name() (string, bool) {\n\tif e.class == nil {\n\t\treturn \"\", false\n\t}\n\treturn string(*e.class), true\n}", "func (o *IamServiceProviderAllOf) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *Metric) GetNameOk() (*string, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Name, true\n}", "func (t *TransformCmd) Name() string {\n\treturn t.fs.Name()\n}", "func IsNameOnly(ref Named) bool {\n\tif _, ok := ref.(NamedTagged); ok {\n\t\treturn false\n\t}\n\tif _, ok := ref.(Canonical); ok {\n\t\treturn false\n\t}\n\treturn true\n}", "func (o *ManualDependency) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *WafPolicyGroup) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}", "func (o *WorkflowServiceItemDefinitionAllOf) GetNameOk() (*string, bool) {\n\tif o == nil || o.Name == nil {\n\t\treturn nil, false\n\t}\n\treturn o.Name, true\n}" ]
[ "0.58264047", "0.5682838", "0.553338", "0.5502983", "0.54955417", "0.54645574", "0.53569835", "0.5317089", "0.52396387", "0.52234924", "0.5217064", "0.52167743", "0.52090096", "0.5162367", "0.5149272", "0.514301", "0.51371473", "0.5136019", "0.5128992", "0.51241666", "0.5123032", "0.5111713", "0.5109032", "0.5097334", "0.5094223", "0.5089262", "0.50885105", "0.507955", "0.5077652", "0.5072113", "0.5067703", "0.5065896", "0.5065752", "0.5063343", "0.505739", "0.50536776", "0.50530344", "0.50523615", "0.50475174", "0.50429714", "0.504278", "0.5035049", "0.5025678", "0.502469", "0.5013358", "0.50130695", "0.5004714", "0.4980657", "0.49798843", "0.4967478", "0.49654895", "0.4962939", "0.4961125", "0.49544606", "0.49519166", "0.49497724", "0.49477148", "0.49433893", "0.49360177", "0.49345985", "0.4932927", "0.49296463", "0.49183732", "0.49159893", "0.49121848", "0.49112684", "0.49080676", "0.4890064", "0.488754", "0.48855945", "0.4879432", "0.48744962", "0.48702896", "0.48699215", "0.48690262", "0.4856592", "0.48536503", "0.4848277", "0.48471832", "0.48421344", "0.48312622", "0.48312357", "0.48312357", "0.48271427", "0.48270527", "0.48264962", "0.48260087", "0.4822884", "0.4821565", "0.48196217", "0.48155734", "0.4815108", "0.481179", "0.4806653", "0.48037443", "0.48013157", "0.480119", "0.4800254", "0.479818", "0.47960123", "0.47959566" ]
0.0
-1
determine if a name corresponds to a vertex array object
func IsVertexArray(array uint32) bool { ret := C.glowIsVertexArray(gpIsVertexArray, (C.GLuint)(array)) return ret == TRUE }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func testVertex(name string, interested_item string) bool {\n\t// fmt.Println(\"name:\", name, \"interested_item\", interested_item)\n\n\tif name == interested_item {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func IsVertexArray(array uint32) bool {\n ret := C.glowIsVertexArray(gpIsVertexArray, (C.GLuint)(array))\n return ret == TRUE\n}", "func IsVertexArray(array uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsVertexArray, 1, uintptr(array), 0, 0)\n\treturn ret != 0\n}", "func inArray(arrays []string, key string) (bool, int) {\n\tfor index, arr := range arrays {\n\t\tif key == arr {\n\t\t\treturn true, index\n\t\t}\n\t}\n\treturn false, 0\n}", "func (g *Graph) hasVertex(id string) bool {\n\t_, ok := g.Vertices[id]\n\treturn ok\n}", "func (*Array) Name() string {\n\treturn \"array\"\n}", "func arrContains(str string) bool {\n\tfor _, compare := range []string{\"CREATE\", \"REMOVE\", \"RENAME\"} {\n\t\tif strings.Contains(strings.ToUpper(str), compare) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (arr *varArray) Name() string {\n\treturn arr.name\n}", "func (r *PackageAggRow) HasValidName() bool { return r.Data.Name != nil }", "func inArray(needle interface{}, haystack interface{}) (exists bool) {\n\texists = false\n\tif reflect.TypeOf(haystack).Kind() != reflect.Slice {\n\t\treturn\n\t}\n\n\tarray := reflect.ValueOf(haystack)\n\tfor i := 0; i < array.Len(); i++ {\n\t\tif reflect.DeepEqual(needle, array.Index(i).Interface()) {\n\t\t\texists = true\n\t\t\treturn\n\t\t}\n\t}\n\n\treturn\n}", "func sliceContains(s []*dag.Vertex, v *dag.Vertex) bool {\n\tfor _, i := range s {\n\t\tif i == v {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func InSlice(mineral Mineral, minerals []Mineral) bool {\n\tisIt := false\n\tfor _, m := range minerals {\n\t\tif m.Name == mineral.Name {\n\t\t\tisIt = true\n\t\t}\n\t}\n\n\treturn isIt\n}", "func InSlice(mineral Mineral, minerals []Mineral) bool {\n\tisIt := false\n\tfor _, m := range minerals {\n\t\tif m.Name == mineral.Name {\n\t\t\tisIt = true\n\t\t}\n\t}\n\n\treturn isIt\n}", "func names_match(\np int32,/* points to the proposed match */\nid[]rune,/* the identifier*/\nt int32)bool{\nif len(name_dir[p].name)!=len(id){\nreturn false\n}\nreturn compare_runes(id,name_dir[p].name)==0\n}", "func exist(board [][]byte, word string) bool {\n \n}", "func (vertex Vertex) Contains(cube Cube) bool {\n\tfor _, c := range vertex.Path {\n\t\tif c.Equals(cube) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func arrayContains(source []string, item string) bool {\n\tfor _, s := range source {\n\t\tif s == item {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func member(a string, arr []string) bool {\n\tfor _, s := range arr {\n\t\tif a == s {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func constraints(arr interface{}, v string) bool {\n\tarrs := reflect.ValueOf(arr)\n\tlen := arrs.Len()\n\tfor i := 0; i < len; i++ {\n\t\tif arrs.Index(i).String() == v {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (me TAttlistDescriptorNameType) IsGeographic() bool { return me.String() == \"Geographic\" }", "func VNameEqual(v1, v2 *spb.VName) bool {\n\treturn (v1 == v2) || (v1.GetSignature() == v2.GetSignature() && v1.GetCorpus() == v2.GetCorpus() && v1.GetRoot() == v2.GetRoot() && v1.GetPath() == v2.GetPath() && v1.GetLanguage() == v2.GetLanguage())\n}", "func (me TSearchQualificationTypesSortProperty) IsName() bool { return me.String() == \"Name\" }", "func (s *subsumer) vertices(x, y *adt.Vertex) bool {\n\tif x == y {\n\t\treturn true\n\t}\n\n\tif s.Defaults {\n\t\ty = y.Default()\n\t}\n\n\tif b, _ := y.BaseValue.(*adt.Bottom); b != nil {\n\t\t// If the value is incomplete, the error is not final. So either check\n\t\t// structural equivalence or return an error.\n\t\treturn !b.IsIncomplete()\n\t}\n\n\tctx := s.ctx\n\n\tfinal := y.IsData() || s.Final\n\n\tswitch v := x.BaseValue.(type) {\n\tcase *adt.Bottom:\n\t\treturn false\n\n\tcase *adt.ListMarker:\n\t\tif !y.IsList() {\n\t\t\ts.errf(\"list does not subsume %s (type %s)\", y, y.Kind())\n\t\t\treturn false\n\t\t}\n\t\tif !s.listVertices(x, y) {\n\t\t\treturn false\n\t\t}\n\t\t// TODO: allow other arcs alongside list arc.\n\t\treturn true\n\n\tcase *adt.StructMarker:\n\t\t_, ok := y.BaseValue.(*adt.StructMarker)\n\t\tif !ok {\n\t\t\treturn false\n\t\t}\n\n\tcase adt.Value:\n\t\tif !s.values(v, y.Value()) {\n\t\t\treturn false\n\t\t}\n\n\t\t// Embedded scalars could still have arcs.\n\t\tif final {\n\t\t\treturn true\n\t\t}\n\n\tdefault:\n\t\tpanic(fmt.Sprintf(\"unexpected type %T\", v))\n\t}\n\n\txClosed := x.IsClosedStruct() && !s.IgnoreClosedness\n\t// TODO: this should not close for taking defaults. Do a more principled\n\t// makeover of this package before making it public, though.\n\tyClosed := s.Final || s.Defaults ||\n\t\t(y.IsClosedStruct() && !s.IgnoreClosedness)\n\n\tif xClosed && !yClosed && !final {\n\t\treturn false\n\t}\n\n\ttypes := x.OptionalTypes()\n\tif !final && !s.IgnoreOptional && types&(adt.HasPattern|adt.HasAdditional) != 0 {\n\t\t// TODO: there are many cases where pattern constraints can be checked.\n\t\ts.inexact = true\n\t\treturn false\n\t}\n\n\t// All arcs in x must exist in y and its values must subsume.\n\txFeatures := export.VertexFeatures(s.ctx, x)\n\tfor _, f := range xFeatures {\n\t\tif s.Final && !f.IsRegular() {\n\t\t\tcontinue\n\t\t}\n\n\t\ta := x.Lookup(f)\n\t\taOpt := false\n\t\tif a == nil {\n\t\t\t// x.f is optional\n\t\t\tif s.IgnoreOptional {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\ta = &adt.Vertex{Label: f}\n\t\t\tx.MatchAndInsert(ctx, a)\n\t\t\ta.Finalize(ctx)\n\n\t\t\t// If field a is optional and has value top, neither the\n\t\t\t// omission of the field nor the field defined with any value\n\t\t\t// may cause unification to fail.\n\t\t\tif a.Kind() == adt.TopKind {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\taOpt = true\n\t\t}\n\n\t\tb := y.Lookup(f)\n\t\tif b == nil {\n\t\t\t// y.f is optional\n\t\t\tif !aOpt {\n\t\t\t\ts.errf(\"required field is optional in subsumed value: %s\", f)\n\t\t\t\treturn false\n\t\t\t}\n\n\t\t\t// If f is undefined for y and if y is closed, the field is\n\t\t\t// implicitly defined as _|_ and thus subsumed. Technically, this is\n\t\t\t// even true if a is not optional, but in that case it means that y\n\t\t\t// is invalid, so return false regardless\n\t\t\tif !y.Accept(ctx, f) || y.IsData() || s.Final {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tb = &adt.Vertex{Label: f}\n\t\t\ty.MatchAndInsert(ctx, b)\n\t\t\tb.Finalize(ctx)\n\t\t}\n\n\t\tif s.values(a, b) {\n\t\t\tcontinue\n\t\t}\n\n\t\ts.missing = f\n\t\ts.gt = a\n\t\ts.lt = y\n\n\t\ts.errf(\"field %s not present in %s\", f, y)\n\t\treturn false\n\t}\n\n\tif xClosed && !yClosed && !s.Final {\n\t\ts.errf(\"closed struct does not subsume open struct\")\n\t\treturn false\n\t}\n\n\tyFeatures := export.VertexFeatures(s.ctx, y)\nouter:\n\tfor _, f := range yFeatures {\n\t\tif s.Final && !f.IsRegular() {\n\t\t\tcontinue\n\t\t}\n\n\t\tfor _, g := range xFeatures {\n\t\t\tif g == f {\n\t\t\t\t// already validated\n\t\t\t\tcontinue outer\n\t\t\t}\n\t\t}\n\n\t\tb := y.Lookup(f)\n\t\tif b == nil {\n\t\t\tif s.IgnoreOptional || s.Final {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tb = &adt.Vertex{Label: f}\n\t\t\ty.MatchAndInsert(ctx, b)\n\t\t}\n\n\t\tif !x.Accept(ctx, f) {\n\t\t\tif s.Profile.IgnoreClosedness {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\ts.errf(\"field not allowed in closed struct: %s\", f)\n\t\t\treturn false\n\t\t}\n\n\t\ta := &adt.Vertex{Label: f}\n\t\tx.MatchAndInsert(ctx, a)\n\t\tif len(a.Conjuncts) == 0 {\n\t\t\t// It is accepted and has no further constraints, so all good.\n\t\t\tcontinue\n\t\t}\n\n\t\ta.Finalize(ctx)\n\t\tb.Finalize(ctx)\n\n\t\tif !s.vertices(a, b) {\n\t\t\treturn false\n\t\t}\n\t}\n\n\treturn true\n}", "func isMember(val string, slice []string) (bl bool, idx int) {\n\tfor i, v := range slice {\n\t\tif val == v {\n\t\t\treturn true, i\n\t\t}\n\t}\n\treturn false, -1\n}", "func (this *ObjectNames) Type() value.Type { return value.ARRAY }", "func (this *ObjectNames) Type() value.Type { return value.ARRAY }", "func (p ParameterFile) IsArray() bool {\n\treturn strings.HasSuffix(p.Type, \"[]\")\n}", "func IsBucketInBucketsArray(buckets []nb.BucketInfo, bucketName string) bool {\n\tfor _, b := range buckets {\n\t\tif b.Name == bucketName {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func InArray(value string, array []string) bool {\n\tfor _, v := range array {\n\t\tif v == value {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\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 ArrayContains(s []string, e string) bool {\n\tfor _, a := range s {\n\t\tif a == e {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func ContainsArray(slice []string, items []string) bool {\n\tret := 0\n\tfor _, item := range items {\n\t\tif Contains(slice, item) {\n\t\t\tret++\n\t\t}\n\t}\n\tif ret != 0 && len(items) == ret {\n\t\treturn true\n\t}\n\treturn false\n}", "func (*ArraySchema) GetName() string {\n\treturn typeArray\n}", "func contains(vs []*View, x, y float64) bool {\n\tfor _, v := range vs {\n\t\tif v.contains(x, y) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (pk PKArray) Has(name string) bool {\n\tfor _, col := range pk {\n\t\tif col == name {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func IsArrayType(namespace xmpregistry.Namespace, fieldName string) (flag bool, err error) {\n\tdefer func() {\n\t\tif errRaw := recover(); errRaw != nil {\n\t\t\terr = log.Wrap(errRaw.(error))\n\t\t}\n\t}()\n\n\tft, found := namespace.Fields[fieldName]\n\n\tif found == false {\n\t\treturn false, ErrChildFieldNotFound\n\t}\n\n\t_, ok := ft.(ArrayFieldType)\n\n\treturn ok, nil\n}", "func isArray(s spec.Schema) bool {\n\treturn len(s.Type) > 0 && s.Type[0] == \"array\"\n}", "func ArrayContains(ary []string, check string) bool {\n\tfor _, k := range ary {\n\t\tif k == check {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func containSecret(array []corev1.LocalObjectReference, secretName string) bool {\n\tif array != nil {\n\t\tfor _, a := range array {\n\t\t\tif a.Name == secretName {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\treturn false\n}", "func containVirus(grid [][]int) int {\n \n}", "func IsArrayType(dataType DataType) bool {\n\treturn (dataType & 0x01000000) > 0\n}", "func iscall(prog *obj.Prog, name *obj.LSym) bool {\n\tif prog == nil {\n\t\tFatal(\"iscall: prog is nil\")\n\t}\n\tif name == nil {\n\t\tFatal(\"iscall: function name is nil\")\n\t}\n\tif prog.As != obj.ACALL {\n\t\treturn false\n\t}\n\treturn name == prog.To.Sym\n}", "func (c *vertexCollection) Name() string {\n\treturn c.name\n}", "func isRegistered(sample string, stringArray []string) bool {\n\tfor _, value := range stringArray {\n\t\tif ok := strings.Compare(sample, value); ok == 0 {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (o *ObjectRef) IsArray() bool {\n\treturn o.isArray\n}", "func InArray(elem interface{}, arr []interface{}) bool {\n\tfor _, e := range arr {\n\t\tif e == elem {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (j JO) IsArray(path ...string) (bool, error) {\n\treturn IsArray(j, path...)\n}", "func (g *Graph) isAdj(orig, adj int) bool {\n if g.vertex[orig] == nil {\n return false\n } else {\n n := g.vertex[orig]\n for ; n.next != nil ; {\n if (*n).val == adj {\n return true\n }\n n = n.next\n }\n return false\n }\n}", "func (g *Graph) isAdj(orig, adj int) bool {\n if g.vertex[orig] == nil {\n return false\n } else {\n n := g.vertex[orig]\n for ; n.next != nil ; {\n if (*n).val == adj {\n return true\n }\n n = n.next\n }\n return false\n }\n}", "func ArrayContains(l, elem interface{}) bool {\n\tvl := reflect.ValueOf(l)\n\tfor i := 0; i < vl.Len(); i++ {\n\t\tif ObjectEqual(vl.Index(i).Interface(), elem) {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (s Strategy) HasArrayField(t Entity) bool {\n\t//Fields []map[string]interface{}\n\n\tfor _, f := range t.Fields {\n\t\tif f[\"type\"] == \"Array\" {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (me TAttlistSupplMeshNameType) IsProtocol() bool { return me.String() == \"Protocol\" }", "func isVector(u *Matrix, shape []int) bool {\n\tif u.Rank() == 0 || len(shape) == 0 || u.shape[0] != shape[len(shape)-1] {\n\t\treturn false\n\t}\n\tfor _, dim := range u.shape[1:] {\n\t\tif dim != 1 {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func (s FileInfoSlice) ContainsFileByName(name string) bool {\n\ti := sort.Search(s.Len(), func(i int) bool {\n\t\treturn s[i].Name() >= name\n\t})\n\tif i < s.Len() && s[i].Name() == name {\n\t\treturn true\n\t}\n\treturn false\n}", "func (d *Data) Contains(name string, version uint) bool {\n\t_, inValues := d.Get(name, version)\n\treturn inValues\n}", "func (g *Graph) hasAdj(orig int) bool {\n if g.vertex[orig] == nil {\n return false\n } else {\n return true\n }\n}", "func (gdt *Array) Has(value Variant) Bool {\n\targ0 := gdt.getBase()\n\targ1 := value.getBase()\n\n\tret := C.go_godot_array_has(GDNative.api, arg0, arg1)\n\n\treturn Bool(ret)\n}", "func almostEqualVertex(a, b gfx.Vec3) bool {\n\tif !almostEqualFloat32(a.X, b.X) {\n\t\treturn false\n\t}\n\tif !almostEqualFloat32(a.Y, b.Y) {\n\t\treturn false\n\t}\n\tif !almostEqualFloat32(a.Z, b.Z) {\n\t\treturn false\n\t}\n\n\treturn true\n}", "func hasName(t Type) bool {\n\tswitch t.(type) {\n\tcase *Basic, *Named, *TypeParam:\n\t\treturn true\n\t}\n\treturn false\n}", "func (tet *Tetrahedron) IsFlat()(bool){\n\tfor idx0, v0 := range tet.Vertices {\n\t\tfor idx1, v1 := range tet.Vertices {\n\t\t\tif idx0 != idx1 {\n\t\t\t\tif v0.equals(v1) {\n\t\t\t\t\t//log.Println(\"here\")\n\t\t\t\t\t//log.Println(tet.Id)\n\t\t\t\t\treturn true\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tsingleX := true\n\tsingleY := true\n\tsingleZ := true\n\n\tfor i := 1; i < len(tet.Vertices); i++ {\n\t\tif tet.Vertices[i].Vec[0] != tet.Vertices[i-1].Vec[0] {\n\t\t\tsingleX = false\n\t\t}\n\t\tif tet.Vertices[i].Vec[1] != tet.Vertices[i-1].Vec[1] {\n\t\t\tsingleY = false\n\t\t}\n\t\tif tet.Vertices[i].Vec[2] != tet.Vertices[i-1].Vec[2] {\n\t\t\tsingleZ = false\n\t\t}\n\t}\n\treturn singleX || singleY || singleZ\n}", "func (me TshapeEnumType) IsSphere() bool { return me == \"sphere\" }", "func (p *PKGBUILD) Contains(name string) bool {\n\tcb := atom.NamedCheckAll(\n\t\tatom.NewNameMatcher(atom.VarArray, atom.VarString, atom.Function),\n\t\tatom.CheckName(name),\n\t)\n\t_, ok := p.info.FilterFirst(cb)\n\treturn ok\n}", "func (o *StorageHitachiParityGroupAllOf) HasArray() bool {\n\tif o != nil && o.Array != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (a Vertex) Less(b Vertex) bool {\n\tfor i := range a.pos {\n\t\tswitch {\n\t\tcase a.pos[i] < b.pos[i]:\n\t\t\treturn true\n\t\tcase a.pos[i] > b.pos[i]:\n\t\t\treturn false\n\t\t}\n\t}\n\tfor i := range a.color {\n\t\tswitch {\n\t\tcase a.color[i] < b.color[i]:\n\t\t\treturn true\n\t\tcase a.color[i] > b.color[i]:\n\t\t\treturn false\n\t\t}\n\t}\n\treturn false\n}", "func checkSlice(name string, attr string, data interface{}) {\n\tif reflect.ValueOf(data).Kind() != reflect.Slice {\n\t\tpanic(fmt.Errorf(\"MakeMesh error: Mesh '%s' '%s' data is not a slice\", name, attr))\n\t}\n}", "func (e *Event) HasName(name string) bool {\n\ts := (*C.gchar)(C.CString(name))\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_event_has_name(e.g(), s) != 0\n}", "func inSlice(v string, s []string) bool {\n\tfor _, scope := range s {\n\t\tif scope == v {\n\t\t\treturn true\n\t\t}\n\t}\n\n\treturn false\n}", "func (r *Relation) Polygon() bool {\n\tt := r.Tags.Find(\"type\")\n\treturn t == \"multipolygon\" || t == \"boundary\"\n}", "func tagArraysEqual(a []GeneratedType, b []string) bool {\n\tif len(a) != len(b) {\n\t\treturn false\n\t}\n\tfor i := 0; i < len(a); i++ {\n\t\tfound := false\n\t\tfor j := 0; j < len(b); j++ {\n\t\t\tif a[i].(string) == b[j] {\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\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func InArray(v interface{}, in interface{}) (ok bool, i int) {\n\thaystack := reflect.Indirect(reflect.ValueOf(in))\n\tswitch haystack.Kind() {\n\tcase reflect.Slice, reflect.Array:\n\t\tfor ; i < haystack.Len(); i++ {\n\t\t\tif ok = v == haystack.Index(i).Interface(); ok {\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func isEq(f Array, s Array) bool {\n\tif len(f) != len(s) {\n\t\treturn false\n\t}\n\n\tfor idx, item := range f {\n\t\tif item != s[idx] {\n\t\t\treturn false\n\t\t}\n\t}\n\n\treturn true\n}", "func inSlice(v string, s []string) bool {\n\tfor _, scope := range s {\n\t\tif scope == v {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (ids WorkloadEndpointIdentifiers) NameMatches(name string) (bool, error) {\n\t// Extract the required segments for this orchestrator type.\n\treq, err := ids.getSegments()\n\tif err != nil {\n\t\treturn false, err\n\t}\n\n\t// Extract the parameters from the name.\n\tparts := ExtractDashSeparatedParms(name, len(req))\n\tif len(parts) == 0 {\n\t\treturn false, nil\n\t}\n\n\t// Check each name segment for a non-match.\n\tfor i, r := range req {\n\t\tif r.value != \"\" && r.value != parts[i] {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func isArrayKey(key string) bool {\n\treturn !isMapKey(key) && strings.HasSuffix(key, array)\n}", "func issafepoint(prog *obj.Prog) bool {\n\treturn prog.As == obj.ATEXT || prog.As == obj.ACALL\n}", "func contains(arr []string, v string) bool {\r\n\tfor _, s := range arr {\r\n\t\tif s == v {\r\n\t\t\treturn true\r\n\t\t}\r\n\t}\r\n\treturn false\r\n}", "func (o *WorkbookChart) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (o *SearchSLOResponseDataAttributesFacets) HasCreatorName() bool {\n\tif o != nil && o.CreatorName != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (f Unstructured) HasByName(field string) bool {\n\tif f.IsUndefined() {\n\t\treturn true\n\t}\n\t_, ok := f.fields[field]\n\treturn ok\n}", "func InArray(needle interface{}, haystack interface{}) bool {\n\tval := reflect.ValueOf(haystack)\n\tswitch val.Kind() {\n\tcase reflect.Slice, reflect.Array:\n\t\tfor i := 0; i < val.Len(); i++ {\n\t\t\tif reflect.DeepEqual(needle, val.Index(i).Interface()) {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\tcase reflect.Map:\n\t\tfor _, k := range val.MapKeys() {\n\t\t\tif reflect.DeepEqual(needle, val.MapIndex(k).Interface()) {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\tdefault:\n\t\tpanic(\"haystack: haystack type muset be slice, array or map\")\n\t}\n\n\treturn false\n}", "func InArray(val string, array []string) (exists bool, index int) {\n\texists = false\n\tindex = -1\n\tfor i, v := range array {\n\t\tif val == v {\n\t\t\tindex = i\n\t\t\texists = true\n\t\t\treturn\n\t\t}\n\t}\n\treturn\n}", "func isListType(v interface{}) bool {\n\treturn strings.HasPrefix(toString(v), \"[]\")\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 hasElem(array interface{}, elem interface{}) bool {\n\tarrV := reflect.ValueOf(array)\n\n\tif arrV.Kind() == reflect.Slice {\n\t\tfor i := 0; i < arrV.Len(); i++ {\n\t\t\tif arrV.Index(i).Interface() == elem {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\n\treturn false\n}", "func (ctx *ASTNodeTypeInfo) IsArray() bool {\n\t_, ok := ctx.Type.Underlying().(*types.Slice)\n\treturn ok\n}", "func isLabel(input string) bool {\n\tif len(input) > 0 {\n\t\tfor _, t := range labelList {\n\t\t\tif t == input {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\treturn false\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 isInArray(strArr []string, search string) bool {\n\tfor _, item := range strArr {\n\t\tif search == item {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func (o *V0037Node) HasName() bool {\n\tif o != nil && o.Name != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func IsArray(dt DataType) bool { return AsArray(dt) != nil }", "func (o *ShowPluginOptions) validateName(args []string) error {\n\tswitch len(args) {\n\tcase 0:\n\t\treturn fmt.Errorf(\"no name was specified\")\n\tcase 1:\n\t\to.Name = strings.ToLower(args[0])\n\t\treturn nil\n\tdefault:\n\t\treturn fmt.Errorf(\"only one positional argument may be specified, the name, but multiple were received: %s\", args)\n\n\t}\n}", "func IsVector(t Tuplelike) bool {\n\treturn t.At(3) == vectorW\n}", "func (o *EventsScalarQuery) HasName() bool {\n\treturn o != nil && o.Name != nil\n}", "func (v *testVolume) isLabel(label uint64, body *testBody) bool {\n\tnx := v.size[0]\n\tnxy := nx * v.size[1]\n\tfor _, span := range body.voxelSpans {\n\t\tz, y, x0, x1 := span.Unpack()\n\t\tp := (z*nxy + y*nx) * 8\n\t\tfor i := p + x0*8; i <= p+x1*8; i += 8 {\n\t\t\tcurLabel := binary.LittleEndian.Uint64(v.data[i : i+8])\n\t\t\tif curLabel != label {\n\t\t\t\treturn false\n\t\t\t}\n\t\t}\n\t}\n\treturn true\n}", "func (f *fieldRef) IsArray() bool {\n\treturn f.Meta.Type().Format().IsList()\n}", "func (ao *Array) Type() ObjectType { return ARRAY_OBJ }", "func isValueExistArray(a string, b []string) bool {\n\texist := false\n\tfor _, value := range b {\n\t\tif value == a {\n\t\t\texist = true\n\t\t\tbreak\n\t\t}\n\t}\n\treturn exist\n}", "func (o *GstObj) SetName(name string) bool {\n\ts := C.CString(name)\n\tdefer C.free(unsafe.Pointer(s))\n\treturn C.gst_object_set_name(o.g(), (*C.gchar)(s)) != 0\n}" ]
[ "0.5841462", "0.5635004", "0.5388105", "0.49901265", "0.4957508", "0.49247536", "0.4924174", "0.48913977", "0.4851098", "0.483455", "0.48001277", "0.47970814", "0.47970814", "0.47772264", "0.47765008", "0.47683877", "0.47553006", "0.47452325", "0.47421932", "0.4691339", "0.46901417", "0.46884894", "0.46641776", "0.46599606", "0.4657784", "0.4657784", "0.46473843", "0.46465644", "0.46368015", "0.46333334", "0.46319425", "0.46173972", "0.46143812", "0.46101892", "0.46054944", "0.4584281", "0.45784333", "0.45692143", "0.45664036", "0.45575115", "0.4554791", "0.4549286", "0.4541477", "0.45406", "0.45321882", "0.45116058", "0.45104074", "0.4498611", "0.4498611", "0.44969693", "0.4494218", "0.44929674", "0.44900894", "0.44894898", "0.44864437", "0.4478648", "0.44744575", "0.44739223", "0.4462619", "0.44537383", "0.44523692", "0.44490227", "0.44443667", "0.4442134", "0.44400087", "0.44389382", "0.44373724", "0.44363907", "0.4425457", "0.4424209", "0.4422722", "0.4421363", "0.44196343", "0.44161302", "0.4411856", "0.44067833", "0.4404812", "0.44041085", "0.44015664", "0.44011968", "0.43999654", "0.43979356", "0.43969333", "0.43969333", "0.4393819", "0.4388241", "0.43797517", "0.43680415", "0.43642107", "0.43626904", "0.43616077", "0.43513036", "0.43490824", "0.4346363", "0.4344985", "0.43396068", "0.433762", "0.43375453", "0.43358922" ]
0.5159486
4
specify the line stipple pattern
func LineStipple(factor int32, pattern uint16) { C.glowLineStipple(gpLineStipple, (C.GLint)(factor), (C.GLushort)(pattern)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func LineStipple(factor int32, pattern uint16) {\n\tsyscall.Syscall(gpLineStipple, 2, uintptr(factor), uintptr(pattern), 0)\n}", "func LineStipple(factor int32, pattern uint16) {\n C.glowLineStipple(gpLineStipple, (C.GLint)(factor), (C.GLushort)(pattern))\n}", "func PolygonStipple(mask *uint8) {\n C.glowPolygonStipple(gpPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func PolygonStipple(mask *uint8) {\n\tsyscall.Syscall(gpPolygonStipple, 1, uintptr(unsafe.Pointer(mask)), 0, 0)\n}", "func newLineDashPattern(dash, gap, phase int) *lineDashPattern {\n\treturn &lineDashPattern{dash, gap, phase}\n}", "func PolygonStipple(mask *uint8) {\n\tC.glowPolygonStipple(gpPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func line(m draw.Image, x0, y0, x1, y1 int, c color.Color) {\n\tabs := func(x int) int {\n\t\tif x < 0 {\n\t\t\treturn -x\n\t\t}\n\t\treturn x\n\t}\n\n\tvar dx, dy, sx, sy, e, e2 int\n\n\tdx = abs(x1 - x0)\n\tdy = -abs(y1 - y0)\n\tif sx = -1; x0 < x1 {\n\t\tsx = 1\n\t}\n\tif sy = -1; y0 < y1 {\n\t\tsy = 1\n\t}\n\te = dx + dy\n\tfor {\n\t\tm.Set(x0, y0, c)\n\t\tif x0 == x1 && y0 == y1 {\n\t\t\tbreak\n\t\t}\n\t\tif e2 = 2 * e; e2 >= dy {\n\t\t\te += dy\n\t\t\tx0 += sx\n\t\t} else if e2 <= dx {\n\t\t\te += dx\n\t\t\ty0 += sy\n\t\t}\n\t}\n}", "func hLine(rectImg *image.RGBA, color color.RGBA, x, y, length , width int) {\n\trectLine := image.NewRGBA(image.Rect(x, y, x+length, y+width))\n\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{color}, image.ZP, draw.Src)\n}", "func (el *Fill) Polyline() {}", "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 BLENDPS(i, mx, x operand.Op) { ctx.BLENDPS(i, mx, x) }", "func PBLENDW(i, mx, x operand.Op) { ctx.PBLENDW(i, mx, x) }", "func NewLineHatch(ifill interface{}, angle, distance, thickness float64) *HatchPattern {\n\tcell := Identity.Rotate(angle).Scale(distance, distance)\n\treturn NewHatchPattern(ifill, thickness, cell, func(x0, y0, x1, y1 float64) *Path {\n\t\tp := &Path{}\n\t\tfor y := math.Floor(y0); y <= y1; y += 1.0 {\n\t\t\tp.MoveTo(x0, y)\n\t\t\tp.LineTo(x1, y)\n\t\t}\n\t\treturn p\n\t})\n}", "func (self *Graphics) LineStyle(lineWidth int, color int, alpha int) *Graphics{\n return &Graphics{self.Object.Call(\"lineStyle\", lineWidth, color, alpha)}\n}", "func iLine(x1, y1, x2, y2 int, size float32, color color.RGBA) *canvas.Line {\n\tp1 := fyne.Position{X: float32(x1), Y: float32(y1)}\n\tp2 := fyne.Position{X: float32(x2), Y: float32(y2)}\n\tl := &canvas.Line{StrokeColor: color, StrokeWidth: size, Position1: p1, Position2: p2}\n\treturn l\n}", "func LineStyle(children ...Element) *CompoundElement { return newCE(\"LineStyle\", children) }", "func BLENDPD(i, mx, x operand.Op) { ctx.BLENDPD(i, mx, x) }", "func (h *HexWidget) SetSlant(s float32) {\n\th.hexOffset = s\n\th.Refresh()\n}", "func (s *Surface) StylePattern(t DrawType, p Pattern) {\n\tif p.Type == \"\" {\n\t\tp.Type = RepeatXY\n\t}\n\tpat := s.Ctx.Call(\"createPattern\", p.Source.Canvas, p.Type)\n\ts.Ctx.Set(string(t)+\"Style\", pat)\n}", "func GenerateLine(nodes int, spacing time.Duration) [][]time.Duration {\n\ttruth := make([][]time.Duration, nodes)\n\tfor i := range truth {\n\t\ttruth[i] = make([]time.Duration, nodes)\n\t}\n\n\tfor i := 0; i < nodes; i++ {\n\t\tfor j := i + 1; j < nodes; j++ {\n\t\t\trtt := time.Duration(j-i) * spacing\n\t\t\ttruth[i][j], truth[j][i] = rtt, rtt\n\t\t}\n\t}\n\treturn truth\n}", "func Line(emoji string, style Style, s string) FancyLine {\n\treturn FancyLine{\n\t\temoji: emoji,\n\t\tstyle: style,\n\t\tformat: \"%s\",\n\t\targs: []interface{}{s},\n\t}\n}", "func DrawHLine(m draw.Image, x1, y, x2 int) {\n\tfor ; x1 <= x2; x1++ {\n\t\tm.Set(x1, y, color.RGBA{0, 0, 255, 255})\n\t}\n}", "func newLine(page Page, startX, startY, endX, endY, lineWidth int) *line {\n\tstrokes := make([]int, 2)\n\tstrokes[0] = endX\n\tstrokes[1] = endY\n\treturn &line{\n\t\tgraphicsObject: graphicsObject{\n\t\t\tpage: page,\n\t\t},\n\t\tstartX: startX,\n\t\tstartY: startY,\n\t\tstrokes: strokes,\n\t\tcolor: newColorUndef(),\n\t\tlineWidth: lineWidth,\n\t\tlcs: lineCapStyleUndefined,\n\t\tljs: lineJoinStyleUndefined,\n\t}\n}", "func generateLineItems() []opts.LineData {\n\titems := make([]opts.LineData, 0)\n\tfor i := 0; i < 7; i++ {\n\t\titems = append(items, opts.LineData{Value: rand.Intn(300)})\n\t}\n\treturn items\n}", "func generateLineItems() []opts.LineData {\n\titems := make([]opts.LineData, 0)\n\tfor i := 0; i < 7; i++ {\n\t\titems = append(items, opts.LineData{Value: rand.Intn(300)})\n\t}\n\treturn items\n}", "func dline (x int, y int, height int) {\n\tadd := 1\n\tn := 0\n\theight += height % 2\n\tif height < 0 {\n\t\tadd = -1\n\t}\n\tfor n != height {\n\t\timg.Set(x, y - n, col)\n\t\timg.Set(x, y - n - add, col)\n\t\tx += 1;\n\t\tn += 2 * add\n\t}\n}", "func removeLineColor(list *tview.List, id int) {\n\tcurrentText, currentSecondary := list.GetItemText(id)\n\tre := regexp.MustCompile(`^\\[[a-zA-Z0-9:-]+\\]`)\n\ttmp := re.ReplaceAllString(currentText, \"${1}\")\n\tlist.SetItemText(id, tmp, currentSecondary)\n\n}", "func (self *Graphics) LineStyleI(args ...interface{}) *Graphics{\n return &Graphics{self.Object.Call(\"lineStyle\", args)}\n}", "func DrawLineSeries(r Renderer, canvasBox Box, xrange, yrange Range, s Style, vs ValueProvider) {\n\tif vs.Len() == 0 {\n\t\treturn\n\t}\n\n\tct := canvasBox.Top\n\tcb := canvasBox.Bottom\n\tcr := canvasBox.Right\n\n\tv0x, v0y := vs.GetValue(0)\n\tx0 := cr - xrange.Translate(v0x)\n\ty0 := yrange.Translate(v0y) + ct\n\n\tvar vx, vy float64\n\tvar x, y int\n\n\tfill := s.GetFillColor()\n\tif !fill.IsZero() {\n\t\tr.SetFillColor(fill)\n\t\tr.MoveTo(x0, y0)\n\t\tfor i := 1; i < vs.Len(); i++ {\n\t\t\tvx, vy = vs.GetValue(i)\n\t\t\tx = cr - xrange.Translate(vx)\n\t\t\ty = yrange.Translate(vy) + ct\n\t\t\tr.LineTo(x, y)\n\t\t}\n\t\tr.LineTo(x, cb)\n\t\tr.LineTo(x0, cb)\n\t\tr.Close()\n\t\tr.Fill()\n\t}\n\n\tstroke := s.GetStrokeColor()\n\tr.SetStrokeColor(stroke)\n\tr.SetStrokeWidth(s.GetStrokeWidth(DefaultStrokeWidth))\n\n\tr.MoveTo(x0, y0)\n\tfor i := 1; i < vs.Len(); i++ {\n\t\tvx, vy = vs.GetValue(i)\n\t\tx = cr - xrange.Translate(vx)\n\t\ty = yrange.Translate(vy) + ct\n\t\tr.LineTo(x, y)\n\t}\n\tr.Stroke()\n}", "func (me *TxsdPresentationAttributesFillStrokeStrokeLinecap) Set(s string) { (*xsdt.String)(me).Set(s) }", "func VBLENDPD(i, mxy, xy, xy1 operand.Op) { ctx.VBLENDPD(i, mxy, xy, xy1) }", "func VPBLENDD(i, mxy, xy, xy1 operand.Op) { ctx.VPBLENDD(i, mxy, xy, xy1) }", "func VBLENDPS(i, mxy, xy, xy1 operand.Op) { ctx.VBLENDPS(i, mxy, xy, xy1) }", "func GetPolygonStipple(mask *uint8) {\n C.glowGetPolygonStipple(gpGetPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func VPBLENDW(i, mxy, xy, xy1 operand.Op) { ctx.VPBLENDW(i, mxy, xy, xy1) }", "func HLine(img *image.RGBA, x1, y, x2 int, col color.Color) {\n\tfor ; x1 <= x2; x1++ {\n\t\timg.Set(x1, y, col)\n\t}\n}", "func (canvas *Canvas) Stroke(p *Path) {\n\tio.Copy(canvas.contents, &p.buf)\n\twriteCommand(canvas.contents, \"S\")\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 PCMPESTRI(i, mx, x operand.Op) { ctx.PCMPESTRI(i, mx, x) }", "func Draw(d Drawable, l rune, x, y int, r, g, b byte) error {\n\n\tfontLine := func(s string, x, y int) {\n\t\tfor _, l := range s {\n\t\t\tif l == '*' {\n\t\t\t\td.Set(x, y, color.NRGBA{r, g, b, 255})\n\t\t\t} else if l == '-' {\n\t\t\t\td.Set(x, y, color.NRGBA{r, g, b, 64})\n\t\t\t}\n\t\t\tx++\n\t\t}\n\t\treturn\n\t}\n\n\tswitch l {\n\tcase 'a':\n\t\tfontLine(\"***-\", x+1, y+1)\n\t\tfontLine(\"--**\", x+1, y+2)\n\t\tfontLine(\"-****\", x, y+3)\n\t\tfontLine(\"**-**-\", x, y+4)\n\t\tfontLine(\"-**-**\", x, y+5)\n\tcase 'A':\n\t\tfontLine(\"-**-\", x+1, y)\n\t\tfontLine(\"-****-\", x, y+1)\n\t\tfontLine(\"**--**\", x, y+2)\n\t\tfontLine(\"******\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"** **\", x, y+5)\n\tcase 'b':\n\t\tfontLine(\"***\", x, y)\n\t\tfontLine(\"-**-\", x, y+1)\n\t\tfontLine(\"****-\", x+1, y+2)\n\t\tfontLine(\"** **\", x+1, y+3)\n\t\tfontLine(\"-**-**\", x, y+4)\n\t\tfontLine(\"**-**-\", x, y+5)\n\tcase 'B':\n\t\tfontLine(\"*****-\", x, y)\n\t\tfontLine(\"-**-**\", x, y+1)\n\t\tfontLine(\"****-\", x+1, y+2)\n\t\tfontLine(\"** **\", x+1, y+3)\n\t\tfontLine(\"-** **\", x, y+4)\n\t\tfontLine(\"*****-\", x, y+5)\n\tcase 'c':\n\t\tfontLine(\"-****-\", x, y+1)\n\t\tfontLine(\"**--**\", x, y+2)\n\t\tfontLine(\"** ---\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 'C':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**- -*\", x, y+1)\n\t\tfontLine(\"**\", x, y+2)\n\t\tfontLine(\"**\", x, y+3)\n\t\tfontLine(\"**- -*\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 'd':\n\t\tfontLine(\"***\", x+3, y)\n\t\tfontLine(\"-**\", x+3, y+1)\n\t\tfontLine(\"-*****\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"** **\", x, y+4)\n\t\tfontLine(\"-***-*\", x, y+5)\n\tcase 'D':\n\t\tfontLine(\"****-\", x, y)\n\t\tfontLine(\"**-**-\", x, y+1)\n\t\tfontLine(\"** -**\", x, y+2)\n\t\tfontLine(\"** -**\", x, y+3)\n\t\tfontLine(\"**-**-\", x, y+4)\n\t\tfontLine(\"****-\", x, y+5)\n\tcase 'e':\n\t\tfontLine(\"-****-\", x, y+1)\n\t\tfontLine(\"** -**\", x, y+2)\n\t\tfontLine(\"******\", x, y+3)\n\t\tfontLine(\"**-\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 'E':\n\t\tfontLine(\"-*****\", x, y)\n\t\tfontLine(\"**---*\", x, y+1)\n\t\tfontLine(\"****-\", x, y+2)\n\t\tfontLine(\"**--\", x, y+3)\n\t\tfontLine(\"**- **\", x, y+4)\n\t\tfontLine(\"*****-\", x, y+5)\n\tcase 'f':\n\t\tfontLine(\"-***-\", x+1, y)\n\t\tfontLine(\"-**--*\", x, y+1)\n\t\tfontLine(\"****\", x, y+2)\n\t\tfontLine(\"-**-\", x, y+3)\n\t\tfontLine(\"**\", x+1, y+4)\n\t\tfontLine(\"****\", x, y+5)\n\tcase 'F':\n\t\tfontLine(\"*****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"**-\", x, y+2)\n\t\tfontLine(\"****\", x, y+3)\n\t\tfontLine(\"**-\", x, y+4)\n\t\tfontLine(\"*-\", x, y+5)\n\tcase 'g':\n\t\tfontLine(\"-**-**\", x, y+1)\n\t\tfontLine(\"** **-\", x, y+2)\n\t\tfontLine(\"-****\", x, y+3)\n\t\tfontLine(\"-**\", x+2, y+4)\n\t\tfontLine(\"****-\", x, y+5)\n\tcase 'G':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"**\", x, y+2)\n\t\tfontLine(\"** ***\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-***-*\", x, y+5)\n\tcase 'h':\n\t\tfontLine(\"***\", x, y)\n\t\tfontLine(\"-**-\", x, y+1)\n\t\tfontLine(\"****-\", x+1, y+2)\n\t\tfontLine(\"**-**\", x+1, y+3)\n\t\tfontLine(\"-** **\", x, y+4)\n\t\tfontLine(\"*** **\", x, y+5)\n\tcase 'H':\n\t\tfontLine(\"** **\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"******\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"** **\", x, y+4)\n\t\tfontLine(\"** **\", x, y+5)\n\tcase 'i':\n\t\tfontLine(\"**\", x+2, y)\n\t\tfontLine(\"--\", x+2, y+1)\n\t\tfontLine(\"***\", x+1, y+2)\n\t\tfontLine(\"-**\", x+1, y+3)\n\t\tfontLine(\"-**-\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase 'I':\n\t\tfontLine(\"****\", x+1, y)\n\t\tfontLine(\"-**-\", x+1, y+1)\n\t\tfontLine(\"**\", x+2, y+2)\n\t\tfontLine(\"**\", x+2, y+3)\n\t\tfontLine(\"-**-\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase 'j':\n\t\tfontLine(\"**\", x+3, y)\n\t\tfontLine(\"--\", x+3, y+1)\n\t\tfontLine(\"***\", x+2, y+2)\n\t\tfontLine(\"-**\", x+2, y+3)\n\t\tfontLine(\"**-**\", x, y+4)\n\t\tfontLine(\"-***-\", x, y+5)\n\tcase 'J':\n\t\tfontLine(\"****\", x+2, y)\n\t\tfontLine(\"-**-\", x+2, y+1)\n\t\tfontLine(\"**\", x+3, y+2)\n\t\tfontLine(\"** **\", x, y+3)\n\t\tfontLine(\"**-**\", x, y+4)\n\t\tfontLine(\"-***-\", x, y+5)\n\tcase 'k':\n\t\tfontLine(\"***\", x, y)\n\t\tfontLine(\"-**\", x, y+1)\n\t\tfontLine(\"**-**\", x+1, y+2)\n\t\tfontLine(\"****-\", x+1, y+3)\n\t\tfontLine(\"-**-**\", x, y+4)\n\t\tfontLine(\"*** **\", x, y+5)\n\tcase 'K':\n\t\tfontLine(\"***-**\", x, y)\n\t\tfontLine(\"-****-\", x, y+1)\n\t\tfontLine(\"***-\", x+1, y+2)\n\t\tfontLine(\"****-\", x+1, y+3)\n\t\tfontLine(\"-**-**\", x, y+4)\n\t\tfontLine(\"*** **\", x, y+5)\n\tcase 'l':\n\t\tfontLine(\"***\", x+1, y)\n\t\tfontLine(\"-**\", x+1, y+1)\n\t\tfontLine(\"**\", x+2, y+2)\n\t\tfontLine(\"**\", x+2, y+3)\n\t\tfontLine(\"-**-\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase 'L':\n\t\tfontLine(\"****\", x, y)\n\t\tfontLine(\"-**-\", x, y+1)\n\t\tfontLine(\"**\", x+1, y+2)\n\t\tfontLine(\"**\", x+1, y+3)\n\t\tfontLine(\"-**--*\", x, y+4)\n\t\tfontLine(\"******\", x, y+5)\n\tcase 'm':\n\t\tfontLine(\"**-**-\", x, y+1)\n\t\tfontLine(\"-*****\", x, y+2)\n\t\tfontLine(\"*-*-*\", x+1, y+3)\n\t\tfontLine(\"*-*-*\", x+1, y+4)\n\t\tfontLine(\"*-*-*\", x+1, y+5)\n\tcase 'M':\n\t\tfontLine(\"**-**\", x+1, y)\n\t\tfontLine(\"**-**\", x+1, y+1)\n\t\tfontLine(\"*-*-*\", x+1, y+2)\n\t\tfontLine(\"*- -*\", x+1, y+3)\n\t\tfontLine(\"*- -*\", x+1, y+4)\n\t\tfontLine(\"* *\", x+1, y+5)\n\tcase 'n':\n\t\tfontLine(\"**-**-\", x, y+1)\n\t\tfontLine(\"-*****\", x, y+2)\n\t\tfontLine(\"**-**\", x+1, y+3)\n\t\tfontLine(\"** **\", x+1, y+4)\n\t\tfontLine(\"** **\", x+1, y+5)\n\tcase 'N':\n\t\tfontLine(\"** **\", x, y)\n\t\tfontLine(\"**- **\", x, y+1)\n\t\tfontLine(\"***-**\", x, y+2)\n\t\tfontLine(\"**-***\", x, y+3)\n\t\tfontLine(\"** -**\", x, y+4)\n\t\tfontLine(\"** **\", x, y+5)\n\tcase 'o':\n\t\tfontLine(\"-****-\", x, y+1)\n\t\tfontLine(\"**--**\", x, y+2)\n\t\tfontLine(\"** **\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 'O':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"** **\", x, y+2)\n\t\tfontLine(\"** **\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 'p':\n\t\tfontLine(\"**-**-\", x, y+1)\n\t\tfontLine(\"-**--*\", x, y+2)\n\t\tfontLine(\"****\", x+1, y+3)\n\t\tfontLine(\"-**-\", x, y+4)\n\t\tfontLine(\"****\", x, y+5)\n\tcase 'P':\n\t\tfontLine(\"*****-\", x, y)\n\t\tfontLine(\"-**-**\", x, y+1)\n\t\tfontLine(\"****-\", x+1, y+2)\n\t\tfontLine(\"**-\", x+1, y+3)\n\t\tfontLine(\"-**-\", x, y+4)\n\t\tfontLine(\"****\", x, y+5)\n\tcase 'q':\n\t\tfontLine(\"-**-**\", x, y+1)\n\t\tfontLine(\"*--**-\", x, y+2)\n\t\tfontLine(\"-****\", x, y+3)\n\t\tfontLine(\"-**-\", x+2, y+4)\n\t\tfontLine(\"****\", x+2, y+5)\n\tcase 'Q':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"** -**\", x, y+2)\n\t\tfontLine(\"**-***\", x, y+3)\n\t\tfontLine(\"-****-\", x, y+4)\n\t\tfontLine(\"-**\", x+3, y+5)\n\tcase 'r':\n\t\tfontLine(\"**-**-\", x, y+1)\n\t\tfontLine(\"-*****\", x, y+2)\n\t\tfontLine(\"**--*\", x+1, y+3)\n\t\tfontLine(\"-**-\", x, y+4)\n\t\tfontLine(\"****\", x, y+5)\n\tcase 'R':\n\t\tfontLine(\"****-\", x, y)\n\t\tfontLine(\"-*--*-\", x, y+1)\n\t\tfontLine(\"*--*-\", x+1, y+2)\n\t\tfontLine(\"***-\", x+1, y+3)\n\t\tfontLine(\"-*-**-\", x, y+4)\n\t\tfontLine(\"**--**\", x, y+5)\n\tcase 's':\n\t\tfontLine(\"-*****\", x, y+1)\n\t\tfontLine(\"**-\", x, y+2)\n\t\tfontLine(\"-****-\", x, y+3)\n\t\tfontLine(\"-**\", x+3, y+4)\n\t\tfontLine(\"*****-\", x, y+5)\n\tcase 'S':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"-***-\", x, y+2)\n\t\tfontLine(\"-**-\", x+2, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 't':\n\t\tfontLine(\"-*\", x+1, y)\n\t\tfontLine(\"-**-\", x, y+1)\n\t\tfontLine(\"****\", x, y+2)\n\t\tfontLine(\"-**-\", x, y+3)\n\t\tfontLine(\"**-*\", x+1, y+4)\n\t\tfontLine(\"-**-\", x+1, y+5)\n\tcase 'T':\n\t\tfontLine(\"******\", x, y)\n\t\tfontLine(\"*-**-*\", x, y+1)\n\t\tfontLine(\"**\", x+2, y+2)\n\t\tfontLine(\"**\", x+2, y+3)\n\t\tfontLine(\"-**-\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase 'u':\n\t\tfontLine(\"** **\", x, y+1)\n\t\tfontLine(\"** **\", x, y+2)\n\t\tfontLine(\"** **\", x, y+3)\n\t\tfontLine(\"**-**-\", x, y+4)\n\t\tfontLine(\"-**-**\", x, y+5)\n\tcase 'U':\n\t\tfontLine(\"** **\", x, y)\n\t\tfontLine(\"** **\", x, y+1)\n\t\tfontLine(\"** **\", x, y+2)\n\t\tfontLine(\"** **\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase 'v':\n\t\tfontLine(\"** **\", x, y+1)\n\t\tfontLine(\"** **\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"-****-\", x, y+4)\n\t\tfontLine(\"-**-\", x+1, y+5)\n\tcase 'V':\n\t\tfontLine(\"** **\", x, y)\n\t\tfontLine(\"** **\", x, y+1)\n\t\tfontLine(\"** **\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"-****-\", x, y+4)\n\t\tfontLine(\"-**-\", x+1, y+5)\n\tcase 'w':\n\t\tfontLine(\"* *\", x+1, y+1)\n\t\tfontLine(\"*- -*\", x+1, y+2)\n\t\tfontLine(\"*-*-*\", x+1, y+3)\n\t\tfontLine(\"*-*-*\", x+1, y+4)\n\t\tfontLine(\"-*-*-\", x+1, y+5)\n\tcase 'W':\n\t\tfontLine(\"* *\", x+1, y)\n\t\tfontLine(\"*- -*\", x+1, y+1)\n\t\tfontLine(\"*- -*\", x+1, y+2)\n\t\tfontLine(\"*-*-*\", x+1, y+3)\n\t\tfontLine(\"**-**\", x+1, y+4)\n\t\tfontLine(\"-*-*-\", x+1, y+5)\n\tcase 'x':\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"-****-\", x, y+2)\n\t\tfontLine(\"-**-\", x+1, y+3)\n\t\tfontLine(\"-****-\", x, y+4)\n\t\tfontLine(\"**--**\", x, y+5)\n\tcase 'X':\n\t\tfontLine(\"**--**\", x, y)\n\t\tfontLine(\"-****-\", x, y+1)\n\t\tfontLine(\"-**-\", x+1, y+2)\n\t\tfontLine(\"-**-\", x+1, y+3)\n\t\tfontLine(\"-****-\", x, y+4)\n\t\tfontLine(\"**--**\", x, y+5)\n\tcase 'y':\n\t\tfontLine(\"** **\", x, y+1)\n\t\tfontLine(\"**--**\", x, y+2)\n\t\tfontLine(\"-****-\", x, y+3)\n\t\tfontLine(\"-*\", x+4, y+4)\n\t\tfontLine(\"*****-\", x, y+5)\n\tcase 'Y':\n\t\tfontLine(\"** **\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"-****-\", x, y+2)\n\t\tfontLine(\"-**-\", x+1, y+3)\n\t\tfontLine(\"-**-\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase 'z':\n\t\tfontLine(\"******\", x, y+1)\n\t\tfontLine(\"*--**-\", x, y+2)\n\t\tfontLine(\"-**-\", x+1, y+3)\n\t\tfontLine(\"-**--*\", x, y+4)\n\t\tfontLine(\"******\", x, y+5)\n\tcase 'Z':\n\t\tfontLine(\"******\", x, y)\n\t\tfontLine(\"*- -**\", x, y+1)\n\t\tfontLine(\"-**-\", x+2, y+2)\n\t\tfontLine(\"-**-\", x+1, y+3)\n\t\tfontLine(\"-**--*\", x, y+4)\n\t\tfontLine(\"******\", x, y+5)\n\tcase 'æ':\n\t\tfontLine(\"****-\", x, y+1)\n\t\tfontLine(\"-*-*\", x+1, y+2)\n\t\tfontLine(\"-***-\", x, y+3)\n\t\tfontLine(\"*-*-\", x, y+4)\n\t\tfontLine(\"-****\", x, y+5)\n\tcase 'Æ':\n\t\tfontLine(\"-*****\", x, y)\n\t\tfontLine(\"**-**-\", x, y+1)\n\t\tfontLine(\"******\", x, y+2)\n\t\tfontLine(\"**-**-\", x, y+3)\n\t\tfontLine(\"** **-\", x, y+4)\n\t\tfontLine(\"** ***\", x, y+5)\n\tcase 'ø':\n\t\tfontLine(\"-***-*\", x, y+1)\n\t\tfontLine(\"*--**-\", x, y+2)\n\t\tfontLine(\"*-**-*\", x, y+3)\n\t\tfontLine(\"-**--*\", x, y+4)\n\t\tfontLine(\"*-***-\", x, y+5)\n\tcase 'Ø':\n\t\tfontLine(\"-***-*\", x, y)\n\t\tfontLine(\"*--**-\", x, y+1)\n\t\tfontLine(\"*-**-*\", x, y+2)\n\t\tfontLine(\"*-**-*\", x, y+3)\n\t\tfontLine(\"-**--*\", x, y+4)\n\t\tfontLine(\"*-***-\", x, y+5)\n\tcase 'å':\n\t\tfontLine(\"-**-\", x+1, y)\n\t\tfontLine(\"***-\", x+1, y+1)\n\t\tfontLine(\"--**\", x+1, y+2)\n\t\tfontLine(\"-****\", x, y+3)\n\t\tfontLine(\"**-**-\", x, y+4)\n\t\tfontLine(\"-**-**\", x, y+5)\n\tcase 'Å':\n\t\tfontLine(\"**\", x+2, y)\n\t\tfontLine(\"--\", x+2, y+1)\n\t\tfontLine(\"-****-\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"******\", x, y+4)\n\t\tfontLine(\"**--**\", x, y+5)\n\tcase '.':\n\t\tfontLine(\"**-\", x+1, y+4)\n\t\tfontLine(\"-**\", x, y+5)\n\tcase ':':\n\t\tfontLine(\"**-\", x+1, y)\n\t\tfontLine(\"-**\", x, y+1)\n\t\tfontLine(\"**-\", x+1, y+4)\n\t\tfontLine(\"-**\", x, y+5)\n\tcase ';':\n\t\tfontLine(\"**-\", x+1, y)\n\t\tfontLine(\"-**\", x, y+1)\n\t\tfontLine(\"-*\", x+1, y+4)\n\t\tfontLine(\"*-\", x+1, y+5)\n\tcase ',':\n\t\tfontLine(\"-*\", x+1, y+4)\n\t\tfontLine(\"*-\", x+1, y+5)\n\tcase '\\'':\n\t\tfontLine(\"-*\", x+1, y)\n\t\tfontLine(\"*-\", x+1, y+1)\n\tcase '\"':\n\t\tfontLine(\"-* -*\", x, y)\n\t\tfontLine(\"*- *-\", x, y+1)\n\tcase '→':\n\t\tfontLine(\"-*-\", x+2, y)\n\t\tfontLine(\"-*-\", x+3, y+1)\n\t\tfontLine(\"******\", x, y+2)\n\t\tfontLine(\"-*-\", x+3, y+3)\n\t\tfontLine(\"-*-\", x+2, y+4)\n\tcase '*':\n\t\tfontLine(\"* *\", x+2, y+1)\n\t\tfontLine(\" *\", x+2, y+2)\n\t\tfontLine(\"* *\", x+2, y+3)\n\tcase '+':\n\t\tfontLine(\" *\", x, y)\n\t\tfontLine(\" *\", x, y+1)\n\t\tfontLine(\"*****\", x, y+2)\n\t\tfontLine(\" *\", x, y+3)\n\t\tfontLine(\" *\", x, y+4)\n\tcase '!':\n\t\tfontLine(\"**\", x+1, y)\n\t\tfontLine(\"-**-\", x, y+1)\n\t\tfontLine(\"-**-\", x, y+2)\n\t\tfontLine(\"**\", x+1, y+3)\n\t\tfontLine(\"--\", x+1, y+4)\n\t\tfontLine(\"**\", x+1, y+5)\n\tcase '?':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"-**-\", x+2, y+2)\n\t\tfontLine(\"**-\", x+2, y+3)\n\t\tfontLine(\"--\", x+2, y+4)\n\t\tfontLine(\"**\", x+2, y+5)\n\tcase '-':\n\t\tfontLine(\"-****-\", x, y+3)\n\tcase '=':\n\t\tfontLine(\"-****-\", x, y+2)\n\t\tfontLine(\"-****-\", x, y+4)\n\tcase '_':\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase '/':\n\t\tfontLine(\"*\", x+4, y+1)\n\t\tfontLine(\"*-\", x+3, y+2)\n\t\tfontLine(\"*-\", x+2, y+3)\n\t\tfontLine(\"*-\", x+1, y+4)\n\t\tfontLine(\"*-\", x, y+5)\n\tcase '1':\n\t\tfontLine(\"-**\", x+1, y)\n\t\tfontLine(\"***\", x+1, y+1)\n\t\tfontLine(\"-**\", x+1, y+2)\n\t\tfontLine(\"**\", x+2, y+3)\n\t\tfontLine(\"**-\", x+2, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase '2':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"*- -**\", x, y+1)\n\t\tfontLine(\"-**-\", x+2, y+2)\n\t\tfontLine(\"-**-\", x+1, y+3)\n\t\tfontLine(\"-**--*\", x, y+4)\n\t\tfontLine(\"******\", x, y+5)\n\tcase '3':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"**-\", x+3, y+2)\n\t\tfontLine(\"-**\", x+3, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase '4':\n\t\tfontLine(\"-***\", x+1, y)\n\t\tfontLine(\"-*-**\", x, y+1)\n\t\tfontLine(\"*--**-\", x, y+2)\n\t\tfontLine(\"******\", x, y+3)\n\t\tfontLine(\"-**-\", x+2, y+4)\n\t\tfontLine(\"****\", x+2, y+5)\n\tcase '5':\n\t\tfontLine(\"******\", x, y)\n\t\tfontLine(\"**-\", x, y+1)\n\t\tfontLine(\"*****-\", x, y+2)\n\t\tfontLine(\"-**\", x+3, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase '6':\n\t\tfontLine(\"-***\", x+1, y)\n\t\tfontLine(\"-**-\", x, y+1)\n\t\tfontLine(\"**-\", x, y+2)\n\t\tfontLine(\"*****-\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase '7':\n\t\tfontLine(\"******\", x, y)\n\t\tfontLine(\"*- -**\", x, y+1)\n\t\tfontLine(\"-**\", x+3, y+2)\n\t\tfontLine(\"-**-\", x+2, y+3)\n\t\tfontLine(\"**-\", x+2, y+4)\n\t\tfontLine(\"**\", x+2, y+5)\n\tcase '8':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"-****-\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase '9':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"-*****\", x, y+2)\n\t\tfontLine(\"-**\", x+3, y+3)\n\t\tfontLine(\"-**-\", x+2, y+4)\n\t\tfontLine(\"-***-\", x, y+5)\n\tcase '0':\n\t\tfontLine(\"-****-\", x, y)\n\t\tfontLine(\"**--**\", x, y+1)\n\t\tfontLine(\"**--**\", x, y+2)\n\t\tfontLine(\"**--**\", x, y+3)\n\t\tfontLine(\"**--**\", x, y+4)\n\t\tfontLine(\"-****-\", x, y+5)\n\tcase '(':\n\t\tfontLine(\"-***\", x+2, y)\n\t\tfontLine(\"**-\", x+2, y+1)\n\t\tfontLine(\"**-\", x+1, y+2)\n\t\tfontLine(\"**-\", x+1, y+3)\n\t\tfontLine(\"**-\", x+2, y+4)\n\t\tfontLine(\"-***\", x+2, y+5)\n\tcase ')':\n\t\tfontLine(\"***-\", x, y)\n\t\tfontLine(\"-**\", x+1, y+1)\n\t\tfontLine(\"-**\", x+2, y+2)\n\t\tfontLine(\"-**\", x+2, y+3)\n\t\tfontLine(\"-**\", x+1, y+4)\n\t\tfontLine(\"***-\", x, y+5)\n\tcase '{':\n\t\tfontLine(\"-**\", x+2, y)\n\t\tfontLine(\"*\", x+2, y+1)\n\t\tfontLine(\"*\", x+2, y+2)\n\t\tfontLine(\"*\", x+1, y+3)\n\t\tfontLine(\"*\", x+2, y+4)\n\t\tfontLine(\"*\", x+2, y+5)\n\t\tfontLine(\"-**\", x+2, y+6)\n\tcase '}':\n\t\tfontLine(\"**-\", x+1, y)\n\t\tfontLine(\"*\", x+3, y+1)\n\t\tfontLine(\"*\", x+3, y+2)\n\t\tfontLine(\"*\", x+4, y+3)\n\t\tfontLine(\"*\", x+3, y+4)\n\t\tfontLine(\"*\", x+3, y+5)\n\t\tfontLine(\"**-\", x+1, y+6)\n\tcase '[':\n\t\tfontLine(\"****\", x+1, y)\n\t\tfontLine(\"**\", x+1, y+1)\n\t\tfontLine(\"**\", x+1, y+2)\n\t\tfontLine(\"**\", x+1, y+3)\n\t\tfontLine(\"**\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase ']':\n\t\tfontLine(\"****\", x+1, y)\n\t\tfontLine(\" **\", x+1, y+1)\n\t\tfontLine(\" **\", x+1, y+2)\n\t\tfontLine(\" **\", x+1, y+3)\n\t\tfontLine(\" **\", x+1, y+4)\n\t\tfontLine(\"****\", x+1, y+5)\n\tcase '<':\n\t\tfontLine(\" *-\", x+2, y+1)\n\t\tfontLine(\" *-\", x+2, y+2)\n\t\tfontLine(\"*-\", x+2, y+3)\n\t\tfontLine(\" *-\", x+2, y+4)\n\t\tfontLine(\" *-\", x+2, y+5)\n\tcase '>':\n\t\tfontLine(\"-*\", x+2, y+1)\n\t\tfontLine(\"-*\", x+3, y+2)\n\t\tfontLine(\" -*\", x+3, y+3)\n\t\tfontLine(\"-*\", x+3, y+4)\n\t\tfontLine(\"-*\", x+2, y+5)\n\tcase '&':\n\t\tfontLine(\" **\", x, y)\n\t\tfontLine(\"** *\", x, y+1)\n\t\tfontLine(\" ** *\", x, y+2)\n\t\tfontLine(\" **-*\", x, y+3)\n\t\tfontLine(\"* **\", x, y+4)\n\t\tfontLine(\" ** **\", x, y+5)\n\tcase '|':\n\t\tfontLine(\"*\", x+3, y)\n\t\tfontLine(\"*\", x+3, y+1)\n\t\tfontLine(\"*\", x+3, y+2)\n\t\tfontLine(\"*\", x+3, y+3)\n\t\tfontLine(\"*\", x+3, y+4)\n\t\tfontLine(\"*\", x+3, y+5)\n\tcase '\\\\':\n\t\tfontLine(\"**\", x+1, y+1)\n\t\tfontLine(\"-**\", x+1, y+2)\n\t\tfontLine(\"-**\", x+2, y+3)\n\t\tfontLine(\"-**\", x+3, y+4)\n\t\tfontLine(\"-**\", x+4, y+5)\n\n\tcase 0:\n\t\treturn errors.New(\"the rune was 0. Did you pass a coordinate instead of a rune?\")\n\tdefault:\n\t\treturn fmt.Errorf(\"rune %s is not available\", string(l))\n\t}\n\treturn nil\n}", "func vLine(rectImg *image.RGBA, color color.RGBA, x, y, length , width int) {\n\trectLine := image.NewRGBA(image.Rect(x, y, x+width, y+length))\n\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{color}, image.ZP, draw.Src)\n}", "func fillLine(rowCounter int) bool {\n\tif (rowCounter+1)%3 == 0 { // fill every 3rd row only\n\t\treturn true\n\t} else {\n\t\treturn false\n\t}\n}", "func (vr *vectorRenderer) Stroke() {\n\tvr.drawPath(vr.s.SVGStroke())\n}", "func (p *Page) Stroke() {\n\tfmt.Fprint(p.contents, \"S\\n\")\n}", "func drawLine(w, y int, ln line) int {\n\t// figure out whether the line needs to be shortened\n\tvar truncLen int\n\ttruncIndex := -1\n\tlineWidth := 0\n\tfor _, seg := range ln {\n\t\tlineWidth += len(seg.text)\n\t}\n\tif lineWidth > w-2 {\n\t\t// figure out which segment to shorten\n\t\ttruncIndex = len(ln) - 1\n\t\tfor i, seg := range ln {\n\t\t\tif seg.el != ellipsisNone {\n\t\t\t\ttruncIndex = i\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t\t// figure out by how much to shorten it\n\t\ttruncLen = len(ln[truncIndex].text) - (lineWidth - (w - 2) + 3)\n\t\tif truncLen < 0 {\n\t\t\ttruncLen = 0\n\t\t}\n\t}\n\n\t// draw characters\n\tx := 0\n\tfor i, seg := range ln {\n\t\ttext := seg.text\n\n\t\t// ...text\n\t\tif i == truncIndex {\n\t\t\tif seg.el == ellipsisLeft {\n\t\t\t\tx = drawEllipsis(x, y, seg.fg, seg.bg)\n\t\t\t\ttext = text[len(text)-truncLen:]\n\t\t\t} else {\n\t\t\t\ttext = text[:truncLen]\n\t\t\t}\n\t\t}\n\n\t\tfor _, ch := range text {\n\t\t\ttermbox.SetCell(x, y, ch, seg.fg, seg.bg)\n\t\t\tx++\n\t\t}\n\n\t\t// text...\n\t\tif i == truncIndex && seg.el != ellipsisLeft {\n\t\t\tx = drawEllipsis(x, y, seg.fg, seg.bg)\n\t\t}\n\t}\n\n\treturn x\n}", "func (dw *DrawingWand) PushPattern(patternId string, x, y, width, height float64) {\n\tcstr := C.CString(patternId)\n\tdefer C.free(unsafe.Pointer(cstr))\n\tC.MagickDrawPushPattern(dw.dw, cstr, C.double(x), C.double(y), C.double(width), C.double(height))\n}", "func drawLine(screen []byte, width, x1, x2, y int) []byte {\n\tbytesPerRow := width / 8\n\tbyteAtRowStart := y * bytesPerRow\n\tminByteInRow := x1 / 8\n\tmaxByteInRow := x2 / 8\n\tminByte := byteAtRowStart + minByteInRow\n\tmaxByte := byteAtRowStart + maxByteInRow\n\tminByteMinBit := x1 % 8\n\tmaxByteMaxBit := x2 % 8\n\t// TODO: Error handling.\n\tfor i := minByte; i <= maxByte; i++ {\n\t\tminBit := 0\n\t\tif i == minByte {\n\t\t\tminBit = minByteMinBit\n\t\t}\n\t\tmaxBit := 7\n\t\tif i == maxByte {\n\t\t\tmaxBit = maxByteMaxBit\n\t\t}\n\t\tfor j := minBit; j <= maxBit; j++ {\n\t\t\t// setBit indexes from right to left so we need to reverse the bits\n\t\t\t// before and after.\n\t\t\tscreen[i] = reverseBits(byte(setBit(int(reverseBits(screen[i])), j, 1)))\n\t\t}\n\t}\n\treturn screen\n}", "func (dw *DrawingWand) Line(sx, sy, ex, ey float64) {\n\tC.MagickDrawLine(dw.dw, C.double(sx), C.double(sy), C.double(ex), C.double(ey))\n}", "func (p *Projection) line(w1x float64, w1y float64, w2x float64, w2y float64, col color.RGBA) {\n c1x, c1y := p.project(w1x, w1y)\n c2x, c2y := p.project(w2x, w2y)\n\n c := draw2d.NewGraphicContext(p.img)\n c.SetStrokeColor(col)\n c.SetLineWidth(1)\n\n c.MoveTo(c1x, c1y)\n c.LineTo(c2x, c2y)\n c.Stroke()\n}", "func AbsLine(cont *fyne.Container, x1, y1, x2, y2 int, size float32, color color.RGBA) {\n\n\t//\tcurrently there is a cap of StrokeWidth > 10 for straight lines, so make rectangles\n\t//\tTODO: remove this special case when the bug is fixed.\n\t// if x1 == x2 && size > 10 { // vertical line\n\t// \tlineLength := y2 - y1\n\t// \tAbsRect(cont, x1, y1+(lineLength/2), int(size), lineLength, color)\n\t// \treturn\n\t// }\n\t// if y1 == y2 && size > 10 { // horizontal line\n\t// \tlineLength := x2 - x1\n\t// \tAbsRect(cont, x1+(lineLength/2), y1, lineLength, int(size), color)\n\t// \treturn\n\t// }\n\tp1 := fyne.Position{X: float32(x1), Y: float32(y1)}\n\tp2 := fyne.Position{X: float32(x2), Y: float32(y2)}\n\tcont.AddObject(&canvas.Line{StrokeColor: color, StrokeWidth: size, Position1: p1, Position2: p2})\n}", "func drawPath() {\n\tdest := image.NewRGBA(image.Rect(0, 0, 1200, 1200.0))\n\tgc := draw2dimg.NewGraphicContext(dest)\n\tgc.SetStrokeColor(color.Black)\n\tgc.SetLineWidth(1)\n\n\tgc.MoveTo(0, 0)\n\tfor i := 0; i < len(xyInput); i++ {\n\t\tgc.LineTo(float64(xyInput[i].gx), float64(xyInput[i].gy))\n\n\t}\n\n\tgc.Close()\n\tgc.FillStroke()\n\n\tdraw2dimg.SaveToPngFile(\"pathline.png\", dest)\n}", "func PBLENDVB(x, mx, x1 operand.Op) { ctx.PBLENDVB(x, mx, x1) }", "func renderTexturedLine(x, y float64, imd *imdraw.IMDraw) {\n\timd.Intensity = 1.\n\timd.Picture = pixel.V(x, 0)\n\timd.Push(pixel.V(x, 0))\n\timd.Picture = pixel.V(x+1, y)\n\timd.Push(pixel.V(x+1, y))\n\timd.Rectangle(0)\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 NewLineNoise() *Linenoise {\n\tl := Linenoise{}\n\tl.historyMaxlen = 32\n\treturn &l\n}", "func (re renderEdge) render(row string, vertIdx, vertDist int) string {\n\tsetEdgeChar := func(s string, i int, r rune) string {\n\t\tif s[i] == byte(r) {\n\t\t\treturn s\n\t\t} else if s[i] == ' ' {\n\t\t\treturn s[:i] + string(r) + s[i+1:]\n\t\t}\n\t\treturn s[:i] + \"+\" + s[i+1:] // set the coordinate to \"+\" if there's an edge crossing\n\t}\n\tif re.src == re.dest {\n\t\treturn setEdgeChar(row, re.src, '|')\n\t}\n\tconst srcEdgeCenterOffset = 1 // start drawing a diagonal edge one space away from the center of a node\n\tadjustedXDist := re.distance() - srcEdgeCenterOffset // number of horizontal spaces we must fill with edges\n\t// vertical line\n\tif vertDist > adjustedXDist && vertIdx >= adjustedXDist/2 && vertIdx < vertDist-adjustedXDist/2 {\n\t\treturn setEdgeChar(row, (re.src+re.dest)/2, '|')\n\t}\n\t// horizontal line\n\tif vertDist < adjustedXDist && vertIdx == vertDist/2 {\n\t\tstep := 1\n\t\tif re.src > re.dest {\n\t\t\tstep = -1\n\t\t}\n\t\tdiagCoverage := (vertDist / 2) * step\n\t\ttmp := re.src + diagCoverage\n\t\tfor tmp != re.dest-diagCoverage-(step*vertDist%2) {\n\t\t\ttmp += step\n\t\t\trow = setEdgeChar(row, tmp, '-')\n\t\t}\n\t\treturn row\n\t}\n\t// diagonal line\n\toffset := vertIdx + srcEdgeCenterOffset\n\t// calculate offset based on distance from the end in case we're on the bottom half of the edge\n\tif vertIdx > vertDist/2 {\n\t\toffset = adjustedXDist - (vertDist - offset)\n\t}\n\tif re.src > re.dest {\n\t\treturn setEdgeChar(row, re.src-offset, '/')\n\t} else {\n\t\treturn setEdgeChar(row, re.src+offset, '\\\\')\n\t}\n}", "func (r *ride) unshiftLines() Line {\n\tline, lines := r.lines[0], r.lines[1:]\n\tr.lines = lines\n\treturn line\n}", "func (p *HatchPattern) Tile(clip *Path) *Path {\n\tdst := clip.FastBounds()\n\n\t// find extremes along cell axes\n\tinvCell := p.cell.Inv()\n\tpoints := []Point{\n\t\tinvCell.Dot(Point{dst.X - p.Thickness, dst.Y - p.Thickness}),\n\t\tinvCell.Dot(Point{dst.X + dst.W + p.Thickness, dst.Y - p.Thickness}),\n\t\tinvCell.Dot(Point{dst.X + dst.W + p.Thickness, dst.Y + dst.H + p.Thickness}),\n\t\tinvCell.Dot(Point{dst.X - p.Thickness, dst.Y + dst.H + p.Thickness}),\n\t}\n\tx0, x1 := points[0].X, points[0].X\n\ty0, y1 := points[0].Y, points[0].Y\n\tfor _, point := range points[1:] {\n\t\tx0 = math.Min(x0, point.X)\n\t\tx1 = math.Max(x1, point.X)\n\t\ty0 = math.Min(y0, point.Y)\n\t\ty1 = math.Max(y1, point.Y)\n\t}\n\n\thatch := p.hatch(x0, y0, x1, y1)\n\thatch = hatch.Transform(p.cell)\n\thatch = hatch.And(clip)\n\tif p.Thickness != 0.0 {\n\t\thatch = hatch.Stroke(p.Thickness, ButtCap, MiterJoin, 0.01)\n\t}\n\treturn hatch\n}", "func (s *SVG) Line(p0, p1 sdf.V2) {\n\tif len(s.p0s) == 0 {\n\t\ts.min = p0.Min(p1)\n\t\ts.max = p0.Max(p1)\n\t} else {\n\t\ts.min = s.min.Min(p0)\n\t\ts.min = s.min.Min(p1)\n\t\ts.max = s.max.Max(p0)\n\t\ts.max = s.max.Max(p1)\n\t}\n\ts.p0s = append(s.p0s, p0)\n\ts.p1s = append(s.p1s, p1)\n}", "func (p *Pattern) Rep(min, max int) *Pattern {\n\treturn Rep(p, min, max)\n}", "func Line() string {\n\treturn \"================================================================================\"\n}", "func (rg Range) Line(y int) Range {\n\tif rg.Min.Shift(0, y).In(rg) {\n\t\trg.Min.Y = rg.Min.Y + y\n\t\trg.Max.Y = rg.Min.Y + 1\n\t} else {\n\t\trg = Range{}\n\t}\n\treturn rg\n}", "func (imd *IMDraw) Line(thickness float64) {\n\timd.polyline(thickness, false)\n}", "func PitchPatternAt(p synth.Pitch, n int) Option {\n\treturn func(g Generator) {\n\t\tif hpp, ok := g.(HasPitches); ok {\n\t\t\tpitches := hpp.GetPitchPattern()\n\t\t\tif len(pitches) < n {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tpitches[n] = p\n\t\t\thpp.SetPitchPattern(pitches)\n\t\t}\n\t}\n}", "func (el *Fill) Path() {}", "func (r *Renderer) line(context js.Value, thick int, x1, y1, x2, y2 int) {\n\tcontext.Call(\"moveTo\", nudge(x1, thick)*r.PixelRatio, nudge(y1, thick)*r.PixelRatio)\n\tcontext.Call(\"lineTo\", nudge(x2, thick)*r.PixelRatio, nudge(y2, thick)*r.PixelRatio)\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 DrawThickLine(rgba *image.RGBA, x1, y1, x2, y2 int, c color.Color, thickness int) {\n\n\txDelta := math.Abs(float64(x2 - x1))\n\tyDelta := math.Abs(float64(y2 - y1))\n\n\txSlope := -1\n\tif x2 < x1 {\n\t\txSlope = 1\n\t}\n\tySlope := -1\n\tif y2 < y1 {\n\t\tySlope = 1\n\t}\n\n\terr := xDelta - yDelta\n\tvar err2 float64\n\tfor i := 0; true; i++ {\n\n\t\tfor xm := x2 - thickness; xm <= (x2 + thickness); xm++ {\n\t\t\tfor ym := y2 - thickness; ym <= (y2 + thickness); ym++ {\n\t\t\t\trgba.Set(xm, ym, c)\n\t\t\t}\n\t\t}\n\t\tif x2 == x1 && y2 == y1 {\n\t\t\tbreak\n\t\t}\n\t\terr2 = 2 * err\n\t\tif err2 > -1*yDelta {\n\t\t\terr -= yDelta\n\t\t\tx2 += xSlope\n\t\t}\n\t\tif err2 < xDelta {\n\t\t\terr += xDelta\n\t\t\ty2 += ySlope\n\t\t}\n\t}\n}", "func Linef(emoji string, style Style, format string, a ...interface{}) FancyLine {\n\targs := make([]interface{}, len(a))\n\tfor i := range a {\n\t\targs[i] = a[i]\n\t}\n\n\treturn FancyLine{\n\t\temoji: emoji,\n\t\tstyle: style,\n\t\tformat: format,\n\t\targs: args,\n\t}\n}", "func drawPhysLine(rgba *image.RGBA, x0, y0, x1, y1 int, col color.Color) {\n\tdx := x1 - x0\n\tif dx < 0 {\n\t\tdx = -dx\n\t}\n\tdy := y1 - y0\n\tif dy < 0 {\n\t\tdy = -dy\n\t}\n\tvar sx, sy int\n\tif x0 < x1 {\n\t\tsx = 1\n\t} else {\n\t\tsx = -1\n\t}\n\tif y0 < y1 {\n\t\tsy = 1\n\t} else {\n\t\tsy = -1\n\t}\n\terr := dx - dy\n\tfor {\n\t\trgba.Set(x0, y0, col)\n\t\tif x0 == x1 && y0 == y1 {\n\t\t\tbreak\n\t\t}\n\t\te2 := 2 * err\n\t\tif e2 > -dy {\n\t\t\terr -= dy\n\t\t\tx0 += sx\n\t\t}\n\t\tif e2 < dx {\n\t\t\terr += dx\n\t\t\ty0 += sy\n\t\t}\n\t}\n}", "func SlopeInd(m, xc, yc, xlen float64, lbl string, flip, xlog, ylog bool, args, argsLbl *A) {\n\tif args == nil {\n\t\targs = &A{C: \"k\"}\n\t}\n\targs.NoClip = true\n\tl := 0.5 * xlen\n\tx := []float64{xc - l, xc + l, xc + l, xc - l}\n\ty := []float64{yc - m*l, yc - m*l, yc + m*l, yc - m*l}\n\tif flip {\n\t\tx[1] = xc - l\n\t\ty[1] = yc + m*l\n\t}\n\tdx, dy := x[2]-x[0], y[2]-y[0]\n\td := 0.03 * math.Sqrt(dx*dx+dy*dy)\n\txm := xc - l - d\n\txp := xc + l + d\n\tym := yc + m*l - d\n\typ := yc + m*l + d\n\tyr := yc - m*l + d\n\tys := yc - m*l - d\n\tif xlog {\n\t\tfor i := 0; i < 4; i++ {\n\t\t\tx[i] = math.Pow(10.0, x[i])\n\t\t}\n\t\txc = math.Pow(10.0, xc)\n\t\txm = math.Pow(10.0, xm)\n\t\txp = math.Pow(10.0, xp)\n\t}\n\tif ylog {\n\t\tfor i := 0; i < 4; i++ {\n\t\t\ty[i] = math.Pow(10.0, y[i])\n\t\t}\n\t\tyc = math.Pow(10.0, yc)\n\t\tym = math.Pow(10.0, ym)\n\t\typ = math.Pow(10.0, yp)\n\t\tyr = math.Pow(10.0, yr)\n\t\tys = math.Pow(10.0, ys)\n\t}\n\tPlot(x, y, args)\n\tif lbl != \"\" {\n\t\tif argsLbl == nil {\n\t\t\targsLbl = &A{C: \"k\", Fsz: 6}\n\t\t}\n\t\targsLbl.NoClip = true\n\t\tif flip {\n\t\t\targsLbl.Ha = \"center\"\n\t\t\tif m < 0 {\n\t\t\t\targsLbl.Va = \"top\"\n\t\t\t\tText(xc, ym, \"1\", argsLbl)\n\t\t\t} else {\n\t\t\t\targsLbl.Va = \"bottom\"\n\t\t\t\tText(xc, yp, \"1\", argsLbl)\n\t\t\t}\n\t\t\targsLbl.Ha = \"right\"\n\t\t\targsLbl.Va = \"center\"\n\t\t\tText(xm, yc, lbl, argsLbl)\n\t\t} else {\n\t\t\targsLbl.Ha = \"center\"\n\t\t\tif m < 0 {\n\t\t\t\targsLbl.Va = \"bottom\"\n\t\t\t\tText(xc, yr, \"1\", argsLbl)\n\t\t\t} else {\n\t\t\t\targsLbl.Va = \"top\"\n\t\t\t\tText(xc, ys, \"1\", argsLbl)\n\t\t\t}\n\t\t\targsLbl.Ha = \"left\"\n\t\t\targsLbl.Va = \"center\"\n\t\t\tText(xp, yc, lbl, argsLbl)\n\t\t}\n\t}\n}", "func (p linear) getInfill(layerNr int, outline clipper.Path, holes clipper.Paths, overlap float32) clipper.Paths {\n\tvar result clipper.Paths\n\n\t// clip the paths with the lines using intersection\n\texset := clipper.Paths{outline}\n\n\tco := clipper.NewClipperOffset()\n\tcl := clipper.NewClipper(clipper.IoNone)\n\n\t// generate the ex-set for the overlap (only if needed)\n\tif overlap != 0 {\n\t\tco.AddPaths(exset, clipper.JtSquare, clipper.EtClosedPolygon)\n\t\tco.MiterLimit = 2\n\t\texset = co.Execute(float64(-overlap))\n\n\t\tco.Clear()\n\t\tco.AddPaths(holes, clipper.JtSquare, clipper.EtClosedPolygon)\n\t\tco.MiterLimit = 2\n\t\tholes = co.Execute(float64(overlap))\n\t}\n\n\t// clip the lines by the outline and holes\n\tcl.AddPaths(exset, clipper.PtClip, true)\n\tcl.AddPaths(holes, clipper.PtClip, true)\n\n\tif layerNr%2 == 0 {\n\t\tcl.AddPaths(p.verticalPaths, clipper.PtSubject, false)\n\t} else {\n\t\tcl.AddPaths(p.horizontalPaths, clipper.PtSubject, false)\n\t}\n\n\ttree, ok := cl.Execute2(clipper.CtIntersection, clipper.PftEvenOdd, clipper.PftEvenOdd)\n\tif !ok {\n\t\tfmt.Println(\"getLinearFill failed\")\n\t\treturn nil\n\t}\n\n\tfor _, c := range tree.Childs() {\n\t\tresult = append(result, c.Contour())\n\t}\n\n\treturn result\n}", "func (el *Fill) AnimateMotion() {}", "func (style strokeStyle) Line(canvas *pdf.Canvas, pt1, pt2 pdf.Point) {\n\tvar path pdf.Path\n\tpath.Move(pt1)\n\tpath.Line(pt2)\n\n\tcanvas.SetLineWidth(style.LineWidth)\n\tcanvas.SetStrokeColor(style.R, style.G, style.B)\n\tcanvas.Stroke(&path)\n}", "func decorate(s string, color string) string {\n\tswitch color {\n\tcase \"green\":\n\t\ts = \"\\x1b[0;32m\" + s\n\tcase \"red\":\n\t\ts = \"\\x1b[0;31m\" + s\n\tdefault:\n\t\treturn s\n\t}\n\treturn s + \"\\x1b[0m\"\n}", "func BLENDVPS(x, mx, x1 operand.Op) { ctx.BLENDVPS(x, mx, x1) }", "func (dst *Image) Line(p0, p1 Point, end0, end1 End, thick int, src *Image, sp Point) {\n\tdst.Display.mu.Lock()\n\tdefer dst.Display.mu.Unlock()\n\tdst.lineOp(p0, p1, end0, end1, thick, src, sp, SoverD)\n}", "func VBLENDVPD(xy, mxy, xy1, xy2 operand.Op) { ctx.VBLENDVPD(xy, mxy, xy1, xy2) }", "func (w *Window) Line(v1, v2 *geom.Vec2, r, g, b byte) {\n\t// Always draw from left to right (x1 <= x2)\n\tif v1[0] > v2[0] {\n\t\tv1, v2 = v2, v1\n\t}\n\tdx := v2[0] - v1[0]\n\tdy := v2[1] - v1[1]\n\tvar steps int\n\tif tmath.Absi(dx) > tmath.Absi(dy) {\n\t\tsteps = dx\n\t} else {\n\t\tsteps = tmath.Absi(dy)\n\t}\n\txinc := float64(dx) / float64(steps)\n\tyinc := float64(dy) / float64(steps)\n\tx := float64(v1[0])\n\ty := float64(v1[1])\n\tfor s := 0; s <= steps; s++ {\n\t\tw.Setxy(tmath.Round(x), tmath.Round(y), r, g, b)\n\t\tx += xinc\n\t\ty += yinc\n\t}\n}", "func flake(x, y, w, h openvg.VGfloat, color string) {\n\tcx := x + (w / 2)\n\tcy := y + (h / 2)\n\tr := w * 0.30\n\topenvg.StrokeColor(color)\n\topenvg.StrokeWidth(w / 20)\n\tfor t := 0.0; t < 2*math.Pi; t += math.Pi / 4 {\n\t\tc := openvg.VGfloat(math.Cos(t))\n\t\ts := openvg.VGfloat(math.Sin(t))\n\t\tx1 := (r * c) + cx\n\t\ty1 := (r * s) + cy\n\t\topenvg.Line(cx, cy, x1, y1)\n\t}\n\topenvg.StrokeWidth(0)\n}", "func makeLine(l *string, strLen int, offset int) {\n\n\t//*l = \" \" + *l\n\tfor i := 0; i < offset; i++ {\n\t\t*l = \" \" + *l\n\t}\n\tlen := 0\n\tfor _, c := range *l {\n\t\tlen += runewidth.RuneWidth(c)\n\t}\n\tif len > strLen {\n\t\t*l = (*l)[:strLen]\n\t\treturn\n\t}\n\tfor len < strLen {\n\t\t*l += \" \"\n\t\tlen++\n\t}\n}", "func (self *Graphics) SetLineColorA(member string) {\n self.Object.Set(\"lineColor\", member)\n}", "func BLENDVPD(x, mx, x1 operand.Op) { ctx.BLENDVPD(x, mx, x1) }", "func PCMPISTRI(i, mx, x operand.Op) { ctx.PCMPISTRI(i, mx, x) }", "func Underline() string {\n\treturn csi(\"3m\")\n}", "func (a axes) drawDirectLine(l Line, xy xyer, cs vg.CoordinateSystem) {\n\tr := image.Rectangle{image.Point{a.x, a.y}, image.Point{a.x + a.width, a.y + a.height}}\n\tim := a.parent.SubImage(r)\n\t/*\n\t\tm := raster.Image{\n\t\t\tImage: im.(*image.RGBA),\n\t\t\tColor: a.plot.Style.Color.Order.Get(l.Style.Line.Color, l.Id+1).Color(),\n\t\t}\n\t\tx, y, _ := xy.XY(l)\n\t\traster.FloatLines(m, x, y, raster.CoordinateSystem(cs))\n\t*/\n\tp := vg.NewPainter(im.(*image.RGBA))\n\ta.drawLine(p, xy, cs, l, false)\n\tp.Paint()\n}", "func VBLENDVPS(xy, mxy, xy1, xy2 operand.Op) { ctx.VBLENDVPS(xy, mxy, xy1, xy2) }", "func (el *Fill) Animate() {}", "func (self *Graphics) LineToI(args ...interface{}) *Graphics{\n return &Graphics{self.Object.Call(\"lineTo\", args)}\n}", "func DrawVLine(m draw.Image, x, y1, y2 int) {\n\tfor ; y1 <= y2; y1++ {\n\t\tm.Set(x, y1, color.RGBA{0, 0, 255, 255})\n\t}\n}", "func (el *Fill) Ellipse() {}", "func (tile *Tile) tileLine(line int) string {\n\n\ts := \"\"\n\tif tile == nil {\n\t\ts = \" \"\n\t} else if line == 0 {\n\t\ts = fmt.Sprintf(\" %04x \", tile.sides[(tile.rotation+1)%4])\n\t} else if line == 1 {\n\t\ts = fmt.Sprintf(\"%04x %4v %04x \", tile.sides[(tile.rotation)%4], tile.tileNumber, tile.sides[(tile.rotation+2)%4])\n\t} else if line == 2 {\n\t\ts = fmt.Sprintf(\" %04x \", tile.sides[(tile.rotation+3)%4])\n\t}\n\treturn s\n}", "func (p *Page) StrokeGray(g float64) {\n\tfmt.Fprint(p.contents, g, \" G \")\n}", "func Rep(p *Pattern, min, max int) *Pattern {\n\tvar size int\n\tif max < 0 {\n\t\tsize = min + 3\n\t} else {\n\t\tsize = min + 2*(max-min) + 1\n\t}\n\targs := make([]interface{}, size)\n\tfor i := 0; i < min; i++ {\n\t\targs[i] = p\n\t}\n\tpos := min\n\tif max < 0 {\n\t\targs[pos+0] = &IChoice{3}\n\t\targs[pos+1] = p\n\t\targs[pos+2] = &ICommit{-2}\n\t\tpos += 3\n\t} else {\n\t\targs[pos+0] = &IChoice{2 * (max - min)}\n\t\tpos++\n\t\tfor i := min; i < max; i++ {\n\t\t\targs[pos+0] = p\n\t\t\targs[pos+1] = &IPartialCommit{1}\n\t\t\tpos += 2\n\t\t}\n\t\targs[pos+0] = &ICommit{1}\n\t\tpos++\n\t}\n\treturn Seq2(args)\n}", "func NewLine(p complex128, q complex128) Circle {\n\t// TODO check this matrix\n\treturn Circle{\n\t\tA: 0,\n\t\tC: p - q,\n\t\tD: 1,\n\t}\n}", "func printDividerLine() {\r\n\tfmt.Println(\"------------------------------------------------------------\")\r\n}", "func VPBLENDVB(xy, mxy, xy1, xy2 operand.Op) { ctx.VPBLENDVB(xy, mxy, xy1, xy2) }", "func (gpu *CHIP8GPU) draw_line8(x, y int8, line uint8) Registr {\n\tret := 0\n\tif y >= 32 {\n\t\ty -= 32\n\t}\n\tfor y < 0 {\n\t\ty += 32\n\t}\n\tfor i := 0; i < 8; i++ {\n\t\txp := x + int8(i)\n\t\tif xp >= 64 {\n\t\t\txp -= 64\n\t\t}\n\t\tfor xp < 0 {\n\t\t\txp += 64\n\t\t}\n\t\tnew_pix := (gpu.pic[xp][y] & 1) ^ ((line >> uint(7-i)) & 1)\n\t\tif gpu.pic[xp][y] == 1 && new_pix == 0 {\n\t\t\tret = 1\n\t\t}\n\t\tgpu.pic[xp][y] = new_pix\n\t}\n\treturn Registr(ret)\n}", "func (m *TransposableMatrix) DrawLine(line []Point, suffix string, pivotPointsOnly bool) {\n\tfor i := 0; i < len(line); i++ {\n\t\ts := spf(\"%v%v\", i%10, suffix)\n\t\tif suffix == \"\" {\n\t\t\ts = \"\"\n\t\t}\n\t\tif pivotPointsOnly || i == len(line)-1 {\n\t\t\tm.SetLabel(line[i].x, line[i].y, Slot{Label: s})\n\t\t} else {\n\t\t\tx := util.Min(line[i+1].x, line[i].x)\n\t\t\ty := util.Min(line[i+1].y, line[i].y)\n\t\t\tdx := util.Abs(line[i+1].x - line[i].x)\n\t\t\tdy := util.Abs(line[i+1].y - line[i].y)\n\t\t\t// pf(\"sect :%v %v %v %v \\n\", x, x+dx, y, y+dy)\n\t\t\tfor j := x; j <= x+dx; j++ {\n\t\t\t\tfor k := y; k <= y+dy; k++ {\n\t\t\t\t\tm.SetLabel(j, k, Slot{Label: s})\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func formatTileLine(t *Tile, tileY int, flipHorizontal, flipVertical bool, tileLineStorageArea *[8]int) {\n\t//flip both\n\tif flipVertical && flipHorizontal {\n\t\tfor x := 0; x < 8; x++ {\n\t\t\ttileLineStorageArea[x] = t[7-tileY][7-x]\n\t\t}\n\t\treturn\n\t}\n\n\tif flipVertical {\n\t\tfor i, v := range t[7-tileY] {\n\t\t\ttileLineStorageArea[i] = v\n\t\t}\n\t\treturn\n\t}\n\n\tif flipHorizontal {\n\t\tfor x := 0; x < 8; x++ {\n\t\t\ttileLineStorageArea[x] = t[tileY][7-x]\n\t\t}\n\t\treturn\n\t}\n\n\tfor i, v := range t[tileY] {\n\t\ttileLineStorageArea[i] = v\n\t}\n}" ]
[ "0.81452554", "0.7987065", "0.5726458", "0.5603769", "0.541468", "0.54131484", "0.5227642", "0.5086973", "0.503296", "0.50162023", "0.4964184", "0.49558353", "0.49404633", "0.48910254", "0.48617828", "0.4848811", "0.48212528", "0.4772971", "0.4762349", "0.47515386", "0.4743267", "0.47324497", "0.4732247", "0.47109333", "0.47109333", "0.4710766", "0.4695215", "0.46875623", "0.46746746", "0.46693835", "0.46105197", "0.46050388", "0.45929593", "0.45538428", "0.45515245", "0.45502", "0.4547459", "0.45426673", "0.45307514", "0.45277247", "0.45159748", "0.44717735", "0.44671088", "0.4455681", "0.44491935", "0.44444957", "0.44350082", "0.4414306", "0.44073358", "0.44072908", "0.4402744", "0.43818873", "0.43763688", "0.43599313", "0.43592757", "0.43589965", "0.43549985", "0.43477365", "0.43467572", "0.43384874", "0.4331828", "0.43135193", "0.43124783", "0.43115085", "0.43018064", "0.42980027", "0.42859957", "0.42845842", "0.42606726", "0.4250604", "0.42491004", "0.42479667", "0.42402187", "0.4237992", "0.42358834", "0.42344478", "0.42275938", "0.422445", "0.42130724", "0.42102158", "0.42084956", "0.42078373", "0.4205093", "0.4184645", "0.41825828", "0.41790646", "0.41762936", "0.4167397", "0.41619053", "0.41530156", "0.41422704", "0.41346508", "0.41324502", "0.41242754", "0.4119293", "0.41145507", "0.4109438", "0.41076213", "0.40940228", "0.40886047" ]
0.7616251
2
specify the width of rasterized lines
func LineWidth(width float32) { C.glowLineWidth(gpLineWidth, (C.GLfloat)(width)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func LineWidth(width float32) {\n\tgl.LineWidth(width)\n}", "func LineWidth(width float32) {\n\tsyscall.Syscall(gpLineWidth, 1, uintptr(math.Float32bits(width)), 0, 0)\n}", "func LineWidth(width float32) {\n C.glowLineWidth(gpLineWidth, (C.GLfloat)(width))\n}", "func (native *OpenGL) LineWidth(lw float32) {\n\tgl.LineWidth(lw)\n}", "func (self *Graphics) LineWidth() int{\n return self.Object.Get(\"lineWidth\").Int()\n}", "func hLine(rectImg *image.RGBA, color color.RGBA, x, y, length , width int) {\n\trectLine := image.NewRGBA(image.Rect(x, y, x+length, y+width))\n\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{color}, image.ZP, draw.Src)\n}", "func pixelBufferLength(bytesPerPixel int, r Rectangle, imageTypeName string) int {\n\ttotalLength := mul3NonNeg(bytesPerPixel, r.Dx(), r.Dy())\n\tif totalLength < 0 {\n\t\tpanic(\"image: New\" + imageTypeName + \" Rectangle has huge or negative dimensions\")\n\t}\n\treturn totalLength\n}", "func (c *Context) LineWidth(w float32) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: w,\n\t\tDefaultValue: 1.0,\n\t\tKey: csLineWidth,\n\t\tGLCall: c.glLineWidth,\n\t}\n}", "func (v *Value) LineWidth(l, offset, tab int) int {\n\tvar width int\n\tif l < len(v.Newlines) {\n\t\twidth += v.Newlines[l][1]\n\t}\n\tif len(v.Tabs[l]) != 0 {\n\t\twidth += tabwidth(v.Tabs[l], offset, tab)\n\t}\n\tif l == len(v.Newlines) {\n\t\twidth += v.Width\n\t}\n\treturn width\n}", "func vLine(rectImg *image.RGBA, color color.RGBA, x, y, length , width int) {\n\trectLine := image.NewRGBA(image.Rect(x, y, x+width, y+length))\n\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{color}, image.ZP, draw.Src)\n}", "func (w *LDRWrapper) Size() int {\n\treturn w.Bounds().Dx() * w.Bounds().Dy()\n}", "func (self *Graphics) SetLineWidthA(member int) {\n self.Object.Set(\"lineWidth\", member)\n}", "func (o DashboardLineChartLineStyleSettingsOutput) LineWidth() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v DashboardLineChartLineStyleSettings) *string { return v.LineWidth }).(pulumi.StringPtrOutput)\n}", "func (m *Mapper) NumLines() int {\n\treturn len(m.offsets) - 1\n}", "func (p *PixelLine) Resize(newLen int) PixelLine {\n\tif newLen <= 1 {\n\t\tpanic(\"Lines of 1 or less length are invalid\")\n\t}\n\tnewSpline := gospline.NewMonotoneSpline\n\tlocs := genLocs(p.len)\n\n\tend := float64(locs[len(locs)-1])\n\tstep := end / float64(newLen-1)\n\n\t// Because float rounding can screw us.\n\t// This is based on the observed math inside cubic.Range in gospline\n\t//\n\t// Found with fuzzing!\n\tfor int(end/step) < newLen-1 {\n\t\tstep = math.Nextafter(step, 0)\n\t}\n\n\tnewParts := make([][]float64, len(p.parts))\n\tfmt.Printf(\"from %d to %d\\n\", p.len, newLen)\n\tfor i, part := range p.parts {\n\t\tnewParts[i] = newSpline(locs, part).Range(0, end, step)\n\t}\n\treturn PixelLine{\n\t\tlen: newLen,\n\t\tmodel: p.model,\n\t\tparts: newParts,\n\t}\n}", "func (g *Grid) SetWidth(w int) { g.Width = w }", "func SetLineWidth(width Float) {\n\tcwidth, _ := (C.GLfloat)(width), cgoAllocsUnknown\n\tC.glLineWidth(cwidth)\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 (s *Surface) SetLineWidth(width float64) {\n\ts.Ctx.Set(\"lineWidth\", width)\n}", "func (o GoogleCloudRetailV2alphaImageOutput) Width() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v GoogleCloudRetailV2alphaImage) *int { return v.Width }).(pulumi.IntPtrOutput)\n}", "func drawLine(w, y int, ln line) int {\n\t// figure out whether the line needs to be shortened\n\tvar truncLen int\n\ttruncIndex := -1\n\tlineWidth := 0\n\tfor _, seg := range ln {\n\t\tlineWidth += len(seg.text)\n\t}\n\tif lineWidth > w-2 {\n\t\t// figure out which segment to shorten\n\t\ttruncIndex = len(ln) - 1\n\t\tfor i, seg := range ln {\n\t\t\tif seg.el != ellipsisNone {\n\t\t\t\ttruncIndex = i\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t\t// figure out by how much to shorten it\n\t\ttruncLen = len(ln[truncIndex].text) - (lineWidth - (w - 2) + 3)\n\t\tif truncLen < 0 {\n\t\t\ttruncLen = 0\n\t\t}\n\t}\n\n\t// draw characters\n\tx := 0\n\tfor i, seg := range ln {\n\t\ttext := seg.text\n\n\t\t// ...text\n\t\tif i == truncIndex {\n\t\t\tif seg.el == ellipsisLeft {\n\t\t\t\tx = drawEllipsis(x, y, seg.fg, seg.bg)\n\t\t\t\ttext = text[len(text)-truncLen:]\n\t\t\t} else {\n\t\t\t\ttext = text[:truncLen]\n\t\t\t}\n\t\t}\n\n\t\tfor _, ch := range text {\n\t\t\ttermbox.SetCell(x, y, ch, seg.fg, seg.bg)\n\t\t\tx++\n\t\t}\n\n\t\t// text...\n\t\tif i == truncIndex && seg.el != ellipsisLeft {\n\t\t\tx = drawEllipsis(x, y, seg.fg, seg.bg)\n\t\t}\n\t}\n\n\treturn x\n}", "func (o DashboardLineChartLineStyleSettingsPtrOutput) LineWidth() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *DashboardLineChartLineStyleSettings) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn v.LineWidth\n\t}).(pulumi.StringPtrOutput)\n}", "func (f *Font) RunesWidth(r []rune) int {\n\tf.lock()\n\tdefer f.unlock()\n\treturn stringnwidth(f, \"\", nil, r)\n}", "func (this *TableCol) LineCount(maxWidth ...int) int {\n\tif len(maxWidth) == 0 || maxWidth[0] == 0 {\n\t\treturn this.lineCount\n\t}\n\treturn strings.Count(this.Content(maxWidth[0]), \"\\n\") + 1\n}", "func DrawLineSeries(r Renderer, canvasBox Box, xrange, yrange Range, s Style, vs ValueProvider) {\n\tif vs.Len() == 0 {\n\t\treturn\n\t}\n\n\tct := canvasBox.Top\n\tcb := canvasBox.Bottom\n\tcr := canvasBox.Right\n\n\tv0x, v0y := vs.GetValue(0)\n\tx0 := cr - xrange.Translate(v0x)\n\ty0 := yrange.Translate(v0y) + ct\n\n\tvar vx, vy float64\n\tvar x, y int\n\n\tfill := s.GetFillColor()\n\tif !fill.IsZero() {\n\t\tr.SetFillColor(fill)\n\t\tr.MoveTo(x0, y0)\n\t\tfor i := 1; i < vs.Len(); i++ {\n\t\t\tvx, vy = vs.GetValue(i)\n\t\t\tx = cr - xrange.Translate(vx)\n\t\t\ty = yrange.Translate(vy) + ct\n\t\t\tr.LineTo(x, y)\n\t\t}\n\t\tr.LineTo(x, cb)\n\t\tr.LineTo(x0, cb)\n\t\tr.Close()\n\t\tr.Fill()\n\t}\n\n\tstroke := s.GetStrokeColor()\n\tr.SetStrokeColor(stroke)\n\tr.SetStrokeWidth(s.GetStrokeWidth(DefaultStrokeWidth))\n\n\tr.MoveTo(x0, y0)\n\tfor i := 1; i < vs.Len(); i++ {\n\t\tvx, vy = vs.GetValue(i)\n\t\tx = cr - xrange.Translate(vx)\n\t\ty = yrange.Translate(vy) + ct\n\t\tr.LineTo(x, y)\n\t}\n\tr.Stroke()\n}", "func (sprite *Sprite) Width() int {\n\treturn 16\n}", "func (s *ImageSpec) ScanlineBytes(native bool) int {\n\tret := int(C.ImageSpec_scanline_bytes(s.ptr, C.bool(native)))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func hline(width int) string {\n\tr := \"\\n\"\n\tfor i := 0; i < 9*width; i++ {\n\t\tr += \"\\u2500\"\n\t}\n\treturn r\n}", "func (p *PixelLine) Len() int {\n\treturn p.len\n}", "func (canvas *Canvas) SetLineWidth(w Unit) {\n\twriteCommand(canvas.contents, \"w\", w)\n}", "func (b *Bound) Width() float64 {\n\treturn b.ne.X() - b.sw.X()\n}", "func (r *renderer) Spacing() int { return 0 }", "func Width(value float64) *SimpleElement { return newSEFloat(\"width\", value) }", "func (m *ModuleBase) Width(takable, taken float64) float64 {\n\treturn taken\n}", "func maxWidth(no_lines int, widthFromLineNo widthFunc) int {\n\tvar max int\n\tfor i := 0; i < no_lines; i++ {\n\t\tval := widthFromLineNo(i)\n\t\tif val > max {\n\t\t\tmax = val\n\t\t}\n\t}\n\treturn max\n}", "func (o GoogleCloudRetailV2alphaImageResponseOutput) Width() pulumi.IntOutput {\n\treturn o.ApplyT(func(v GoogleCloudRetailV2alphaImageResponse) int { return v.Width }).(pulumi.IntOutput)\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 (s *ImageSpec) TileWidth() int {\n\tret := int(C.ImageSpec_tile_width(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func (r *Renderer) CalcScaledLineWidth(onScreenLineThicknessInDevicePixels int) int {\n\treturn int(math.Round(float64(onScreenLineThicknessInDevicePixels) * r.PixelRatio))\n}", "func (num *number) Width() int {\n\treturn num.size * 3 / 4\n}", "func (c *Canvas) Width() int {\n\treturn c.maxCorner.X - c.minCorner.X + 1\n}", "func dline (x int, y int, height int) {\n\tadd := 1\n\tn := 0\n\theight += height % 2\n\tif height < 0 {\n\t\tadd = -1\n\t}\n\tfor n != height {\n\t\timg.Set(x, y - n, col)\n\t\timg.Set(x, y - n - add, col)\n\t\tx += 1;\n\t\tn += 2 * add\n\t}\n}", "func DrawHLine(m draw.Image, x1, y, x2 int) {\n\tfor ; x1 <= x2; x1++ {\n\t\tm.Set(x1, y, color.RGBA{0, 0, 255, 255})\n\t}\n}", "func (planet *Planet) getMultiTileWidth(layer []Tile, x,y int) int {\n\toffsetX := 1\n\tfor layer[planet.GetTileIndex(x+offsetX,y)].OffsetX == int8(offsetX) {\n\t\toffsetX++\n\t}\n\treturn offsetX\n}", "func nodeWidth(n uint) uint {\n\treturn 2*(n-1) + 1\n}", "func (r *Renderer) countLines(buf bytes.Buffer) int {\n\tw, err := r.termWidth()\n\tif err != nil || w == 0 {\n\t\t// if we got an error due to terminal.GetSize not being supported\n\t\t// on current platform then just assume a very wide terminal\n\t\tw = 10000\n\t}\n\n\tbufBytes := buf.Bytes()\n\n\tcount := 0\n\tcurr := 0\n\tdelim := -1\n\tfor curr < len(bufBytes) {\n\t\t// read until the next newline or the end of the string\n\t\trelDelim := bytes.IndexRune(bufBytes[curr:], '\\n')\n\t\tif relDelim != -1 {\n\t\t\tcount += 1 // new line found, add it to the count\n\t\t\tdelim = curr + relDelim\n\t\t} else {\n\t\t\tdelim = len(bufBytes) // no new line found, read rest of text\n\t\t}\n\n\t\tif lineWidth := utf8.RuneCount(bufBytes[curr:delim]); lineWidth > w {\n\t\t\t// account for word wrapping\n\t\t\tcount += lineWidth / w\n\t\t\tif (lineWidth % w) == 0 {\n\t\t\t\t// content whose width is exactly a multiplier of available width should not\n\t\t\t\t// count as having wrapped on the last line\n\t\t\t\tcount -= 1\n\t\t\t}\n\t\t}\n\t\tcurr = delim + 1\n\t}\n\n\treturn count\n}", "func LatencyWidth(b1, b2, bTot Bucket) float64 {\n\treturn (b2.Max - b1.Min) / (b2.Max - bTot.Min)\n}", "func (self *Graphics) SetWidthA(member int) {\n self.Object.Set(\"width\", member)\n}", "func QuantizeLineGeometry(thickness0 int, position0 int) (int, int) {\n\tvar thickness1 C.int32_t\n\tvar position1 C.int32_t\n\tthickness1 = C.int32_t(thickness0)\n\tposition1 = C.int32_t(position0)\n\tC.pango_quantize_line_geometry(&thickness1, &position1)\n\tvar thickness2 int\n\tvar position2 int\n\tthickness2 = int(thickness1)\n\tposition2 = int(position1)\n\treturn thickness2, position2\n}", "func iLine(x1, y1, x2, y2 int, size float32, color color.RGBA) *canvas.Line {\n\tp1 := fyne.Position{X: float32(x1), Y: float32(y1)}\n\tp2 := fyne.Position{X: float32(x2), Y: float32(y2)}\n\tl := &canvas.Line{StrokeColor: color, StrokeWidth: size, Position1: p1, Position2: p2}\n\treturn l\n}", "func (f *Framebuffer) Width() int { return f.fb.Bounds().Max.X }", "func (bm Blendmap) Width() float32 {\n\treturn bm.Map.width\n}", "func (win *window) Lines(pt []image.Point) {\n\tif len(pt) < 2 {\n\t\treturn\n\t}\n\tpts := make([]xgb.Point, len(pt))\n\tfor i, p := range pt {\n\t\tpts[i].X, pts[i].Y = int16(p.X), int16(p.Y)\n\t}\n\txwin.PolyLine(xgb.CoordModeOrigin, win.id, win.gc, pts)\n}", "func (s *SVG) SetWidth(w int) {\n\ts.width = w\n}", "func (tm *Term) LessMinLines() error {\n\ttm.MinLines--\n\ttm.MinLines = ints.MaxInt(3, tm.MinLines)\n\treturn tm.Draw()\n}", "func (b *AppendOnlyBufferedBatch) Width() int {\n\treturn b.batch.Width()\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 drawLine(screen []byte, width, x1, x2, y int) []byte {\n\tbytesPerRow := width / 8\n\tbyteAtRowStart := y * bytesPerRow\n\tminByteInRow := x1 / 8\n\tmaxByteInRow := x2 / 8\n\tminByte := byteAtRowStart + minByteInRow\n\tmaxByte := byteAtRowStart + maxByteInRow\n\tminByteMinBit := x1 % 8\n\tmaxByteMaxBit := x2 % 8\n\t// TODO: Error handling.\n\tfor i := minByte; i <= maxByte; i++ {\n\t\tminBit := 0\n\t\tif i == minByte {\n\t\t\tminBit = minByteMinBit\n\t\t}\n\t\tmaxBit := 7\n\t\tif i == maxByte {\n\t\t\tmaxBit = maxByteMaxBit\n\t\t}\n\t\tfor j := minBit; j <= maxBit; j++ {\n\t\t\t// setBit indexes from right to left so we need to reverse the bits\n\t\t\t// before and after.\n\t\t\tscreen[i] = reverseBits(byte(setBit(int(reverseBits(screen[i])), j, 1)))\n\t\t}\n\t}\n\treturn screen\n}", "func (object Object) Width(value int64) Object {\n\treturn object.SimpleValue(as.PropertyWidth, value)\n}", "func (matrix *CosineLabeledMatrix) Width() int {\n\treturn len(matrix.Label)\n}", "func (p *Projection) line(w1x float64, w1y float64, w2x float64, w2y float64, col color.RGBA) {\n c1x, c1y := p.project(w1x, w1y)\n c2x, c2y := p.project(w2x, w2y)\n\n c := draw2d.NewGraphicContext(p.img)\n c.SetStrokeColor(col)\n c.SetLineWidth(1)\n\n c.MoveTo(c1x, c1y)\n c.LineTo(c2x, c2y)\n c.Stroke()\n}", "func (b *BoundingBox2D) width() float64 {\n\n\treturn b.upperCorner.X - b.lowerCorner.X\n}", "func (s *Surface) SetLineMiterLimit(miter float64) {\n\ts.Ctx.Set(\"miterLimit\", miter)\n}", "func (info *ImageInfoType) Width() float64 {\n\treturn info.w / (info.scale * info.dpi / 72)\n}", "func (t *Type) ArgWidth() int64", "func HLine(img *image.RGBA, x1, y, x2 int, col color.Color) {\n\tfor ; x1 <= x2; x1++ {\n\t\timg.Set(x1, y, col)\n\t}\n}", "func (l Line) Len() float64 {\n\treturn l.A.To(l.B).Len()\n}", "func renderTexturedLine(x, y float64, imd *imdraw.IMDraw) {\n\timd.Intensity = 1.\n\timd.Picture = pixel.V(x, 0)\n\timd.Push(pixel.V(x, 0))\n\timd.Picture = pixel.V(x+1, y)\n\timd.Push(pixel.V(x+1, y))\n\timd.Rectangle(0)\n}", "func (e *HTMLApplet) Width(v string) *HTMLApplet {\n\te.a[\"width\"] = v\n\treturn e\n}", "func (w *Window) Line(v1, v2 *geom.Vec2, r, g, b byte) {\n\t// Always draw from left to right (x1 <= x2)\n\tif v1[0] > v2[0] {\n\t\tv1, v2 = v2, v1\n\t}\n\tdx := v2[0] - v1[0]\n\tdy := v2[1] - v1[1]\n\tvar steps int\n\tif tmath.Absi(dx) > tmath.Absi(dy) {\n\t\tsteps = dx\n\t} else {\n\t\tsteps = tmath.Absi(dy)\n\t}\n\txinc := float64(dx) / float64(steps)\n\tyinc := float64(dy) / float64(steps)\n\tx := float64(v1[0])\n\ty := float64(v1[1])\n\tfor s := 0; s <= steps; s++ {\n\t\tw.Setxy(tmath.Round(x), tmath.Round(y), r, g, b)\n\t\tx += xinc\n\t\ty += yinc\n\t}\n}", "func (tv *TextView) WrappedLines(ln int) int {\n\tif ln >= len(tv.Renders) {\n\t\treturn 0\n\t}\n\treturn len(tv.Renders[ln].Spans)\n}", "func rowSpace(radius float64) float64 {\n\treturn 2.0 * radius\n}", "func (f *Font) RunesSize(r []rune) image.Point {\n\treturn image.Pt(f.RunesWidth(r), f.Height)\n}", "func (p *Page) SetLineWidth(w float64) {\n\tfmt.Fprint(p.contents, w, \" w \")\n}", "func (b *BinP1D) XWidth() float64 {\n\treturn b.xrange.Max - b.xrange.Min\n}", "func WrapWidth(w float64) MeshOption {\n\treturn func(t *Mesh) error {\n\t\tt.renderAutoWrap = true\n\t\tt.renderWrapWidth = w\n\n\t\treturn nil\n\t}\n}", "func (vr *vectorRenderer) SetStrokeWidth(width float64) {\n\tvr.s.StrokeWidth = width\n}", "func Width(width float32) Option {\n\treturn func(i *Info) {\n\t\ti.Width = width\n\t}\n}", "func (lc *LineChart) minSize() image.Point {\n\t// At the very least we need:\n\t// - n cells width for the Y axis and its labels as reported by it.\n\t// - at least 1 cell width for the graph.\n\treqWidth := axes.RequiredWidth(lc.yMin, lc.yMax) + 1\n\n\t// And for the height:\n\t// - n cells width for the X axis and its labels as reported by it.\n\t// - at least 2 cell height for the graph.\n\treqHeight := axes.RequiredHeight(lc.maxXValue(), lc.xLabels, lc.opts.xLabelOrientation) + 2\n\treturn image.Point{reqWidth, reqHeight}\n}", "func (f ChangeLineSpaceFilter) getLineRanges(src image.Image) lineRanges {\n\tbounds := src.Bounds()\n\tsrcWidth, srcHeight := bounds.Dx(), bounds.Dy()\n\tthreshold16 := f.option.Threshold * 256\n\n\tvar ranges lineRanges\n\tvar r lineRange\n\n\tmaxDotCount := int(f.option.EmptyLineThreshold)\n\tif f.option.EmptyLineThreshold < 1 {\n\t\tmaxDotCount = int(float64(srcWidth) * f.option.EmptyLineThreshold)\n\t}\n\tfor y := 0; y < srcHeight; y++ {\n\t\temptyLine := true\n\t\tdotCount := 0\n\t\tfor x := 0; x < srcWidth; x++ {\n\t\t\tr, g, b, _ := src.At(x, y).RGBA()\n\t\t\tbrightness := getBrightness(r, g, b)\n\t\t\tif brightness < threshold16 {\n\t\t\t\tdotCount++\n\t\t\t\tif dotCount >= maxDotCount {\n\t\t\t\t\temptyLine = false\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif emptyLine {\n\t\t\tif y == 0 {\n\t\t\t\tr = lineRange{start: y, end: y, emptyLine: true}\n\t\t\t} else {\n\t\t\t\tif r.emptyLine {\n\t\t\t\t\tr.end = y\n\t\t\t\t} else {\n\t\t\t\t\tranges = append(ranges, r)\n\t\t\t\t\tr = lineRange{start: y, end: y, emptyLine: true}\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tif y == 0 {\n\t\t\t\tr = lineRange{start: y, end: y, emptyLine: false}\n\t\t\t} else {\n\t\t\t\tif r.emptyLine {\n\t\t\t\t\tranges = append(ranges, r)\n\t\t\t\t\tr = lineRange{start: y, end: y, emptyLine: false}\n\t\t\t\t} else {\n\t\t\t\t\tr.end = y\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t}\n\tranges = append(ranges, r)\n\treturn ranges\n}", "func (me TxsdMarkerTypeMarkerUnits) IsStrokeWidth() bool { return me.String() == \"strokeWidth\" }", "func (r *Renderer) line(context js.Value, thick int, x1, y1, x2, y2 int) {\n\tcontext.Call(\"moveTo\", nudge(x1, thick)*r.PixelRatio, nudge(y1, thick)*r.PixelRatio)\n\tcontext.Call(\"lineTo\", nudge(x2, thick)*r.PixelRatio, nudge(y2, thick)*r.PixelRatio)\n}", "func (tm *Term) MoreMinLines() error {\n\ttm.MinLines++\n\treturn tm.Draw()\n}", "func (o *TileBounds) SetWidth(v int32) {\n\to.Width = &v\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 line(m draw.Image, x0, y0, x1, y1 int, c color.Color) {\n\tabs := func(x int) int {\n\t\tif x < 0 {\n\t\t\treturn -x\n\t\t}\n\t\treturn x\n\t}\n\n\tvar dx, dy, sx, sy, e, e2 int\n\n\tdx = abs(x1 - x0)\n\tdy = -abs(y1 - y0)\n\tif sx = -1; x0 < x1 {\n\t\tsx = 1\n\t}\n\tif sy = -1; y0 < y1 {\n\t\tsy = 1\n\t}\n\te = dx + dy\n\tfor {\n\t\tm.Set(x0, y0, c)\n\t\tif x0 == x1 && y0 == y1 {\n\t\t\tbreak\n\t\t}\n\t\tif e2 = 2 * e; e2 >= dy {\n\t\t\te += dy\n\t\t\tx0 += sx\n\t\t} else if e2 <= dx {\n\t\t\te += dx\n\t\t\ty0 += sy\n\t\t}\n\t}\n}", "func getLineRanges(src image.Image,\n\tthreshold uint32,\n\temptyLineThreshold float64) []lineRange {\n\tbounds := src.Bounds()\n\tsrcWidth, srcHeight := bounds.Dx(), bounds.Dy()\n\tthreshold16 := threshold * 256\n\n\tvar ranges []lineRange\n\tvar r lineRange\n\n\tmaxDotCount := int(emptyLineThreshold)\n\tif emptyLineThreshold < 1 {\n\t\tmaxDotCount = int(float64(srcWidth) * emptyLineThreshold)\n\t}\n\tfor y := 0; y < srcHeight; y++ {\n\t\temptyLine := true\n\t\tdotCount := 0\n\t\tfor x := 0; x < srcWidth; x++ {\n\t\t\tr, g, b, _ := src.At(x, y).RGBA()\n\t\t\tbrightness := getBrightness(r, g, b)\n\t\t\tif brightness < threshold16 {\n\t\t\t\tdotCount++\n\t\t\t\tif dotCount >= maxDotCount {\n\t\t\t\t\temptyLine = false\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif emptyLine {\n\t\t\tif y == 0 {\n\t\t\t\tr = lineRange{start: y, end: y, emptyLine: true}\n\t\t\t} else {\n\t\t\t\tif r.emptyLine {\n\t\t\t\t\tr.end = y\n\t\t\t\t} else {\n\t\t\t\t\tranges = append(ranges, r)\n\t\t\t\t\tr = lineRange{start: y, end: y, emptyLine: true}\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tif y == 0 {\n\t\t\t\tr = lineRange{start: y, end: y, emptyLine: false}\n\t\t\t} else {\n\t\t\t\tif r.emptyLine {\n\t\t\t\t\tranges = append(ranges, r)\n\t\t\t\t\tr = lineRange{start: y, end: y, emptyLine: false}\n\t\t\t\t} else {\n\t\t\t\t\tr.end = y\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t}\n\tranges = append(ranges, r)\n\treturn ranges\n}", "func (dw *DrawingWand) Line(sx, sy, ex, ey float64) {\n\tC.MagickDrawLine(dw.dw, C.double(sx), C.double(sy), C.double(ex), C.double(ey))\n}", "func (self *TileSprite) SetWidthA(member int) {\n self.Object.Set(\"width\", member)\n}", "func (s Spec) Width() float64 {\n\treturn s.SpecWidth\n}", "func (s *CountMinSketch) Width() uint {\n\treturn s.w\n}", "func (image *image) TermBufferLength() int32 {\n\treturn image.termLengthMask + 1\n}", "func (s *ImageSpec) Width() int {\n\tret := int(C.ImageSpec_width(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func (fw *Writer) NumRows() int { return fw.nrows }", "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 (t *Link) SetWidth(v int64) {\n\tt.width = &widthIntermediateType{nonNegativeInteger: &v}\n\n}", "func (self *Graphics) Width() int{\n return self.Object.Get(\"width\").Int()\n}", "func (m BoolMatrix) Width() int64 { return m.w }", "func (r *ImageRef) Width() int {\n\treturn int(r.image.Xsize)\n}" ]
[ "0.67532694", "0.6400872", "0.6385761", "0.6306526", "0.6233118", "0.5742466", "0.5557246", "0.5539842", "0.54203606", "0.53814673", "0.5364804", "0.53304803", "0.532151", "0.52899444", "0.52257097", "0.5220577", "0.51964474", "0.51629263", "0.51582474", "0.51361305", "0.51292014", "0.5120381", "0.5082592", "0.5012111", "0.5008549", "0.49884918", "0.49819842", "0.49653006", "0.49433553", "0.49331948", "0.4918131", "0.49176615", "0.4912207", "0.49008316", "0.48976776", "0.48867375", "0.48769134", "0.48583218", "0.48392296", "0.48361987", "0.4828132", "0.4825635", "0.48085025", "0.47985893", "0.47984195", "0.47968063", "0.47921628", "0.4790775", "0.4790103", "0.47893554", "0.478087", "0.4771731", "0.47529683", "0.47489244", "0.47476852", "0.4747388", "0.47348115", "0.4731439", "0.472675", "0.47227848", "0.47162417", "0.471449", "0.47133398", "0.47128454", "0.469735", "0.4682028", "0.4680015", "0.46798316", "0.46760687", "0.46673444", "0.46617657", "0.46564853", "0.4647828", "0.46409842", "0.4637976", "0.46331373", "0.46302807", "0.4622419", "0.46171853", "0.46050727", "0.460228", "0.459768", "0.4593761", "0.45922557", "0.4585387", "0.458152", "0.4568987", "0.45687923", "0.4561601", "0.45600253", "0.4557599", "0.4555869", "0.4547273", "0.4545643", "0.45362017", "0.45353356", "0.45275745", "0.45204258", "0.45139214" ]
0.64162534
2
Links a program object
func LinkProgram(program uint32) { C.glowLinkProgram(gpLinkProgram, (C.GLuint)(program)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (program Program) Link() {\n\tgl.LinkProgram(uint32(program))\n}", "func LinkProgram(p Program) {\n\tgl.LinkProgram(p.Value)\n}", "func LinkProgram(program uint32) {\n\tsyscall.Syscall(gpLinkProgram, 1, uintptr(program), 0, 0)\n}", "func LinkProgram(program uint32) {\n C.glowLinkProgram(gpLinkProgram, (C.GLuint)(program))\n}", "func (debugging *debuggingOpenGL) LinkProgram(program uint32) {\n\tdebugging.recordEntry(\"LinkProgram\", program)\n\tdebugging.gl.LinkProgram(program)\n\tdebugging.recordExit(\"LinkProgram\")\n}", "func (native *OpenGL) LinkProgram(program uint32) {\n\tgl.LinkProgram(program)\n}", "func (app *linker) Execute(parsed parsers.Program) (linkers.Program, error) {\n\treturn app.lnk.Execute(parsed)\n}", "func LinkProgram(program Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tC.glLinkProgram(cprogram)\n}", "func unlinkedprog(as int) *obj.Prog {\n\tp := Ctxt.NewProg()\n\tClearp(p)\n\tp.As = int16(as)\n\treturn p\n}", "func (gl *WebGL) LinkProgram(shaderProgram WebGLShaderProgram) error {\n\tgl.context.Call(\"linkProgram\", shaderProgram)\n\n\tif !gl.GetProgramParameter(shaderProgram, GlLinkStatus).Bool() {\n\t\terr := errors.New(gl.GetProgramInfoLog(shaderProgram))\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func LinkNewProgram(gl interfaces.OpenGL, shaders ...uint32) (program uint32, err error) {\n\tprogram = gl.CreateProgram()\n\n\tfor _, shader := range shaders {\n\t\tgl.AttachShader(program, shader)\n\t}\n\tgl.LinkProgram(program)\n\n\tif gl.GetProgramParameter(program, oglconsts.LINK_STATUS) == 0 {\n\t\terr = fmt.Errorf(\"%v\", gl.GetProgramInfoLog(program))\n\t\tgl.DeleteProgram(program)\n\t\tprogram = 0\n\t}\n\n\treturn\n}", "func (s *BaselimboListener) EnterProgram(ctx *ProgramContext) {}", "func (m *ProgramControl) SetProgram(value Programable)() {\n err := m.GetBackingStore().Set(\"program\", value)\n if err != nil {\n panic(err)\n }\n}", "func (r renderer) AutoLink(out *bytes.Buffer, link []byte, kind int) {}", "func (l *links) Run(ctx context.Context, args ...string) error {\n\tif len(args) != 1 {\n\t\treturn tool.CommandLineErrorf(\"links expects 1 argument\")\n\t}\n\tconn, err := l.app.connect(ctx, nil)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer conn.terminate(ctx)\n\n\tfrom := span.Parse(args[0])\n\turi := from.URI()\n\n\tif _, err := conn.openFile(ctx, uri); err != nil {\n\t\treturn err\n\t}\n\tresults, err := conn.DocumentLink(ctx, &protocol.DocumentLinkParams{\n\t\tTextDocument: protocol.TextDocumentIdentifier{\n\t\t\tURI: protocol.URIFromSpanURI(uri),\n\t\t},\n\t})\n\tif err != nil {\n\t\treturn fmt.Errorf(\"%v: %v\", from, err)\n\t}\n\tif l.JSON {\n\t\tenc := json.NewEncoder(os.Stdout)\n\t\tenc.SetIndent(\"\", \"\\t\")\n\t\treturn enc.Encode(results)\n\t}\n\tfor _, v := range results {\n\t\tfmt.Println(*v.Target)\n\t}\n\treturn nil\n}", "func (s *BaseednListener) EnterProgram(ctx *ProgramContext) {}", "func link(pack *godata.GoPackage) bool {\n\tvar argc int\n\tvar argv []string\n\tvar argvFilled int\n\tvar objDir string = \"\" //outputDirPrefix + getObjDir();\n\n\t// build the command line for the linker\n\targc = 4\n\tif *flagIncludePaths != \"\" {\n\t\targc += 2\n\t}\n\tif pack.NeedsLocalSearchPath() {\n\t\targc += 2\n\t}\n\tif pack.Name == \"main\" {\n\t\targc += 2\n\t}\n\n\targv = make([]string, argc*3)\n\n\targv[argvFilled] = linkerBin\n\targvFilled++\n\targv[argvFilled] = \"-o\"\n\targvFilled++\n\targv[argvFilled] = outputDirPrefix + pack.OutputFile\n\targvFilled++\n\tif *flagIncludePaths != \"\" {\n\t\tfor _, v := range strings.Split(*flagIncludePaths, \",\", -1) {\n\t\t\targv[argvFilled] = \"-L\"\n\t\t\targvFilled++\n\t\t\targv[argvFilled] = v\n\t\t\targvFilled++\n\t\t}\n\t}\n\t// \tif pack.NeedsLocalSearchPath() {\n\t// \t\targv[argvFilled] = \"-L\"\n\t// \t\targvFilled++\n\t// \t\tif objDir != \"\" {\n\t// \t\t\targv[argvFilled] = objDir\n\t// \t\t} else {\n\t// \t\t\targv[argvFilled] = \".\"\n\t// \t\t}\n\t// \t\targvFilled++\n\t// \t}\n\tif pack.Name == \"main\" {\n\t\targv[argvFilled] = \"-L\"\n\t\targvFilled++\n\t\targv[argvFilled] = \".\"\n\t\targvFilled++\n\t}\n\targv[argvFilled] = objDir + pack.OutputFile + objExt\n\targvFilled++\n\n\tlogger.Info(\"Linking %s...\\n\", argv[2])\n\tlogger.Info(\" %s\\n\\n\", getCommandline(argv))\n\n\tcmd, err := exec.Run(linkerBin, argv[0:argvFilled], os.Environ(), rootPath,\n\t\texec.DevNull, exec.PassThrough, exec.PassThrough)\n\tif err != nil {\n\t\tlogger.Error(\"%s\\n\", err)\n\t\tos.Exit(1)\n\t}\n\twaitmsg, err := cmd.Wait(0)\n\tif err != nil {\n\t\tlogger.Error(\"Linker execution error (%s), aborting compilation.\\n\", err)\n\t\tos.Exit(1)\n\t}\n\n\tif waitmsg.ExitStatus() != 0 {\n\t\tlogger.Error(\"Linker returned with errors, aborting.\\n\")\n\t\treturn false\n\t}\n\treturn true\n}", "func BuildAppLink(appNames []string) {\n\tgenSource(runtimePath, \"Processer.go\", APPLINK, map[string]interface{}{\"Apps\": appNames})\n}", "func (s *BaseAspidaListener) EnterProgram(ctx *ProgramContext) {}", "func UseProgram(p Program) {\n\tgl.UseProgram(p.Value)\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 (s *BasemumpsListener) EnterProgram(ctx *ProgramContext) {}", "func UseProgram(program uint32) {\n\tsyscall.Syscall(gpUseProgram, 1, uintptr(program), 0, 0)\n}", "func (s *BaseBrainfuckListener) EnterProgram(ctx *ProgramContext) {}", "func (p *Parser)program() {\n\tp.declarations()\n\tp.begin()\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 Link(client *occlient.Client, sourceComponent, targetComponent, applicationName string) (*LinkInfo, error) {\n\t// Get Service associated with the target component\n\tserviceLabels := componentlabels.GetLabels(targetComponent, applicationName, false)\n\tserviceSelector := util.ConvertLabelsToSelector(serviceLabels)\n\ttargetService, err := client.GetOneServiceFromSelector(serviceSelector)\n\tif err != nil {\n\t\treturn nil, errors.Wrapf(err, \"unable to get service associated with the component %v\", targetComponent)\n\t}\n\n\t// Generate environment variables to inject\n\tlinkHostKey := fmt.Sprintf(\"COMPONENT_%v_HOST\", strings.ToUpper(targetComponent))\n\tlinkHostValue := targetService.Name\n\n\tlinkPortKey := fmt.Sprintf(\"COMPONENT_%v_PORT\", strings.ToUpper(targetComponent))\n\tlinkPort, err := getPortFromService(targetService)\n\tif err != nil {\n\t\treturn nil, errors.Wrapf(err, \"unable to get port from Service %v\", targetService.Name)\n\t}\n\tlinkPortValue := fmt.Sprint(linkPort)\n\n\t// Inject environment variable to source component\n\tdcLabels := componentlabels.GetLabels(sourceComponent, applicationName, false)\n\tdcSelector := util.ConvertLabelsToSelector(dcLabels)\n\tsourceDC, err := client.GetOneDeploymentConfigFromSelector(dcSelector)\n\tif err != nil {\n\t\treturn nil, errors.Wrapf(err, \"unable to get Deployment Config for component %v\", sourceComponent)\n\t}\n\n\tif err := client.AddEnvironmentVariablesToDeploymentConfig(\n\t\t[]corev1.EnvVar{\n\t\t\t{\n\t\t\t\tName: linkHostKey,\n\t\t\t\tValue: linkHostValue,\n\t\t\t},\n\t\t\t{\n\t\t\t\tName: linkPortKey,\n\t\t\t\tValue: linkPortValue,\n\t\t\t},\n\t\t}, sourceDC); err != nil {\n\t\treturn nil, errors.Wrapf(err, \"unable to add environment variables to Deployment Config %v\", sourceDC.Name)\n\t}\n\n\treturn &LinkInfo{\n\t\tSourceComponent: sourceComponent,\n\t\tTargetComponent: targetComponent,\n\t\tEnvs: []string{\n\t\t\tfmt.Sprintf(\"%v=%v\", linkHostKey, linkHostValue),\n\t\t\tfmt.Sprintf(\"%v=%v\", linkPortKey, linkPortValue),\n\t\t},\n\t}, 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 LinkCmd(parentName string) *cobra.Command {\n\treturn &cobra.Command{\n\t\tUse: \"link [code]\",\n\t\tShort: \"Link multiple machines to your Charm account\",\n\t\tLong: paragraph(\"It’s easy to \" + keyword(\"link\") + \" multiple machines or keys to your Charm account. Just run \" + code(parentName+\" link\") + \" on a machine connected to the account to want to link to start the process.\"),\n\t\tExample: indent.String(fmt.Sprintf(\"%s link\\b%s link XXXXXX\", parentName, parentName), 2),\n\t\tArgs: cobra.RangeArgs(0, 1),\n\t\tRunE: func(cmd *cobra.Command, args []string) error {\n\t\t\t// Log to file if specified in the environment\n\t\t\tcfg := getCharmConfig()\n\t\t\tif cfg.Logfile != \"\" {\n\t\t\t\tf, err := tea.LogToFile(cfg.Logfile, \"charm\")\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tdefer f.Close() //nolint:errcheck\n\t\t\t}\n\n\t\t\tvar p *tea.Program\n\t\t\tswitch len(args) {\n\t\t\tcase 0:\n\t\t\t\t// Initialize a linking session\n\t\t\t\tp = linkgen.NewProgram(cfg, parentName)\n\t\t\tdefault:\n\t\t\t\t// Join in on a linking session\n\t\t\t\tp = link.NewProgram(cfg, args[0])\n\t\t\t}\n\t\t\tif _, err := p.Run(); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\treturn nil\n\t\t},\n\t}\n}", "func NewProgram(lessons []*LessonPgm) *Program {\n\treturn &Program{base.WildCardLabel, lessons}\n}", "func LinkNewStandardProgram(gl interfaces.OpenGL, vertexShaderSource, fragmentShaderSource string) (program uint32, err error) {\n\tvertexShader, vertexErr := CompileNewShader(gl, oglconsts.VERTEX_SHADER, vertexShaderSource)\n\tdefer gl.DeleteShader(vertexShader)\n\tfragmentShader, fragmentErr := CompileNewShader(gl, oglconsts.FRAGMENT_SHADER, fragmentShaderSource)\n\tdefer gl.DeleteShader(fragmentShader)\n\n\tif (vertexErr == nil) && (fragmentErr == nil) {\n\t\tprogram, err = LinkNewProgram(gl, vertexShader, fragmentShader)\n\t} else {\n\t\terr = fmt.Errorf(\"[OpenGL Utils] Error compiling shaders:\\n%v\\n%v\", vertexErr, fragmentErr)\n\t}\n\n\treturn\n}", "func (bh *Header) AddProgram(p *Program) error {\n\tif _, ok := bh.seenProgs[p.uid]; ok {\n\t\treturn errDupProgram\n\t}\n\tif p.owner != nil || p.id >= 0 {\n\t\treturn errUsedProgram\n\t}\n\tp.owner = bh\n\tp.id = int32(len(bh.progs))\n\tbh.seenProgs[p.uid] = p.id\n\tbh.progs = append(bh.progs, p)\n\treturn nil\n}", "func (amv *AMV) Link() string {\n\treturn \"/amv/\" + amv.ID\n}", "func (b *ProgramControlRequestBuilder) Program() *ProgramRequestBuilder {\n\tbb := &ProgramRequestBuilder{BaseRequestBuilder: b.BaseRequestBuilder}\n\tbb.baseURL += \"/program\"\n\treturn bb\n}", "func (s *BaseLittleDuckListener) EnterPrograma(ctx *ProgramaContext) {}", "func Link(oldname, newname string) error", "func (am *Manager) AddProgram(set ShaderSet, prog uint32) error {\n\tif _, ok := am.GetProgram(set); ok {\n\t\treturn fmt.Errorf(\"asset.Manager.AddProgram error: Program '%v' already exists\", set)\n\t}\n\n\tLogger.Printf(\"Manager: adding Program '%v'\\n\", set)\n\tam.Programs[set] = prog\n\n\treturn nil\n}", "func (rs accessResources) Link(w http.ResponseWriter, r *http.Request) {\n\tw.Write( []byte( \"Linking...\" ) )\n}", "func UseProgram(program uint32) {\n\tC.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func UseProgram(program uint32) {\n\tC.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func (m *ProgramControl) GetProgram()(Programable) {\n val, err := m.GetBackingStore().Get(\"program\")\n if err != nil {\n panic(err)\n }\n if val != nil {\n return val.(Programable)\n }\n return nil\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\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 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(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 (f *Flags) Link() {\n\tflag.StringVar(&f.ConfigPath, \"c\", \"clutch-config.yaml\", \"path to YAML configuration\")\n\tflag.BoolVar(&f.Template, \"template\", false, \"executes go templates on the configuration file\")\n\tflag.BoolVar(&f.Validate, \"validate\", false, \"validates the configuration file and exits\")\n}", "func (r renderer) Link(out *bytes.Buffer, link []byte, title []byte, content []byte) {\n\tout.Write(content)\n}", "func (obj *miner) ToLink() blocks.Blocks {\n\treturn obj.toLink\n}", "func (l *CPIO9PFID) Link(target p9.File, newname string) error {\n\treturn os.ErrPermission\n}", "func (coll *Collection) DetachProgram(name string) *Program {\n\tp := coll.Programs[name]\n\tdelete(coll.Programs, name)\n\treturn p\n}", "func execLinkAppender(link string) {\n\t_, err := exec.Command(\"rssadd\", link).Output()\n\tif err != nil {\n\t\tlog.Fatalln(\"Can't exec rssadd: \", err)\n\t}\n}", "func (debugging *debuggingOpenGL) UseProgram(program uint32) {\n\tdebugging.recordEntry(\"UseProgram\", program)\n\tdebugging.gl.UseProgram(program)\n\tdebugging.recordExit(\"UseProgram\")\n}", "func mainAlias(ctx *cli.Context) error {\n\tcli.ShowCommandHelp(ctx, ctx.Args().First())\n\treturn nil\n\t// Sub-commands like add, list and remove have their own main.\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 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 (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 (c *Chip8) LoadProgram(prog string) {\n\tprogFile, err := os.Open(prog)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\t_, err = progFile.Read(c.memory[progStart:])\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func evalProgram(prog *ast.Program, e *object.Env) object.Object {\n\tvar result object.Object\n\n\tfor _, stmt := range prog.Statements {\n\t\tresult = Eval(stmt, e)\n\t\tif result == nil {\n\t\t\treturn &object.Error{\n\t\t\t\tMessage: \"NULL encounterd.\",\n\t\t\t}\n\t\t}\n\t\tif result.Type() == object.ReturnObject {\n\t\t\treturn result.(*object.Return).Value\n\t\t}\n\t}\n\n\treturn result\n}", "func main() {\n\tdefer contracts.ShowHelp(help)\n\tnProd, nCons, bufferSize := parseArguments()\n\n\tprogram(nProd, nCons, bufferSize)\n}", "func (c *Collector) Link() string {\n\treturn \"\"\n}", "func (l LocalLinker) Link(file string, line int) string {\n\treturn localFileFunc(file) + \":\" + strconv.Itoa(line)\n}", "func main() {\n\ta := createHelp()\n\terr := a.Run(os.Args)\n\tif err != nil {\n\t\tfmt.Fprintln(os.Stderr, err)\n\t\tos.Exit(1)\n\t}\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\t// Println prints the phrase on the standard output and also break a line.\n\tfmt.Println(\"Hello Gophers!!\")\n}", "func (p Pointer) Link(ctx context.Context, n path.Node) (path.Node, error) {\n\tif cmd := path.FindCommand(n); cmd != nil {\n\t\treturn cmd.MemoryAfter(uint32(p.Pool), p.Address, 0), nil\n\t}\n\treturn nil, nil\n}", "func (b *Binary) Link() string {\n\treturn fmt.Sprintf(`/data/%s/%d/%s/%s`, b.TableName(), b.ID, \"data\", b.Hash)\n}", "func main() {\n\tapp := &cli.App{\n\t\tName: \"RULEX, a lightweight iot data rule gateway\",\n\t\tUsage: \"http://rulex.ezlinker.cn\",\n\t\tCommands: []*cli.Command{\n\t\t\t{\n\t\t\t\tName: \"run\",\n\t\t\t\tUsage: \"rulex run [path of 'rulex.db']\",\n\t\t\t\tAction: func(c *cli.Context) error {\n\t\t\t\t\tutils.ShowBanner()\n\t\t\t\t\tif c.Args().Len() > 0 {\n\t\t\t\t\t\tlog.Info(\"Use config db:\", c.Args().Get(0))\n\t\t\t\t\t\tengine.RunRulex(c.Args().Get(0))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tengine.RunRulex(\"rulex.db\")\n\t\t\t\t\t}\n\t\t\t\t\tlog.Debug(\"Run rulex successfully.\")\n\t\t\t\t\treturn nil\n\t\t\t\t},\n\t\t\t},\n\t\t\t// version\n\t\t\t{\n\t\t\t\tName: \"version\",\n\t\t\t\tUsage: \"rulex version\",\n\t\t\t\tAction: func(c *cli.Context) error {\n\t\t\t\t\tfmt.Println(\"Current Version is: \" + typex.DefaultVersion.Version)\n\t\t\t\t\treturn nil\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t}\n\n\terr := app.Run(os.Args)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\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 (r *Workload) Link(p *api.Provider) {\n\tr.SelfLink = base.Link(\n\t\tWorkloadRoot,\n\t\tbase.Params{\n\t\t\tbase.ProviderParam: string(p.UID),\n\t\t\tVMParam: r.ID,\n\t\t})\n\tr.Cluster.Link(p)\n\tr.DataCenter.Link(p)\n\tif r.Host != nil {\n\t\tr.Host.Link(p)\n\t}\n}", "func (emitter *Emitter) EmitExecutable(executable string) (err error) {\n\tobjfile := fmt.Sprintf(\"%s.tmp.o\", executable)\n\tobj, err := emitter.EmitObject()\n\tif err != nil {\n\t\treturn\n\t}\n\tif err = ioutil.WriteFile(objfile, obj, 0666); err != nil {\n\t\treturn\n\t}\n\tdefer os.Remove(objfile)\n\tlinker := newDefaultLinker(emitter.LinkerFlags)\n\terr = linker.link(executable, []string{objfile})\n\t// Linker link runtime and make an executable\n\treturn\n}", "func main() {\n\n\tflag.Parse()\n\tif *helpBoolFlag || *urlStringFlag == \"\" {\n\t\tflag.Usage()\n\t\tos.Exit(0)\n\t}\n\n\tbow := surf.NewBrowser()\n\terr := bow.Open(*urlStringFlag)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tfmt.Println(\">> Title:\")\n\tfmt.Println(bow.Title())\n\tfmt.Println()\n\tfmt.Println(\">> Images:\")\n\tfor i, image := range bow.Images() {\n\t\tfmt.Println(i, image.ID, image.URL)\n\t}\n\tfmt.Println()\n\tfmt.Println(\">> Links:\")\n\tfor i, link := range bow.Links() {\n\t\tfmt.Println(i, link.URL)\n\t}\n}", "func Program(importPath string) (*loader.Program, error) {\n\tcacheLock.Lock()\n\tdefer cacheLock.Unlock()\n\tif p := importCache[importPath]; p != nil {\n\t\treturn p, nil\n\t}\n\tloadConfig.Import(importPath)\n\tp, err := loadConfig.Load()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\timportCache[importPath] = p\n\treturn p, err\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 Readlink(name string) (string, error)", "func main() {\n\tapp := cli.NewApp()\n\n\tapp.Commands = commands()\n\n\terr := app.Run(os.Args)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n}", "func Link(url, text string) string {\n\treturn Osc + \"8;;\" + url + Bel + text + Osc + \"8;;\" + Bel\n}", "func main() {\n\tapplication.Application()\n}", "func (t *astTest) Link() *errors.JVSAstError {\n\t//link build\n\t//builds have been all parsed\n\tif t.buildName != \"\" {\n\t\tbuild := jvsAstRoot.GetBuild(t.buildName)\n\t\tif build == nil {\n\t\t\treturn errors.JVSAstLinkError(t.Name+\"(\"+t.file+\")\", \"build \"+t.buildName+\" of \"+t.Name+\"is undef!\")\n\t\t}\n\t\tt.build = build\n\t}\n\tfor _, arg := range t.args {\n\t\t//Options have been all parsed\n\t\topt, err := GetJvsAstOption(arg)\n\t\tif err != nil {\n\t\t\treturn errors.JVSAstLinkError(\"args of \"+t.Name+\"(\"+t.file+\")\", err.Error())\n\t\t}\n\t\tt.optionArgs.Add(opt.GetName(), opt.Clone())\n\n\t}\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 (native *OpenGL) UseProgram(program uint32) {\n\tgl.UseProgram(program)\n}", "func (app *App) Run(addr string) {}", "func (b *AddonInstallationBuilder) Link(value bool) *AddonInstallationBuilder {\n\tb.bitmap_ |= 1\n\treturn b\n}", "func main() {\n\truntime.GOMAXPROCS(runtime.NumCPU())\n\n\tapp := cliapp.NewApp()\n\tapp.Version = \"1.0.3\"\n\tapp.Description = \"this is my cli application\"\n\n\tapp.SetVerbose(cliapp.VerbDebug)\n\t// app.DefaultCmd(\"exampl\")\n\n\tapp.Add(cmd.GitCommand())\n\t// app.Add(cmd.ColorCommand())\n\tapp.Add(builtin.GenShAutoComplete())\n\t// fmt.Printf(\"%+v\\n\", cliapp.CommandNames())\n\tapp.Run()\n}", "func main() {\n\ta := &computer{\"Apple\"}\n\tb := a\n\tchange(b)\n\tchange(b)\n}", "func main() {\n\tMain(todo.OpenDB)\n}", "func (program Program) Use() {\n\tgl.UseProgram(uint32(program))\n}", "func (prg Program) Pointer(ctx gl.Context, a gl.Attrib, size int) {\n\tctx.EnableVertexAttribArray(a)\n\tctx.VertexAttribPointer(a, size, gl.FLOAT, false, 0, 0)\n}", "func (*testObject) LinkAddress() tcpip.LinkAddress {\n\treturn \"\"\n}", "func ShowUsage() {\n\tprintln(\"Usage:\\n\\thref_links <html source file>\\n\\tRead content from stdin: href_links -\\ne.g. curl https://example.com/ | href_links -\\nBy default utility tries read ./home.html\")\n\n}", "func (compiler *Compiler) Link() (err error) {\n\n\tdefer func() {\n\t\tif e := recover(); e != nil {\n\t\t\terr = e.(error)\n\t\t}\n\t}()\n\n\tlinker := &_Linker{\n\t\tLog: gslogger.Get(\"linker\"),\n\t\ttypes: make(map[string]ast.Type),\n\t\terrorHandler: compiler.errorHandler,\n\t\tcompiler: compiler,\n\t}\n\n\tcompiler.module.Foreach(func(script *ast.Script) bool {\n\t\tlinker.createSymbolTable(script)\n\t\treturn true\n\t})\n\n\tcompiler.module.Types = linker.types\n\n\tcompiler.module.Foreach(func(script *ast.Script) bool {\n\t\tlinker.linkTypes(script)\n\t\treturn true\n\t})\n\n\tcompiler.module.Foreach(func(script *ast.Script) bool {\n\n\t\tscript.TypeForeach(func(gslangType ast.Type) {\n\n\t\t\tlinker.checkAnnotation(script, gslangType)\n\t\t})\n\n\t\treturn true\n\t})\n\n\treturn\n}", "func (app *application) Link(additional uint) error {\n\tendpoint := fmt.Sprintf(\"%s%d\", \"/links/\", additional)\n\turl := fmt.Sprintf(baseFormat, app.url, endpoint)\n\tresp, err := app.client.R().\n\t\tSetHeader(shared.TokenHeadKeyname, app.token).\n\t\tPost(url)\n\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif resp.StatusCode() == http.StatusOK {\n\t\treturn nil\n\t}\n\n\treturn errors.New(string(resp.Body()))\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() *Program {\n\treturn &Program{\n\t\tframe: EmptyFrame(),\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\tother.Hail()\n}", "func main() {\n\tdomTarget := dom.GetWindow().Document().GetElementByID(\"app\")\n\n\tr.Render(container.Container(), domTarget)\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 (pool *PackagePool) Link(path, dstPath string) error {\n\treturn os.Link(filepath.Join(pool.rootPath, path), dstPath)\n}", "func main() {\n\tdebugln(\"main!\")\n}" ]
[ "0.72972095", "0.6831142", "0.6822032", "0.65613335", "0.65003073", "0.61334103", "0.58112955", "0.577948", "0.5677661", "0.5647645", "0.55451894", "0.55361384", "0.54883385", "0.5471105", "0.54211915", "0.53957856", "0.53956985", "0.53811044", "0.5370915", "0.53390664", "0.52913606", "0.5212983", "0.51984394", "0.51657903", "0.51214385", "0.51148003", "0.51041704", "0.50888175", "0.50804025", "0.5062978", "0.504586", "0.5045138", "0.50428814", "0.5030429", "0.50094444", "0.499724", "0.4994348", "0.49556908", "0.49438584", "0.49438584", "0.49378064", "0.49295548", "0.49140045", "0.4907104", "0.49044195", "0.49010643", "0.48952934", "0.48693058", "0.4866425", "0.4866164", "0.48581302", "0.48335218", "0.48177254", "0.48153925", "0.4785069", "0.47817338", "0.47750416", "0.47601345", "0.47566485", "0.4755213", "0.4747413", "0.47355196", "0.47310498", "0.47309023", "0.47301534", "0.4725154", "0.47169316", "0.47136143", "0.4713104", "0.4712509", "0.4706892", "0.47033834", "0.47029975", "0.47019958", "0.46953246", "0.46880287", "0.46771684", "0.46751118", "0.4672282", "0.4671932", "0.4662664", "0.46619922", "0.46615896", "0.4644251", "0.4639079", "0.46353304", "0.46352223", "0.46273193", "0.46226975", "0.46214542", "0.46178493", "0.4617012", "0.46135107", "0.46123743", "0.46115375", "0.46107566", "0.46061003", "0.46010804", "0.45955878" ]
0.6486157
6
set the displaylist base for
func ListBase(base uint32) { C.glowListBase(gpListBase, (C.GLuint)(base)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (m *List) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func ListBase(base uint32) {\n\tsyscall.Syscall(gpListBase, 1, uintptr(base), 0, 0)\n}", "func ListBase(base uint32) {\n C.glowListBase(gpListBase, (C.GLuint)(base))\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 (controller *List) Display() {\n\tcontroller.Data[\"searches\"] = controller.Account.GetSearches().GetAll()\n\tcontroller.SetCustomTitle(\"Account - Activity\")\n\tcontroller.LoadTemplate(\"home\")\n}", "func (l *FileList) Display(\n\taccessKey *ui.Entry,\n\tsecretKey *ui.Entry,\n\tbucket *ui.Entry) (err error) {\n\n\tlist, err := comm.Refresh(\n\t\taccessKey.Text(), secretKey.Text(), bucket.Text())\n\n\tif err != nil {\n\t\treturn\n\t}\n\tlog.Println(\"Displaying the list.\")\n\n\tl.name.Clear()\n\tl.mType.Clear()\n\tl.size.Clear()\n\tl.checkbox.Clear()\n\tlog.Println(\"Boxes cleared.\")\n\n\tl.NameList = []string{}\n\tl.CheckboxList = []*ui.Checkbox{}\n\tlog.Println(\"Lists cleared.\")\n\n\t// Fix the number of the list.\n\t// TODO: clear this limit.\n\tif len(list) > 30 {\n\t\tlist = list[:30]\n\t}\n\n\tfor _, item := range list {\n\t\tl.name.Append(ui.NewLabel(item.Key), true)\n\t\tl.NameList = append(l.NameList, item.Key)\n\n\t\tl.mType.Append(ui.NewLabel(item.MimeType), true)\n\t\tl.size.Append(\n\t\t\tui.NewLabel(tool.FormatSize(item.Fsize)), true)\n\n\t\ttempCheckbox := ui.NewCheckbox(\"\")\n\t\tl.checkbox.Append(tempCheckbox, true)\n\t\tl.CheckboxList = append(l.CheckboxList, tempCheckbox)\n\t}\n\tlog.Println(\"Displayed the list.\")\n\n\treturn\n}", "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 (c *UsageController) setList(list []models.Usage) {\n\tc.Usage = list\n\tc.parseNewID()\n}", "func (ll *linkedList) display() {\n\tfor tip := ll.head; tip != nil; tip = tip.Next {\n\t\tfmt.Printf(\"NODE: %+v %p \\n\", tip, tip)\n\t}\n\tfmt.Println()\n}", "func (lc *imgListCfg) displayImagesOnRegistry(ims []utils.Repositories) {\n\n\t// get \"username/\"\n\tu := lc.pf.username + \"/\"\n\n\tfor _, r := range ims {\n\t\tfor _, i := range r.ImgNames {\n\n\t\t\t// display image excluding top of \"username/\"\n\t\t\tp := strings.Index(i, u)\n\t\t\tif p == -1 { // not display image whose top is not \"username/\"\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfmt.Println(i[len(u):])\n\t\t}\n\t}\n}", "func newBaseInstanceList(allocateCIDR bool, clusterCIDR *net.IPNet, subnetMaskSize int) *baseInstanceList {\n\tcidrSet, _ := cidrset.NewCIDRSet(clusterCIDR, subnetMaskSize)\n\treturn &baseInstanceList{\n\t\tallocateCIDR: allocateCIDR,\n\t\tclusterCIDR: clusterCIDR,\n\t\tsubnetMaskSize: subnetMaskSize,\n\t\tcidrSet: cidrSet,\n\t\tinstances: make(map[meta.Key]*baseInstance),\n\t}\n}", "func (L *List) Display() {\n\tnode := L.Head\n\tfor node != nil {\n\t\tfmt.Printf(\"%+v -> \", node.Key)\n\t\tnode = node.next\n\t}\n\tfmt.Println(\"---\")\n}", "func (l *List) Display() {\n\tlst := l.head\n\tfor lst != nil {\n\t\tif lst.next != nil {\n\t\t\tfmt.Printf(\"%+v -> \", lst.val)\n\t\t} else {\n\t\t\tfmt.Printf(\"%+v\", lst.val)\n\t\t}\n\t\tlst = lst.next\n\t}\n\tfmt.Println()\n}", "func ShowCurrentUserList() {\n\tul := &define.UserList\n\tShowUserList(ul)\n}", "func (d *Inbrs) DisplayTable(w io.Writer) {\n\tvar data [][]string\n\tfor _, s := range d.list {\n\t\tdata = append(data, []string{s.hostname, s.intName, s.area,\n\t\t\ts.remoteID, s.fwAddress.String()})\n\t}\n\ttable := tablewriter.NewWriter(w)\n\ttable.SetHeader([]string{\"hostname\", \"interface\", \"area\", \"remote id\", \"FW address\"})\n\tfor _, v := range data {\n\t\ttable.Append(v)\n\t}\n\ttable.Render() // Send output\n}", "func (m *IdentityProviderBase) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func DisplayAll() {\n\n\tif len(dataStorageMap) == 0 {\n\t\tfmt.Println(\"Data Storage Empty!!! No data Found !!!\")\n\t} else {\n\t\tfor key, val := range dataStorageMap {\n\t\t\tfmt.Println(key, \"-->\", val)\n\t\t}\n\t}\n}", "func (mysqlFlavor) baseShowTables() string {\n\treturn \"SELECT table_name, table_type, unix_timestamp(create_time), table_comment FROM information_schema.tables WHERE table_schema = database()\"\n}", "func (l *Typelist) setStorageFormat(format string) {\n\tFormat = format\n}", "func (r *Ri) Display(name, typeof, mode RtToken, parameterlist ...Rter) error {\n\n\tvar out = []Rter{name, typeof, mode, PARAMETERLIST}\n\tout = append(out, parameterlist...)\n\n\treturn r.writef(\"Display\", out...)\n}", "func (m *BrowserSiteList) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (r *LocalRegistry) List(artHome string, extended bool) {\n\t// get a table writer for the stdout\n\tw := tabwriter.NewWriter(os.Stdout, 0, 0, 1, ' ', tabwriter.Debug)\n\t// print the header row\n\tvar err error\n\tif extended {\n\t\t_, err = fmt.Fprintln(w, i18n.String(artHome, i18n.LBL_LS_HEADER_PLUS))\n\t} else {\n\t\t_, err = fmt.Fprintln(w, i18n.String(artHome, i18n.LBL_LS_HEADER))\n\t}\n\tcore.CheckErr(err, \"failed to write table header\")\n\tvar (\n\t\ts *data.Seal\n\t\tauthor string\n\t)\n\t// repository, tag, package id, created, size\n\tfor _, repo := range r.Repositories {\n\t\tfor _, a := range repo.Packages {\n\t\t\ts, err = r.GetSeal(a)\n\t\t\tif err != nil {\n\t\t\t\tauthor = \"unknown\"\n\t\t\t} else {\n\t\t\t\tauthor = s.Manifest.Author\n\t\t\t}\n\t\t\t// if the package is dangling (no tags)\n\t\t\tif len(a.Tags) == 0 {\n\t\t\t\tif extended {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\t\"<none>\",\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size,\n\t\t\t\t\t\tauthor),\n\t\t\t\t\t)\n\t\t\t\t} else {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\t\"<none>\",\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size),\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t\tcore.CheckErr(err, \"failed to write output\")\n\t\t\t}\n\t\t\tfor _, tag := range a.Tags {\n\t\t\t\tif extended {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\ttag,\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size,\n\t\t\t\t\t\tauthor),\n\t\t\t\t\t)\n\t\t\t\t} else {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\ttag,\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size),\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t\tcore.CheckErr(err, \"failed to write output\")\n\t\t\t}\n\t\t}\n\t}\n\terr = w.Flush()\n\tcore.CheckErr(err, \"failed to flush output\")\n}", "func (s *BaselimboListener) EnterInit_list(ctx *Init_listContext) {}", "func initHistlist(ed editor, ev *eval.Evaler, getCmds func() ([]string, error), lsMode *listing.Mode, lsBinding *bindingMap) eval.Ns {\n\tbinding := emptyBindingMap\n\tmode := histlist.Mode{\n\t\tMode: lsMode,\n\t\tKeyHandler: keyHandlerFromBindings(ed, ev, &binding, lsBinding),\n\t}\n\tns := eval.Ns{}.\n\t\tAddGoFn(\"<edit:histlist>\", \"start\", func() {\n\t\t\tstartHistlist(ed, getCmds, &mode)\n\t\t})\n\treturn ns\n}", "func (m *AdministrativeUnit) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func updateDisplays(elevatorFloor int, e *Elevator) {\n\tfor _, display := range e.floorDisplaysList {\n\t\tdisplay.floor = elevatorFloor\n\t}\n}", "func (m *RemoteAssistancePartner) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (l *ToDoList) showList() []string {\n\treturn l.list\n}", "func (s *BasevhdlListener) EnterGeneric_list(ctx *Generic_listContext) {}", "func (ll *Doubly[T]) Display() {\n\tfor cur := ll.Head.Next; cur != ll.Head; cur = cur.Next {\n\t\tfmt.Print(cur.Val, \" \")\n\t}\n\n\tfmt.Print(\"\\n\")\n}", "func (x *FzDisplayList) Ref() *C.fz_display_list {\n\tif x == nil {\n\t\treturn nil\n\t}\n\treturn (*C.fz_display_list)(unsafe.Pointer(x))\n}", "func (l List) ShowList() {\n\tfmt.Println(\"ID\\tArrival\\tBurst\\tPriority\")\n\n\tfor i := 0; i < len(l); i++ {\n\t\tfmt.Printf(\"%d\\t%d\\t%d\\t%d\\n\",\n\t\t\tl[i].ID, l[i].Arrival, l[i].Burst, l[i].Priority)\n\t}\n\tfmt.Printf(\"Number of jobs: %d\\n\\n\", len(l))\n}", "func (cl ContactList) DisplayContacts() {\n\tfor _, contact := range cl.directory {\n\t\tfmt.Println(\" Name :\", contact.Name)\n\t\tfmt.Printf(\"Address : %s:%s\\n\", contact.Address, contact.Port)\n\t}\n}", "func (b *Skiplist) DisplayAll() {\n\tfmt.Printf(\"\\nhead->\")\n\tcurrentNode := b.Header\n\n\t//Draw forward[0] base\n\tfor {\n\t\tif (currentNode.flags&f_first)==0 {\n\t\t\tfmt.Printf(\"[key:%v][val:%v]->\", currentNode.Key, currentNode.Val)\n\t\t} else {\n\t\t\tfmt.Printf(\"[HEAD]->\")\n\t\t}\n\t\tif currentNode.Forward[0] == nil {\n\t\t\tbreak\n\t\t}\n\t\tcurrentNode = currentNode.Forward[0]\n\t}\n\tfmt.Printf(\"nil\\n\")\n\n\tfmt.Println(\"---------------------------------------------------------\")\n\tcurrentNode = b.Header\n\t//Draw all data node.\n\tfor {\n\t\tif (currentNode.flags&f_first)==0 {\n\t\t\tfmt.Printf(\"[node:%v], val:%v, level:%d \", currentNode.Key, currentNode.Val, currentNode.Level)\n\t\t} else {\n\t\t\tfmt.Printf(\"[HEAD], level:%d \", currentNode.Level)\n\t\t}\n\n\t\tif currentNode.Forward[0] == nil {\n\t\t\tbreak\n\t\t}\n\n\t\tfor j := currentNode.Level - 1; j >= 0; j-- {\n\t\t\tfmt.Printf(\" fw[%d]:\", j)\n\t\t\tif currentNode.Forward[j] != nil {\n\t\t\t\tfmt.Printf(\"%v\", currentNode.Forward[j].Key)\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"nil\")\n\t\t\t}\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t\tcurrentNode = currentNode.Forward[0]\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func (m *Group) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (m *AccessPackageCatalog) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (m *_ViewDescription) InitializeParent(parent ExtensionObjectDefinition) {}", "func (m *List) SetList(value ListInfoable)() {\n m.list = value\n}", "func (m *WorkforceIntegration) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (a *adapter) setList(l []*net.IPNet) {\n\ta.atomicList.Store(l)\n}", "func ShowUserList(ul *[]define.User) {\n\t//ul := &define.UserList\n\tt := tablewriter.NewWriter(os.Stdout)\n\tt.SetAutoFormatHeaders(false)\n\tt.SetAutoWrapText(false)\n\tt.SetReflowDuringAutoWrap(false)\n\tt.SetHeader([]string{\"ID\", \"Name\", \"Cell\", \"Address\", \"Born\", \"Passwd\"})\n\tfor _, user := range *ul {\n\t\tid := strconv.FormatUint(uint64(user.ID), 10)\n\t\tt.Append([]string{id, user.Name, user.Cell, user.Address,\n\t\t\tuser.Born.Format(\"2006.01.02\"), user.Passwd})\n\t}\n\tt.Render()\n}", "func (m *NamedLocation) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (w *ListWidget) SetView(view *gocui.View) {\n\tw.base.SetView(view)\n\tw.base.Highlight = w.Highlight\n\tw.render()\n}", "func (w *ListWidget) View() *gocui.View {\n\treturn w.base.View()\n}", "func (m *Drive) SetList(value Listable)() {\n m.list = value\n}", "func (s *BaseednListener) EnterList_(ctx *List_Context) {}", "func (m *List) SetSystem(value SystemFacetable)() {\n m.system = value\n}", "func (s *BasevhdlListener) EnterInstantiation_list(ctx *Instantiation_listContext) {}", "func (srv *PolicyDBServer) ListBaseNames(\n\tctx context.Context,\n\tnetworkId *orcprotos.NetworkID,\n) (*protos.ChargingRuleNameSet, error) {\n\ttable := datastore.GetTableName(networkId.GetId(), CHARGING_RULE_BASE_NAME_TABLE)\n\tkeys, err := srv.store.ListKeys(table)\n\tif err != nil {\n\t\tglog.Error(err)\n\t\treturn &protos.ChargingRuleNameSet{}, status.Errorf(\n\t\t\tcodes.Aborted, \"Error listing Base Names %s, for network: %s\", err, networkId.GetId())\n\t}\n\treturn &protos.ChargingRuleNameSet{RuleNames: keys}, nil\n}", "func (pt AuthProviderType) Display() string {\n\tswitch pt {\n\tcase AuthProviderTypeAnonymous:\n\t\treturn \"Anonymous\"\n\tcase AuthProviderTypeUserPassword:\n\t\treturn \"User/Password\"\n\tcase AuthProviderTypeAPIKey:\n\t\treturn \"ApiKey\"\n\tcase AuthProviderTypeApple:\n\t\treturn \"Apple\"\n\tcase AuthProviderTypeGoogle:\n\t\treturn \"Google\"\n\tcase AuthProviderTypeFacebook:\n\t\treturn \"Facebook\"\n\tcase AuthProviderTypeCustomToken:\n\t\treturn \"Custom JWT\"\n\tcase AuthProviderTypeCustomFunction:\n\t\treturn \"Custom Function\"\n\tdefault:\n\t\treturn \"Unknown\"\n\t}\n}", "func List() {\n\terr := ListCmd.Parse(os.Args[2:])\n\tif err != nil || internal.Help {\n\t\tListCmd.Usage()\n\t\tos.Exit(0)\n\t}\n\n\tconfigurator, err := config.NewConfigurator()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tlist, err := configurator.GetCollaborators()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tsort.Slice(list, func(i, j int) bool {\n\t\treturn config.Less(list[i], list[j])\n\t})\n\n\ttw := tabwriter.NewWriter(os.Stdout, 0, 0, 2, ' ', 0x0)\n\tfor _, collab := range list {\n\t\tline := fmt.Sprintf(\"\\t%s\\t<%s>\", collab.Name, collab.Email)\n\t\tif (collab.Alias != collab.Name) {\n\t\t\tline = fmt.Sprintf(\"%s:%s\", collab.Alias, line)\n\t\t}\n\t\tfmt.Fprintln(tw, line)\n\t}\n\ttw.Flush()\n}", "func (m *List) GetDisplayName()(*string) {\n return m.displayName\n}", "func listExtended(cmd *cobra.Command, features []FeatureInfo) error {\n\tvar t component.OutputWriterSpinner\n\tt, err := component.NewOutputWriterWithSpinner(cmd.OutOrStdout(), outputFormat,\n\t\t\"Retrieving Features...\", true, \"NAME\", \"ACTIVATION STATE\", \"STABILITY\", \"DESCRIPTION\", \"IMMUTABLE\", \"FEATUREGATE\")\n\tif err != nil {\n\t\treturn fmt.Errorf(\"could not get OutputWriterSpinner: %w\", err)\n\t}\n\n\tfor _, info := range features {\n\t\tt.AddRow(info.Name, info.Activated, info.Stability, info.Description, info.Immutable, info.FeatureGate)\n\t}\n\tt.RenderWithSpinner()\n\n\treturn nil\n}", "func (a *ForjFlag) setList(ol *ForjObjectList, instance, field string) {\n\ta.list = ol\n\ta.setObjectField(ol.obj, field)\n\ta.setObjectInstance(instance)\n}", "func (m *Application) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (m *DeviceManagementConfigurationSettingDefinition) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (c *TiCommunityCherrypicker) setDefaults() {\n\tif len(c.LabelPrefix) == 0 {\n\t\tc.LabelPrefix = DefaultCherryPickLabelPrefix\n\t}\n}", "func (mysqlFlavor56) baseShowTablesWithSizes() string {\n\treturn TablesWithSize56\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\treturn defaultCtrl.RenderList(w, r, l)\n}", "func (m *Setting) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (pane *TaskPane) LoadDynamicList(logic string) {\n\tvar tasks []model.Task\n\tvar err error\n\n\ttoday := toDate(time.Now())\n\tzeroTime := time.Time{}\n\trangeDesc := \"\"\n\n\tswitch logic {\n\tcase \"today\":\n\t\ttasks, err = pane.taskRepo.GetAllByDateRange(zeroTime, today)\n\t\trangeDesc = \"Today (and overdue)\"\n\n\tcase \"tomorrow\":\n\t\ttomorrow := today.AddDate(0, 0, 1)\n\t\ttasks, err = pane.taskRepo.GetAllByDate(tomorrow)\n\t\trangeDesc = \"Tomorrow\"\n\n\tcase \"upcoming\":\n\t\tweek := today.Add(7 * 24 * time.Hour)\n\t\ttasks, err = pane.taskRepo.GetAllByDateRange(today, week)\n\t\trangeDesc = \"Upcoming (next 7 days)\"\n\n\tcase \"unscheduled\":\n\t\ttasks, err = pane.taskRepo.GetAllByDate(zeroTime)\n\t\trangeDesc = \"Unscheduled (task with no due date) \"\n\t}\n\n\tprojectPane.activeProject = nil\n\ttaskPane.ClearList()\n\n\tif err == storm.ErrNotFound {\n\t\tstatusBar.showForSeconds(\"[yellow]No Task in list - \"+rangeDesc, 5)\n\t\tpane.SetList(tasks)\n\t} else if err != nil {\n\t\tstatusBar.showForSeconds(\"[red]Error: \"+err.Error(), 5)\n\t} else {\n\t\tsort.Slice(tasks, func(i, j int) bool { return tasks[i].ProjectID < tasks[j].ProjectID })\n\t\tpane.SetList(tasks)\n\t\tapp.SetFocus(taskPane)\n\n\t\tstatusBar.showForSeconds(\"[yellow] Displaying tasks of \"+rangeDesc, 5)\n\t}\n\n\tpane.RemoveItem(pane.hint)\n\tremoveThirdCol()\n}", "func (e emp) display() {\n\tfmt.Println(e.name)\n}", "func initLists() {\n\tdirectories = make(map[string]bool)\n\tdirsToDelete = make([]string, 0)\n\tdirectories[\"build\"] = true\n\tdirectories[\".gradle\"] = true\n\tdirectories[\".git\"] = true\n\tdirectories[\"libraries\"] = true\n\n\tfiles = make(map[string]bool)\n\tfilesToDelete = make([]string, 0)\n\tfiles[\"gradle.xml\"] = true\n\tfiles[\"workspace.xml\"] = true\n\tfiles[\"local.properties\"] = true\n\tfiles[\".DS_Store\"] = true\n\tfiles[\"thumbs.db\"] = true\n}", "func (mysqlFlavor80) baseShowTablesWithSizes() string {\n\treturn TablesWithSize80\n}", "func (hc *Hailconfig) List() error {\n\tcols, _ := consolesize.GetConsoleSize()\n\tmaxLenAlias := 25\n\tmaxLenCommand := 80\n\tmaxLenDescription := 25\n\tif cols > 10 {\n\t\tmaxLenAlias = cols/4 - 5\n\t\tmaxLenCommand = cols / 2\n\t\tmaxLenDescription = cols/4 - 5\n\t}\n\n\tt := table.NewWriter()\n\tt.SetOutputMirror(os.Stdout)\n\tt.AppendHeader(table.Row{\"Alias\", \"Command\", \"Description\"})\n\tt.SetColumnConfigs([]table.ColumnConfig{\n\t\t{\n\t\t\tName: \"Alias\",\n\t\t\tWidthMin: 5,\n\t\t\tWidthMax: maxLenAlias,\n\t\t},\n\t\t{\n\t\t\tName: \"Command\",\n\t\t\tWidthMin: 10,\n\t\t\tWidthMax: maxLenCommand,\n\t\t}, {\n\t\t\tName: \"Description\",\n\t\t\tWidthMin: 5,\n\t\t\tWidthMax: maxLenDescription,\n\t\t},\n\t})\n\t//t.SetAllowedRowLength(90)\n\tfor alias, script := range hc.Scripts {\n\t\tt.AppendRow([]interface{}{alias, script.Command, script.Description})\n\t\tt.AppendSeparator()\n\t}\n\tt.Render()\n\treturn nil\n}", "func (this *Iter) SetList(l *[]interface{}) {\n\tthis.list = l\n\tthis.index = -1\n\tthis.currentPage = 1\n}", "func (l *linkedliststock) Display() {\n\tcurrent := l.front\n\tfor current != nil {\n\t\t//taking values of corresponding struct\n\t\tvalue1 := current.stockname\n\t\tvalue2 := current.stockshares\n\t\tvalue3 := current.stockprice\n\t\tfmt.Println(\"--------------------------------------\")\n\t\tfmt.Printf(\"Stock Name : %s\\n\", value1)\n\t\tfmt.Printf(\"Stock Shares : %d\\n\", value2)\n\t\tfmt.Printf(\"Stock Price : %d\\n\", value3)\n\t\tfmt.Println(\"--------------------------------------\")\n\t\t//moving to next struct\n\t\tcurrent = current.next\n\t}\n\n}", "func (m *TelecomExpenseManagementPartner) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (m *TemplateParameter) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (m *AccessPackage) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (m *EducationAssignment) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (m *ManagementTemplateStepTenantSummary) SetManagementTemplateCollectionDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"managementTemplateCollectionDisplayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func NewNotificationDisplayInfo_List(s *capnp.Segment, sz int32) (NotificationDisplayInfo_List, error) {\n\tl, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}, sz)\n\treturn NotificationDisplayInfo_List{l}, err\n}", "func (m *PrintConnector) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (base Base) ListRemote() (result []string, err error) {\n\treturn\n}", "func (w *ListWidget) SetCurrent(idx int) error {\n\treturn w.base.SetCurrent(idx)\n}", "func (m *RoleDefinition) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (mysqlFlavor57) baseShowTablesWithSizes() string {\n\treturn TablesWithSize57\n}", "func (m *DirectorySetting) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (s *BasevhdlListener) EnterInterface_list(ctx *Interface_listContext) {}", "func (*CrmBasedUserListInfo) Descriptor() ([]byte, []int) {\n\treturn file_google_ads_googleads_v14_common_user_lists_proto_rawDescGZIP(), []int{1}\n}", "func newListWin(filters []string) *listWin {\n\tsort.Strings(filters)\n\n\ttitle := fmt.Sprintf(\"%s/%s\", path, strings.Join(filters, \"\"))\n\twin, err := acme.New(title)\n\tif err != nil {\n\t\tdie(1, \"Failed to create a new window %s: %s\", title, err)\n\t}\n\tif err := win.Fprintf(\"tag\", \"Sort \"); err != nil {\n\t\tdie(1, \"Failed to write the tag of %s: %s\", title, err)\n\t}\n\tlw := &listWin{\n\t\tWin: win,\n\t\ttitle: title,\n\t\tfilters: filters,\n\t\tless: lessFuncs[\"prio\"],\n\t}\n\twg.Add(1)\n\tgo lw.events()\n\tlw.refresh()\n\treturn lw\n}", "func (w *ListWidget) SetModel(model []string) {\n\tw.base.SetMax(len(model))\n\tw.model = model\n\tw.render()\n}", "func (*RuleBasedUserListInfo) Descriptor() ([]byte, []int) {\n\treturn file_google_ads_googleads_v14_common_user_lists_proto_rawDescGZIP(), []int{10}\n}", "func (s *BasevhdlListener) EnterLogical_name_list(ctx *Logical_name_listContext) {}", "func (c *Eth) ShowList() ([]string, error) {\n c.con.LogQuery(\"(show) list of ethernet interfaces\")\n path := c.xpath(nil)\n return c.con.EntryListUsing(c.con.Show, path[:len(path) - 1])\n}", "func (ap *AnimeParser) setAllDetail() {\n\tvar topList []model.Anime\n\tarea := ap.Parser.Find(\"table\")\n\tarea.Find(\"tr.ranking-list\").Each(func(j int, eachTop *goquery.Selection) {\n\t\tnameArea := eachTop.Find(\"td .detail\")\n\t\tinfoArea, _ := nameArea.Find(\"div.information\").Html()\n\t\tparsedInfo := strings.Split(infoArea, \"<br/>\")\n\n\t\ttopList = append(topList, model.Anime{\n\t\t\tRank: ap.getRank(eachTop),\n\t\t\tImage: ap.getImage(eachTop),\n\t\t\tID: ap.getID(nameArea),\n\t\t\tTitle: ap.getTitle(nameArea),\n\t\t\tType: ap.getType(parsedInfo),\n\t\t\tEpisode: ap.getEpCh(parsedInfo),\n\t\t\tStartDate: ap.getDate(parsedInfo, 0),\n\t\t\tEndDate: ap.getDate(parsedInfo, 1),\n\t\t\tMember: ap.getMember(parsedInfo),\n\t\t\tScore: ap.getScore(eachTop),\n\t\t})\n\t})\n\n\tap.Data = topList\n}", "func (c *listCmd) setClient() error {\n\tss, err := c.syncCmd.storageFromParam(\"src\", c.syncCmd.src)\n\tif err != nil {\n\t\tfmt.Errorf(\"Could not set client for describe requests: %v\", err)\n\t}\n\tvar ok bool\n\tc.cl, ok = ss.(*client.Client)\n\tif !ok {\n\t\treturn fmt.Errorf(\"storageFromParam returned a %T, was expecting a *client.Client\", ss)\n\t}\n\treturn nil\n}", "func (m *BookingNamedEntity) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (c *Dg) ShowList() ([]string, error) {\n c.con.LogQuery(\"(show) list of device groups\")\n path := c.xpath(nil)\n return c.con.EntryListUsing(c.con.Show, path[:len(path) - 1])\n}", "func (m *DB) ListStandupers() ([]model.Standuper, error) {\n\titems := []model.Standuper{}\n\terr := m.db.Select(&items, \"SELECT * FROM `standupers`\")\n\treturn items, err\n}", "func mergeDisplayTasks(current DisplayTask, toMerge DisplayTask) DisplayTask {\n\tfor _, et := range toMerge.ExecTasks {\n\t\tif !utility.StringSliceContains(current.ExecTasks, et) {\n\t\t\tcurrent.ExecTasks = append(current.ExecTasks, et)\n\t\t}\n\t}\n\treturn current\n}", "func (m *Model) SetValues(values Values) {\n\tm.Err = nil\n\tm.selectedList = 0\n\tm.values = values\n\tnumCats := values.NumCategories()\n\tm.valueLists = make([]*list.Model, numCats)\n\tm.listItems = make([][]list.Item, numCats)\n\tconst stdHeight = 10\n\tlistDecorationRows :=\n\t\t1 +\n\t\t\tmax(\n\t\t\t\tm.Styles.FocusedTitleBar.GetVerticalPadding(),\n\t\t\t\tm.Styles.BlurredTitleBar.GetVerticalPadding()) +\n\t\t\tmax(\n\t\t\t\tm.Styles.FocusedTitleBar.GetVerticalMargins(),\n\t\t\t\tm.Styles.BlurredTitleBar.GetVerticalMargins()) +\n\t\t\t1 +\n\t\t\tm.Styles.PaginationStyle.GetVerticalPadding() +\n\t\t\t// (facepalm) the list widget forces a vertical margin of 1...\n\t\t\tmax(1, m.Styles.PaginationStyle.GetVerticalMargins())\n\tm.maxHeight = listDecorationRows\n\n\tperItemHeight := 1 + max(\n\t\tm.Styles.Item.GetVerticalPadding(),\n\t\tm.Styles.SelectedItem.GetVerticalPadding())\n\n\tfor i := 0; i < numCats; i++ {\n\t\tcategory := values.CategoryTitle(i)\n\t\tvar maxWidth int\n\t\tm.listItems[i], maxWidth = convertToItems(values, i)\n\t\tm.maxHeight = max(m.maxHeight, len(m.listItems[i])*perItemHeight+listDecorationRows)\n\t\tmaxWidth = max(maxWidth+1, rw.StringWidth(category))\n\t\tr := &renderer{m: m, listIdx: i, width: maxWidth}\n\t\tl := list.New(m.listItems[i], r, maxWidth, stdHeight)\n\t\tl.Title = category\n\t\tl.KeyMap = m.KeyMap.KeyMap\n\t\tl.DisableQuitKeybindings()\n\t\tl.SetShowHelp(false)\n\t\tl.SetShowStatusBar(false)\n\t\tm.valueLists[i] = &l\n\t}\n\n\t// Make space for the description.\n\tm.maxHeight++\n\n\t// Propagate the logical heights to all lists.\n\tm.SetHeight(m.maxHeight)\n\n\twasFocused := m.focused\n\tm.Blur()\n\tif wasFocused {\n\t\tm.Focus()\n\t}\n}", "func (cli *CLI) SystemList() {\n\tlist := nbv1.NooBaaList{}\n\terr := cli.Client.List(cli.Ctx, nil, &list)\n\tif meta.IsNoMatchError(err) {\n\t\tcli.Log.Warningf(\"CRD not installed.\\n\")\n\t\treturn\n\t}\n\tutil.Panic(err)\n\tif len(list.Items) == 0 {\n\t\tcli.Log.Printf(\"No systems found.\\n\")\n\t\treturn\n\t}\n\ttable := (&util.PrintTable{}).AddRow(\n\t\t\"NAMESPACE\",\n\t\t\"NAME\",\n\t\t\"PHASE\",\n\t\t\"MGMT-ENDPOINTS\",\n\t\t\"S3-ENDPOINTS\",\n\t\t\"IMAGE\",\n\t\t\"AGE\",\n\t)\n\tfor i := range list.Items {\n\t\ts := &list.Items[i]\n\t\ttable.AddRow(\n\t\t\ts.Namespace,\n\t\t\ts.Name,\n\t\t\tstring(s.Status.Phase),\n\t\t\tfmt.Sprint(s.Status.Services.ServiceMgmt.NodePorts),\n\t\t\tfmt.Sprint(s.Status.Services.ServiceS3.NodePorts),\n\t\t\ts.Status.ActualImage,\n\t\t\tsince(s.ObjectMeta.CreationTimestamp.Time),\n\t\t)\n\t}\n\tfmt.Print(table.String())\n}", "func (m *ProgramControl) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func InitializeList(uninitializedList *List, itemSize uint64) {\n uninitializedList.itemSize = itemSize;\n uninitializedList.capacity = 16; //Allocate 16 items by default\n uninitializedList.baseAddress = Alloc(uninitializedList.capacity * uninitializedList.itemSize);\n uninitializedList.itemCount = 0; //Reset item count (to zero)\n}", "func ShowList(manuals []*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\n\t}\n\n\t// show manuals\n\thead, rows := createList(manuals)\n\tfmt.Println(ansi.ColorCode(\"cyan\") + head + ansi.Reset)\n\tfmt.Println(strings.Join(rows, \"\\n\"))\n}", "func Display(lst *Node) {\n\tfor lst != nil {\n\t\tif lst.next != nil {\n\t\t\tfmt.Printf(\"%v -> \", lst.val)\n\t\t} else {\n\t\t\tfmt.Printf(\"%v\", lst.val)\n\t\t}\n\t\tlst = lst.next\n\t}\n\tfmt.Println()\n}", "func (me *TdisplayModeEnumType) Set(s string) { (*xsdt.String)(me).Set(s) }", "func (m *ManagedAppPolicy) SetDisplayName(value *string)() {\n m.displayName = value\n}" ]
[ "0.5717477", "0.57107383", "0.5401722", "0.52565634", "0.51821727", "0.5164439", "0.51175773", "0.501092", "0.4951619", "0.48923728", "0.487103", "0.48666343", "0.48548758", "0.4821617", "0.4754428", "0.4739806", "0.4737783", "0.47319996", "0.47286794", "0.47130919", "0.470105", "0.46951008", "0.467894", "0.4670312", "0.46558172", "0.46504045", "0.464324", "0.46410933", "0.46262828", "0.46182054", "0.46062034", "0.45998833", "0.45948997", "0.45823002", "0.4551363", "0.4547855", "0.45441455", "0.45404175", "0.4532028", "0.45243922", "0.45155674", "0.4512246", "0.44941393", "0.44914237", "0.44862494", "0.4486157", "0.44759476", "0.44647974", "0.44463712", "0.4431175", "0.43997535", "0.4396352", "0.43915513", "0.43906826", "0.43760037", "0.43739942", "0.43691793", "0.43685713", "0.43641335", "0.4362694", "0.43573374", "0.43514386", "0.43498677", "0.43496004", "0.43493038", "0.43470284", "0.434377", "0.43352142", "0.43348375", "0.43292606", "0.43252453", "0.43139902", "0.43083128", "0.43079978", "0.4307996", "0.42965972", "0.429279", "0.4281644", "0.42778337", "0.42713356", "0.4255774", "0.42471954", "0.42435798", "0.42347026", "0.42326066", "0.42286667", "0.4224294", "0.42166916", "0.42154533", "0.42146543", "0.42131352", "0.42113337", "0.42080975", "0.4207383", "0.42054185", "0.42026407", "0.41935995", "0.41917378", "0.4185225", "0.41838813" ]
0.5506329
2
replace the current matrix with the identity matrix
func LoadIdentity() { C.glowLoadIdentity(gpLoadIdentity) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (c2d *C2DMatrix) Identity() {\n\tc2d.matrix.m11 = 1\n\tc2d.matrix.m12 = 0\n\tc2d.matrix.m13 = 0\n\n\tc2d.matrix.m21 = 0\n\tc2d.matrix.m22 = 1\n\tc2d.matrix.m23 = 0\n\n\tc2d.matrix.m31 = 0\n\tc2d.matrix.m32 = 0\n\tc2d.matrix.m33 = 1\n}", "func Identity() Matrix {\n\treturn Matrix{1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1}\n}", "func InitializeIdentityMatrix(m Matrix, v int64) {\n\tnumRows := m.Rows()\n\n\ti := 0\n\n\tfor i < numRows {\n\t\tm.SetElement(i, i, v)\n\n\t\ti += 1\n\t}\n}", "func Identity(width int) *Matrix {\n\tm := New(width, width)\n\tif m.IsError() {\n\t\tm.MatrixError().OperationName = \"Identity\"\n\t\treturn m\n\t}\n\n\tfor i := 0; i < width; i++ {\n\t\tm.values[i + i * width] = 1\n\t}\n\n\treturn m\n}", "func IdentityMatrix(s int) Mat {\n var temp [][]float32\n for i := 0; i < s; i++ {\n temp_r := make([]float32, s)\n temp_r[i] = 1\n temp = append(temp, temp_r)\n }\n return Mat{temp, []int{s,s}}\n}", "func Identity(n int) *Matrix {\n\tA := Zeros(n, n)\n\n\tfor i := 0; i < len(A.data); i += (n + 1) {\n\t\tA.data[i] = 1.0\n\t}\n\n\treturn A\n}", "func Identity(m, n int) Matrix {\n\t// TODO: Determine if this should this panic when m,n = 0.\n\n\t// Note: this generating function is called the Kronecker delta\n\t// and is typically denoted as d(i,j).\n\tf := func(i, j int) float64 {\n\t\tif i == j {\n\t\t\treturn 1\n\t\t}\n\t\treturn 0\n\t}\n\n\treturn New(m, n, f)\n}", "func MatrixIdentity() Matrix {\n\treturn NewMatrix(\n\t\t1.0, 0.0, 0.0, 0.0,\n\t\t0.0, 1.0, 0.0, 0.0,\n\t\t0.0, 0.0, 1.0, 0.0,\n\t\t0.0, 0.0, 0.0, 1.0)\n}", "func NewMatrixIdentity() Matrix {\n\treturn Matrix{\n\t\tM0: 1, M1: 0, M2: 0, M3: 0,\n\t\tM4: 0, M5: 1, M6: 0, M7: 0,\n\t\tM8: 0, M9: 0, M10: 1, M11: 0,\n\t\tM12: 0, M13: 0, M14: 0, M15: 1,\n\t}\n}", "func (mPointer *GF8Matrix) Inv() (*GF8Matrix, error) {\n\tm := NewMatrix(mPointer.numRow, mPointer.numCol)\n\tcopy(m.Matrix, mPointer.Matrix)\n\tif m.numCol != m.numRow {\n\t\tlog.Fatal(ErrNotSquareMatrix)\n\t}\n\t// extend identity matrix to right half\n\tfor r := 0; r < m.numRow; r++ {\n\t\tprepandArray := make([]byte, m.numCol)\n\t\tprepandArray[r] = 1\n\t\tm.Matrix[r] = append(m.Matrix[r], prepandArray...)\n\t}\n\toriginalNumCol := m.numCol\n\tm.numCol += originalNumCol\n\t// make left half identity\n\tfor r := 0; r < m.numRow; r++ {\n\t\t// find head\n\t\tsingularFlag := true\n\t\tfor iFindHead := r; iFindHead < m.numRow; iFindHead++ {\n\t\t\tif m.Matrix[iFindHead][r] != 0 {\n\t\t\t\tif iFindHead != r {\n\t\t\t\t\tm.swapRow(iFindHead, r)\n\t\t\t\t}\n\t\t\t\tsingularFlag = false\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif singularFlag {\n\t\t\treturn nil, ErrSingularMatrix\n\t\t}\n\t\t// make this diagnal unit\n\t\thead := m.Matrix[r][r]\n\t\tm.multRow(r, inverseTbl[head])\n\t\t// erase other rows\n\t\tfor rFollow := 0; rFollow < m.numRow; rFollow++ {\n\t\t\tif rFollow == r || m.Matrix[rFollow][r] == 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tm.mulAddToRow(r, m.Matrix[rFollow][r], rFollow)\n\t\t}\n\t}\n\t//remove left half\n\tfor r := 0; r < m.numRow; r++ {\n\t\tm.Matrix[r] = m.Matrix[r][originalNumCol:]\n\t}\n\tm.numCol = originalNumCol\n\n\tif SanityCheck {\n\t\tshouldBeIdentity := m.Mul(mPointer)\n\t\tshouldBeIdentity.ShowMatrix(SanityCheck)\n\t\tfor r := 0; r < m.numRow; r++ {\n\t\t\tfor c := 0; c < m.numCol; c++ {\n\t\t\t\tif r == c && shouldBeIdentity.Matrix[r][c] != 1 {\n\t\t\t\t\tlog.Fatalf(\"Fail the sanity check, %v != 1\", shouldBeIdentity.Matrix[r][c])\n\t\t\t\t} else if r != c && shouldBeIdentity.Matrix[r][c] != 0 {\n\t\t\t\t\tlog.Fatalf(\"Fail the sanity check, %v != 0\", shouldBeIdentity.Matrix[r][c])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn m, nil\n}", "func Identity() *Mtx {\n\treturn NewMat(\n\t\t1, 0, 0, 0,\n\t\t0, 1, 0, 0,\n\t\t0, 0, 1, 0,\n\t\t0, 0, 0, 1,\n\t)\n}", "func (A *Matrix) Clear() {\n\tfor i := 0; i < A.height; i++ {\n\t\tAi := A.Row(i)\n\t\tfor j := range Ai {\n\t\t\tAi[j] = 0\n\t\t}\n\t}\n}", "func Identity(i int) M {\n\trm := M{r: i, c: i, values: make([]Frac, i*i)}\n\n\tfor r := 1; r <= rm.Rows(); r++ {\n\t\tfor c := 1; c <= rm.Cols(); c++ {\n\t\t\tif r == c {\n\t\t\t\trm.Set(r, c, NewScalarFrac(1))\n\t\t\t} else {\n\t\t\t\trm.Set(r, c, NewScalarFrac(0))\n\t\t\t}\n\t\t}\n\t}\n\n\treturn rm\n}", "func nullifyRow(matrix [][]int, numColumns int, rowId int) {\n\tfor j := 0; j < numColumns; j++ {\n\t\tmatrix[rowId][j] = 0\n\t}\n}", "func orIdentity(a *bmatrix) {\n\tfor i := 0; i < n; i++ {\n\t\ta[i][i] = true\n\t}\n}", "func GenerateIdentity(n int) Matrix {\n\treturn GeneratePartialIdentity(n, IgnoreNoRows)\n}", "func (g *G1) SetIdentity() { g.x = ff.Fp{}; g.y.SetOne(); g.z = ff.Fp{} }", "func setZeroes(matrix [][]int) {\n\t// 20200819\n\t// 1、全部复制\n\t// O(M*N)\n\t// 不需要用visitor数组,直接在原数组设置\n\t/*if len(matrix) == 0 || len(matrix[0]) == 0 {\n\t\treturn\n\t}\n\tm := len(matrix)\n\tn := len(matrix[0])\n\tvisited := make([][]bool, m)\n\tfor i := range visited {\n\t\tvisited[i] = make([]bool, n)\n\t}\n\tfor i:=0;i<m;i++{\n\t\tfor j:=0;j<n;j++{\n\t\t\tif !visited[i][j] && matrix[i][j] == 0 {\n\t\t\t\tfor p := 0; p<n;p++ {\n\t\t\t\t\tif !visited[i][p] {\n\t\t\t\t\t\tmatrix[i][p] = 0\n\t\t\t\t\t\tvisited[i][p] = true\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tfor p := 0; p<m;p++ {\n\t\t\t\t\tif !visited[p][j] {\n\t\t\t\t\t\tmatrix[p][j] = 0\n\t\t\t\t\t\tvisited[p][j] = true\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t//visited[i][j] = true\n\t\t}\n\t}\n\tfmt.Println(matrix)*/\n\t// https://leetcode-cn.com/problems/set-matrix-zeroes/solution/ju-zhen-zhi-ling-by-leetcode/\n\t// 1、两次扫描,额外空间,用set\n\t// O(M*N)/O(M+N)\n\t// 执行耗时:16 ms,击败了70.23% 的Go用户\n\t// 内存消耗:6 MB,击败了42.53% 的Go用户\n\t// 本题算法不需要,工程化最好加上\n\t//if len(matrix) == 0 || len(matrix[0]) == 0 {\n\t//\treturn\n\t//}\n\t/*m := len(matrix)\n\tn := len(matrix[0])\n\trows := map[int]bool{}\n\tcols := map[int]bool{}\n\tfor i:=0;i<m;i++{\n\t\tfor j:=0;j<n;j++{\n\t\t\tif matrix[i][j] == 0 {\n\t\t\t\trows[i] = true\n\t\t\t\tcols[j] = true\n\t\t\t}\n\t\t}\n\t}\n\tfor i:=0;i<m;i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tif rows[i] || cols[j] {\n\t\t\t\tmatrix[i][j] = 0\n\t\t\t}\n\t\t}\n\t}*/\n\t// 3、O(1)空间复杂度+暴力\n\t// O((MxN)x(M+N))/O(1)\n\t// 执行耗时:24 ms,击败了7.36% 的Go用户\n\t// 内存消耗:6 MB,击败了13.79% 的Go用户\n\t/*FLAG := math.MinInt64\n\tm := len(matrix)\n\tn := len(matrix[0])\n\tfor i:=0;i<m;i++{\n\t\tfor j:=0;j<n;j++{\n\t\t\tif matrix[i][j] == 0{\n\t\t\t\tfor k :=0;k<m;k++{\n\t\t\t\t\tif matrix[k][j] != 0{\n\t\t\t\t\t\tmatrix[k][j] = FLAG\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tfor k :=0;k<n;k++{\n\t\t\t\t\tif matrix[i][k] != 0 {\n\t\t\t\t\t\tmatrix[i][k] = FLAG\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i:=0;i<m;i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tif matrix[i][j] == FLAG {\n\t\t\t\tmatrix[i][j] = 0\n\t\t\t}\n\t\t}\n\t}*/\n\t// 3、只将每行和每列的第一个元素赋值为0\n\t// O(MxN)/O(1)\n\t// 执行耗时:20 ms,击败了15.72% 的Go用户\n\t// 内存消耗:6.1 MB,击败了5.75% 的Go用户\n\tm := len(matrix)\n\tn := len(matrix[0])\n\tisCol := false\n\tfor i := 0; i < m; i++ {\n\t\tif matrix[i][0] == 0 {\n\t\t\tisCol = true\n\t\t}\n\t\tfor j := 1; j < n; j++ {\n\t\t\tif matrix[i][j] == 0 {\n\t\t\t\tmatrix[0][j] = 0\n\t\t\t\tmatrix[i][0] = 0\n\t\t\t}\n\t\t}\n\t}\n\tfor i := 1; i < m; i++ {\n\t\tfor j := 1; j < n; j++ {\n\t\t\tif matrix[i][0] == 0 || matrix[0][j] == 0 {\n\t\t\t\tmatrix[i][j] = 0\n\t\t\t}\n\t\t}\n\t}\n\tif matrix[0][0] == 0 {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tmatrix[0][j] = 0\n\t\t}\n\t}\n\tif isCol {\n\t\tfor i := 0; i < m; i++ {\n\t\t\tmatrix[i][0] = 0\n\t\t}\n\t}\n\tfmt.Println(matrix)\n}", "func Identity(v magica.VoxelObject) (r magica.VoxelObject) {\n\tr = v.Copy()\n\treturn r\n}", "func MakeIdentityComplexMatrix(degree int) MatrixComplex {\n\tmatrix := MakeComplexMatrix(degree, degree)\n\n\tfor i := 0; i < degree; i++ {\n\t\tmatrix.Set(i, i, complex128(1))\n\t}\n\n\treturn matrix\n}", "func (p *CompressedEdwardsY) Identity() *CompressedEdwardsY {\n\t*p = [CompressedPointSize]byte{\n\t\t1, 0, 0, 0, 0, 0, 0, 0,\n\t\t0, 0, 0, 0, 0, 0, 0, 0,\n\t\t0, 0, 0, 0, 0, 0, 0, 0,\n\t\t0, 0, 0, 0, 0, 0, 0, 0,\n\t}\n\treturn p\n}", "func zeroMatrix(m [][]int) [][]int {\n\tif m == nil || len(m) == 0 || len(m[0]) == 0 {\n\t\treturn m\n\t}\n\tmatrix := copyMatrix(m)\n\tvar coordsToZero []coord\n\tfor row, _ := range matrix {\n\t\tfor col, _ := range matrix[0] {\n\t\t\tif matrix[row][col] == 0 {\n\t\t\t\tcoordsToZero = append(coordsToZero, coord{row, col})\n\t\t\t}\n\t\t}\n\t}\n\tfor _, coord := range coordsToZero {\n\t\tzeroCross(matrix, coord.row, coord.col)\n\t}\n\treturn matrix\n}", "func (matrix *Matrix4) SetInverseOf(m *Matrix4, errorOnDegenerate bool) error {\n\tt11 := m.elements[9 ]*m.elements[14]*m.elements[7 ] - m.elements[13]*m.elements[10]*m.elements[7 ] + m.elements[13]*m.elements[6 ]*m.elements[11] - m.elements[5 ]*m.elements[14]*m.elements[11] - m.elements[9 ]*m.elements[6 ]*m.elements[15] + m.elements[5 ]*m.elements[10]*m.elements[15]\n\tt12 := m.elements[12]*m.elements[10]*m.elements[7 ] - m.elements[8 ]*m.elements[14]*m.elements[7 ] - m.elements[12]*m.elements[6 ]*m.elements[11] + m.elements[4 ]*m.elements[14]*m.elements[11] + m.elements[8 ]*m.elements[6 ]*m.elements[15] - m.elements[4 ]*m.elements[10]*m.elements[15]\n\tt13 := m.elements[8 ]*m.elements[13]*m.elements[7 ] - m.elements[12]*m.elements[9 ]*m.elements[7 ] + m.elements[12]*m.elements[5 ]*m.elements[11] - m.elements[4 ]*m.elements[13]*m.elements[11] - m.elements[8 ]*m.elements[5 ]*m.elements[15] + m.elements[4 ]*m.elements[9 ]*m.elements[15]\n\tt14 := m.elements[12]*m.elements[9 ]*m.elements[6 ] - m.elements[8 ]*m.elements[13]*m.elements[6 ] - m.elements[12]*m.elements[5 ]*m.elements[10] + m.elements[4 ]*m.elements[13]*m.elements[10] + m.elements[8 ]*m.elements[5 ]*m.elements[14] - m.elements[4 ]*m.elements[9 ]*m.elements[14]\n\n\tdet := m.elements[0 ]*t11 + m.elements[1 ]*t12 + m.elements[2 ]*t13 + m.elements[3 ]*t14\n\n\tif det == 0 {\n\t\tif errorOnDegenerate == true {\n\t\t\treturn errors.New(\".getInverse() can't invert matrix, determinant is 0\")\n\t\t} else {\n\t\t\tlog.Println(\".getInverse() can't invert matrix, determinant is 0\")\n\t\t\tmatrix.SetIdentity()\n\t\t\treturn nil\n\t\t}\n\t}\n\n\tdetInv := 1 / det\n\n\tmatrix.elements[0 ] = t11 * detInv\n\tmatrix.elements[1 ] = (m.elements[13]*m.elements[10]*m.elements[3 ] - m.elements[9 ]*m.elements[14]*m.elements[3 ] - m.elements[13]*m.elements[2 ]*m.elements[11] + m.elements[1 ]*m.elements[14]*m.elements[11] + m.elements[9 ]*m.elements[2 ]*m.elements[15] - m.elements[1 ]*m.elements[10]*m.elements[15]) * detInv\n\tmatrix.elements[2 ] = (m.elements[5 ]*m.elements[14]*m.elements[3 ] - m.elements[13]*m.elements[6 ]*m.elements[3 ] + m.elements[13]*m.elements[2 ]*m.elements[7 ] - m.elements[1 ]*m.elements[14]*m.elements[7 ] - m.elements[5 ]*m.elements[2 ]*m.elements[15] + m.elements[1 ]*m.elements[6 ]*m.elements[15]) * detInv\n\tmatrix.elements[3 ] = (m.elements[9 ]*m.elements[6 ]*m.elements[3 ] - m.elements[5 ]*m.elements[10]*m.elements[3 ] - m.elements[9 ]*m.elements[2 ]*m.elements[7 ] + m.elements[1 ]*m.elements[10]*m.elements[7 ] + m.elements[5 ]*m.elements[2 ]*m.elements[11] - m.elements[1 ]*m.elements[6 ]*m.elements[11]) * detInv\n\n\tmatrix.elements[4 ] = t12 * detInv\n\tmatrix.elements[5 ] = (m.elements[8 ]*m.elements[14]*m.elements[3 ] - m.elements[12]*m.elements[10]*m.elements[3 ] + m.elements[12]*m.elements[2 ]*m.elements[11] - m.elements[0 ]*m.elements[14]*m.elements[11] - m.elements[8 ]*m.elements[2 ]*m.elements[15] + m.elements[0 ]*m.elements[10]*m.elements[15]) * detInv\n\tmatrix.elements[6 ] = (m.elements[12]*m.elements[6 ]*m.elements[3 ] - m.elements[4 ]*m.elements[14]*m.elements[3 ] - m.elements[12]*m.elements[2 ]*m.elements[7 ] + m.elements[0 ]*m.elements[14]*m.elements[7 ] + m.elements[4 ]*m.elements[2 ]*m.elements[15] - m.elements[0 ]*m.elements[6 ]*m.elements[15]) * detInv\n\tmatrix.elements[7 ] = (m.elements[4 ]*m.elements[10]*m.elements[3 ] - m.elements[8 ]*m.elements[6 ]*m.elements[3 ] + m.elements[8 ]*m.elements[2 ]*m.elements[7 ] - m.elements[0 ]*m.elements[10]*m.elements[7 ] - m.elements[4 ]*m.elements[2 ]*m.elements[11] + m.elements[0 ]*m.elements[6 ]*m.elements[11]) * detInv\n\n\tmatrix.elements[8 ] = t13 * detInv\n\tmatrix.elements[9 ] = (m.elements[12]*m.elements[9 ]*m.elements[3 ] - m.elements[8 ]*m.elements[13]*m.elements[3 ] - m.elements[12]*m.elements[1 ]*m.elements[11] + m.elements[0 ]*m.elements[13]*m.elements[11] + m.elements[8 ]*m.elements[1 ]*m.elements[15] - m.elements[0 ]*m.elements[9 ]*m.elements[15]) * detInv\n\tmatrix.elements[10] = (m.elements[4 ]*m.elements[13]*m.elements[3 ] - m.elements[12]*m.elements[5 ]*m.elements[3 ] + m.elements[12]*m.elements[1 ]*m.elements[7 ] - m.elements[0 ]*m.elements[13]*m.elements[7 ] - m.elements[4 ]*m.elements[1 ]*m.elements[15] + m.elements[0 ]*m.elements[5 ]*m.elements[15]) * detInv\n\tmatrix.elements[11] = (m.elements[8 ]*m.elements[5 ]*m.elements[3 ] - m.elements[4 ]*m.elements[9 ]*m.elements[3 ] - m.elements[8 ]*m.elements[1 ]*m.elements[7 ] + m.elements[0 ]*m.elements[9 ]*m.elements[7 ] + m.elements[4 ]*m.elements[1 ]*m.elements[11] - m.elements[0 ]*m.elements[5 ]*m.elements[11]) * detInv\n\n\tmatrix.elements[12] = t14 * detInv\n\tmatrix.elements[13] = (m.elements[8 ]*m.elements[13]*m.elements[2 ] - m.elements[12]*m.elements[9 ]*m.elements[2 ] + m.elements[12]*m.elements[1 ]*m.elements[10] - m.elements[0 ]*m.elements[13]*m.elements[10] - m.elements[8 ]*m.elements[1 ]*m.elements[14] + m.elements[0 ]*m.elements[9 ]*m.elements[14]) * detInv\n\tmatrix.elements[14] = (m.elements[12]*m.elements[5 ]*m.elements[2 ] - m.elements[4 ]*m.elements[13]*m.elements[2 ] - m.elements[12]*m.elements[1 ]*m.elements[6 ] + m.elements[0 ]*m.elements[13]*m.elements[6 ] + m.elements[4 ]*m.elements[1 ]*m.elements[14] - m.elements[0 ]*m.elements[5 ]*m.elements[14]) * detInv\n\tmatrix.elements[15] = (m.elements[4 ]*m.elements[9 ]*m.elements[2 ] - m.elements[8 ]*m.elements[5 ]*m.elements[2 ] + m.elements[8 ]*m.elements[1 ]*m.elements[6 ] - m.elements[0 ]*m.elements[9 ]*m.elements[6 ] - m.elements[4 ]*m.elements[1 ]*m.elements[10] + m.elements[0 ]*m.elements[5 ]*m.elements[10]) * detInv\n\n\treturn nil\n}", "func (m *Matrix) ZeroMatrix() (matrix *Matrix) {\n\tmatrix = Copy(m)\n\tmatrix.matrix = make([]float64, m.row*m.column)\n\treturn\n}", "func GeneratePartialIdentity(n int, ignore RowIgnore) Matrix {\n\tout := GenerateEmpty(n, n)\n\n\tfor i := 0; i < n; i++ {\n\t\tif !ignore(i) {\n\t\t\tout[i][i].SetOne()\n\t\t}\n\t}\n\n\treturn out\n}", "func InitializeMatrix(m Matrix) {\n\tnumRows := m.Rows()\n\n\tnumCols := m.Columns()\n\n\tv := int64(0)\n\n\tr := 0\n\n\tc := 0\n\n\tfor r < numRows {\n\t\tc = 0\n\n\t\tfor c < numCols {\n\t\t\tm.SetElement(r, c, v)\n\n\t\t\tv += 1\n\t\t\tc += 1\n\t\t}\n\n\t\tr += 1\n\t}\n}", "func initMatrix(matrix [][]int) [][][]int {\n\tvar new_matrix [][][]int\n\n\tnew_matrix = make([][][]int, len(matrix))\n\n\tfor i := range new_matrix {\n\t\tnew_matrix[i] = make([][]int, len(matrix[0]))\n\t\tfor j := range new_matrix[i] {\n\t\t\tnew_matrix[i][j] = make([]int, 3)\n\t\t}\n\t}\n\n\tfor i := 0; i < len(matrix); i++ {\n\t\tfor j := 0; j < len(matrix[0]); j++ {\n\t\t\tnew_matrix[i][j][0] = matrix[i][j]\n\t\t\t// new_matrix[i][j][1] = float64(i)\n\t\t\tnew_matrix[i][j][1] = (i)\n\t\t\t// new_matrix[i][j][2] = float64(j)\n\t\t\tnew_matrix[i][j][2] = (j)\n\t\t}\n\t}\n\n\treturn new_matrix\n}", "func (mat Mat) InverseMatrix() (Mat,error) {\n if mat.Shape[0] != mat.Shape[1] {\n return mat,&MatrixError{\"Not a Square matrix.\"}\n }\n adj_mat,determinant := AdjointMatrix(mat)\n if determinant == 0 {\n return mat,&MatrixError{\"The determinant of the matrix is zero.\"}\n }\n adj_mat = adj_mat.MultiplyScalar(1/determinant)\n return adj_mat,nil\n}", "func ZeroMatrix(matrix [][]int) [][]int {\n\t// make sure the first does not have a zero\n\tvar firstRowHasZero,firstColHasZero bool\n\tfor i := 0; i < len(matrix[0]); i++ {\n\t\tif matrix[0][i] == 0 {\n\t\t\tfirstRowHasZero = true\n\t\t\tbreak\n\t\t}\n\t}\n\tfor i := 0; i<len(matrix);i++ {\n\t\tif matrix[i][0] == 0 {\n\t\t\tfirstColHasZero = true\n\t\t\tbreak\n\t\t}\n\t}\n\n\t// mark which cell has a 0, by using the first row and col as placeholders\n\tfor row := 1; row < len(matrix); row++ {\n\t\tfor col := 1; col < len(matrix[0]); col++ {\n\t\t\tif matrix[row][col] == 0 {\n\t\t\t\tmatrix[row][0] = 0\n\t\t\t\tmatrix[0][col] = 0\n\t\t\t}\n\t\t}\n\t}\n\n\t// zero out every row and col that have a zero\n\tfor row := 0; row < len(matrix); row ++ {\n\t\tif matrix[row][0] == 0 {\n\t\t\tmatrix = zeroRow(matrix, row)\n\t\t}\n\t}\n\n\tfor col := 0; col < len(matrix[0]); col++ {\n\t\tif matrix[0][col] == 0 {\n\t\t\tmatrix = zeroCol(matrix, col)\n\t\t}\n\t}\n\n\tif firstRowHasZero {\n\t\tmatrix = zeroRow(matrix, 0)\n\t}\n\tif firstColHasZero {\n\t\tmatrix = zeroCol(matrix, 0)\n\t}\n\n\treturn matrix\n}", "func MatrixInvert(mat Matrix) Matrix {\n\tvar result Matrix\n\n\ta00 := mat.M0\n\ta01 := mat.M1\n\ta02 := mat.M2\n\ta03 := mat.M3\n\ta10 := mat.M4\n\ta11 := mat.M5\n\ta12 := mat.M6\n\ta13 := mat.M7\n\ta20 := mat.M8\n\ta21 := mat.M9\n\ta22 := mat.M10\n\ta23 := mat.M11\n\ta30 := mat.M12\n\ta31 := mat.M13\n\ta32 := mat.M14\n\ta33 := mat.M15\n\n\tb00 := a00*a11 - a01*a10\n\tb01 := a00*a12 - a02*a10\n\tb02 := a00*a13 - a03*a10\n\tb03 := a01*a12 - a02*a11\n\tb04 := a01*a13 - a03*a11\n\tb05 := a02*a13 - a03*a12\n\tb06 := a20*a31 - a21*a30\n\tb07 := a20*a32 - a22*a30\n\tb08 := a20*a33 - a23*a30\n\tb09 := a21*a32 - a22*a31\n\tb10 := a21*a33 - a23*a31\n\tb11 := a22*a33 - a23*a32\n\n\t// Calculate the invert determinant (inlined to avoid double-caching)\n\tinvDet := 1.0 / (b00*b11 - b01*b10 + b02*b09 + b03*b08 - b04*b07 + b05*b06)\n\n\tresult.M0 = (a11*b11 - a12*b10 + a13*b09) * invDet\n\tresult.M1 = (-a01*b11 + a02*b10 - a03*b09) * invDet\n\tresult.M2 = (a31*b05 - a32*b04 + a33*b03) * invDet\n\tresult.M3 = (-a21*b05 + a22*b04 - a23*b03) * invDet\n\tresult.M4 = (-a10*b11 + a12*b08 - a13*b07) * invDet\n\tresult.M5 = (a00*b11 - a02*b08 + a03*b07) * invDet\n\tresult.M6 = (-a30*b05 + a32*b02 - a33*b01) * invDet\n\tresult.M7 = (a20*b05 - a22*b02 + a23*b01) * invDet\n\tresult.M8 = (a10*b10 - a11*b08 + a13*b06) * invDet\n\tresult.M9 = (-a00*b10 + a01*b08 - a03*b06) * invDet\n\tresult.M10 = (a30*b04 - a31*b02 + a33*b00) * invDet\n\tresult.M11 = (-a20*b04 + a21*b02 - a23*b00) * invDet\n\tresult.M12 = (-a10*b09 + a11*b07 - a12*b06) * invDet\n\tresult.M13 = (a00*b09 - a01*b07 + a02*b06) * invDet\n\tresult.M14 = (-a30*b03 + a31*b01 - a32*b00) * invDet\n\tresult.M15 = (a20*b03 - a21*b01 + a22*b00) * invDet\n\n\treturn result\n}", "func invertMatrix(matrix []byte, k int) error {\n\tpivot_searcher := newPivotSearcher(k)\n\tindxc := make([]int, k)\n\tindxr := make([]int, k)\n\tid_row := make([]byte, k)\n\n\tfor col := 0; col < k; col++ {\n\t\ticol, irow, err := pivot_searcher.search(col, matrix)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif irow != icol {\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tswap(&matrix[irow*k+i], &matrix[icol*k+i])\n\t\t\t}\n\t\t}\n\n\t\tindxr[col] = irow\n\t\tindxc[col] = icol\n\t\tpivot_row := matrix[icol*k:][:k]\n\t\tc := pivot_row[icol]\n\n\t\tif c == 0 {\n\t\t\treturn Error.New(\"singular matrix\")\n\t\t}\n\n\t\tif c != 1 {\n\t\t\tc = gf_inverse[c]\n\t\t\tpivot_row[icol] = 1\n\t\t\tmul_c := gf_mul_table[c][:]\n\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tpivot_row[i] = mul_c[pivot_row[i]]\n\t\t\t}\n\t\t}\n\n\t\tid_row[icol] = 1\n\t\tif !bytes.Equal(pivot_row, id_row) {\n\t\t\tp := matrix\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tif i != icol {\n\t\t\t\t\tc = p[icol]\n\t\t\t\t\tp[icol] = 0\n\t\t\t\t\taddmul(p[:k], pivot_row, c)\n\t\t\t\t}\n\t\t\t\tp = p[k:]\n\t\t\t}\n\t\t}\n\n\t\tid_row[icol] = 0\n\t}\n\n\tfor i := 0; i < k; i++ {\n\t\tif indxr[i] != indxc[i] {\n\t\t\tfor row := 0; row < k; row++ {\n\t\t\t\tswap(&matrix[row*k+indxr[i]], &matrix[row*k+indxc[i]])\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func (m Matrix3) IsIdentity() bool {\n\treturn m == New3()\n}", "func (t *TriDense) Reset() {\n\t// N and Stride must be zeroed in unison.\n\tt.mat.N, t.mat.Stride = 0, 0\n\t// Defensively zero Uplo to ensure\n\t// it is set correctly later.\n\tt.mat.Uplo = 0\n\tt.mat.Data = t.mat.Data[:0]\n}", "func getMatrix(matrix [][][]int) [][]int {\n\n\tvar new_matrix [][]int\n\n\tnew_matrix = make([][]int, len(matrix))\n\n\tfor i := range new_matrix {\n\t\tnew_matrix[i] = make([]int, len(matrix[0]))\n\t}\n\n\tfor i := 0; i < len(matrix); i++ {\n\t\tfor j := 0; j < len(matrix[0]); j++ {\n\t\t\tnew_matrix[i][j] = matrix[i][j][0]\n\t\t}\n\t}\n\n\treturn new_matrix\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 (a *Mtx) Inverse() *Mtx {\n\tif a.inv != nil {\n\t\treturn a.inv\n\t}\n\ti := Identity()\n\te := a.el\n\ti.el[0][0] = e[1][1]*e[2][2]*e[3][3] - e[1][1]*e[2][3]*e[3][2] - e[2][1]*e[1][2]*e[3][3] + e[2][1]*e[1][3]*e[3][2] + e[3][1]*e[1][2]*e[2][3] - e[3][1]*e[1][3]*e[2][2]\n\ti.el[1][0] = e[1][0]*e[2][3]*e[3][2] - e[1][0]*e[2][2]*e[3][3] + e[2][0]*e[1][2]*e[3][3] - e[2][0]*e[1][3]*e[3][2] - e[3][0]*e[1][2]*e[2][3] + e[3][0]*e[1][3]*e[2][2]\n\ti.el[2][0] = e[1][0]*e[2][1]*e[3][3] - e[1][0]*e[2][3]*e[3][1] - e[2][0]*e[1][1]*e[3][3] + e[2][0]*e[1][3]*e[3][1] + e[3][0]*e[1][1]*e[2][3] - e[3][0]*e[1][3]*e[2][1]\n\ti.el[3][0] = e[1][0]*e[2][2]*e[3][1] - e[1][0]*e[2][1]*e[3][2] + e[2][0]*e[1][1]*e[3][2] - e[2][0]*e[1][2]*e[3][1] - e[3][0]*e[1][1]*e[2][2] + e[3][0]*e[1][2]*e[2][1]\n\ti.el[0][1] = e[0][1]*e[2][3]*e[3][2] - e[0][1]*e[2][2]*e[3][3] + e[2][1]*e[0][2]*e[3][3] - e[2][1]*e[0][3]*e[3][2] - e[3][1]*e[0][2]*e[2][3] + e[3][1]*e[0][3]*e[2][2]\n\ti.el[1][1] = e[0][0]*e[2][2]*e[3][3] - e[0][0]*e[2][3]*e[3][2] - e[2][0]*e[0][2]*e[3][3] + e[2][0]*e[0][3]*e[3][2] + e[3][0]*e[0][2]*e[2][3] - e[3][0]*e[0][3]*e[2][2]\n\ti.el[2][1] = e[0][0]*e[2][3]*e[3][1] - e[0][0]*e[2][1]*e[3][3] + e[2][0]*e[0][1]*e[3][3] - e[2][0]*e[0][3]*e[3][1] - e[3][0]*e[0][1]*e[2][3] + e[3][0]*e[0][3]*e[2][1]\n\ti.el[3][1] = e[0][0]*e[2][1]*e[3][2] - e[0][0]*e[2][2]*e[3][1] - e[2][0]*e[0][1]*e[3][2] + e[2][0]*e[0][2]*e[3][1] + e[3][0]*e[0][1]*e[2][2] - e[3][0]*e[0][2]*e[2][1]\n\ti.el[0][2] = e[0][1]*e[1][2]*e[3][3] - e[0][1]*e[1][3]*e[3][2] - e[1][1]*e[0][2]*e[3][3] + e[1][1]*e[0][3]*e[3][2] + e[3][1]*e[0][2]*e[1][3] - e[3][1]*e[0][3]*e[1][2]\n\ti.el[1][2] = e[0][0]*e[1][3]*e[3][2] - e[0][0]*e[1][2]*e[3][3] + e[1][0]*e[0][2]*e[3][3] - e[1][0]*e[0][3]*e[3][2] - e[3][0]*e[0][2]*e[1][3] + e[3][0]*e[0][3]*e[1][2]\n\ti.el[2][2] = e[0][0]*e[1][1]*e[3][3] - e[0][0]*e[1][3]*e[3][1] - e[1][0]*e[0][1]*e[3][3] + e[1][0]*e[0][3]*e[3][1] + e[3][0]*e[0][1]*e[1][3] - e[3][0]*e[0][3]*e[1][1]\n\ti.el[3][2] = e[0][0]*e[1][2]*e[3][1] - e[0][0]*e[1][1]*e[3][2] + e[1][0]*e[0][1]*e[3][2] - e[1][0]*e[0][2]*e[3][1] - e[3][0]*e[0][1]*e[1][2] + e[3][0]*e[0][2]*e[1][1]\n\ti.el[0][3] = e[0][1]*e[1][3]*e[2][2] - e[0][1]*e[1][2]*e[2][3] + e[1][1]*e[0][2]*e[2][3] - e[1][1]*e[0][3]*e[2][2] - e[2][1]*e[0][2]*e[1][3] + e[2][1]*e[0][3]*e[1][2]\n\ti.el[1][3] = e[0][0]*e[1][2]*e[2][3] - e[0][0]*e[1][3]*e[2][2] - e[1][0]*e[0][2]*e[2][3] + e[1][0]*e[0][3]*e[2][2] + e[2][0]*e[0][2]*e[1][3] - e[2][0]*e[0][3]*e[1][2]\n\ti.el[2][3] = e[0][0]*e[1][3]*e[2][1] - e[0][0]*e[1][1]*e[2][3] + e[1][0]*e[0][1]*e[2][3] - e[1][0]*e[0][3]*e[2][1] - e[2][0]*e[0][1]*e[1][3] + e[2][0]*e[0][3]*e[1][1]\n\ti.el[3][3] = e[0][0]*e[1][1]*e[2][2] - e[0][0]*e[1][2]*e[2][1] - e[1][0]*e[0][1]*e[2][2] + e[1][0]*e[0][2]*e[2][1] + e[2][0]*e[0][1]*e[1][2] - e[2][0]*e[0][2]*e[1][1]\n\tdet := 1.0 / (e[0][0]*i.el[0][0] + e[0][1]*i.el[1][0] + e[0][2]*i.el[2][0] + e[0][3]*i.el[3][0])\n\tfor j := 0; j < 4; j++ {\n\t\tfor k := 0; k < 4; k++ {\n\t\t\ti.el[j][k] *= det\n\t\t}\n\t}\n\ta.inv, i.inv = i, a\n\treturn i\n}", "func ZeroMatrix(arr [][]int) {\n\tm := len(arr)\n\tif m > 0 {\n\t\tn := len(arr[0])\n\n\t\trows := make([]bool, m)\n\t\tcols := make([]bool, n)\n\n\t\tfor i := 0; i < m; i++ {\n\t\t\tfor j := 0; j < n; j++ {\n\t\t\t\tif arr[i][j] == 0 {\n\t\t\t\t\trows[i] = true\n\t\t\t\t\tcols[j] = true\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// \"zero out\" rows\n\t\tfor i := 0; i < m; i++ {\n\t\t\tif rows[i] == true {\n\t\t\t\tfor j := 0; j < n; j++ {\n\t\t\t\t\tarr[i][j] = 0\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// \"zero out\" columns\n\t\tfor i := 0; i < n; i++ {\n\t\t\tif cols[i] == true {\n\t\t\t\tfor j := 0; j < m; j++ {\n\t\t\t\t\tarr[j][i] = 0\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func (p *EdwardsPoint) Identity() *EdwardsPoint {\n\tp.inner.X.Zero()\n\tp.inner.Y.One()\n\tp.inner.Z.One()\n\tp.inner.T.Zero()\n\treturn p\n}", "func Inverse(m M) (M, error) {\n\tm = CopyMatrix(m)\n\n\tif m.Rows() != m.Cols() {\n\t\treturn m, errors.New(\"non-square matrices have no inverse\")\n\t}\n\n\tm, _ = Augment(m, Identity(m.r)) // ignore error because Identity will always match m row size\n\n\tm = Rref(m)\n\n\tfor c := 1; c <= m.Rows(); c++ { // must be square, so m.Rows() works here\n\t\tfound := false\n\t\tfor r := 1; r <= m.Rows(); r++ {\n\t\t\tif isLeadingEntry(m, r, c) && m.Get(r, c).Numerator() == 1 && m.Get(r, c).Denominator() == 1 { //Leading entry that is one\n\t\t\t\tfound = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t\tif !found { //no leading entry that is one... not the identity, not invertible :(\n\t\t\treturn m, errors.New(\"matrix has no inverse\")\n\t\t}\n\t}\n\n\trm := M{r: m.r, c: m.r, values: make([]Frac, m.r*m.r)}\n\n\tfor r := 1; r <= rm.Rows(); r++ {\n\t\tfor c := 1; c <= rm.Cols(); c++ {\n\t\t\trm.Set(r, c, m.Get(r, rm.Cols()+c))\n\t\t}\n\t}\n\n\treturn rm, nil\n}", "func (b *BoolMatrixLinear) SetMatrix(newmat []byte) {\n\tfor i, _ := range b.matrix {\n\t\tif (newmat[i/8]>>(7-(i%8)))&1 == 1 {\n\t\t\tb.matrix[i] = true\n\t\t} else {\n\t\t\tb.matrix[i] = false\n\t\t}\n\t}\n}", "func (g *Game) fillMatrix() {\n\t// Fill Snake Head\n\tfor k := 0; k < numSquares; k++ {\n\t\tx := g.x\n\t\ty := g.y\n\n\t\tg.board[y][x] = 1\n\n\t}\n\t// fill dot\n\tfor k := 0; k < numSquares; k++ {\n\t\tx := g.dotX\n\t\ty := g.dotY\n\n\t\tg.board[y][x] = 2\n\n\t}\n\t// fill extra Snake\n\tfor k := 0; k < numSquares; k++ {\n\n\t\tfor m := 0; m < g.d; m++ {\n\n\t\t\tx := g.prevLocations[m][1]\n\t\t\ty := g.prevLocations[m][0]\n\n\t\t\tg.board[y][x] = 1\n\n\t\t}\n\n\t}\n\n\tg.resetFallingTimer()\n\n}", "func updateMatrix(matrix [][]int) [][]int {\n if len(matrix) == 0 {\n return matrix\n }\n\n q := [][]int{}\n\n push := func(x,y int) {\n q = append(q,[]int{x,y})\n }\n\n pull := func() (int,int) {\n if len(q) == 0 {\n return -1,-1\n }\n\n out := q[0]\n q = q[1:]\n return out[0],out[1]\n }\n\n out := make([][]int,len(matrix))\n for i := range matrix {\n out[i] = make([]int,len(matrix[i]))\n for j := range matrix[i] {\n if matrix[i][j] == 0 {\n out[i][j] = 0\n push(i,j)\n } else {\n out[i][j] = -1\n }\n }\n }\n\n for len(q) > 0 {\n i,j := pull()\n if i + 1 < len(out) && out[i+1][j] == -1 {\n out[i+1][j] = out[i][j] + 1\n push(i+1,j)\n }\n if i > 0 && out[i-1][j] == -1 {\n out[i-1][j] = out[i][j] + 1\n push(i-1,j)\n }\n if j + 1 < len(out[i]) && out[i][j+1] == -1 {\n out[i][j+1] = out[i][j] + 1\n push(i,j+1)\n }\n if j > 0 && out[i][j-1] == -1 {\n out[i][j-1] = out[i][j] + 1\n push(i,j-1)\n }\n }\n\n return out\n}", "func (c Cycles) Matrix() Matrix {\n\tm := make(Matrix, c.len())\n\tfor u := range m {\n\t\tm[u] = make([]int8, len(m))\n\t}\n\n\tfor _, cycle := range c {\n\t\tfor i, u := range cycle {\n\t\t\tv := cycle[0]\n\t\t\tif i < len(cycle)-1 {\n\t\t\t\tv = cycle[i+1]\n\t\t\t}\n\t\t\tm[u][v] = 1\n\t\t}\n\t}\n\n\treturn m\n}", "func main() {\n\tmatrix := [][]int{\n\t\t{1, 2, 0},\n\t\t{4, 5, 6},\n\t\t{7, 8, 9},\n\t}\n\n\tzeroMatrix(matrix)\n}", "func newMatrix(n int) (m [][]int) {\n\tm = make([][]int, n)\n\tfor i := range m {\n\t\tm[i] = make([]int, n)\n\t}\n\treturn m\n}", "func setZeroes(matrix [][]int) {\n\tfor row := 0; row < len(matrix); row++ {\n\t\tfor col := 0; col < len(matrix[0]); col++ {\n\t\t\tif matrix[row][col] != 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfor row2 := 0; row2 < len(matrix); row2++ {\n\t\t\t\tif matrix[row2][col] != 0 {\n\t\t\t\t\tmatrix[row2][col] = 2147483649\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor col2 := 0; col2 < len(matrix[0]); col2++ {\n\t\t\t\tif matrix[row][col2] != 0 {\n\t\t\t\t\tmatrix[row][col2] = 2147483649\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tfor row := 0; row < len(matrix); row++ {\n\t\tfor col := 0; col < len(matrix[0]); col++ {\n\t\t\tif matrix[row][col] == 2147483649 {\n\t\t\t\tmatrix[row][col] = 0\n\t\t\t}\n\t\t}\n\t}\n}", "func (m *BoolMatrix) SetMatrix(newmat []byte) {\n\t//\tfor i := 0; i < len(newmat); i++ {\n\t//\t\tm.matrix[i] = newmat[i]\n\t//\t}\n\tm.matrix = newmat\n}", "func (A Matrix) Inverse() Matrix {\n\tm, n := A.Dimensions()\n\tif m != n {\n\t\tpanic(\"invalid dimensions\")\n\t}\n\n\tB := A.Join(Identity(m, m))\n\tfor i := 1; i < m; i++ {\n\t\tfor j := i; j < m; j++ {\n\t\t\tif B[j][j-1] != 0 {\n\t\t\t\tB[j].Divide(B[j][j-1])\n\t\t\t\tB[j].Multiply(B[j-1][j-1])\n\t\t\t\tB[j].Subtract(B[i-1])\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i := m - 2; 0 <= i; i-- {\n\t\tfor j := i; 0 <= j; j-- {\n\t\t\tif B[j][j+1] != 0 {\n\t\t\t\tB[j].Divide(B[j][j+1])\n\t\t\t\tB[j].Multiply(B[j+1][j+1])\n\t\t\t\tB[j].Subtract(B[i+1])\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i, b := range B {\n\t\tif b[i] != 0 {\n\t\t\tb.Divide(b[i])\n\t\t}\n\t}\n\n\treturn New(m, m, func(i, j int) float64 { return B[i+m][j] })\n}", "func (matrix Matrix4) Mult(other Matrix4) Matrix4 {\n\n\tnewMat := NewMatrix4()\n\n\tnewMat[0][0] = matrix[0][0]*other[0][0] + matrix[0][1]*other[1][0] + matrix[0][2]*other[2][0] + matrix[0][3]*other[3][0]\n\tnewMat[1][0] = matrix[1][0]*other[0][0] + matrix[1][1]*other[1][0] + matrix[1][2]*other[2][0] + matrix[1][3]*other[3][0]\n\tnewMat[2][0] = matrix[2][0]*other[0][0] + matrix[2][1]*other[1][0] + matrix[2][2]*other[2][0] + matrix[2][3]*other[3][0]\n\tnewMat[3][0] = matrix[3][0]*other[0][0] + matrix[3][1]*other[1][0] + matrix[3][2]*other[2][0] + matrix[3][3]*other[3][0]\n\n\tnewMat[0][1] = matrix[0][0]*other[0][1] + matrix[0][1]*other[1][1] + matrix[0][2]*other[2][1] + matrix[0][3]*other[3][1]\n\tnewMat[1][1] = matrix[1][0]*other[0][1] + matrix[1][1]*other[1][1] + matrix[1][2]*other[2][1] + matrix[1][3]*other[3][1]\n\tnewMat[2][1] = matrix[2][0]*other[0][1] + matrix[2][1]*other[1][1] + matrix[2][2]*other[2][1] + matrix[2][3]*other[3][1]\n\tnewMat[3][1] = matrix[3][0]*other[0][1] + matrix[3][1]*other[1][1] + matrix[3][2]*other[2][1] + matrix[3][3]*other[3][1]\n\n\tnewMat[0][2] = matrix[0][0]*other[0][2] + matrix[0][1]*other[1][2] + matrix[0][2]*other[2][2] + matrix[0][3]*other[3][2]\n\tnewMat[1][2] = matrix[1][0]*other[0][2] + matrix[1][1]*other[1][2] + matrix[1][2]*other[2][2] + matrix[1][3]*other[3][2]\n\tnewMat[2][2] = matrix[2][0]*other[0][2] + matrix[2][1]*other[1][2] + matrix[2][2]*other[2][2] + matrix[2][3]*other[3][2]\n\tnewMat[3][2] = matrix[3][0]*other[0][2] + matrix[3][1]*other[1][2] + matrix[3][2]*other[2][2] + matrix[3][3]*other[3][2]\n\n\tnewMat[0][3] = matrix[0][0]*other[0][3] + matrix[0][1]*other[1][3] + matrix[0][2]*other[2][3] + matrix[0][3]*other[3][3]\n\tnewMat[1][3] = matrix[1][0]*other[0][3] + matrix[1][1]*other[1][3] + matrix[1][2]*other[2][3] + matrix[1][3]*other[3][3]\n\tnewMat[2][3] = matrix[2][0]*other[0][3] + matrix[2][1]*other[1][3] + matrix[2][2]*other[2][3] + matrix[2][3]*other[3][3]\n\tnewMat[3][3] = matrix[3][0]*other[0][3] + matrix[3][1]*other[1][3] + matrix[3][2]*other[2][3] + matrix[3][3]*other[3][3]\n\n\treturn newMat\n\n}", "func (m *Matrix) init() {\n\tfor w := 0; w < m.width; w++ {\n\t\tfor h := 0; h < m.height; h++ {\n\t\t\tm.mat[w][h] = QRValue_INIT_V0\n\t\t}\n\t}\n}", "func Empty(m, n int) Matrix {\n\treturn New(m, n, func(i, j int) float64 { return 0 })\n}", "func (i *identity) Reset() {\n\ti.data = make([]byte, 0)\n}", "func getNewMatrix(c, r int) (matrix [][]float64) {\n\tfor i := 0; i < c; i++ {\n\t\tfor j := 0; j < r; j++ {\n\t\t\tfor x := len(matrix); x <= i; x++ {\n\t\t\t\tmatrix = append(matrix, []float64{})\n\t\t\t}\n\t\t\tfor y := len(matrix[i]); y <= j; y++ {\n\t\t\t\tmatrix[i] = append(matrix[i], 0)\n\t\t\t}\n\t\t\tmatrix[i][j] = 0\n\t\t}\n\t}\n\treturn\n}", "func (p *Proc) Matrix(a, b, c, d, e, f float64) {\n\tp.stk.matrix(f32.NewAffine2D(\n\t\tfloat32(a), float32(b), float32(c),\n\t\tfloat32(d), float32(e), float32(f),\n\t))\n}", "func (m Matrix) Inverse() Matrix {\n\td := m.Determinant()\n\treturn Matrix{\n\t\tm[3] / d, -m[1] / d,\n\t\t-m[2] / d, m[0] / d,\n\t\t(m[2]*m[5] - m[3]*m[4]) / d,\n\t\t(m[1]*m[4] - m[0]*m[5]) / d,\n\t}\n}", "func zeroCross(matrix [][]int, row, col int) {\n\tm, n := len(matrix), len(matrix[0])\n\tfor curCol := 0; curCol < n; curCol++ {\n\t\tmatrix[row][curCol] = 0\n\t}\n\tfor curRow := 0; curRow < m; curRow++ {\n\t\tmatrix[curRow][col] = 0\n\t}\n}", "func Mat3Identity(out []float64) []float64 {\n\tout[0] = 1\n\tout[1] = 0\n\tout[2] = 0\n\tout[3] = 0\n\tout[4] = 1\n\tout[5] = 0\n\tout[6] = 0\n\tout[7] = 0\n\tout[8] = 1\n\treturn out\n}", "func GenerateFull(n, m int) Matrix {\n\tout := GenerateEmpty(n, m)\n\n\tfor i, _ := range out {\n\t\tfor j, _ := range out[i] {\n\t\t\tout[i][j].SetOne()\n\t\t}\n\t}\n\n\treturn out\n}", "func (t *TriDense) Zero() {\n\tif t.isUpper() {\n\t\tfor i := 0; i < t.mat.N; i++ {\n\t\t\tzero(t.mat.Data[i*t.mat.Stride+i : i*t.mat.Stride+t.mat.N])\n\t\t}\n\t\treturn\n\t}\n\tfor i := 0; i < t.mat.N; i++ {\n\t\tzero(t.mat.Data[i*t.mat.Stride : i*t.mat.Stride+i+1])\n\t}\n}", "func Inverse(a Matrix) (Matrix, error) {\n\tinv, err := mat64.Inverse(ToMat64(a))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn ToMatrix(inv), nil\n}", "func Matrix(index uint) uint {\n\tif index <= 1 {\n\t\treturn index\n\t}\n\n\tf := [2][2]uint{\n\t\t{1, 1},\n\t\t{1, 0},\n\t}\n\n\tf = matrixPower(f, index-1)\n\n\treturn f[0][0]\n}", "func buildMatrix(dataShards, totalShards int) matrix {\n\t// Start with a Vandermonde matrix. This matrix would work, in theory, but\n\t// doesn't have the property that the data shards are unchanged after\n\t// encoding.\n\tvm := vandermonde(totalShards, dataShards)\n\n\t// Multiply by the inverse of the top square of the matrix. This will make\n\t// the top square be the identity matrix, but preserve the property that any\n\t// square subset of rows is invertible.\n\ttop := vm.SubMatrix(0, 0, dataShards, dataShards)\n\ttopInv, _ := top.Invert()\n\treturn vm.Multiply(topInv)\n}", "func MatrixInverse(scope *Scope, input tf.Output, optional ...MatrixInverseAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"MatrixInverse\",\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 (o *SparseDependencyMap) Identity() elemental.Identity {\n\n\treturn DependencyMapIdentity\n}", "func restoreMatrix(rowSum []int, colSum []int) [][]int {\n\tm := len(rowSum)\n\tn := len(colSum)\n\n\tarr := make([][]int, 0, m)\n\tfor i := 0; i < m; i++ {\n\t\tarr = append(arr, make([]int, n))\n\t}\n\n\tx, y := 0, 0\n\tfor x < n && y < m {\n\t\ta := colSum[x]\n\t\tb := rowSum[y]\n\t\tt := a\n\t\tif t > b {\n\t\t\tt = b\n\t\t}\n\n\t\tarr[y][x] = t\n\t\tcolSum[x] -= t\n\t\trowSum[y] -= t\n\t\tif colSum[x] == 0 {\n\t\t\tx++\n\t\t}\n\n\t\tif rowSum[y] == 0 {\n\t\t\ty++\n\t\t}\n\t}\n\n\treturn arr\n}", "func ZeroMatrix(x [][]int) [][]int {\n\tn := len(x)\n\t// create a slice of boleans that each index will refer\n\t// to a row or col that we found a zero at\n\tzr := make([]bool, n)\n\tzc := make([]bool, len(x[0]))\n\n\tfor i := 0; i < n; i++ {\n\t\tfor j := 0; j < len(x[0]); j++ {\n\t\t\tif x[i][j] == 0 {\n\t\t\t\t// save the row that we found a 0 at in the bool array of rows\n\t\t\t\tzr[i] = true\n\t\t\t\t// save the col that we found a 0 at in the bool array of cols\n\t\t\t\tzc[j] = true\n\t\t\t}\n\t\t}\n\t}\n\t// loop through again and zero out everything at that row\n\tfor r, v := range zr {\n\t\tif v == true {\n\t\t\tzeroRow(x, r)\n\t\t}\n\t}\n\t// same as above but for cols\n\tfor c, v := range zc {\n\t\tif v == true {\n\t\t\tzeroCol(x, c)\n\t\t}\n\t}\n\treturn x\n}", "func (origMtx *ScoringMatrix) copy() (newMtx *ScoringMatrix) {\n\n\tnewMtx = new(ScoringMatrix)\n\n\tnewMtx.PlayerInfoMap = make(map[*Player](map[Position]float64))\n\n\tfor playerInfo := range origMtx.PlayerInfoMap {\n\t\tnewMtx.PlayerInfoMap[playerInfo] = make(map[Position]float64)\n\n\t\tfor fieldPos, score := range origMtx.PlayerInfoMap[playerInfo] {\n\t\t\tnewMtx.PlayerInfoMap[playerInfo][fieldPos] = score\n\t\t}\n\t}\n\n\treturn\n}", "func (c *CSR) Reset() {\n\tc.matrix.I, c.matrix.J = 0, 0\n\tc.matrix.Indptr = c.matrix.Indptr[:0]\n\tc.matrix.Ind = c.matrix.Ind[:0]\n\tc.matrix.Data = c.matrix.Data[:0]\n}", "func (o *SparseEnforcerReport) Identity() elemental.Identity {\n\n\treturn EnforcerReportIdentity\n}", "func Ones(m, n int) *Matrix {\n\tA := Zeros(m, n)\n\tfor i := range(A.data) {\n\t\tA.data[i] = 1.0\n\t}\n\treturn A\n}", "func (o *SparseMetricsQuery) Identity() elemental.Identity {\n\n\treturn MetricsQueryIdentity\n}", "func copyMatrix(m [][]int) [][]int {\n\tvar matrix [][]int\n\tfor _, row := range m {\n\t\tnewRow := make([]int, len(row))\n\t\tcopy(newRow, row)\n\t\tmatrix = append(matrix, newRow)\n\t}\n\treturn matrix\n}", "func fillNaNDense(m *mat.Dense) {\n\tr, c := m.Dims()\n\tfor i := 0; i < r; i++ {\n\t\tfor j := 0; j < c; j++ {\n\t\t\tm.Set(i, j, math.NaN())\n\t\t}\n\t}\n}", "func (A *Matrix64) T() SparseMatrix64 {\n\ttA := &Matrix64{\n\t\telems: make(Vector64, len(A.elems)),\n\t\tnrows: A.ncols,\n\t\tncols: A.nrows,\n\t}\n\tm, n := A.Nrows(), A.Ncols()\n\tfor i := 0; i < m; i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\ttA.elems[j+i*n] = A.elems[i+j*m]\n\t\t}\n\t}\n\treturn tA\n}", "func (o *SparseClaims) Identity() elemental.Identity {\n\n\treturn ClaimsIdentity\n}", "func adjugateMatrix(A [][]float64) (adjA [][]float64) {\n\tN := len(A)\n\tvar B [][]float64\n\tfor i := 0; i < N; i++ {\n\t\tadjA = append(adjA, make([]float64, N))\n\t\tfor j := 0; j < N; j++ {\n\t\t\tfor m := 0; m < N; m++ {\n\t\t\t\tfor n := 0; n < N; n++ {\n\t\t\t\t\tfor x := len(B); x <= m; x++ {\n\t\t\t\t\t\tB = append(B, []float64{})\n\t\t\t\t\t}\n\t\t\t\t\tfor k := len(B[m]); k <= n; k++ {\n\t\t\t\t\t\tB[m] = append(B[m], 0)\n\t\t\t\t\t}\n\t\t\t\t\tB[m][n] = A[m][n]\n\t\t\t\t}\n\t\t\t}\n\t\t\tadjA[i][j] = cofactorMatrix(j, i, B)\n\t\t}\n\t}\n\treturn\n}", "func (g *Graph) Identity(x Node) Node {\n\treturn g.NewOperator(fn.NewIdentity(x), x)\n}", "func (imd *IMDraw) SetMatrix(m pixel.Matrix) {\n\timd.matrix = m\n\timd.batch.SetMatrix(imd.matrix)\n}", "func Copy(m *Matrix) *Matrix {\n\treturn nil\n}", "func (o *SparseRenderTemplate) Identity() elemental.Identity {\n\n\treturn RenderTemplateIdentity\n}", "func Identity(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: \"Identity\",\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 (m *spiralMemory) reallocate() {\n\t// add zero rows before/after the existing ones\n\tnewGrid := make([][]int, m.offset*4+1)\n\tcopy(newGrid[m.offset:], m.grid)\n\tm.grid = newGrid\n\tfor i := range m.grid {\n\t\tif i < 2 || i > m.offset*3 {\n\t\t\t// new blank row\n\t\t\tm.grid[i] = make([]int, m.offset*4+1)\n\t\t} else {\n\t\t\t// resize existing row\n\t\t\tnewRow := make([]int, m.offset*4+1)\n\t\t\t// copy existing values into the right position, leaving the existing\n\t\t\t// offset's worth of zero values\n\t\t\tcopy(newRow[m.offset:], m.grid[i])\n\t\t\tm.grid[i] = newRow\n\t\t}\n\t}\n\t// record new offset\n\tm.offset *= 2\n}", "func (s *Dense) Reset() {\n\tif s.v != nil {\n\t\ts.v = s.v[:0]\n\t}\n}", "func _rotate(matrix [][]int) {\n\tn := len(matrix)\n\tif n <= 1 {\n\t\treturn\n\t}\n\n\t// 从外到内遍历每一圈\n\tfor level := 1; level <= n/2; level++ {\n\t\trowMin := level - 1\n\t\trowMax := n - level\n\t\tcolMin := level - 1\n\t\tcolMax := n - level\n\t\t// 将每一圈分为四块相等的区域,每个区域的元素数目为 n-2*(level-1)-1\n\t\tbatchSize := n - 2*(level-1) - 1\n\t\tfor offset := 0; offset < batchSize; offset++ {\n\t\t\t// 在缓存区中放入上区块的元素\n\t\t\ttemp := matrix[rowMin][colMin+offset]\n\t\t\t// 在上区块放入左区块的元素\n\t\t\tmatrix[rowMin][colMin+offset] = matrix[rowMax-offset][colMin]\n\t\t\t// 在左区块放入下区块的元素\n\t\t\tmatrix[rowMax-offset][colMin] = matrix[rowMax][colMax-offset]\n\t\t\t// 在下区块放入右区块的元素\n\t\t\tmatrix[rowMax][colMax-offset] = matrix[rowMin+offset][colMax]\n\t\t\t// 在右区块放入缓存区的元素\n\t\t\tmatrix[rowMin+offset][colMax] = temp\n\t\t}\n\t}\n}", "func baseRotation(from [][]int, to [][]int) {\n\tto[0][2] = from[0][0]\n\tto[2][2] = from[0][2]\n\tto[2][0] = from[2][2]\n\tto[0][0] = from[2][0]\n\n\tto[1][2] = from[0][1]\n\tto[2][1] = from[1][2]\n\tto[1][0] = from[2][1]\n\tto[0][1] = from[1][0]\n}", "func matrixClone(matrix [][]float64) (cloneMatrix [][]float64) {\n\tfor i := 0; i < len(matrix); i++ {\n\t\tfor j := 0; j < len(matrix[i]); j++ {\n\t\t\tfor x := len(cloneMatrix); x <= i; x++ {\n\t\t\t\tcloneMatrix = append(cloneMatrix, []float64{})\n\t\t\t}\n\t\t\tfor k := len(cloneMatrix[i]); k <= j; k++ {\n\t\t\t\tcloneMatrix[i] = append(cloneMatrix[i], 0)\n\t\t\t}\n\t\t\tcloneMatrix[i][j] = matrix[i][j]\n\t\t}\n\t}\n\treturn\n}", "func PushMatrix() {\n\tsyscall.Syscall(gpPushMatrix, 0, 0, 0, 0)\n}", "func (m *OneHotEncoder) InverseTransform(X, Y *mat.Dense) (Xout, Yout *mat.Dense) {\n\tnSamples, _ := X.Dims()\n\tnFeatures := len(m.NValues)\n\tYout = Y\n\tXout = mat.NewDense(nSamples, nFeatures, nil)\n\n\tfor feature := 0; feature < nFeatures; feature++ {\n\t\tcstart, cend := m.FeatureIndices[feature], m.FeatureIndices[feature+1]\n\t\tfor sample := 0; sample < nSamples; sample++ {\n\t\t\tclassNo := floats.MaxIdx(X.RawRowView(sample)[cstart:cend])\n\t\t\tXout.Set(sample, feature, float64(classNo))\n\t\t}\n\t}\n\treturn\n\n}", "func IdentMat4() *Mat4 {\n\tvar m Mat4\n\tm[0].X = 1.0\n\tm[1].Y = 1.0\n\tm[2].Z = 1.0\n\tm[3].W = 1.0\n\treturn &m\n}", "func (matrix *Matrix) fillMatrix(info Information) *Matrix {\n\tvar newIndexes []*IndexLetter\n\n\tdata := info.Data\n\n\t// Llenar la primera dimension\n\n\tfor i, dat := range data { // Recorremos cada dato obtenido del json\n\t\tnewIndex := IndexLetter{\n\t\t\tIndex: dat.Index,\n\t\t}\n\t\tnewIndexes = append(newIndexes, &newIndex)\n\t\t//newIndexes[i].Index = dat.Index // Agrega la letra del indice\n\t\tvar newDepartments []DepartmentMatrix\n\n\t\tfor j, dep := range dat.Departments { // Recorremos cada departamento de cada indice\n\t\t\tnewDepartment := DepartmentMatrix{\n\t\t\t\tName: dep.Name,\n\t\t\t}\n\t\t\tnewDepartments = append(newDepartments, newDepartment)\n\t\t\tvar newRatings [5]Rating\n\n\t\t\tfor l := 1; l <= 5; l++ { // Se le crea una lista a cada posicion\n\t\t\t\tnewRatings[l-1] = Rating{\n\t\t\t\t\tNumber: l,\n\t\t\t\t\tLista: NewDoublyLinkedList(),\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor _, sto := range dep.Stores { // Recorremos cada tienda de cada departamento\n\n\t\t\t\trate := int(sto.Rating) - 1\n\t\t\t\tnode := NewNode(sto)\n\t\t\t\tnewRatings[rate].Lista.Append(node) // Se agrega la nueva tienda a la posicion del arreglo correspondiente a su calificacion\n\t\t\t\tagregarTiendaMerkle(sto)\n\t\t\t}\n\t\t\tnewDepartments[j].Ratings = newRatings\n\t\t}\n\t\tnewIndexes[i].Departments = newDepartments\n\n\t}\n\n\tmatrix.Indexes = newIndexes\n\n\treturn matrix\n}", "func (o InferenceClusterOutput) Identity() InferenceClusterIdentityPtrOutput {\n\treturn o.ApplyT(func(v *InferenceCluster) InferenceClusterIdentityPtrOutput { return v.Identity }).(InferenceClusterIdentityPtrOutput)\n}", "func (o *SparseImageVulnerability) Identity() elemental.Identity {\n\n\treturn ImageVulnerabilityIdentity\n}", "func (c *Canvas) SetMatrix(m pixel.Matrix) {\n\tfor i := range m {\n\t\tc.mat[i] = float32(m[i])\n\t}\n}", "func (A *Matrix) Set(i, j int, v float64){\n\tA.data[i * A.stride + j] = v\n}", "func (target *Matrix) Copy(m *Matrix) *Matrix {\n\treturn nil\n}", "func rotate(matrix [][]int) {\n n := len(matrix)\n for i:=0;i<n;i++{\n for j:=i+1;j<n;j++{\n temp:=matrix[i][j]\n matrix[i][j]=matrix[j][i]\n matrix[j][i]=temp\n }\n }\n for i:=0;i<n;i++{\n for j:=0;j<n/2;j++{\n temp:=matrix[i][j]\n matrix[i][j]=matrix[i][n-1-j]\n matrix[i][n-1-j]=temp\n }\n }\n}", "func (m *matrixComplex) IsIdentity() bool {\n\treturn reflect.DeepEqual(m, MakeIdentityComplexMatrix(m.GetNumRows()))\n}", "func (b *BaseDevice) SetMatrixClip(mat *Matrix, bw *Region, clipStack *ClipStack) {\n\ttoimpl()\n}", "func newIntMatrix(r, c int) [][]int {\n\tmem := make([]int, r*c)\n\tmat := make([][]int, r)\n\tfor i := 0; i < r; i++ {\n\t\tmat[i], mem = mem[:c], mem[c:]\n\t}\n\treturn mat\n}", "func (m *TransposableMatrix) Empty(x, y int) bool {\n\tsl := m.Get(x, y)\n\tif sl.AmX == nil {\n\t\treturn true\n\t}\n\treturn false\n}", "func rnd_m4_affine_inv(_mat [16]float64) ([16]float64, [9]float64) {\n\tupper := [9]float64{}\n\tcopy(upper[0:3], _mat[0:3])\n\tcopy(upper[3:6], _mat[4:7])\n\tcopy(upper[6:9], _mat[8:11])\n\tinv3 := mat.NewDense(3, 3, upper[:])\n\tif err:= inv3.Inverse(inv3); err!=nil {\n\t\tfmt.Println(\"Cannot inverse the matrix\")\n\t\tfmt.Println(err.Error())\n\t\tos.Exit(1)\n\t}\n\t_V := [3]float64{-_mat[3], -_mat[7], -_mat[11]}\n\tV := mat.NewVecDense(3, _V[:])\n\t//var U mat.VecDense\n\tactual := make([]float64,3)\n\tU:= mat.NewVecDense(3, actual)\n\tU.MulVec(inv3, V)\n\t_inv := [16]float64{\n\t\tupper[0], upper[1], upper[2], actual[0],\n\t\tupper[3], upper[4], upper[5], actual[1],\n\t\tupper[6], upper[7], upper[8], actual[2],\n\t\t0, 0, 0, 1,\n\t}\n\treturn _inv,upper\n}" ]
[ "0.70241266", "0.7021237", "0.6878587", "0.67622966", "0.66264474", "0.6616889", "0.6402463", "0.6309763", "0.6251513", "0.6238026", "0.6185736", "0.60612005", "0.60321355", "0.6030096", "0.60041106", "0.5827118", "0.5573641", "0.5540295", "0.5516417", "0.5383947", "0.5379023", "0.5368106", "0.5359107", "0.53481126", "0.53282845", "0.53223157", "0.52745116", "0.52700585", "0.52141476", "0.51882404", "0.51643", "0.5159775", "0.5155883", "0.51374006", "0.5125092", "0.5122332", "0.50969046", "0.5086076", "0.5082549", "0.5062201", "0.5038996", "0.50267863", "0.5022793", "0.50178003", "0.50171703", "0.5010728", "0.4999035", "0.49807253", "0.4968581", "0.49479547", "0.4947212", "0.4917534", "0.49146584", "0.49143463", "0.49080226", "0.49031976", "0.48904243", "0.48706347", "0.48643306", "0.48595342", "0.48250413", "0.481924", "0.48188657", "0.4818449", "0.48091635", "0.4807902", "0.48021665", "0.47975487", "0.4777438", "0.4776052", "0.47446665", "0.4738519", "0.4736748", "0.47291884", "0.47201595", "0.47086406", "0.47075528", "0.47056216", "0.46988717", "0.4698764", "0.46982875", "0.46927246", "0.468525", "0.46802", "0.46753493", "0.4673505", "0.4672787", "0.4665757", "0.4665661", "0.46531743", "0.46514174", "0.465015", "0.46500796", "0.46436515", "0.4639547", "0.46355623", "0.4622861", "0.46221924", "0.46206707", "0.46174607", "0.46157733" ]
0.0
-1
load a name onto the name stack
func LoadName(name uint32) { C.glowLoadName(gpLoadName, (C.GLuint)(name)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func LoadName(name uint32) {\n\tsyscall.Syscall(gpLoadName, 1, uintptr(name), 0, 0)\n}", "func LoadName(name uint32) {\n C.glowLoadName(gpLoadName, (C.GLuint)(name))\n}", "func (s *BasePCREListener) EnterName(ctx *NameContext) {}", "func (s *BasecluListener) EnterName(ctx *NameContext) {}", "func (s *BaseSyslParserListener) EnterName_str(ctx *Name_strContext) {}", "func (p *Puck) Load(name ...string) error {\n\tcmd := []byte(\"load();\\n\")\n\terr := p.command(name, cmd)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (s *BaseAspidaListener) EnterName(ctx *NameContext) {}", "func LoadByName(s *state.State, name string) (Network, error) {\n\tid, netInfo, err := s.Cluster.GetNetworkInAnyState(name)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tdriverFunc, ok := drivers[netInfo.Type]\n\tif !ok {\n\t\treturn nil, ErrUnknownDriver\n\t}\n\n\tn := driverFunc()\n\tn.init(s, id, name, netInfo.Type, netInfo.Description, netInfo.Config, netInfo.Status)\n\n\treturn n, nil\n}", "func PushName(name uint32) {\n\tsyscall.Syscall(gpPushName, 1, uintptr(name), 0, 0)\n}", "func (s *BasevhdlListener) EnterName(ctx *NameContext) {}", "func LoadVariable(name string) {\n\toutput.EmitLn(\"MOVE \" + name + \"(PC),D0\")\n}", "func (s *BasecookieListener) EnterName(ctx *NameContext) {}", "func (s *BaseRFC5424Listener) EnterName(ctx *NameContext) {}", "func load(interpreter *Interpreter) {\n\tname := interpreter.PopName()\n\tvalue, _ := interpreter.FindValueInDictionaries(name)\n\tif value == nil {\n\t\tlog.Printf(\"Can't find value %s\\n\", name)\n\t}\n\tinterpreter.Push(value)\n}", "func parseName(raw string) (name, error) {\n\thead, tail := peel(raw, \"/\")\n\tif tail == \"\" {\n\t\tn := name{Kind: idName}\n\t\tvar err error\n\t\tn.ID, err = reflow.Digester.Parse(head)\n\t\tif _, ok := err.(hex.InvalidByteError); ok {\n\t\t\treturn n, errors.E(\"invalid reflow object name: \", raw, err)\n\t\t}\n\t\treturn n, err\n\t}\n\tvar n name\n\tn.InstanceID = head\n\thead, tail = peel(tail, \"/\")\n\tn.AllocID = head\n\tif tail == \"\" {\n\t\tn.Kind = allocName\n\t\treturn n, nil\n\t}\n\tvar err error\n\tn.ID, err = reflow.Digester.Parse(tail)\n\tif _, ok := err.(hex.InvalidByteError); ok {\n\t\treturn n, errors.E(\"invalid reflow object name: \", raw, err)\n\t}\n\tif err != nil {\n\t\treturn name{}, err\n\t}\n\tn.Kind = execName\n\treturn n, nil\n}", "func GetDataLoadReleaseName(name string) string {\n\treturn fmt.Sprintf(\"%s-loader\", name)\n}", "func (s *BasePlSqlParserListener) EnterLabel_name(ctx *Label_nameContext) {}", "func (s *BasevhdlListener) EnterName_part(ctx *Name_partContext) {}", "func (s *BaseAspidaListener) EnterNameMain(ctx *NameMainContext) {}", "func (s *BasecluListener) EnterOp_name(ctx *Op_nameContext) {}", "func PushName(name uint32) {\n C.glowPushName(gpPushName, (C.GLuint)(name))\n}", "func PushName(name uint32) {\n\tC.glowPushName(gpPushName, (C.GLuint)(name))\n}", "func (n *nameHistory) Load() error {\n\tfp, err := os.OpenFile(n.filepath, os.O_RDONLY, os.ModePerm)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"could not open %q file: %v\", n.filepath, err)\n\t}\n\tdefer fp.Close()\n\n\tif err := yaml.NewDecoder(fp).Decode(&n.entries); err != nil {\n\t\treturn fmt.Errorf(\"could not decode file: %v\", err)\n\t}\n\n\tn.isChanged = false\n\n\treturn nil\n}", "func (s *BasePlSqlParserListener) EnterProfile_name(ctx *Profile_nameContext) {}", "func LoadMnemonic(mnemonic string) string {\n\tif bip39.IsMnemonicValid(mnemonic) {\n\t\treturn TrimMnemonic(mnemonic)\n\t}\n\n\treturn TrimMnemonic(mnemonicFromFile(mnemonic))\n}", "func (s *BasePlSqlParserListener) EnterVariable_name(ctx *Variable_nameContext) {}", "func (b *cloudBackend) parseStackName(s string) (qualifiedStackReference, error) {\n\tvar q qualifiedStackReference\n\n\tsplit := strings.Split(s, \"/\")\n\tswitch len(split) {\n\tcase 1:\n\t\tq.Name = split[0]\n\tcase 2:\n\t\tq.Owner = split[0]\n\t\tq.Name = split[1]\n\tcase 3:\n\t\tq.Owner = split[0]\n\t\tq.Project = split[1]\n\t\tq.Name = split[2]\n\tdefault:\n\t\treturn qualifiedStackReference{}, fmt.Errorf(\"could not parse stack name '%s'\", s)\n\t}\n\n\treturn q, nil\n}", "func (s *BaseSyslParserListener) EnterAtomT_name(ctx *AtomT_nameContext) {}", "func LoadStack(name string, cfg composetypes.Config) (*apiv1beta1.Stack, error) {\n\tres, err := yaml.Marshal(cfg)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &apiv1beta1.Stack{\n\t\tObjectMeta: metav1.ObjectMeta{\n\t\t\tName: name,\n\t\t},\n\t\tSpec: apiv1beta1.StackSpec{\n\t\t\tComposeFile: string(res),\n\t\t},\n\t}, nil\n}", "func (s *BasePlSqlParserListener) EnterLibrary_name(ctx *Library_nameContext) {}", "func (s *BasecluListener) EnterName_list(ctx *Name_listContext) {}", "func (s *BaseSyslParserListener) EnterName_with_attribs(ctx *Name_with_attribsContext) {}", "func (st *scopeStack) push(name ID) {\n\tids := idScope{\n\t\tID: name,\n\t\tscope: scope{},\n\t}\n\tst.stack = append(st.stack, ids)\n}", "func (r *PopRow) SetName(name string) { r.Data.Name = name }", "func (s *GruleV2ParserListener) EnterRuleName(ctx *parser2.RuleNameContext) {\n\tif s.StopParse {\n\t\treturn\n\t}\n\tentry := s.Stack.Peek().(*ast.RuleEntry)\n\tentry.Name = ctx.SIMPLENAME().GetText()\n}", "func (color *Color) readName(r io.Reader) (err error) {\n\tif color.nameLen == 0 {\n\t\treturn\n\t}\n\n\t//\tmake array for our color name based on block length\n\tname := make([]uint16, color.nameLen) // assumes the nameLen was already defined.\n\tif err = binary.Read(r, binary.BigEndian, &name); err != nil {\n\t\treturn\n\t}\n\n\t//\tdecode our name. we trim off the last byte since it's zero terminated\n\t// utf16.Decode returns a slice of runes from an input of []uint16\n\tcolor.Name = string(utf16.Decode(name[:len(name)-1]))\n\n\treturn\n}", "func (c *Compiler) loadSymbol(s symbols.Symbol) {\n\tswitch s.Scope {\n\tcase symbols.GlobalScope:\n\t\tc.emit(operation.GetGlobal, s.Index)\n\tcase symbols.LocalScope:\n\t\tc.emit(operation.GetLocal, s.Index)\n\tcase symbols.BuiltinScope:\n\t\tc.emit(operation.GetBuiltin, s.Index)\n\tcase symbols.FreeScope:\n\t\tc.emit(operation.GetFree, s.Index)\n\t}\n}", "func (p Profiles) LoadProfileByName(name, key string) (string, error) {\n\tprofile, found := p.NamedProfiles[name]\n\tif !found {\n\t\treturn \"\", errors.Wrap(ProfileNotExistError, name)\n\t}\n\n\td, err := readProfileFile(profile.Path, key)\n\treturn d, err\n}", "func fromName(name string, cmder runner.Cmder) *Node {\n\treturn &Node{\n\t\tname: name,\n\t\tcache: &nodeCache{},\n\t\tcmder: cmder,\n\t}\n}", "func (self *TileSprite) SetNameA(member string) {\n self.Object.Set(\"name\", member)\n}", "func (yl *KaminoYAMLLoader) Name() string {\n\treturn yl.name\n}", "func (v *VarSet) load(name string) (string, bool) {\n\tfor _, lookup := range v.sources {\n\t\trv, ok := lookup(name)\n\t\tif ok {\n\t\t\treturn rv, true\n\t\t}\n\t}\n\treturn \"\", false\n}", "func (p *parser) evalName(x *ebnf.Name) bool {\n\tdbg.Println(\"evalName:\", exprString(x))\n\tprod := p.grammar[x.String]\n\treturn p.evalProd(prod)\n}", "func (s *BasePlSqlParserListener) EnterSavepoint_name(ctx *Savepoint_nameContext) {}", "func LoadVMByName(name string) (machine.VM, error) {\n\tvm := new(MachineVM)\n\tvmConfigDir, err := machine.GetConfDir(vmtype)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tb, err := ioutil.ReadFile(filepath.Join(vmConfigDir, name+\".json\"))\n\tif os.IsNotExist(err) {\n\t\treturn nil, errors.Wrap(machine.ErrNoSuchVM, name)\n\t}\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\terr = json.Unmarshal(b, vm)\n\tlogrus.Debug(vm.CmdLine)\n\treturn vm, err\n}", "func (m *LabelActionBase) SetName(value *string)() {\n err := m.GetBackingStore().Set(\"name\", value)\n if err != nil {\n panic(err)\n }\n}", "func (self *Build) load(ctx core.Context, moduleLabel core.Label) (starlark.StringDict, error) {\n\t// Only .bzl files can ever be loaded.\n\tif filepath.Ext(string(moduleLabel.Target)) != \".bzl\" {\n\t\treturn nil, fmt.Errorf(\"%v: load not allowed: %v is not a .bzl file\", ctx.Label(),\n\t\t\tmoduleLabel)\n\t}\n\tmoduleLabelString := moduleLabel.String()\n\n\te, ok := self.loadCache[moduleLabelString]\n\tif ok {\n\t\tif e == nil {\n\t\t\treturn nil, fmt.Errorf(\"%v: load of %v failed: cycle in load graph\",\n\t\t\t\tctx.Label(), moduleLabel)\n\t\t}\n\t\treturn e.globals, e.err\n\t}\n\n\tsourceData, err := self.sourceFileReader(moduleLabel)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"%v: load of %v failed: read failed: %v\", ctx.Label(),\n\t\t\tmoduleLabel, err)\n\t}\n\n\tself.loadCache[moduleLabelString] = nil\n\n\tthread := createThread(self, moduleLabel, core.FileTypeBzl)\n\tglobals, err := starlark.ExecFile(thread, moduleLabelString, sourceData,\n\t\tbuiltins.InitialGlobals(core.FileTypeBzl))\n\tself.loadCache[moduleLabelString] = &loadCacheEntry{globals, err}\n\treturn globals, err\n}", "func LoadWorkerByName(ctx context.Context, db gorp.SqlExecutor, workerName string) (*sdk.Worker, error) {\n\tvar work dbWorker\n\tquery := gorpmapping.NewQuery(`SELECT * FROM worker WHERE name = $1`).Args(workerName)\n\tfound, err := gorpmapping.Get(ctx, db, query, &work)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif !found {\n\t\treturn nil, sdk.WithStack(sdk.ErrNotFound)\n\t}\n\tisValid, err := gorpmapping.CheckSignature(work, work.Signature)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif !isValid {\n\t\treturn nil, sdk.WithStack(sdk.ErrInvalidData)\n\t}\n\treturn &work.Worker, err\n}", "func (js JavaScriptHandler) Load(name string, code []string) {\n\t// Create a unique function name called the same as the object macro name.\n\tjs.functions[name] = fmt.Sprintf(`\n\t\tfunction object_%s(rs, args) {\n\t\t\t%s\n\t\t}\n\t`, name, strings.Join(code, \"\\n\"))\n\n\t// Run this code to load the function into the VM.\n\tjs.VM.RunString(js.functions[name])\n}", "func (m *ParentLabelDetails) SetName(value *string)() {\n err := m.GetBackingStore().Set(\"name\", value)\n if err != nil {\n panic(err)\n }\n}", "func (s *BasePlSqlParserListener) EnterRecord_name(ctx *Record_nameContext) {}", "func (s *BaselimboListener) EnterType_name(ctx *Type_nameContext) {}", "func (l *Lexer) readName() string {\n\tvar out bytes.Buffer\n\tout.WriteRune(l.char)\n\n\t// Read until a non-name character is found.\n\tfor l.isName(l.peek()) {\n\t\tl.advance()\n\t\tout.WriteRune(l.char)\n\t}\n\n\treturn out.String()\n}", "func (s *BasevhdlListener) EnterSlice_name_part(ctx *Slice_name_partContext) {}", "func (s *BasePlSqlParserListener) EnterObject_name(ctx *Object_nameContext) {}", "func (l *Loader) Name() string { return l.cfg.Name }", "func (s *BaseSyslParserListener) EnterPackage_name(ctx *Package_nameContext) {}", "func (s *BasePlSqlParserListener) EnterLink_name(ctx *Link_nameContext) {}", "func (s *BasePlSqlParserListener) EnterLob_segname(ctx *Lob_segnameContext) {}", "func (s *BasePlSqlParserListener) EnterRollback_segment_name(ctx *Rollback_segment_nameContext) {}", "func (st *SymTab) Enter(name ID) {\n\tst.scopes.push(name)\n}", "func (b *Bst) InsertName(name string, number string,address string) {\n b.InsertNameRec(b.root,name,number,address)\n}", "func (s *BasePlSqlParserListener) EnterSequence_name(ctx *Sequence_nameContext) {}", "func (c *Collection) LoadByName(name string) (Interface, bool) {\n\treturn loadProvisioner(c.byName, name)\n}", "func (e *HTMLApplet) Name(v string) *HTMLApplet {\n\te.a[\"name\"] = v\n\treturn e\n}", "func (s *BasePlSqlParserListener) EnterRoutine_name(ctx *Routine_nameContext) {}", "func (s *BaseSyslParserListener) EnterModel_name(ctx *Model_nameContext) {}", "func NewLuaObjectFromName(L *lua.State, path string) *LuaObject {\n Lookup(L, path, 0)\n return NewLuaObject(L, -1)\n}", "func (b *OGame) BeginNamed(name string) Prioritizable {\n\treturn b.WithPriority(taskRunner.Normal).BeginNamed(name)\n}", "func (s *BaseSyslParserListener) EnterApp_name(ctx *App_nameContext) {}", "func GetDataLoadRef(name, namespace string) string {\n\treturn fmt.Sprintf(\"%s-%s\", namespace, name)\n}", "func (s *BasePlSqlParserListener) EnterException_name(ctx *Exception_nameContext) {}", "func (s *BasePlSqlParserListener) EnterType_name(ctx *Type_nameContext) {}", "func (n Name) RName() Name { return n }", "func Load(name string, data interface{}) error {\n\tp := jsonPath(name)\n\t// Don't load anything if the file doesn't exist\n\t_, err := os.Stat(p)\n\tif os.IsNotExist(err) {\n\t\tlog.Printf(\"File %s didn't exist, loading with fresh data\\n\", p)\n\t\treturn nil\n\t}\n\n\t// Read and unmarshal the json\n\tif b, err := ioutil.ReadFile(p); err != nil {\n\t\treturn err\n\t} else if len(b) == 0 {\n\t\tlog.Printf(\"File %s was empty, loading with fresh data\\n\", p)\n\t\treturn nil\n\t} else if err := json.Unmarshal(b, data); err != nil {\n\t\treturn fmt.Errorf(\"failed to load file %s error: %s\", p, err)\n\t}\n\n\tlog.Printf(\"Loaded %s\\n\", p)\n\treturn nil\n}", "func (s *scope) Insert(name string) Variable {\n\tl := len(s.levels)\n\tv, ok := s.levels[l-1].named[name]\n\tif ok {\n\t\treturn v\n\t}\n\tv = Variable(s.len())\n\ts.levels[l-1].named[name] = v\n\ts.maxLen++\n\treturn v\n}", "func (self templateEngine) loadTemplate(name string) (t string) {\n b, err := ioutil.ReadFile(self.templateFilepath(name))\n if err == nil {\n t = string(b)\n } else {\n log.Println(\"error loading template\", err)\n t = err.Error()\n }\n return\n}", "func (p *literalProcessor) name() string { return \"\" }", "func (s *BasePlSqlParserListener) EnterRole_name(ctx *Role_nameContext) {}", "func (t *Engine) LoadChain(name string) error {\n\treturn t.chainM.LoadChain(name)\n}", "func Tempname(nn *Node, t *Type)", "func load(thread *starlark.Thread, module string) (starlark.StringDict, error) {\n\tctx := GetContextImpl(thread)\n\tmoduleLabel, err := core.ParseLabel(ctx.Label().Workspace, ctx.Label().Package, module)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"%v: load of %v failed: invalid label: %v\", ctx.Label(),\n\t\t\tmodule, err)\n\t}\n\treturn ctx.build.load(ctx, moduleLabel)\n}", "func (s *BasePlSqlParserListener) EnterDb_name(ctx *Db_nameContext) {}", "func DecodeName(name [16]byte) (org, bucket platform.ID) {\n\torg = platform.ID(binary.BigEndian.Uint64(name[0:8]))\n\tbucket = platform.ID(binary.BigEndian.Uint64(name[8:16]))\n\treturn\n}", "func (loader *MapLoader) LoadTemplate(name string) (string, error) {\n\tif src, ok := (*loader)[name]; ok {\n\t\treturn src, nil\n\t}\n\treturn \"\", Errorf(\"Could not find template \" + name)\n}", "func (s *BasePlSqlParserListener) EnterPolicy_name(ctx *Policy_nameContext) {}", "func (self *LSHforest) Load(path string) error {\n\tb, err := ioutil.ReadFile(path)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn msgpack.Unmarshal(b, self)\n}", "func (s *BasePlSqlParserListener) EnterPackage_name(ctx *Package_nameContext) {}", "func Name(value string) *SimpleElement { return newSEString(\"name\", value) }", "func (s *BasePlSqlParserListener) EnterFunction_name(ctx *Function_nameContext) {}", "func (*unifinames) Name() string { return \"unifi-names\" }", "func (s *BasePlSqlParserListener) EnterProcedure_name(ctx *Procedure_nameContext) {}", "func LoadLabFromString(text string, lab *Lab) error {\n\treturn proto.UnmarshalText(text, lab)\n}", "func (instance *cache) GetName() string {\n\treturn instance.name.Load().(string)\n}", "func (s *BasePlSqlParserListener) EnterDatabase_name(ctx *Database_nameContext) {}", "func (g *Gear) LoaderName() template.JS {\n\treturn template.JS(g.loaderName)\n}", "func (b *Board) setPlayerName(color Color, name string) {\n\tb.players[color] = name\n}", "func newname(s *types.Sym) *Node {\n\tn := newnamel(lineno, s)\n\tn.Name.Curfn = Curfn\n\treturn n\n}", "func (s *BasePlSqlParserListener) EnterCollection_name(ctx *Collection_nameContext) {}", "func (p *Prefix) Load(_ string) (string, bool) { return p.Default(), true }" ]
[ "0.7251144", "0.6228718", "0.6056791", "0.59025365", "0.5862252", "0.58065605", "0.57765925", "0.57720697", "0.5706092", "0.5687984", "0.5686922", "0.5668654", "0.56624854", "0.56124383", "0.55617344", "0.548181", "0.53953135", "0.5366688", "0.5350478", "0.5284687", "0.526836", "0.52134365", "0.5156622", "0.51339144", "0.51239103", "0.5114372", "0.5112917", "0.51100194", "0.5102509", "0.509474", "0.50746536", "0.50727254", "0.50392777", "0.5024915", "0.5009271", "0.5009232", "0.5008986", "0.499848", "0.49864748", "0.4984268", "0.49826935", "0.49811676", "0.4976543", "0.49740803", "0.49718586", "0.4970366", "0.4967576", "0.49550968", "0.4952622", "0.49506715", "0.49469054", "0.49437603", "0.4942614", "0.49280632", "0.49238604", "0.49237624", "0.49152622", "0.4912393", "0.4904389", "0.4900442", "0.48848298", "0.48779503", "0.48775786", "0.4866345", "0.48620638", "0.48582217", "0.48524556", "0.4851653", "0.48332968", "0.4818832", "0.48187426", "0.48179284", "0.4798399", "0.4795971", "0.47939873", "0.47806364", "0.47795257", "0.47768223", "0.4775878", "0.47693178", "0.47647524", "0.4756018", "0.47554317", "0.47452706", "0.4742669", "0.4740399", "0.47171727", "0.4717151", "0.4713677", "0.4695823", "0.4693685", "0.468733", "0.46824455", "0.46821555", "0.4672561", "0.46690643", "0.46673727", "0.4660624", "0.4659231", "0.4658724" ]
0.6190922
2
specify a logical pixel operation for rendering
func LogicOp(opcode uint32) { C.glowLogicOp(gpLogicOp, (C.GLenum)(opcode)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DrawWithOp(screen, image *ebiten.Image, px, py int, op *ebiten.DrawImageOptions) {\n\tif op == nil {\n\t\top = &ebiten.DrawImageOptions{}\n\t}\n\top.GeoM.Translate(float64(px), float64(py))\n\tscreen.DrawImage(image, op)\n}", "func POR(mx, x operand.Op) { ctx.POR(mx, x) }", "func or(context *Context) {\n x := context.opcode & 0x0F00 >> 8\n y := context.opcode & 0x00F0 >> 4\n context.cpu.v[x] = context.cpu.v[x] | context.cpu.v[y]\n}", "func drawDot(img *image.RGBA, q, r int, valueX, valueY float64, m int) {\n \n var myRed, myGreen, myBlue uint8\n i := inMandelSet(valueX, valueY, m)\n\n if (i > (m/2)) && (i < (3*m/2)) {myGreen = uint8( i * 255 / m)}\n if (i > (m/3)) && (i < (m/2)) {myRed = uint8( i * 255 / m)}\n myBlue = uint8( i * 255 / m )\n\n img.Set(q, r, color.RGBA{myRed, myGreen, myBlue , 255})\n return\n}", "func ORPD(mx, x operand.Op) { ctx.ORPD(mx, x) }", "func VBLENDPD(i, mxy, xy, xy1 operand.Op) { ctx.VBLENDPD(i, mxy, xy, xy1) }", "func VPBLENDW(i, mxy, xy, xy1 operand.Op) { ctx.VPBLENDW(i, mxy, xy, xy1) }", "func (DrawTexture) IsDrawAction() {}", "func VPBLENDMD(ops ...operand.Op) { ctx.VPBLENDMD(ops...) }", "func PBLENDVB(x, mx, x1 operand.Op) { ctx.PBLENDVB(x, mx, x1) }", "func LogicOp(opcode uint32) {\n C.glowLogicOp(gpLogicOp, (C.GLenum)(opcode))\n}", "func PBLENDW(i, mx, x operand.Op) { ctx.PBLENDW(i, mx, x) }", "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 VPBLENDVB(xy, mxy, xy1, xy2 operand.Op) { ctx.VPBLENDVB(xy, mxy, xy1, xy2) }", "func VPXOR(mxy, xy, xy1 operand.Op) { ctx.VPXOR(mxy, xy, xy1) }", "func (self *Graphics) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func ORW(imr, amr operand.Op) { ctx.ORW(imr, amr) }", "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 drw(context *Context) {\n x := context.opcode & 0x0F00 >> 8\n y := context.opcode & 0x00F0 >> 4\n n := context.opcode & 0x000F\n vx, vy := int(context.cpu.v[x]), int(context.cpu.v[y])\n\n sprite := context.memory[context.cpu.i:context.cpu.i + n]\n\n // Xor screen with sprite\n // Clear VF and set to 1 if there is any pixel collision\n context.cpu.v[0xF] = 0\n for j := 0; j < len(sprite); j++ {\n for i := 0; i < 8; i++ {\n shift := uint(8 - i - 1)\n pixel := context.screen[(vx + i) % 64][(vy + j) % 32] ^ (sprite[j] >> shift) & 0x1\n context.screen[(vx + i) % 64][(vy + j) % 32] = pixel\n context.cpu.v[0xF] |= pixel\n }\n }\n\n if context.cpu.v[0xF] > 0 {\n context.window.Draw(&context.screen)\n }\n context.cpu.pc += 2\n}", "func VPBLENDD(i, mxy, xy, xy1 operand.Op) { ctx.VPBLENDD(i, mxy, xy, xy1) }", "func BLENDPD(i, mx, x operand.Op) { ctx.BLENDPD(i, mx, x) }", "func VPBLENDMD_BCST(ops ...operand.Op) { ctx.VPBLENDMD_BCST(ops...) }", "func Draw(screen, image *ebiten.Image, px, py int) {\n\tDrawWithOp(screen, image, px, py, nil)\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 VPBLENDMW(ops ...operand.Op) { ctx.VPBLENDMW(ops...) }", "func (op Op) Draw(dst Image, r image.Rectangle, src image.Image, sp image.Point) {\n\tDrawMask(dst, r, src, sp, nil, image.Point{}, op)\n}", "func (dst *Image) BytesOp(pt image.Point, src *Image, sp image.Point, f *Font, b []byte, op Op) image.Point {\n\tdst.Display.mu.Lock()\n\tdefer dst.Display.mu.Unlock()\n\treturn _string(dst, pt, src, sp, f, \"\", b, nil, dst.Clipr, nil, image.ZP, op)\n}", "func VBLENDMPD(ops ...operand.Op) { ctx.VBLENDMPD(ops...) }", "func VPBLENDMB(ops ...operand.Op) { ctx.VPBLENDMB(ops...) }", "func (win *window) Pixel(pt image.Point) {\n\txwin.PolyPoint(xgb.CoordModeOrigin, win.id, win.gc, []xgb.Point{xgb.Point{int16(pt.X), int16(pt.Y)}})\n}", "func planLogicalProjectionOp(\n\tctx context.Context,\n\tevalCtx *tree.EvalContext,\n\texpr tree.TypedExpr,\n\tcolumnTypes []*types.T,\n\tinput colexecop.Operator,\n\tacc *mon.BoundAccount,\n\tfactory coldata.ColumnFactory,\n) (op colexecop.Operator, resultIdx int, typs []*types.T, err error) {\n\t// Add a new boolean column that will store the result of the projection.\n\tresultIdx = len(columnTypes)\n\ttyps = appendOneType(columnTypes, types.Bool)\n\tvar (\n\t\ttypedLeft, typedRight tree.TypedExpr\n\t\tleftProjOpChain, rightProjOpChain colexecop.Operator\n\t\tleftIdx, rightIdx int\n\t)\n\tleftFeedOp := colexecop.NewFeedOperator()\n\trightFeedOp := colexecop.NewFeedOperator()\n\tswitch t := expr.(type) {\n\tcase *tree.AndExpr:\n\t\ttypedLeft = t.TypedLeft()\n\t\ttypedRight = t.TypedRight()\n\tcase *tree.OrExpr:\n\t\ttypedLeft = t.TypedLeft()\n\t\ttypedRight = t.TypedRight()\n\tdefault:\n\t\tcolexecerror.InternalError(errors.AssertionFailedf(\"unexpected logical expression type %s\", t.String()))\n\t}\n\tleftProjOpChain, leftIdx, typs, err = planProjectionOperators(\n\t\tctx, evalCtx, typedLeft, typs, leftFeedOp, acc, factory,\n\t)\n\tif err != nil {\n\t\treturn nil, resultIdx, typs, err\n\t}\n\trightProjOpChain, rightIdx, typs, err = planProjectionOperators(\n\t\tctx, evalCtx, typedRight, typs, rightFeedOp, acc, factory,\n\t)\n\tif err != nil {\n\t\treturn nil, resultIdx, typs, err\n\t}\n\tallocator := colmem.NewAllocator(ctx, acc, factory)\n\tinput = colexecutils.NewBatchSchemaSubsetEnforcer(allocator, input, typs, resultIdx, len(typs))\n\tswitch expr.(type) {\n\tcase *tree.AndExpr:\n\t\top, err = colexec.NewAndProjOp(\n\t\t\tallocator,\n\t\t\tinput, leftProjOpChain, rightProjOpChain,\n\t\t\tleftFeedOp, rightFeedOp,\n\t\t\ttyps[leftIdx], typs[rightIdx],\n\t\t\tleftIdx, rightIdx, resultIdx,\n\t\t)\n\tcase *tree.OrExpr:\n\t\top, err = colexec.NewOrProjOp(\n\t\t\tallocator,\n\t\t\tinput, leftProjOpChain, rightProjOpChain,\n\t\t\tleftFeedOp, rightFeedOp,\n\t\t\ttyps[leftIdx], typs[rightIdx],\n\t\t\tleftIdx, rightIdx, resultIdx,\n\t\t)\n\t}\n\treturn op, resultIdx, typs, err\n}", "func drawWithCache(ops *op.Ops) {\n\t// Save the operations in an independent ops value (the cache).\n\tcache := new(op.Ops)\n\tmacro := op.Record(cache)\n\n\tcl := clip.Rect{Max: image.Pt(100, 100)}.Push(cache)\n\tpaint.ColorOp{Color: color.NRGBA{G: 0x80, A: 0xFF}}.Add(cache)\n\tpaint.PaintOp{}.Add(cache)\n\tcl.Pop()\n\tcall := macro.Stop()\n\n\t// Draw the operations from the cache.\n\tcall.Add(ops)\n}", "func (me TxsdFeBlendTypeMode) IsMultiply() bool { return me.String() == \"multiply\" }", "func bitOpOnMem(a []uint32, b, c, d uint32) {\n\t// amd64:`ANDL\\s[$]200,\\s\\([A-Z][A-Z0-9]+\\)`\n\ta[0] &= 200\n\t// amd64:`ORL\\s[$]220,\\s4\\([A-Z][A-Z0-9]+\\)`\n\ta[1] |= 220\n\t// amd64:`XORL\\s[$]240,\\s8\\([A-Z][A-Z0-9]+\\)`\n\ta[2] ^= 240\n}", "func (self *TileSprite) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func VPBLENDMQ(ops ...operand.Op) { ctx.VPBLENDMQ(ops...) }", "func Plot(x, y, color, mode gb.UINT8) {}", "func VBLENDVPD(xy, mxy, xy1, xy2 operand.Op) { ctx.VBLENDVPD(xy, mxy, xy1, xy2) }", "func and(context *Context) {\n x := context.opcode & 0x0F00 >> 8\n y := context.opcode & 0x00F0 >> 4\n context.cpu.v[x] = context.cpu.v[x] & context.cpu.v[y]\n}", "func VPOR(mxy, xy, xy1 operand.Op) { ctx.VPOR(mxy, xy, xy1) }", "func ORPS(mx, x operand.Op) { ctx.ORPS(mx, x) }", "func (bm BitMap) BitOp(ctx context.Context, op BitMapOp, destination string, keys ...string) (int64, error) {\n\tif op != AndOp && op != OrOp && op != XorOp && op != NotOp {\n\t\treturn 0, fmt.Errorf(\"unknown BitMap operation: %s\", op)\n\t}\n\tif op == NotOp && len(keys) != 1 {\n\t\treturn 0, errors.New(\"BitMap Not operation works only with 1 key\")\n\t}\n\treq := newRequestSize(2+len(keys), \"\\r\\n$5\\r\\nBITOP\\r\\n$\")\n\treq.addStringAndStrings(string(op), append([]string{destination}, keys...))\n\treturn bm.c.cmdInt(ctx, req)\n}", "func ANDW(imr, amr operand.Op) { ctx.ANDW(imr, amr) }", "func (c ColorOrder) Pixel(r, g, b byte) Pixel {\n\treturn c.RawPixel(led.Gamma8(r), led.Gamma8(g), led.Gamma8(b))\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 MOVWLZX(mr, r operand.Op) { ctx.MOVWLZX(mr, r) }", "func VBLENDMPD_BCST(ops ...operand.Op) { ctx.VBLENDMPD_BCST(ops...) }", "func MOVBLSX(mr, r operand.Op) { ctx.MOVBLSX(mr, r) }", "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 NOTW(mr operand.Op) { ctx.NOTW(mr) }", "func (gpu *CHIP8GPU) draw_line8(x, y int8, line uint8) Registr {\n\tret := 0\n\tif y >= 32 {\n\t\ty -= 32\n\t}\n\tfor y < 0 {\n\t\ty += 32\n\t}\n\tfor i := 0; i < 8; i++ {\n\t\txp := x + int8(i)\n\t\tif xp >= 64 {\n\t\t\txp -= 64\n\t\t}\n\t\tfor xp < 0 {\n\t\t\txp += 64\n\t\t}\n\t\tnew_pix := (gpu.pic[xp][y] & 1) ^ ((line >> uint(7-i)) & 1)\n\t\tif gpu.pic[xp][y] == 1 && new_pix == 0 {\n\t\t\tret = 1\n\t\t}\n\t\tgpu.pic[xp][y] = new_pix\n\t}\n\treturn Registr(ret)\n}", "func (c ColorOrder) RawPixel(r, g, b byte) Pixel {\n\tswitch c {\n\tcase RGB:\n\t\treturn Pixel{[8]byte{\n\t\t\tzero &^ (r>>7&1 | r>>3&8 | r<<1&0x40),\n\t\t\tzero &^ (r>>4&1 | r>>0&8 | r<<4&0x40),\n\t\t\tzero &^ (r>>1&1 | r<<3&8 | g>>1&0x40),\n\t\t\tzero &^ (g>>6&1 | g>>2&8 | g<<2&0x40),\n\t\t\tzero &^ (g>>3&1 | g<<1&8 | g<<5&0x40),\n\t\t\tzero &^ (g>>0&1 | b>>4&8 | b>>0&0x40),\n\t\t\tzero &^ (b>>5&1 | b>>1&8 | b<<3&0x40),\n\t\t\tzero &^ (b>>2&1 | b<<2&8 | b<<6&0x40),\n\t\t}}\n\tcase GRB:\n\t\treturn Pixel{[8]byte{\n\t\t\tzero &^ (g>>7&1 | g>>3&8 | g<<1&0x40),\n\t\t\tzero &^ (g>>4&1 | g>>0&8 | g<<4&0x40),\n\t\t\tzero &^ (g>>1&1 | g<<3&8 | r>>1&0x40),\n\t\t\tzero &^ (r>>6&1 | r>>2&8 | r<<2&0x40),\n\t\t\tzero &^ (r>>3&1 | r<<1&8 | r<<5&0x40),\n\t\t\tzero &^ (r>>0&1 | b>>4&8 | b>>0&0x40),\n\t\t\tzero &^ (b>>5&1 | b>>1&8 | b<<3&0x40),\n\t\t\tzero &^ (b>>2&1 | b<<2&8 | b<<6&0x40),\n\t\t}}\n\t}\n\treturn Pixel{}\n}", "func (s *Screen) Draw(x int, y int, sprite []uint8) bool {\n\n\tsetFlag := false\n\t//for row, b := range sprite {\n\tfor spriteByteIndex := 0; spriteByteIndex < len(sprite); spriteByteIndex++ {\n\t\tb := sprite[spriteByteIndex]\t\n\t\tfor bitindex := 0; bitindex < 8; bitindex++ {\n\t\t\tif bits.GetBit8(b, uint8(bitindex)) {\n\t\t\t\t// if pixel is already set, unset it, set VF flag in CPU to 1\n\t\t\t\tif s.IsPixelSet(x + bitindex, spriteByteIndex + y) {\n\t\t\t\t\ts.UnsetPixel(x + bitindex, spriteByteIndex + y)\n\t\t\t\t\tsetFlag = true\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"setpixel :%d %#v\\n\", spriteByteIndex, sprite)\n\t\t\t\t\ts.SetPixel(x + bitindex, spriteByteIndex + y, bitindex, spriteByteIndex, x, y)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn setFlag\n}", "func (dst *Image) LineOp(p0, p1 Point, end0, end1 End, radius int, src *Image, sp Point, op Op) {\n\tdst.Display.mu.Lock()\n\tdefer dst.Display.mu.Unlock()\n\tdst.lineOp(p0, p1, end0, end1, radius, src, sp, op)\n}", "func MOVW(imr, mr operand.Op) { ctx.MOVW(imr, mr) }", "func (vm *VM) opOr(instr []uint16) int {\n\ta, b, c := vm.getAbc(instr)\n\n\tvm.registers[a] = b | c\n\treturn 4\n}", "func (d *baseDrawTarget) drawImage(dst, image *ebiten.Image, opt *ebiten.DrawImageOptions, mask core.DrawMask) {\n\tif (mask & d.mask) != d.mask {\n\t\treturn\n\t}\n\tif d.mset {\n\t\tif opt == nil {\n\t\t\topt = &ebiten.DrawImageOptions{}\n\t\t}\n\t\t// m := d.m\n\t\t// pm := opt.GeoM\n\t\t// m.Concat(pm)\n\t\t// opt.GeoM = m\n\t\t// _ = dst.DrawImage(image, opt)\n\t\t// opt.GeoM = pm\n\t\tm := opt.GeoM\n\t\tpm := opt.GeoM\n\t\tm.Concat(d.m)\n\t\t//TODO: check if offscreen\n\t\tx1, y1 := m.Element(0, 2), m.Element(1, 2) //m.Apply(0,0)\n\t\tw, h := image.Size()\n\t\tx2, y2 := m.Apply(float64(w), float64(h))\n\t\tdx, dy := math.Abs(x2-x1), math.Abs(y2-y1)\n\t\thh := math.Hypot(dx, dy)\n\t\tif !d.size.IsZero() && ((x1+hh < 0 || x1-hh > d.size.X) && (y1+hh < 0 || y1-hh > d.size.Y)) {\n\t\t\treturn\n\t\t}\n\t\topt.GeoM = m\n\t\t_ = dst.DrawImage(image, opt)\n\t\topt.GeoM = pm\n\t\treturn\n\t}\n\tif opt != nil {\n\t\tm := opt.GeoM\n\t\tx1, y1 := m.Element(0, 2), m.Element(1, 2) //m.Apply(0,0)\n\t\tw, h := image.Size()\n\t\tx2, y2 := m.Apply(float64(w), float64(h))\n\t\thh := math.Hypot(x2-x1, y2-y1)\n\t\tif !d.size.IsZero() && ((x1+hh < 0 || x1-hh > d.size.X) && (y1+hh < 0 || y1-hh > d.size.Y)) {\n\t\t\treturn\n\t\t}\n\t}\n\tdst.DrawImage(image, opt)\n}", "func VPBLENDMQ_BCST(ops ...operand.Op) { ctx.VPBLENDMQ_BCST(ops...) }", "func drawGraphics() {\n\tfmt.Printf(\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\")\n\t//y loop, 32 scan lines,x 64 pixels in each scan line\n\tfor y := 0; y < 32; y++ {\n\t\tfor x := 0; x < 64; x++ {\n\t\t\tif myChip8.Gfx[(y*64)+x] == 0 {\n\t\t\t\t//Black pixel\n\t\t\t\tfmt.Printf(\"x\")\n\t\t\t} else {\n\t\t\t\t// White pixel\n\t\t\t\tfmt.Printf(\"o\")\n\t\t\t}\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n\n}", "func VBLENDPS(i, mxy, xy, xy1 operand.Op) { ctx.VBLENDPS(i, mxy, xy, xy1) }", "func (b *Bitmap) PixelMode() int {\n\treturn int(b.handle.pixel_mode)\n}", "func NOTB(mr operand.Op) { ctx.NOTB(mr) }", "func (r *Ri) PixelFilter(filterfunc RtFilterFunc, xwidth, ywidth RtFloat) error {\n\treturn r.writef(\"PixelFilter\", filterfunc, xwidth, ywidth)\n}", "func StencilOp(fail uint32, zfail uint32, zpass uint32) {\n C.glowStencilOp(gpStencilOp, (C.GLenum)(fail), (C.GLenum)(zfail), (C.GLenum)(zpass))\n}", "func BLENDPS(i, mx, x operand.Op) { ctx.BLENDPS(i, mx, x) }", "func (s *Surface) SetCompositeOp(op CompositeOp) {\n\ts.Ctx.Set(\"globalCompositeOperation\", string(op))\n}", "func BitwiseOr(scope *Scope, x tf.Output, y tf.Output) (z tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"BitwiseOr\",\n\t\tInput: []tf.Input{\n\t\t\tx, y,\n\t\t},\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (c *CPU) Or_r(r Reg8) {\n\tget, _ := c.getReg8(r)\n\td8 := get()\n\tres := c.A | d8\n\n\t// FLAGS\n\t// z\n\tif res == 0 {\n\t\tc.setFlagZ(true)\n\t} else {\n\t\tc.setFlagZ(false)\n\t}\n\t// n = 0\n\tc.setFlagN(false)\n\t// h = 0\n\tc.setFlagH(false)\n\t// c = 0\n\tc.setFlagC(false)\n\n\tc.A = res\n}", "func (b *BaseElement) PixelHit(x int32, y int32) bool {\n\tif b.IsHidden() {\n\t\treturn false\n\t}\n\treturn b.Hit(x, y)\n}", "func (dst *Image) RunesOp(pt image.Point, src *Image, sp image.Point, f *Font, r []rune, op Op) image.Point {\n\tdst.Display.mu.Lock()\n\tdefer dst.Display.mu.Unlock()\n\treturn _string(dst, pt, src, sp, f, \"\", nil, r, dst.Clipr, nil, image.ZP, op)\n}", "func BLENDVPD(x, mx, x1 operand.Op) { ctx.BLENDVPD(x, mx, x1) }", "func INCL(mr operand.Op) { ctx.INCL(mr) }", "func Draw(dst Image, r image.Rectangle, src image.Image, sp image.Point, op Op) {\n\tDrawMask(dst, r, src, sp, nil, image.Point{}, op)\n}", "func (dst *Image) BorderOp(r image.Rectangle, n int, color *Image, sp image.Point, op Op) {\n\tif n < 0 {\n\t\tr = r.Inset(n)\n\t\tsp = sp.Add(image.Pt(n, n))\n\t\tn = -n\n\t}\n\tdst.Display.mu.Lock()\n\tdefer dst.Display.mu.Unlock()\n\tdraw(dst, image.Rect(r.Min.X, r.Min.Y, r.Max.X, r.Min.Y+n),\n\t\tcolor, sp, nil, sp, op)\n\tpt := image.Pt(sp.X, sp.Y+r.Dy()-n)\n\tdraw(dst, image.Rect(r.Min.X, r.Max.Y-n, r.Max.X, r.Max.Y),\n\t\tcolor, pt, nil, pt, op)\n\tpt = image.Pt(sp.X, sp.Y+n)\n\tdraw(dst, image.Rect(r.Min.X, r.Min.Y+n, r.Min.X+n, r.Max.Y-n),\n\t\tcolor, pt, nil, pt, op)\n\tpt = image.Pt(sp.X+r.Dx()-n, sp.Y+n)\n\tdraw(dst, image.Rect(r.Max.X-n, r.Min.Y+n, r.Max.X, r.Max.Y-n),\n\t\tcolor, pt, nil, pt, op)\n}", "func StencilOpSeparate(face uint32, sfail uint32, dpfail uint32, dppass uint32) {\n\tsyscall.Syscall6(gpStencilOpSeparate, 4, uintptr(face), uintptr(sfail), uintptr(dpfail), uintptr(dppass), 0, 0)\n}", "func StencilOp(fail uint32, zfail uint32, zpass uint32) {\n\tsyscall.Syscall(gpStencilOp, 3, uintptr(fail), uintptr(zfail), uintptr(zpass))\n}", "func ORL(imr, emr operand.Op) { ctx.ORL(imr, emr) }", "func (self *Graphics) IsMask() bool{\n return self.Object.Get(\"isMask\").Bool()\n}", "func SETMI(mr operand.Op) { ctx.SETMI(mr) }", "func (p *FloatGray) Opaque() bool {\n return true\n}", "func (rt *operatorRuntime) boolOp(op func(bool, bool) interface{},\n\tvs parser.Scope, is map[string]interface{}, tid uint64) (interface{}, error) {\n\n\tvar res interface{}\n\n\terrorutil.AssertTrue(len(rt.node.Children) == 2,\n\t\tfmt.Sprint(\"Operation requires 2 operands\", rt.node))\n\n\tres1, err := rt.node.Children[0].Runtime.Eval(vs, is, tid)\n\tif err == nil {\n\t\tvar res2 interface{}\n\n\t\tif res2, err = rt.node.Children[1].Runtime.Eval(vs, is, tid); err == nil {\n\n\t\t\tres1bool, ok := res1.(bool)\n\t\t\tif !ok {\n\t\t\t\treturn nil, rt.erp.NewRuntimeError(util.ErrNotABoolean,\n\t\t\t\t\trt.errorDetailString(rt.node.Children[0].Token, res1), rt.node.Children[0])\n\t\t\t}\n\n\t\t\tres2bool, ok := res2.(bool)\n\t\t\tif !ok {\n\t\t\t\treturn nil, rt.erp.NewRuntimeError(util.ErrNotABoolean,\n\t\t\t\t\trt.errorDetailString(rt.node.Children[1].Token, res2), rt.node.Children[0])\n\t\t\t}\n\n\t\t\tres = op(res1bool, res2bool)\n\t\t}\n\t}\n\n\treturn res, err\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 StencilOpSeparate(face uint32, sfail uint32, dpfail uint32, dppass uint32) {\n C.glowStencilOpSeparate(gpStencilOpSeparate, (C.GLenum)(face), (C.GLenum)(sfail), (C.GLenum)(dpfail), (C.GLenum)(dppass))\n}", "func ANDPD(mx, x operand.Op) { ctx.ANDPD(mx, x) }", "func (vm *VirtualMachine) handleLogicOp(quad quads.Quad) {\n\tleft, ok := vm.getValueForElement(quad.Left).(bool)\n\tif !ok {\n\t\tlog.Fatalf(\n\t\t\t\"Error: (handleLogicOp) couldn't cast %v to bool\",\n\t\t\tvm.getValueForElement(quad.Left),\n\t\t)\n\t}\n\tright, ok := vm.getValueForElement(quad.Right).(bool)\n\tif !ok {\n\t\tlog.Fatalf(\n\t\t\t\"Error: (handleLogicOp) couldn't cast %v to bool\",\n\t\t\tvm.getValueForElement(quad.Right),\n\t\t)\n\t}\n\n\tvar res bool\n\tswitch quad.Action {\n\tcase quads.AND:\n\t\tres = left && right\n\tcase quads.OR:\n\t\tres = left || right\n\t}\n\tmemblock := vm.getMemBlockForElement(quad.Result)\n\terr := memblock.Set(res, quad.Result.GetAddr())\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: (handleLogicOp) %s\", err)\n\t}\n}", "func MOVBLZX(mr, r operand.Op) { ctx.MOVBLZX(mr, r) }", "func (im FancyImage) SetDrawFun(pixelDraw func(int, int) RGBA) {\r\n\tim.PixelDraw = pixelDraw\r\n\t//im.Draw()\r\n\t/*\r\n\tfor y:=0; y < im.Y; y++ {\r\n\t\tfor x:= 0; x < im.X; x++ {\r\n\t\t\tv := pixelDraw(x, y)\t\t\t\t\t//pixel value: RGBA\r\n\t\t\ti := y*im.Stride + 4*x \t\t\t\t//pixel cell offset.\r\n\t\t\tim.Pixels[i] = v.R\r\n\t\t\tim.Pixels[i+1] = v.G\r\n\t\t\tim.Pixels[i+2] = v.B\r\n\t\t\tim.Pixels[i+3] = v.A\r\n\t\t}\r\n\t}\r\n\t*/\r\n}", "func (w *Weighted) Bit(offset Uint128, density uint64, scale uint64) uint64 {\n\tvar bit uint64\n\t// In order to be able to cache/reuse values, we want to grab a whole\n\t// set of 128 bits including a given offset, and use the same\n\t// calculation for all of them. So we mask out the low-order 7 bits\n\t// of offset, and use them separately. Meanwhile, Bits will\n\t// always right-shift its column bits by 7, which reduces the\n\t// space of possible results but means that it produces the same\n\t// set of bits for any given batch...\n\toffset.Lo, bit = offset.Lo&^127, offset.Lo&127\n\tif offset == w.lastOffset && density == w.lastDensity && scale == w.lastScale {\n\t\treturn w.lastValue.Bit(bit)\n\t}\n\tw.lastValue = w.Bits(offset, density, scale)\n\tw.lastOffset, w.lastDensity, w.lastScale = offset, density, scale\n\treturn w.lastValue.Bit(bit)\n}", "func (v *Bitmap256) Set(pos uint8) {\n\tv[pos>>6] |= 1 << (pos & 63)\n}", "func ORB(imr, amr operand.Op) { ctx.ORB(imr, amr) }", "func (native *OpenGL) PixelStorei(name uint32, param int32) {\n\tgl.PixelStorei(name, param)\n}", "func (p *FloatImage) Opaque() bool {\n\tif p.Rect.Empty() {\n\t\treturn true\n\t}\n\ti0, i1 := 3, p.Rect.Dx()*4\n\tfor y := p.Rect.Min.Y; y < p.Rect.Max.Y; y++ {\n\t\tfor i := i0; i < i1; i += 4 {\n\t\t\tif p.Pix[i] != 1 {\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}", "func (i *image) imageToDraw(bit img.Rectangle, rect img.Rectangle) img.Rectangle {\n\tcenter := i.center(bit)\n\tret := img.ZR\n\tret.Min.X, ret.Max.X = i.converMapCoord(rect.Min.X, center.X)\n\tret.Min.Y, ret.Max.Y = i.converMapCoord(rect.Min.Y, center.Y)\n\treturn ret\n}", "func (c *Chip8) ExecOp(opcode uint16) {\n\tswitch opcode {\n\tcase 0x00E0:\n\t\tc.Screen.ClearPixels()\n\t\tbreak\n\tcase 0x00EE:\n\t\tc.Memory.registers.pc = c.Memory.PopStack() + 2\n\t\tbreak\n\tdefault:\n\t\tc.ExecOpExtended(opcode)\n\t}\n}", "func (c *Context) ORPD(mx, x operand.Op) {\n\tc.addinstruction(x86.ORPD(mx, x))\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 VBLENDMPS(ops ...operand.Op) { ctx.VBLENDMPS(ops...) }", "func (me TunitsEnumType) IsPixels() bool { return me == \"pixels\" }", "func PMOVZXBW(mx, x operand.Op) { ctx.PMOVZXBW(mx, x) }" ]
[ "0.57050604", "0.55454075", "0.54799706", "0.54526716", "0.5449463", "0.5410092", "0.5382394", "0.53587544", "0.53446835", "0.5336605", "0.53325933", "0.52956736", "0.52867836", "0.52656794", "0.5261149", "0.5259228", "0.52474874", "0.5197664", "0.518285", "0.5174241", "0.5152828", "0.5144835", "0.5128606", "0.5071376", "0.50686246", "0.50670654", "0.5061421", "0.5050989", "0.5049179", "0.5047973", "0.50447506", "0.5027456", "0.5010653", "0.5009857", "0.49990848", "0.49930826", "0.4975106", "0.49685895", "0.49675354", "0.4958676", "0.4948106", "0.49424216", "0.4940429", "0.49396405", "0.49354756", "0.4931878", "0.49254733", "0.49239582", "0.49191135", "0.4919033", "0.4910603", "0.4902968", "0.48930132", "0.48834383", "0.48764881", "0.48680997", "0.48674867", "0.48574105", "0.48478368", "0.4838284", "0.48283446", "0.48244706", "0.4821857", "0.48127937", "0.4809807", "0.47896868", "0.4783543", "0.4782807", "0.47808048", "0.4770025", "0.47675017", "0.47668347", "0.47661904", "0.4764083", "0.47567242", "0.47549415", "0.47526985", "0.47483215", "0.47460297", "0.47458047", "0.47424468", "0.47390267", "0.47273934", "0.47271675", "0.47141314", "0.47089413", "0.47028267", "0.46927392", "0.46900964", "0.4686612", "0.4686356", "0.4683066", "0.46826038", "0.46817806", "0.46693012", "0.46679908", "0.4664107", "0.46612775", "0.4660372" ]
0.48724133
56
map all of a buffer object's data store into the client's address space
func MapBuffer(target uint32, access uint32) unsafe.Pointer { ret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access)) return (unsafe.Pointer)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func bufferToServerFdMap(buffer []byte) map[string]listenerFdMap {\n\tsfm := make(map[string]listenerFdMap)\n\tif len(buffer) > 0 {\n\t\tj, _ := gjson.LoadContent(buffer)\n\t\tfor k := range j.Var().Map() {\n\t\t\tm := make(map[string]string)\n\t\t\tfor k, v := range j.Get(k).Map() {\n\t\t\t\tm[k] = gconv.String(v)\n\t\t\t}\n\t\t\tsfm[k] = m\n\t\t}\n\t}\n\treturn sfm\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapBuffer, 2, uintptr(target), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\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 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 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 MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapNamedBuffer, 2, uintptr(buffer), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBufferBase, 3, uintptr(target), uintptr(index), uintptr(buffer))\n}", "func (node *Node) receive(ctx context.Context, buffer []byte, data interface{}) (address string, err error) {\n err = node.server.Listen()\n if err != nil {\n return\n }\n done := make(chan bool, 1)\n go func() {\n byteReceived, clientAddress, serverErr := node.server.Receive(ctx, buffer)\n if serverErr != nil {\n err = serverErr\n done <-true\n return\n }\n address = clientAddress\n err = json.Unmarshal(buffer[:byteReceived], &data)\n done <-true\n } ()\n select {\n case <-ctx.Done():\n err = ctx.Err()\n case <-done:\n }\n return\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 (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 (bw *BufWriter) Object(mp map[string]interface{}) {\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\tbw.stringBuf, bw.Error = Object(mp, bw.stringBuf[:0])\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\t_, bw.Error = bw.writer.Write(bw.stringBuf)\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 (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 (manager *Manager) ServerData(c net.Conn, buf []byte) {\n\tfor _, connectionManager := range manager.ConnectionManagers {\n\t\tconnectionManager.ServerData(c, buf)\n\t}\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 *Server) forwardCacheEvents() {\n for e := range s.listener.C {\n // TODO: socket.io eats serialization errors here - use this to debug until this issue is fixed\n /*_, err := json.Marshal(e)\n if err != nil {\n s.logger.Errorf(\"ENCODING ERROR: %s %v\", err, e)\n } */\n s.logger.Debugf(\"forwarding event of type %T (using key %T) to active clients\", e.Object, e.Key)\n s.io.BroadcastTo(\"ui\", \"cache\", e)\n }\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 (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 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 (s *Basememcached_protocolListener) EnterBytes(ctx *BytesContext) {}", "func BindBuffer(target uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBuffer, 2, uintptr(target), uintptr(buffer), 0)\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\n}", "func (n NoopTCPReactor) NetlocBytes(_ context.Context, _ []byte) {}", "func (_ BufferPtrPool4M) Put(b *[]byte) {\n\tPutBytesSlicePtr4M(b)\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\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 (c *HTTPCollector) createBuffer() []*zipkincore.Span {\n\treturn c.batchPool.Get().([]*zipkincore.Span)\n}", "func (_ BufferPtrPool2M) Put(b *[]byte) {\n\tPutBytesSlicePtr2M(b)\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func MapNamedBufferRange(buffer uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapNamedBufferRange, 4, uintptr(buffer), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBufferRange(target uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapBufferRange, 4, uintptr(target), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (m *Magic) Buffer(data []byte) (string, error) {\n\tif m.ptr == nil {\n\t\treturn \"\", ConnectionError\n\t}\n\n\tptr := unsafe.Pointer(&data)\n\tsz := C.size_t(len(data))\n\tcr := C.magic_buffer(m.ptr, ptr, sz)\n\n\tif cr == nil {\n\t\treturn \"\", m.check()\n\t}\n\n\tr := C.GoString(cr)\n\tC.free(unsafe.Pointer(cr))\n\treturn r, nil\n}", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\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 (res *ResponseAdapter) Buffer() *bytes.Buffer {\n\tres.bOnce.Do(func() {\n\t\tvar b bytes.Buffer\n\t\tif _, err := io.Copy(&b, res.Response().Body); err != nil {\n\t\t\tpanic(err) // xxx\n\t\t}\n\t\tres.bytes = b.Bytes()\n\t})\n\treturn bytes.NewBuffer(res.bytes)\n}", "func (b *Buffer) Data() []byte { return b.data }", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func hostSetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32)", "func NewDistributedObjectWithData() {}", "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 (d *pmac) processBuffer() {\n\txor(d.offset[:], d.l[bits.TrailingZeros(d.ctr+1)][:])\n\txor(d.buf[:], d.offset[:])\n\td.ctr++\n\n\td.buf.Encrypt(d.c)\n\txor(d.digest[:], d.buf[:])\n\td.pos = 0\n}", "func (dom *NetDomain) fanoutBuffer(buf []byte, sender *NetNode) {\n\tfor _, nn := range dom.Nodes {\n\t\tif nn == sender || nn.Conn == nil {\n\t\t\tcontinue\n\t\t}\n\t\tif rand.Float32() < dom.CfgDomain.Loss {\n\t\t\tif Verbose {\n\t\t\t\tlog.Println(\"Lost\", len(buf), \"bytes in delivery to\", nn.Name)\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\t\tgo dom.fanoutBufferToNode(buf, nn)\n\t}\n}", "func AddObjectToConnectionData(object GameObject, objectId string, sourceId int) {\n\tTrace.Println(\"Adding to client data\")\n\tclientData := clientIdMap[sourceId]\n\tclientData.GameObjects[objectId] = object\n}", "func MapBuffer(target gl.Enum, access gl.Enum) {\n\tgl.MapBuffer(gl.Enum(target), gl.Enum(access))\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 (_ BufferPtrPool16M) Put(b *[]byte) {\n\tPutBytesSlicePtr16M(b)\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 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 callCgoMmap(addr unsafe.Pointer, n uintptr, prot, flags, fd int32, off uint32) uintptr", "func (b *buffer) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func (c *poolConn) ReadUnsafeBuffer() error {\n\n\t//judge whether the buffer can be moved\n\tif c.buffer.index < c.buffer.size/2 {\n\t\treturn errors.New(\"The bytes need to move is too long!\")\n\t}\n\n\tj := 0\n\tfor i := c.buffer.index; i < c.buffer.size; i, j = i+1, j+1 {\n\t\tc.buffer.realBuffer[j] = c.buffer.realBuffer[i]\n\t}\n\tc.buffer.index = 0\n\treturn c.ReadTcpBlockLink(j)\n}", "func (w wireFormat) MapBySlice() {}", "func writeDataToClient(s *server, m shortMessageType) {\n\tSeqNum := s.clientMap[m.ConnID].writeSequenceMap\n\tmessage := NewData(m.ConnID, SeqNum, len(m.Payload), m.Payload)\n\tdatabuf, err := json.Marshal(message)\n\tif err != nil {\n\t\tfmt.Println(\"Error in Marshaling when writing: \", err)\n\t}\n\t// back up message for resending\n\ts.clientMap[m.ConnID].waitingForAckMessage[SeqNum] = &longMessageType{\n\t\tmessage: message,\n\t\tepochToSent: 0,\n\t\tcurInterval: 0,\n\t}\n\tif verbose {\n\t\tfmt.Printf(\" write to client:%v, seq:%v\\n\", m.ConnID, s.clientMap[m.ConnID].writeSequenceMap)\n\t}\n\ts.clientMap[m.ConnID].writeSequenceMap = s.clientMap[m.ConnID].writeSequenceMap + 1\n\ts.udpConn.WriteToUDP(databuf, s.clientMap[m.ConnID].clientAddressMap)\n}", "func (d PacketData) MergeBuffer(b *buffer.Buffer) {\n\td.pk.buf.Merge(b)\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 (render *Renderer_impl)Mmap( m *Mapped_resource, buf *Buffer, mm Map_mode) fundations.Result{\n\n}", "func (request *Request) Buffer() ([]byte, error) {\n\treturn json.Marshal(request)\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 convertData(data interface{}) []byte {\n\tbuffer, err := serial.Serialize(data, serial.PERSISTENT)\n\tif err != nil {\n\t\tlog.Fatal(\"Persistent Serialization Failed\", \"err\", err, \"data\", data)\n\t}\n\treturn buffer\n}", "func (c *Client) ExchangeBuffer(inbuf []byte, a string, outbuf []byte) (n int, err error) {\n\tw := new(reply)\n\tw.client = c\n\tw.addr = a\n\tif c.Hijacked == nil {\n\t\tif err = w.Dial(); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\tdefer w.Close()\n\t}\n\tif c.Hijacked != nil {\n\t\tw.conn = c.Hijacked\n\t}\n\tif n, err = w.writeClient(inbuf); err != nil {\n\t\treturn 0, err\n\t}\n\t//Why cant we set the buf here?? TODO(MG)\n\tif n, err = w.readClient(outbuf); err != nil {\n\t\treturn n, err\n\t}\n\treturn n, nil\n}", "func (_ BufferPtrPool32K) Put(b *[]byte) {\n\tPutBytesSlicePtr32K(b)\n}", "func (route *GrafanaNet) Dispatch(buf []byte) {\n\t// should return as quickly as possible\n\tlog.Tracef(\"route %s sending to dest %s: %s\", route.key, route.addrMetrics, buf)\n\tbuf = bytes.TrimSpace(buf)\n\tindex := bytes.Index(buf, []byte(\" \"))\n\tif index == -1 {\n\t\tlog.Error(\"RouteGrafanaNet: invalid message\")\n\t\treturn\n\t}\n\n\tkey := buf[:index]\n\thasher := fnv.New32a()\n\thasher.Write(key)\n\tshard := int(hasher.Sum32() % uint32(route.Cfg.Concurrency))\n\troute.dispatch(route.in[shard], buf, route.numBuffered, route.numDropBuffFull)\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 (r *MasterRouter) BindWorker(object *js.Object) {\n\tobject.Set(\"onmessage\", func(evt *js.Object) {\n\t\tdata := evt.Get(\"data\").Interface()\n\t\tfmt.Println(\"DATA\", data)\n\t})\n}", "func (e *Etcd) Buffer() *gbytes.Buffer {\n\treturn e.session.Buffer()\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 freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (r *PacketReadWriter) FeedBuffer(buf *bytes.Buffer) {\n\tr.bodyArena.PutBuffer(buf)\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 (a *ChannelArea) Buffer() []byte {\n\treturn a.buffer\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 (pk PacketBufferPtr) Data() PacketData {\n\treturn PacketData{pk: pk}\n}", "func PutBuffer(buf *bytes.Buffer) {\n\tbufPool.Put(buf)\n}", "func (d PacketData) ToBuffer() buffer.Buffer {\n\tbuf := d.pk.buf.Clone()\n\toffset := d.pk.dataOffset()\n\tbuf.TrimFront(int64(offset))\n\treturn buf\n}", "func proxyDataServer(data []byte) {\n\t_, err := serverConn.Write(data)\n\tif err != nil {\n\t\tpanic(fmt.Errorf(\"Error proxying data to server: %v\", err))\n\t}\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, s.SerializationConfig.BigEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\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 (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 BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func hostGetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32) int32", "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 (record) MarshalRecordsToBuffer(records []common.Record, buffer []byte) error {\n\tif len(records)*recordLength > len(buffer) {\n\t\treturn fmt.Errorf(\"buffer %d is not big enough for records %d\", len(buffer), len(records)*recordLength)\n\t}\n\n\tfor i, r := range records {\n\t\tbuff := buffer[i*recordLength : (i+1)*recordLength]\n\n\t\tif !validation.ValidTraceID(r.ID) { // todo: remove this check. maybe have a max id size of 128 bits?\n\t\t\treturn errors.New(\"ids must be 128 bit\")\n\t\t}\n\n\t\tmarshalRecord(r, buff)\n\t}\n\n\treturn nil\n}", "func init() {\n\taddr2Relay = make([]byte, len(relay2Addr))\n\tfor i, v := range relay2Addr {\n\t\taddr2Relay[v] = byte(i)\n\t}\n}", "func (c *AdapterMemory) Data(ctx context.Context) (map[interface{}]interface{}, error) {\n\treturn c.data.Data()\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func PutBuffer(buffer *bytes.Buffer) {\n\tif buffer == nil {\n\t\treturn\n\t}\n\n\tbuffer.Reset()\n\tdefaultPool.pool.Put(buffer)\n}", "func (vind *Varbinary) Map(_ VCursor, ids []interface{}) ([][]byte, error) {\n\tout := make([][]byte, 0, len(ids))\n\tfor _, id := range ids {\n\t\tdata, err := getVarbinaryHash(id)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"VarBinary_hash.Map :%v\", err)\n\t\t}\n\t\tout = append(out, data)\n\t}\n\treturn out, nil\n}", "func (t *Twemproxy) processPool(\n\tacc telegraf.Accumulator,\n\ttags map[string]string,\n\tdata map[string]interface{},\n) {\n\tserverTags := make(map[string]map[string]string)\n\n\tfields := make(map[string]interface{})\n\tfor key, value := range data {\n\t\tswitch key {\n\t\tcase \"client_connections\", \"forward_error\", \"client_err\", \"server_ejects\", \"fragments\", \"client_eof\":\n\t\t\tif val, ok := value.(float64); ok {\n\t\t\t\tfields[key] = val\n\t\t\t}\n\t\tdefault:\n\t\t\tif data, ok := value.(map[string]interface{}); ok {\n\t\t\t\tif _, ok := serverTags[key]; !ok {\n\t\t\t\t\tserverTags[key] = copyTags(tags)\n\t\t\t\t\tserverTags[key][\"server\"] = key\n\t\t\t\t}\n\t\t\t\tt.processServer(acc, serverTags[key], data)\n\t\t\t}\n\t\t}\n\t}\n\tacc.AddFields(\"twemproxy_pool\", fields, tags)\n}", "func (p *Packet) Buffer() []byte {\n\treturn p.Buf\n}", "func (_ BufferPtrPool2K) Put(b *[]byte) {\n\tPutBytesSlicePtr2K(b)\n}", "func client(ip string) error {\r\n\t// Some test data. Note how GOB even handles maps, slices, and\r\n\t// recursive data structures without problems.\r\n\ttestStruct := complexData{\r\n\t\tN: 23,\r\n\t\tS: \"string data\",\r\n\t\tM: map[string]int{\"one\": 1, \"two\": 2, \"three\": 3},\r\n\t\tP: []byte(\"abc\"),\r\n\t\tC: &complexData{\r\n\t\t\tN: 256,\r\n\t\t\tS: \"Recursive structs? Piece of cake!\",\r\n\t\t\tM: map[string]int{\"01\": 1, \"10\": 2, \"11\": 3},\r\n\t\t},\r\n\t}\r\n\r\n\t// Open a connection to the server.\r\n\trw, err := Open(ip + Port)\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Client: Failed to open connection to \"+ip+Port)\r\n\t}\r\n\r\n\t// Send a STRING request.\r\n\t// Send the request name.\r\n\t// Send the data.\r\n\tlog.Println(\"Send the string request.\")\r\n\tn, err := rw.WriteString(\"STRING\\n\")\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Could not send the STRING request (\"+strconv.Itoa(n)+\" bytes written)\")\r\n\t}\r\n\tn, err = rw.WriteString(\"Additional data.\\n\")\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Could not send additional STRING data (\"+strconv.Itoa(n)+\" bytes written)\")\r\n\t}\r\n\tlog.Println(\"Flush the buffer.\")\r\n\terr = rw.Flush()\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Flush failed.\")\r\n\t}\r\n\r\n\t// Read the reply.\r\n\tlog.Println(\"Read the reply.\")\r\n\tresponse, err := rw.ReadString('\\n')\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Client: Failed to read the reply: '\"+response+\"'\")\r\n\t}\r\n\r\n\tlog.Println(\"STRING request: got a response:\", response)\r\n\r\n\t// Send a GOB request.\r\n\t// Create an encoder that directly transmits to `rw`.\r\n\t// Send the request name.\r\n\t// Send the GOB.\r\n\tlog.Println(\"Send a struct as GOB:\")\r\n\tlog.Printf(\"Outer complexData struct: \\n%#v\\n\", testStruct)\r\n\tlog.Printf(\"Inner complexData struct: \\n%#v\\n\", testStruct.C)\r\n\tenc := gob.NewEncoder(rw)\r\n\tn, err = rw.WriteString(\"GOB\\n\")\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Could not write GOB data (\"+strconv.Itoa(n)+\" bytes written)\")\r\n\t}\r\n\terr = enc.Encode(testStruct)\r\n\tif err != nil {\r\n\t\treturn errors.Wrapf(err, \"Encode failed for struct: %#v\", testStruct)\r\n\t}\r\n\terr = rw.Flush()\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Flush failed.\")\r\n\t}\r\n\treturn nil\r\n}", "func (_ BufferPtrPool4K) Put(b *[]byte) {\n\tPutBytesSlicePtr4K(b)\n}", "func MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, !s.SerializationConfig.LittleEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\n}", "func (_ BufferPtrPool16K) Put(b *[]byte) {\n\tPutBytesSlicePtr16K(b)\n}" ]
[ "0.57664865", "0.5661419", "0.5514609", "0.54701847", "0.52631134", "0.524831", "0.5198386", "0.5182785", "0.5167284", "0.51593655", "0.51026326", "0.50672704", "0.5047997", "0.5034311", "0.503426", "0.5028048", "0.5018037", "0.5013234", "0.5011324", "0.49971262", "0.4964962", "0.4953962", "0.49518362", "0.4943579", "0.49359286", "0.49133956", "0.49040872", "0.489404", "0.48836967", "0.48772225", "0.4870842", "0.48634872", "0.4857098", "0.48551735", "0.48514092", "0.4834322", "0.48258257", "0.48211035", "0.48144257", "0.48001114", "0.47998103", "0.47950944", "0.47946945", "0.4789175", "0.47742096", "0.47723082", "0.47708806", "0.47666782", "0.47644088", "0.4761555", "0.47610733", "0.47334525", "0.47318465", "0.47247547", "0.47150165", "0.47122055", "0.4707771", "0.47007778", "0.46956405", "0.4692537", "0.46895105", "0.4688284", "0.46860132", "0.46846282", "0.46826494", "0.4676438", "0.46733764", "0.4672475", "0.46690863", "0.46684447", "0.4667886", "0.46642792", "0.46608704", "0.46592852", "0.46542388", "0.46520814", "0.46304905", "0.46268243", "0.4620189", "0.46142545", "0.46140563", "0.46135888", "0.46060443", "0.45940432", "0.45930797", "0.45930764", "0.45921302", "0.45908135", "0.4589784", "0.4589561", "0.45838118", "0.45806974", "0.45792195", "0.45780236", "0.4574256", "0.45714766", "0.45714766", "0.45560837", "0.45536447" ]
0.5118411
11
map all or part of a buffer object's data store into the client's address space
func MapBufferRange(target uint32, offset int, length int, access uint32) unsafe.Pointer { ret := C.glowMapBufferRange(gpMapBufferRange, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(length), (C.GLbitfield)(access)) return (unsafe.Pointer)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapBuffer, 2, uintptr(target), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func bufferToServerFdMap(buffer []byte) map[string]listenerFdMap {\n\tsfm := make(map[string]listenerFdMap)\n\tif len(buffer) > 0 {\n\t\tj, _ := gjson.LoadContent(buffer)\n\t\tfor k := range j.Var().Map() {\n\t\t\tm := make(map[string]string)\n\t\t\tfor k, v := range j.Get(k).Map() {\n\t\t\t\tm[k] = gconv.String(v)\n\t\t\t}\n\t\t\tsfm[k] = m\n\t\t}\n\t}\n\treturn sfm\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 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 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 MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapNamedBuffer, 2, uintptr(buffer), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBufferBase, 3, uintptr(target), uintptr(index), uintptr(buffer))\n}", "func (bw *BufWriter) Object(mp map[string]interface{}) {\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\tbw.stringBuf, bw.Error = Object(mp, bw.stringBuf[:0])\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\t_, bw.Error = bw.writer.Write(bw.stringBuf)\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 (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 (node *Node) receive(ctx context.Context, buffer []byte, data interface{}) (address string, err error) {\n err = node.server.Listen()\n if err != nil {\n return\n }\n done := make(chan bool, 1)\n go func() {\n byteReceived, clientAddress, serverErr := node.server.Receive(ctx, buffer)\n if serverErr != nil {\n err = serverErr\n done <-true\n return\n }\n address = clientAddress\n err = json.Unmarshal(buffer[:byteReceived], &data)\n done <-true\n } ()\n select {\n case <-ctx.Done():\n err = ctx.Err()\n case <-done:\n }\n return\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\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 (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 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 (m *Magic) Buffer(data []byte) (string, error) {\n\tif m.ptr == nil {\n\t\treturn \"\", ConnectionError\n\t}\n\n\tptr := unsafe.Pointer(&data)\n\tsz := C.size_t(len(data))\n\tcr := C.magic_buffer(m.ptr, ptr, sz)\n\n\tif cr == nil {\n\t\treturn \"\", m.check()\n\t}\n\n\tr := C.GoString(cr)\n\tC.free(unsafe.Pointer(cr))\n\treturn r, nil\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 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 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 MapNamedBufferRange(buffer uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapNamedBufferRange, 4, uintptr(buffer), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBufferRange(target uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapBufferRange, 4, uintptr(target), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (b *buffer) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBuffer, 2, uintptr(target), uintptr(buffer), 0)\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 (n NoopTCPReactor) NetlocBytes(_ context.Context, _ []byte) {}", "func (_ BufferPtrPool4M) Put(b *[]byte) {\n\tPutBytesSlicePtr4M(b)\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 (_ BufferPtrPool2M) Put(b *[]byte) {\n\tPutBytesSlicePtr2M(b)\n}", "func (s *Basememcached_protocolListener) EnterBytes(ctx *BytesContext) {}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\n}", "func (b *Buffer) Data() []byte { return b.data }", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\n}", "func (d *pmac) processBuffer() {\n\txor(d.offset[:], d.l[bits.TrailingZeros(d.ctr+1)][:])\n\txor(d.buf[:], d.offset[:])\n\td.ctr++\n\n\td.buf.Encrypt(d.c)\n\txor(d.digest[:], d.buf[:])\n\td.pos = 0\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\n}", "func (dom *NetDomain) fanoutBuffer(buf []byte, sender *NetNode) {\n\tfor _, nn := range dom.Nodes {\n\t\tif nn == sender || nn.Conn == nil {\n\t\t\tcontinue\n\t\t}\n\t\tif rand.Float32() < dom.CfgDomain.Loss {\n\t\t\tif Verbose {\n\t\t\t\tlog.Println(\"Lost\", len(buf), \"bytes in delivery to\", nn.Name)\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\t\tgo dom.fanoutBufferToNode(buf, nn)\n\t}\n}", "func (c *poolConn) ReadUnsafeBuffer() error {\n\n\t//judge whether the buffer can be moved\n\tif c.buffer.index < c.buffer.size/2 {\n\t\treturn errors.New(\"The bytes need to move is too long!\")\n\t}\n\n\tj := 0\n\tfor i := c.buffer.index; i < c.buffer.size; i, j = i+1, j+1 {\n\t\tc.buffer.realBuffer[j] = c.buffer.realBuffer[i]\n\t}\n\tc.buffer.index = 0\n\treturn c.ReadTcpBlockLink(j)\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\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 (res *ResponseAdapter) Buffer() *bytes.Buffer {\n\tres.bOnce.Do(func() {\n\t\tvar b bytes.Buffer\n\t\tif _, err := io.Copy(&b, res.Response().Body); err != nil {\n\t\t\tpanic(err) // xxx\n\t\t}\n\t\tres.bytes = b.Bytes()\n\t})\n\treturn bytes.NewBuffer(res.bytes)\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 (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 (_ BufferPtrPool16M) Put(b *[]byte) {\n\tPutBytesSlicePtr16M(b)\n}", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func (c *HTTPCollector) createBuffer() []*zipkincore.Span {\n\treturn c.batchPool.Get().([]*zipkincore.Span)\n}", "func (w wireFormat) MapBySlice() {}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func callCgoMmap(addr unsafe.Pointer, n uintptr, prot, flags, fd int32, off uint32) uintptr", "func hostSetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32)", "func BufferData(target Enum, src []byte, usage Enum) {\n\tgl.BufferData(uint32(target), int(len(src)), gl.Ptr(&src[0]), uint32(usage))\n}", "func (d PacketData) MergeBuffer(b *buffer.Buffer) {\n\td.pk.buf.Merge(b)\n}", "func MapBuffer(target gl.Enum, access gl.Enum) {\n\tgl.MapBuffer(gl.Enum(target), gl.Enum(access))\n}", "func (d PacketData) ToBuffer() buffer.Buffer {\n\tbuf := d.pk.buf.Clone()\n\toffset := d.pk.dataOffset()\n\tbuf.TrimFront(int64(offset))\n\treturn buf\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 (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 (manager *Manager) ServerData(c net.Conn, buf []byte) {\n\tfor _, connectionManager := range manager.ConnectionManagers {\n\t\tconnectionManager.ServerData(c, buf)\n\t}\n}", "func (route *GrafanaNet) Dispatch(buf []byte) {\n\t// should return as quickly as possible\n\tlog.Tracef(\"route %s sending to dest %s: %s\", route.key, route.addrMetrics, buf)\n\tbuf = bytes.TrimSpace(buf)\n\tindex := bytes.Index(buf, []byte(\" \"))\n\tif index == -1 {\n\t\tlog.Error(\"RouteGrafanaNet: invalid message\")\n\t\treturn\n\t}\n\n\tkey := buf[:index]\n\thasher := fnv.New32a()\n\thasher.Write(key)\n\tshard := int(hasher.Sum32() % uint32(route.Cfg.Concurrency))\n\troute.dispatch(route.in[shard], buf, route.numBuffered, route.numDropBuffFull)\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 (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 (a *ChannelArea) Buffer() []byte {\n\treturn a.buffer\n}", "func convertData(data interface{}) []byte {\n\tbuffer, err := serial.Serialize(data, serial.PERSISTENT)\n\tif err != nil {\n\t\tlog.Fatal(\"Persistent Serialization Failed\", \"err\", err, \"data\", data)\n\t}\n\treturn buffer\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, s.SerializationConfig.BigEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\n}", "func (_ BufferPtrPool32K) Put(b *[]byte) {\n\tPutBytesSlicePtr32K(b)\n}", "func (c *Client) ExchangeBuffer(inbuf []byte, a string, outbuf []byte) (n int, err error) {\n\tw := new(reply)\n\tw.client = c\n\tw.addr = a\n\tif c.Hijacked == nil {\n\t\tif err = w.Dial(); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\tdefer w.Close()\n\t}\n\tif c.Hijacked != nil {\n\t\tw.conn = c.Hijacked\n\t}\n\tif n, err = w.writeClient(inbuf); err != nil {\n\t\treturn 0, err\n\t}\n\t//Why cant we set the buf here?? TODO(MG)\n\tif n, err = w.readClient(outbuf); err != nil {\n\t\treturn n, err\n\t}\n\treturn n, nil\n}", "func (render *Renderer_impl)Mmap( m *Mapped_resource, buf *Buffer, mm Map_mode) fundations.Result{\n\n}", "func (r *PacketReadWriter) FeedBuffer(buf *bytes.Buffer) {\n\tr.bodyArena.PutBuffer(buf)\n}", "func (p *Packet) Buffer() []byte {\n\treturn p.Buf\n}", "func NewDistributedObjectWithData() {}", "func (request *Request) Buffer() ([]byte, error) {\n\treturn json.Marshal(request)\n}", "func PutBuffer(buf *bytes.Buffer) {\n\tbufPool.Put(buf)\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\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 (pk PacketBufferPtr) Data() PacketData {\n\treturn PacketData{pk: pk}\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, !s.SerializationConfig.LittleEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\n}", "func (p *Process) read(addr uintptr, ptr interface{}) error {\n\t// Reflection magic!\n\tv := reflect.ValueOf(ptr)\n\tdataAddr := getDataAddr(v)\n\tdataSize := getDataSize(v)\n\n\t// Open the file mapped process memory.\n\tmem, err := os.Open(fmt.Sprintf(\"/proc/%d/mem\", p.PID))\n\tdefer mem.Close()\n\tif err != nil {\n\t\treturn errors.New(fmt.Sprintf(\"Error opening /proc/%d/mem. Are you root?\", p.PID))\n\t}\n\n\t// Create a buffer and read data into it.\n\tdataBuf := make([]byte, dataSize)\n\tn, err := mem.ReadAt(dataBuf, int64(addr))\n\tif n != int(dataSize) {\n\t\treturn errors.New(fmt.Sprintf(\"Tried to read %d bytes, actually read %d bytes\\n\", dataSize, n))\n\t} else if err != nil {\n\t\treturn err\n\t}\n\n\t// Unsafely cast to []byte to copy data into.\n\tbuf := (*[]byte)(unsafe.Pointer(&reflect.SliceHeader{\n\t\tData: dataAddr,\n\t\tLen: int(dataSize),\n\t\tCap: int(dataSize),\n\t}))\n\tcopy(*buf, dataBuf)\n\treturn nil\n}", "func BindBufferRange(target uint32, index uint32, buffer uint32, offset int, size int) {\n\tsyscall.Syscall6(gpBindBufferRange, 5, uintptr(target), uintptr(index), uintptr(buffer), uintptr(offset), uintptr(size), 0)\n}", "func (_ BufferPtrPool2K) Put(b *[]byte) {\n\tPutBytesSlicePtr2K(b)\n}", "func (record) MarshalRecordsToBuffer(records []common.Record, buffer []byte) error {\n\tif len(records)*recordLength > len(buffer) {\n\t\treturn fmt.Errorf(\"buffer %d is not big enough for records %d\", len(buffer), len(records)*recordLength)\n\t}\n\n\tfor i, r := range records {\n\t\tbuff := buffer[i*recordLength : (i+1)*recordLength]\n\n\t\tif !validation.ValidTraceID(r.ID) { // todo: remove this check. maybe have a max id size of 128 bits?\n\t\t\treturn errors.New(\"ids must be 128 bit\")\n\t\t}\n\n\t\tmarshalRecord(r, buff)\n\t}\n\n\treturn nil\n}", "func (p *Process) write(addr uintptr, ptr interface{}) error {\n\t// Reflection magic!\n\tv := reflect.ValueOf(ptr)\n\tdataAddr := getDataAddr(v)\n\tdataSize := getDataSize(v)\n\n\t// Open the file mapped process memory.\n\tmem, err := os.OpenFile(fmt.Sprintf(\"/proc/%d/mem\", p.PID), os.O_WRONLY, 0666)\n\tdefer mem.Close()\n\tif err != nil {\n\t\treturn errors.New(fmt.Sprintf(\"Error opening /proc/%d/mem. Are you root?\", p.PID))\n\t}\n\n\t// Unsafe cast to []byte to copy data from.\n\tbuf := (*[]byte)(unsafe.Pointer(&reflect.SliceHeader{\n\t\tData: dataAddr,\n\t\tLen: int(dataSize),\n\t\tCap: int(dataSize),\n\t}))\n\n\t// Write the data from buf into memory.\n\tn, err := mem.WriteAt(*buf, int64(addr))\n\tif n != int(dataSize) {\n\t\treturn errors.New((fmt.Sprintf(\"Tried to write %d bytes, actually wrote %d bytes\\n\", dataSize, n)))\n\t} else if err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpNamedBufferSubData, 4, uintptr(buffer), uintptr(offset), uintptr(size), uintptr(data), 0, 0)\n}", "func (pk PacketBufferPtr) ToBuffer() buffer.Buffer {\n\tb := pk.buf.Clone()\n\tb.TrimFront(int64(pk.headerOffset()))\n\treturn b\n}", "func (_ BufferPtrPool1K) Put(b *[]byte) {\n\tPutBytesSlicePtr1K(b)\n}", "func BufferSubData(target Enum, offset int, data []byte) {\n\tgl.BufferSubData(uint32(target), offset, int(len(data)), gl.Ptr(&data[0]))\n}", "func (_ BufferPtrPool4K) Put(b *[]byte) {\n\tPutBytesSlicePtr4K(b)\n}", "func (s *Server) forwardCacheEvents() {\n for e := range s.listener.C {\n // TODO: socket.io eats serialization errors here - use this to debug until this issue is fixed\n /*_, err := json.Marshal(e)\n if err != nil {\n s.logger.Errorf(\"ENCODING ERROR: %s %v\", err, e)\n } */\n s.logger.Debugf(\"forwarding event of type %T (using key %T) to active clients\", e.Object, e.Key)\n s.io.BroadcastTo(\"ui\", \"cache\", e)\n }\n}", "func PutBuffer(buffer *bytes.Buffer) {\n\tif buffer == nil {\n\t\treturn\n\t}\n\n\tbuffer.Reset()\n\tdefaultPool.pool.Put(buffer)\n}", "func buffer(rd io.Reader) (buf []byte, endInd int, streamInd int, streamOffset int64, err error) {\n\n\t// process: # gen obj ... obj dict ... {stream ... data ... endstream} ... endobj\n\t// streamInd endInd\n\t// -1 if absent -1 if absent\n\n\t//log.Read.Println(\"buffer: begin\")\n\n\tendInd, streamInd = -1, -1\n\n\tfor endInd < 0 && streamInd < 0 {\n\n\t\tbuf, err = growBufBy(buf, defaultBufSize, rd)\n\t\tif err != nil {\n\t\t\treturn nil, 0, 0, 0, err\n\t\t}\n\n\t\tline := string(buf)\n\t\tendInd = strings.Index(line, \"endobj\")\n\t\tstreamInd = strings.Index(line, \"stream\")\n\n\t\tif endInd > 0 && (streamInd < 0 || streamInd > endInd) {\n\t\t\t// No stream marker in buf detected.\n\t\t\tbreak\n\t\t}\n\n\t\t// For very rare cases where \"stream\" also occurs within obj dict\n\t\t// we need to find the last \"stream\" marker before a possible end marker.\n\t\tfor streamInd > 0 && !keywordStreamRightAfterEndOfDict(line, streamInd) {\n\t\t\tlastStreamMarker(&streamInd, endInd, line)\n\t\t}\n\n\t\tlog.Read.Printf(\"buffer: endInd=%d streamInd=%d\\n\", endInd, streamInd)\n\n\t\tif streamInd > 0 {\n\n\t\t\t// streamOffset ... the offset where the actual stream data begins.\n\t\t\t// is right after the eol after \"stream\".\n\n\t\t\tslack := 10 // for optional whitespace + eol (max 2 chars)\n\t\t\tneed := streamInd + len(\"stream\") + slack\n\n\t\t\tif len(line) < need {\n\n\t\t\t\t// to prevent buffer overflow.\n\t\t\t\tbuf, err = growBufBy(buf, need-len(line), rd)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, 0, 0, 0, err\n\t\t\t\t}\n\n\t\t\t\tline = string(buf)\n\t\t\t}\n\n\t\t\tstreamOffset = int64(nextStreamOffset(line, streamInd))\n\t\t}\n\t}\n\n\t//log.Read.Printf(\"buffer: end, returned bufsize=%d streamOffset=%d\\n\", len(buf), streamOffset)\n\n\treturn buf, endInd, streamInd, streamOffset, nil\n}", "func (_ BufferPtrPool16K) Put(b *[]byte) {\n\tPutBytesSlicePtr16K(b)\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 (serv *Server) handleBin(conn int, payload []byte) {}", "func (e *Etcd) Buffer() *gbytes.Buffer {\n\treturn e.session.Buffer()\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 (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 MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}" ]
[ "0.5849063", "0.5783888", "0.5456638", "0.5427165", "0.54219437", "0.542004", "0.5306011", "0.52919215", "0.52801114", "0.52385104", "0.52342474", "0.5231961", "0.5231961", "0.5217588", "0.521568", "0.51853454", "0.51705945", "0.5169533", "0.51590395", "0.5147361", "0.51278377", "0.5120945", "0.51200885", "0.51113814", "0.510624", "0.5104344", "0.50780845", "0.5064756", "0.5036835", "0.50349474", "0.5032", "0.50309956", "0.5019617", "0.50131345", "0.5010998", "0.4995639", "0.49874768", "0.49812746", "0.49704382", "0.4969785", "0.4951074", "0.49496725", "0.4946186", "0.49286044", "0.49198094", "0.49036545", "0.48856643", "0.4880768", "0.48774582", "0.48672715", "0.48658478", "0.4861885", "0.48615637", "0.48590764", "0.4858189", "0.48581296", "0.48565266", "0.4848441", "0.48399782", "0.48348606", "0.48251984", "0.4822046", "0.48134664", "0.48033562", "0.47998294", "0.47973517", "0.4791661", "0.47896352", "0.4786103", "0.47834873", "0.4783025", "0.47729602", "0.47622532", "0.47547373", "0.47529477", "0.47528267", "0.472959", "0.4728452", "0.4727795", "0.47248933", "0.47225133", "0.47196487", "0.47079474", "0.47054243", "0.47045624", "0.46950096", "0.46934873", "0.46932986", "0.4692886", "0.4691792", "0.46860555", "0.46839768", "0.46831644", "0.46735796", "0.46604538", "0.4656638", "0.4656465", "0.46548662", "0.4652728", "0.4652728", "0.4644973" ]
0.0
-1
map all of a buffer object's data store into the client's address space
func MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer { ret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access)) return (unsafe.Pointer)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func bufferToServerFdMap(buffer []byte) map[string]listenerFdMap {\n\tsfm := make(map[string]listenerFdMap)\n\tif len(buffer) > 0 {\n\t\tj, _ := gjson.LoadContent(buffer)\n\t\tfor k := range j.Var().Map() {\n\t\t\tm := make(map[string]string)\n\t\t\tfor k, v := range j.Get(k).Map() {\n\t\t\t\tm[k] = gconv.String(v)\n\t\t\t}\n\t\t\tsfm[k] = m\n\t\t}\n\t}\n\treturn sfm\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapBuffer, 2, uintptr(target), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\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 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 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 MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapNamedBuffer, 2, uintptr(buffer), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBufferBase, 3, uintptr(target), uintptr(index), uintptr(buffer))\n}", "func (node *Node) receive(ctx context.Context, buffer []byte, data interface{}) (address string, err error) {\n err = node.server.Listen()\n if err != nil {\n return\n }\n done := make(chan bool, 1)\n go func() {\n byteReceived, clientAddress, serverErr := node.server.Receive(ctx, buffer)\n if serverErr != nil {\n err = serverErr\n done <-true\n return\n }\n address = clientAddress\n err = json.Unmarshal(buffer[:byteReceived], &data)\n done <-true\n } ()\n select {\n case <-ctx.Done():\n err = ctx.Err()\n case <-done:\n }\n return\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 (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 MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func (bw *BufWriter) Object(mp map[string]interface{}) {\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\tbw.stringBuf, bw.Error = Object(mp, bw.stringBuf[:0])\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\t_, bw.Error = bw.writer.Write(bw.stringBuf)\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 (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 (manager *Manager) ServerData(c net.Conn, buf []byte) {\n\tfor _, connectionManager := range manager.ConnectionManagers {\n\t\tconnectionManager.ServerData(c, buf)\n\t}\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 *Server) forwardCacheEvents() {\n for e := range s.listener.C {\n // TODO: socket.io eats serialization errors here - use this to debug until this issue is fixed\n /*_, err := json.Marshal(e)\n if err != nil {\n s.logger.Errorf(\"ENCODING ERROR: %s %v\", err, e)\n } */\n s.logger.Debugf(\"forwarding event of type %T (using key %T) to active clients\", e.Object, e.Key)\n s.io.BroadcastTo(\"ui\", \"cache\", e)\n }\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 (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 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 (s *Basememcached_protocolListener) EnterBytes(ctx *BytesContext) {}", "func BindBuffer(target uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBuffer, 2, uintptr(target), uintptr(buffer), 0)\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\n}", "func (n NoopTCPReactor) NetlocBytes(_ context.Context, _ []byte) {}", "func (_ BufferPtrPool4M) Put(b *[]byte) {\n\tPutBytesSlicePtr4M(b)\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\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 (c *HTTPCollector) createBuffer() []*zipkincore.Span {\n\treturn c.batchPool.Get().([]*zipkincore.Span)\n}", "func (_ BufferPtrPool2M) Put(b *[]byte) {\n\tPutBytesSlicePtr2M(b)\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func MapNamedBufferRange(buffer uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapNamedBufferRange, 4, uintptr(buffer), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBufferRange(target uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapBufferRange, 4, uintptr(target), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (m *Magic) Buffer(data []byte) (string, error) {\n\tif m.ptr == nil {\n\t\treturn \"\", ConnectionError\n\t}\n\n\tptr := unsafe.Pointer(&data)\n\tsz := C.size_t(len(data))\n\tcr := C.magic_buffer(m.ptr, ptr, sz)\n\n\tif cr == nil {\n\t\treturn \"\", m.check()\n\t}\n\n\tr := C.GoString(cr)\n\tC.free(unsafe.Pointer(cr))\n\treturn r, nil\n}", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\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 (res *ResponseAdapter) Buffer() *bytes.Buffer {\n\tres.bOnce.Do(func() {\n\t\tvar b bytes.Buffer\n\t\tif _, err := io.Copy(&b, res.Response().Body); err != nil {\n\t\t\tpanic(err) // xxx\n\t\t}\n\t\tres.bytes = b.Bytes()\n\t})\n\treturn bytes.NewBuffer(res.bytes)\n}", "func (b *Buffer) Data() []byte { return b.data }", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func hostSetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32)", "func NewDistributedObjectWithData() {}", "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 (d *pmac) processBuffer() {\n\txor(d.offset[:], d.l[bits.TrailingZeros(d.ctr+1)][:])\n\txor(d.buf[:], d.offset[:])\n\td.ctr++\n\n\td.buf.Encrypt(d.c)\n\txor(d.digest[:], d.buf[:])\n\td.pos = 0\n}", "func (dom *NetDomain) fanoutBuffer(buf []byte, sender *NetNode) {\n\tfor _, nn := range dom.Nodes {\n\t\tif nn == sender || nn.Conn == nil {\n\t\t\tcontinue\n\t\t}\n\t\tif rand.Float32() < dom.CfgDomain.Loss {\n\t\t\tif Verbose {\n\t\t\t\tlog.Println(\"Lost\", len(buf), \"bytes in delivery to\", nn.Name)\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\t\tgo dom.fanoutBufferToNode(buf, nn)\n\t}\n}", "func AddObjectToConnectionData(object GameObject, objectId string, sourceId int) {\n\tTrace.Println(\"Adding to client data\")\n\tclientData := clientIdMap[sourceId]\n\tclientData.GameObjects[objectId] = object\n}", "func MapBuffer(target gl.Enum, access gl.Enum) {\n\tgl.MapBuffer(gl.Enum(target), gl.Enum(access))\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 (_ BufferPtrPool16M) Put(b *[]byte) {\n\tPutBytesSlicePtr16M(b)\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 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 callCgoMmap(addr unsafe.Pointer, n uintptr, prot, flags, fd int32, off uint32) uintptr", "func (b *buffer) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func (c *poolConn) ReadUnsafeBuffer() error {\n\n\t//judge whether the buffer can be moved\n\tif c.buffer.index < c.buffer.size/2 {\n\t\treturn errors.New(\"The bytes need to move is too long!\")\n\t}\n\n\tj := 0\n\tfor i := c.buffer.index; i < c.buffer.size; i, j = i+1, j+1 {\n\t\tc.buffer.realBuffer[j] = c.buffer.realBuffer[i]\n\t}\n\tc.buffer.index = 0\n\treturn c.ReadTcpBlockLink(j)\n}", "func (w wireFormat) MapBySlice() {}", "func writeDataToClient(s *server, m shortMessageType) {\n\tSeqNum := s.clientMap[m.ConnID].writeSequenceMap\n\tmessage := NewData(m.ConnID, SeqNum, len(m.Payload), m.Payload)\n\tdatabuf, err := json.Marshal(message)\n\tif err != nil {\n\t\tfmt.Println(\"Error in Marshaling when writing: \", err)\n\t}\n\t// back up message for resending\n\ts.clientMap[m.ConnID].waitingForAckMessage[SeqNum] = &longMessageType{\n\t\tmessage: message,\n\t\tepochToSent: 0,\n\t\tcurInterval: 0,\n\t}\n\tif verbose {\n\t\tfmt.Printf(\" write to client:%v, seq:%v\\n\", m.ConnID, s.clientMap[m.ConnID].writeSequenceMap)\n\t}\n\ts.clientMap[m.ConnID].writeSequenceMap = s.clientMap[m.ConnID].writeSequenceMap + 1\n\ts.udpConn.WriteToUDP(databuf, s.clientMap[m.ConnID].clientAddressMap)\n}", "func (d PacketData) MergeBuffer(b *buffer.Buffer) {\n\td.pk.buf.Merge(b)\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 (render *Renderer_impl)Mmap( m *Mapped_resource, buf *Buffer, mm Map_mode) fundations.Result{\n\n}", "func (request *Request) Buffer() ([]byte, error) {\n\treturn json.Marshal(request)\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 convertData(data interface{}) []byte {\n\tbuffer, err := serial.Serialize(data, serial.PERSISTENT)\n\tif err != nil {\n\t\tlog.Fatal(\"Persistent Serialization Failed\", \"err\", err, \"data\", data)\n\t}\n\treturn buffer\n}", "func (c *Client) ExchangeBuffer(inbuf []byte, a string, outbuf []byte) (n int, err error) {\n\tw := new(reply)\n\tw.client = c\n\tw.addr = a\n\tif c.Hijacked == nil {\n\t\tif err = w.Dial(); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\tdefer w.Close()\n\t}\n\tif c.Hijacked != nil {\n\t\tw.conn = c.Hijacked\n\t}\n\tif n, err = w.writeClient(inbuf); err != nil {\n\t\treturn 0, err\n\t}\n\t//Why cant we set the buf here?? TODO(MG)\n\tif n, err = w.readClient(outbuf); err != nil {\n\t\treturn n, err\n\t}\n\treturn n, nil\n}", "func (_ BufferPtrPool32K) Put(b *[]byte) {\n\tPutBytesSlicePtr32K(b)\n}", "func (route *GrafanaNet) Dispatch(buf []byte) {\n\t// should return as quickly as possible\n\tlog.Tracef(\"route %s sending to dest %s: %s\", route.key, route.addrMetrics, buf)\n\tbuf = bytes.TrimSpace(buf)\n\tindex := bytes.Index(buf, []byte(\" \"))\n\tif index == -1 {\n\t\tlog.Error(\"RouteGrafanaNet: invalid message\")\n\t\treturn\n\t}\n\n\tkey := buf[:index]\n\thasher := fnv.New32a()\n\thasher.Write(key)\n\tshard := int(hasher.Sum32() % uint32(route.Cfg.Concurrency))\n\troute.dispatch(route.in[shard], buf, route.numBuffered, route.numDropBuffFull)\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 (r *MasterRouter) BindWorker(object *js.Object) {\n\tobject.Set(\"onmessage\", func(evt *js.Object) {\n\t\tdata := evt.Get(\"data\").Interface()\n\t\tfmt.Println(\"DATA\", data)\n\t})\n}", "func (e *Etcd) Buffer() *gbytes.Buffer {\n\treturn e.session.Buffer()\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 freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (r *PacketReadWriter) FeedBuffer(buf *bytes.Buffer) {\n\tr.bodyArena.PutBuffer(buf)\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 (a *ChannelArea) Buffer() []byte {\n\treturn a.buffer\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 (pk PacketBufferPtr) Data() PacketData {\n\treturn PacketData{pk: pk}\n}", "func PutBuffer(buf *bytes.Buffer) {\n\tbufPool.Put(buf)\n}", "func (d PacketData) ToBuffer() buffer.Buffer {\n\tbuf := d.pk.buf.Clone()\n\toffset := d.pk.dataOffset()\n\tbuf.TrimFront(int64(offset))\n\treturn buf\n}", "func proxyDataServer(data []byte) {\n\t_, err := serverConn.Write(data)\n\tif err != nil {\n\t\tpanic(fmt.Errorf(\"Error proxying data to server: %v\", err))\n\t}\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, s.SerializationConfig.BigEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\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 (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 BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func hostGetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32) int32", "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 (record) MarshalRecordsToBuffer(records []common.Record, buffer []byte) error {\n\tif len(records)*recordLength > len(buffer) {\n\t\treturn fmt.Errorf(\"buffer %d is not big enough for records %d\", len(buffer), len(records)*recordLength)\n\t}\n\n\tfor i, r := range records {\n\t\tbuff := buffer[i*recordLength : (i+1)*recordLength]\n\n\t\tif !validation.ValidTraceID(r.ID) { // todo: remove this check. maybe have a max id size of 128 bits?\n\t\t\treturn errors.New(\"ids must be 128 bit\")\n\t\t}\n\n\t\tmarshalRecord(r, buff)\n\t}\n\n\treturn nil\n}", "func init() {\n\taddr2Relay = make([]byte, len(relay2Addr))\n\tfor i, v := range relay2Addr {\n\t\taddr2Relay[v] = byte(i)\n\t}\n}", "func (c *AdapterMemory) Data(ctx context.Context) (map[interface{}]interface{}, error) {\n\treturn c.data.Data()\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func PutBuffer(buffer *bytes.Buffer) {\n\tif buffer == nil {\n\t\treturn\n\t}\n\n\tbuffer.Reset()\n\tdefaultPool.pool.Put(buffer)\n}", "func (vind *Varbinary) Map(_ VCursor, ids []interface{}) ([][]byte, error) {\n\tout := make([][]byte, 0, len(ids))\n\tfor _, id := range ids {\n\t\tdata, err := getVarbinaryHash(id)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"VarBinary_hash.Map :%v\", err)\n\t\t}\n\t\tout = append(out, data)\n\t}\n\treturn out, nil\n}", "func (t *Twemproxy) processPool(\n\tacc telegraf.Accumulator,\n\ttags map[string]string,\n\tdata map[string]interface{},\n) {\n\tserverTags := make(map[string]map[string]string)\n\n\tfields := make(map[string]interface{})\n\tfor key, value := range data {\n\t\tswitch key {\n\t\tcase \"client_connections\", \"forward_error\", \"client_err\", \"server_ejects\", \"fragments\", \"client_eof\":\n\t\t\tif val, ok := value.(float64); ok {\n\t\t\t\tfields[key] = val\n\t\t\t}\n\t\tdefault:\n\t\t\tif data, ok := value.(map[string]interface{}); ok {\n\t\t\t\tif _, ok := serverTags[key]; !ok {\n\t\t\t\t\tserverTags[key] = copyTags(tags)\n\t\t\t\t\tserverTags[key][\"server\"] = key\n\t\t\t\t}\n\t\t\t\tt.processServer(acc, serverTags[key], data)\n\t\t\t}\n\t\t}\n\t}\n\tacc.AddFields(\"twemproxy_pool\", fields, tags)\n}", "func (p *Packet) Buffer() []byte {\n\treturn p.Buf\n}", "func (_ BufferPtrPool2K) Put(b *[]byte) {\n\tPutBytesSlicePtr2K(b)\n}", "func client(ip string) error {\r\n\t// Some test data. Note how GOB even handles maps, slices, and\r\n\t// recursive data structures without problems.\r\n\ttestStruct := complexData{\r\n\t\tN: 23,\r\n\t\tS: \"string data\",\r\n\t\tM: map[string]int{\"one\": 1, \"two\": 2, \"three\": 3},\r\n\t\tP: []byte(\"abc\"),\r\n\t\tC: &complexData{\r\n\t\t\tN: 256,\r\n\t\t\tS: \"Recursive structs? Piece of cake!\",\r\n\t\t\tM: map[string]int{\"01\": 1, \"10\": 2, \"11\": 3},\r\n\t\t},\r\n\t}\r\n\r\n\t// Open a connection to the server.\r\n\trw, err := Open(ip + Port)\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Client: Failed to open connection to \"+ip+Port)\r\n\t}\r\n\r\n\t// Send a STRING request.\r\n\t// Send the request name.\r\n\t// Send the data.\r\n\tlog.Println(\"Send the string request.\")\r\n\tn, err := rw.WriteString(\"STRING\\n\")\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Could not send the STRING request (\"+strconv.Itoa(n)+\" bytes written)\")\r\n\t}\r\n\tn, err = rw.WriteString(\"Additional data.\\n\")\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Could not send additional STRING data (\"+strconv.Itoa(n)+\" bytes written)\")\r\n\t}\r\n\tlog.Println(\"Flush the buffer.\")\r\n\terr = rw.Flush()\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Flush failed.\")\r\n\t}\r\n\r\n\t// Read the reply.\r\n\tlog.Println(\"Read the reply.\")\r\n\tresponse, err := rw.ReadString('\\n')\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Client: Failed to read the reply: '\"+response+\"'\")\r\n\t}\r\n\r\n\tlog.Println(\"STRING request: got a response:\", response)\r\n\r\n\t// Send a GOB request.\r\n\t// Create an encoder that directly transmits to `rw`.\r\n\t// Send the request name.\r\n\t// Send the GOB.\r\n\tlog.Println(\"Send a struct as GOB:\")\r\n\tlog.Printf(\"Outer complexData struct: \\n%#v\\n\", testStruct)\r\n\tlog.Printf(\"Inner complexData struct: \\n%#v\\n\", testStruct.C)\r\n\tenc := gob.NewEncoder(rw)\r\n\tn, err = rw.WriteString(\"GOB\\n\")\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Could not write GOB data (\"+strconv.Itoa(n)+\" bytes written)\")\r\n\t}\r\n\terr = enc.Encode(testStruct)\r\n\tif err != nil {\r\n\t\treturn errors.Wrapf(err, \"Encode failed for struct: %#v\", testStruct)\r\n\t}\r\n\terr = rw.Flush()\r\n\tif err != nil {\r\n\t\treturn errors.Wrap(err, \"Flush failed.\")\r\n\t}\r\n\treturn nil\r\n}", "func (_ BufferPtrPool4K) Put(b *[]byte) {\n\tPutBytesSlicePtr4K(b)\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, !s.SerializationConfig.LittleEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\n}", "func (_ BufferPtrPool16K) Put(b *[]byte) {\n\tPutBytesSlicePtr16K(b)\n}" ]
[ "0.57664865", "0.5661419", "0.5514609", "0.54701847", "0.52631134", "0.524831", "0.5198386", "0.5182785", "0.5167284", "0.51593655", "0.5118411", "0.5118411", "0.51026326", "0.50672704", "0.5047997", "0.5034311", "0.503426", "0.5028048", "0.5018037", "0.5013234", "0.5011324", "0.49971262", "0.4964962", "0.4953962", "0.49518362", "0.4943579", "0.49359286", "0.49133956", "0.49040872", "0.489404", "0.48836967", "0.48772225", "0.4870842", "0.48634872", "0.4857098", "0.48551735", "0.48514092", "0.4834322", "0.48258257", "0.48211035", "0.48144257", "0.48001114", "0.47998103", "0.47950944", "0.47946945", "0.4789175", "0.47742096", "0.47723082", "0.47708806", "0.47666782", "0.47644088", "0.4761555", "0.47610733", "0.47334525", "0.47318465", "0.47247547", "0.47150165", "0.47122055", "0.4707771", "0.47007778", "0.46956405", "0.4692537", "0.46895105", "0.4688284", "0.46860132", "0.46846282", "0.46826494", "0.4676438", "0.46733764", "0.4672475", "0.46690863", "0.46684447", "0.4667886", "0.46642792", "0.46608704", "0.46592852", "0.46542388", "0.46520814", "0.46304905", "0.46268243", "0.4620189", "0.46142545", "0.46140563", "0.46135888", "0.46060443", "0.45940432", "0.45930797", "0.45930764", "0.45921302", "0.45908135", "0.4589784", "0.4589561", "0.45838118", "0.45806974", "0.45792195", "0.45780236", "0.4574256", "0.45560837", "0.45536447" ]
0.45714766
98
map all or part of a buffer object's data store into the client's address space
func MapNamedBufferRange(buffer uint32, offset int, length int, access uint32) unsafe.Pointer { ret := C.glowMapNamedBufferRange(gpMapNamedBufferRange, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length), (C.GLbitfield)(access)) return (unsafe.Pointer)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapBuffer, 2, uintptr(target), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func bufferToServerFdMap(buffer []byte) map[string]listenerFdMap {\n\tsfm := make(map[string]listenerFdMap)\n\tif len(buffer) > 0 {\n\t\tj, _ := gjson.LoadContent(buffer)\n\t\tfor k := range j.Var().Map() {\n\t\t\tm := make(map[string]string)\n\t\t\tfor k, v := range j.Get(k).Map() {\n\t\t\t\tm[k] = gconv.String(v)\n\t\t\t}\n\t\t\tsfm[k] = m\n\t\t}\n\t}\n\treturn sfm\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 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 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 MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpMapNamedBuffer, 2, uintptr(buffer), uintptr(access), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBufferBase, 3, uintptr(target), uintptr(index), uintptr(buffer))\n}", "func (bw *BufWriter) Object(mp map[string]interface{}) {\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\tbw.stringBuf, bw.Error = Object(mp, bw.stringBuf[:0])\n\tif bw.Error != nil {\n\t\treturn\n\t}\n\t_, bw.Error = bw.writer.Write(bw.stringBuf)\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 (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 (node *Node) receive(ctx context.Context, buffer []byte, data interface{}) (address string, err error) {\n err = node.server.Listen()\n if err != nil {\n return\n }\n done := make(chan bool, 1)\n go func() {\n byteReceived, clientAddress, serverErr := node.server.Receive(ctx, buffer)\n if serverErr != nil {\n err = serverErr\n done <-true\n return\n }\n address = clientAddress\n err = json.Unmarshal(buffer[:byteReceived], &data)\n done <-true\n } ()\n select {\n case <-ctx.Done():\n err = ctx.Err()\n case <-done:\n }\n return\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\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 (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 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 (m *Magic) Buffer(data []byte) (string, error) {\n\tif m.ptr == nil {\n\t\treturn \"\", ConnectionError\n\t}\n\n\tptr := unsafe.Pointer(&data)\n\tsz := C.size_t(len(data))\n\tcr := C.magic_buffer(m.ptr, ptr, sz)\n\n\tif cr == nil {\n\t\treturn \"\", m.check()\n\t}\n\n\tr := C.GoString(cr)\n\tC.free(unsafe.Pointer(cr))\n\treturn r, nil\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 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 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 MapNamedBufferRange(buffer uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapNamedBufferRange, 4, uintptr(buffer), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBufferRange(target uint32, offset int, length int, access uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpMapBufferRange, 4, uintptr(target), uintptr(offset), uintptr(length), uintptr(access), 0, 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (b *buffer) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBuffer, 2, uintptr(target), uintptr(buffer), 0)\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 (n NoopTCPReactor) NetlocBytes(_ context.Context, _ []byte) {}", "func (_ BufferPtrPool4M) Put(b *[]byte) {\n\tPutBytesSlicePtr4M(b)\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 (_ BufferPtrPool2M) Put(b *[]byte) {\n\tPutBytesSlicePtr2M(b)\n}", "func (s *Basememcached_protocolListener) EnterBytes(ctx *BytesContext) {}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\n}", "func (b *Buffer) Data() []byte { return b.data }", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\n}", "func (d *pmac) processBuffer() {\n\txor(d.offset[:], d.l[bits.TrailingZeros(d.ctr+1)][:])\n\txor(d.buf[:], d.offset[:])\n\td.ctr++\n\n\td.buf.Encrypt(d.c)\n\txor(d.digest[:], d.buf[:])\n\td.pos = 0\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\n}", "func (dom *NetDomain) fanoutBuffer(buf []byte, sender *NetNode) {\n\tfor _, nn := range dom.Nodes {\n\t\tif nn == sender || nn.Conn == nil {\n\t\t\tcontinue\n\t\t}\n\t\tif rand.Float32() < dom.CfgDomain.Loss {\n\t\t\tif Verbose {\n\t\t\t\tlog.Println(\"Lost\", len(buf), \"bytes in delivery to\", nn.Name)\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\t\tgo dom.fanoutBufferToNode(buf, nn)\n\t}\n}", "func (c *poolConn) ReadUnsafeBuffer() error {\n\n\t//judge whether the buffer can be moved\n\tif c.buffer.index < c.buffer.size/2 {\n\t\treturn errors.New(\"The bytes need to move is too long!\")\n\t}\n\n\tj := 0\n\tfor i := c.buffer.index; i < c.buffer.size; i, j = i+1, j+1 {\n\t\tc.buffer.realBuffer[j] = c.buffer.realBuffer[i]\n\t}\n\tc.buffer.index = 0\n\treturn c.ReadTcpBlockLink(j)\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\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 (res *ResponseAdapter) Buffer() *bytes.Buffer {\n\tres.bOnce.Do(func() {\n\t\tvar b bytes.Buffer\n\t\tif _, err := io.Copy(&b, res.Response().Body); err != nil {\n\t\t\tpanic(err) // xxx\n\t\t}\n\t\tres.bytes = b.Bytes()\n\t})\n\treturn bytes.NewBuffer(res.bytes)\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 (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 (_ BufferPtrPool16M) Put(b *[]byte) {\n\tPutBytesSlicePtr16M(b)\n}", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func (c *HTTPCollector) createBuffer() []*zipkincore.Span {\n\treturn c.batchPool.Get().([]*zipkincore.Span)\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func (w wireFormat) MapBySlice() {}", "func hostSetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32)", "func callCgoMmap(addr unsafe.Pointer, n uintptr, prot, flags, fd int32, off uint32) uintptr", "func BufferData(target Enum, src []byte, usage Enum) {\n\tgl.BufferData(uint32(target), int(len(src)), gl.Ptr(&src[0]), uint32(usage))\n}", "func (d PacketData) MergeBuffer(b *buffer.Buffer) {\n\td.pk.buf.Merge(b)\n}", "func MapBuffer(target gl.Enum, access gl.Enum) {\n\tgl.MapBuffer(gl.Enum(target), gl.Enum(access))\n}", "func (d PacketData) ToBuffer() buffer.Buffer {\n\tbuf := d.pk.buf.Clone()\n\toffset := d.pk.dataOffset()\n\tbuf.TrimFront(int64(offset))\n\treturn buf\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 (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 (manager *Manager) ServerData(c net.Conn, buf []byte) {\n\tfor _, connectionManager := range manager.ConnectionManagers {\n\t\tconnectionManager.ServerData(c, buf)\n\t}\n}", "func (route *GrafanaNet) Dispatch(buf []byte) {\n\t// should return as quickly as possible\n\tlog.Tracef(\"route %s sending to dest %s: %s\", route.key, route.addrMetrics, buf)\n\tbuf = bytes.TrimSpace(buf)\n\tindex := bytes.Index(buf, []byte(\" \"))\n\tif index == -1 {\n\t\tlog.Error(\"RouteGrafanaNet: invalid message\")\n\t\treturn\n\t}\n\n\tkey := buf[:index]\n\thasher := fnv.New32a()\n\thasher.Write(key)\n\tshard := int(hasher.Sum32() % uint32(route.Cfg.Concurrency))\n\troute.dispatch(route.in[shard], buf, route.numBuffered, route.numDropBuffFull)\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 (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 (a *ChannelArea) Buffer() []byte {\n\treturn a.buffer\n}", "func convertData(data interface{}) []byte {\n\tbuffer, err := serial.Serialize(data, serial.PERSISTENT)\n\tif err != nil {\n\t\tlog.Fatal(\"Persistent Serialization Failed\", \"err\", err, \"data\", data)\n\t}\n\treturn buffer\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, s.SerializationConfig.BigEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\n}", "func (_ BufferPtrPool32K) Put(b *[]byte) {\n\tPutBytesSlicePtr32K(b)\n}", "func (c *Client) ExchangeBuffer(inbuf []byte, a string, outbuf []byte) (n int, err error) {\n\tw := new(reply)\n\tw.client = c\n\tw.addr = a\n\tif c.Hijacked == nil {\n\t\tif err = w.Dial(); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\tdefer w.Close()\n\t}\n\tif c.Hijacked != nil {\n\t\tw.conn = c.Hijacked\n\t}\n\tif n, err = w.writeClient(inbuf); err != nil {\n\t\treturn 0, err\n\t}\n\t//Why cant we set the buf here?? TODO(MG)\n\tif n, err = w.readClient(outbuf); err != nil {\n\t\treturn n, err\n\t}\n\treturn n, nil\n}", "func (render *Renderer_impl)Mmap( m *Mapped_resource, buf *Buffer, mm Map_mode) fundations.Result{\n\n}", "func (p *Packet) Buffer() []byte {\n\treturn p.Buf\n}", "func (r *PacketReadWriter) FeedBuffer(buf *bytes.Buffer) {\n\tr.bodyArena.PutBuffer(buf)\n}", "func NewDistributedObjectWithData() {}", "func (request *Request) Buffer() ([]byte, error) {\n\treturn json.Marshal(request)\n}", "func PutBuffer(buf *bytes.Buffer) {\n\tbufPool.Put(buf)\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\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 (pk PacketBufferPtr) Data() PacketData {\n\treturn PacketData{pk: pk}\n}", "func (s *Service) ToData(object interface{}) (r *Data, err error) {\n\tdefer func() {\n\t\tif rec := recover(); rec != nil {\n\t\t\terr = makeError(rec)\n\t\t}\n\t}()\n\tif serData, ok := object.(*Data); ok {\n\t\treturn serData, nil\n\t}\n\t// initial size is kept minimal (head_data_offset + long_size), since it'll grow on demand\n\tdataOutput := NewPositionalObjectDataOutput(16, s, !s.SerializationConfig.LittleEndian)\n\tserializer, err := s.FindSerializerFor(object)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdataOutput.WriteInt32(0) // partition\n\tdataOutput.WriteInt32(serializer.ID())\n\tserializer.Write(dataOutput, object)\n\treturn &Data{dataOutput.buffer[:dataOutput.position]}, err\n}", "func (p *Process) read(addr uintptr, ptr interface{}) error {\n\t// Reflection magic!\n\tv := reflect.ValueOf(ptr)\n\tdataAddr := getDataAddr(v)\n\tdataSize := getDataSize(v)\n\n\t// Open the file mapped process memory.\n\tmem, err := os.Open(fmt.Sprintf(\"/proc/%d/mem\", p.PID))\n\tdefer mem.Close()\n\tif err != nil {\n\t\treturn errors.New(fmt.Sprintf(\"Error opening /proc/%d/mem. Are you root?\", p.PID))\n\t}\n\n\t// Create a buffer and read data into it.\n\tdataBuf := make([]byte, dataSize)\n\tn, err := mem.ReadAt(dataBuf, int64(addr))\n\tif n != int(dataSize) {\n\t\treturn errors.New(fmt.Sprintf(\"Tried to read %d bytes, actually read %d bytes\\n\", dataSize, n))\n\t} else if err != nil {\n\t\treturn err\n\t}\n\n\t// Unsafely cast to []byte to copy data into.\n\tbuf := (*[]byte)(unsafe.Pointer(&reflect.SliceHeader{\n\t\tData: dataAddr,\n\t\tLen: int(dataSize),\n\t\tCap: int(dataSize),\n\t}))\n\tcopy(*buf, dataBuf)\n\treturn nil\n}", "func BindBufferRange(target uint32, index uint32, buffer uint32, offset int, size int) {\n\tsyscall.Syscall6(gpBindBufferRange, 5, uintptr(target), uintptr(index), uintptr(buffer), uintptr(offset), uintptr(size), 0)\n}", "func (_ BufferPtrPool2K) Put(b *[]byte) {\n\tPutBytesSlicePtr2K(b)\n}", "func (record) MarshalRecordsToBuffer(records []common.Record, buffer []byte) error {\n\tif len(records)*recordLength > len(buffer) {\n\t\treturn fmt.Errorf(\"buffer %d is not big enough for records %d\", len(buffer), len(records)*recordLength)\n\t}\n\n\tfor i, r := range records {\n\t\tbuff := buffer[i*recordLength : (i+1)*recordLength]\n\n\t\tif !validation.ValidTraceID(r.ID) { // todo: remove this check. maybe have a max id size of 128 bits?\n\t\t\treturn errors.New(\"ids must be 128 bit\")\n\t\t}\n\n\t\tmarshalRecord(r, buff)\n\t}\n\n\treturn nil\n}", "func (p *Process) write(addr uintptr, ptr interface{}) error {\n\t// Reflection magic!\n\tv := reflect.ValueOf(ptr)\n\tdataAddr := getDataAddr(v)\n\tdataSize := getDataSize(v)\n\n\t// Open the file mapped process memory.\n\tmem, err := os.OpenFile(fmt.Sprintf(\"/proc/%d/mem\", p.PID), os.O_WRONLY, 0666)\n\tdefer mem.Close()\n\tif err != nil {\n\t\treturn errors.New(fmt.Sprintf(\"Error opening /proc/%d/mem. Are you root?\", p.PID))\n\t}\n\n\t// Unsafe cast to []byte to copy data from.\n\tbuf := (*[]byte)(unsafe.Pointer(&reflect.SliceHeader{\n\t\tData: dataAddr,\n\t\tLen: int(dataSize),\n\t\tCap: int(dataSize),\n\t}))\n\n\t// Write the data from buf into memory.\n\tn, err := mem.WriteAt(*buf, int64(addr))\n\tif n != int(dataSize) {\n\t\treturn errors.New((fmt.Sprintf(\"Tried to write %d bytes, actually wrote %d bytes\\n\", dataSize, n)))\n\t} else if err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpNamedBufferSubData, 4, uintptr(buffer), uintptr(offset), uintptr(size), uintptr(data), 0, 0)\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func (_ BufferPtrPool1K) Put(b *[]byte) {\n\tPutBytesSlicePtr1K(b)\n}", "func (pk PacketBufferPtr) ToBuffer() buffer.Buffer {\n\tb := pk.buf.Clone()\n\tb.TrimFront(int64(pk.headerOffset()))\n\treturn b\n}", "func BufferSubData(target Enum, offset int, data []byte) {\n\tgl.BufferSubData(uint32(target), offset, int(len(data)), gl.Ptr(&data[0]))\n}", "func (_ BufferPtrPool4K) Put(b *[]byte) {\n\tPutBytesSlicePtr4K(b)\n}", "func (s *Server) forwardCacheEvents() {\n for e := range s.listener.C {\n // TODO: socket.io eats serialization errors here - use this to debug until this issue is fixed\n /*_, err := json.Marshal(e)\n if err != nil {\n s.logger.Errorf(\"ENCODING ERROR: %s %v\", err, e)\n } */\n s.logger.Debugf(\"forwarding event of type %T (using key %T) to active clients\", e.Object, e.Key)\n s.io.BroadcastTo(\"ui\", \"cache\", e)\n }\n}", "func PutBuffer(buffer *bytes.Buffer) {\n\tif buffer == nil {\n\t\treturn\n\t}\n\n\tbuffer.Reset()\n\tdefaultPool.pool.Put(buffer)\n}", "func (_ BufferPtrPool16K) Put(b *[]byte) {\n\tPutBytesSlicePtr16K(b)\n}", "func buffer(rd io.Reader) (buf []byte, endInd int, streamInd int, streamOffset int64, err error) {\n\n\t// process: # gen obj ... obj dict ... {stream ... data ... endstream} ... endobj\n\t// streamInd endInd\n\t// -1 if absent -1 if absent\n\n\t//log.Read.Println(\"buffer: begin\")\n\n\tendInd, streamInd = -1, -1\n\n\tfor endInd < 0 && streamInd < 0 {\n\n\t\tbuf, err = growBufBy(buf, defaultBufSize, rd)\n\t\tif err != nil {\n\t\t\treturn nil, 0, 0, 0, err\n\t\t}\n\n\t\tline := string(buf)\n\t\tendInd = strings.Index(line, \"endobj\")\n\t\tstreamInd = strings.Index(line, \"stream\")\n\n\t\tif endInd > 0 && (streamInd < 0 || streamInd > endInd) {\n\t\t\t// No stream marker in buf detected.\n\t\t\tbreak\n\t\t}\n\n\t\t// For very rare cases where \"stream\" also occurs within obj dict\n\t\t// we need to find the last \"stream\" marker before a possible end marker.\n\t\tfor streamInd > 0 && !keywordStreamRightAfterEndOfDict(line, streamInd) {\n\t\t\tlastStreamMarker(&streamInd, endInd, line)\n\t\t}\n\n\t\tlog.Read.Printf(\"buffer: endInd=%d streamInd=%d\\n\", endInd, streamInd)\n\n\t\tif streamInd > 0 {\n\n\t\t\t// streamOffset ... the offset where the actual stream data begins.\n\t\t\t// is right after the eol after \"stream\".\n\n\t\t\tslack := 10 // for optional whitespace + eol (max 2 chars)\n\t\t\tneed := streamInd + len(\"stream\") + slack\n\n\t\t\tif len(line) < need {\n\n\t\t\t\t// to prevent buffer overflow.\n\t\t\t\tbuf, err = growBufBy(buf, need-len(line), rd)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, 0, 0, 0, err\n\t\t\t\t}\n\n\t\t\t\tline = string(buf)\n\t\t\t}\n\n\t\t\tstreamOffset = int64(nextStreamOffset(line, streamInd))\n\t\t}\n\t}\n\n\t//log.Read.Printf(\"buffer: end, returned bufsize=%d streamOffset=%d\\n\", len(buf), streamOffset)\n\n\treturn buf, endInd, streamInd, streamOffset, nil\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 (serv *Server) handleBin(conn int, payload []byte) {}", "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 (e *Etcd) Buffer() *gbytes.Buffer {\n\treturn e.session.Buffer()\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 MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapNamedBuffer(buffer uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapNamedBuffer(gpMapNamedBuffer, (C.GLuint)(buffer), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}" ]
[ "0.5847731", "0.5784149", "0.5456988", "0.5427234", "0.5421219", "0.5419336", "0.5306032", "0.5292907", "0.52789736", "0.5239789", "0.5234336", "0.5230619", "0.5230619", "0.5216465", "0.5215346", "0.51862043", "0.5170163", "0.5169575", "0.51600623", "0.514647", "0.5126175", "0.5118753", "0.51183563", "0.5110494", "0.51055133", "0.5104242", "0.5078162", "0.5065087", "0.5037369", "0.5036416", "0.5031002", "0.50295275", "0.5019875", "0.5013661", "0.501169", "0.49934292", "0.4988327", "0.4979431", "0.49700186", "0.49693695", "0.49503183", "0.49484664", "0.49475104", "0.4929627", "0.49205956", "0.49028265", "0.4884927", "0.48798501", "0.48756227", "0.48655564", "0.4864772", "0.4863454", "0.48608884", "0.48594186", "0.4857498", "0.48569435", "0.48559695", "0.48489395", "0.4840611", "0.4834866", "0.48241395", "0.48224646", "0.48129416", "0.48032668", "0.47999611", "0.4797819", "0.47922105", "0.47888187", "0.4784256", "0.47827333", "0.47813794", "0.47746205", "0.4761885", "0.47544646", "0.4752317", "0.47514546", "0.4730304", "0.47289157", "0.4727447", "0.47235394", "0.47233367", "0.47174653", "0.4708625", "0.47053403", "0.4704911", "0.46944147", "0.46943322", "0.46939102", "0.46932143", "0.4691263", "0.46853435", "0.4684111", "0.46825925", "0.4673804", "0.46607992", "0.46568736", "0.46564516", "0.4654543", "0.46522164", "0.46522164", "0.4644936" ]
0.0
-1
specify which matrix is the current matrix
func MatrixMode(mode uint32) { C.glowMatrixMode(gpMatrixMode, (C.GLenum)(mode)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func Matrix(index uint) uint {\n\tif index <= 1 {\n\t\treturn index\n\t}\n\n\tf := [2][2]uint{\n\t\t{1, 1},\n\t\t{1, 0},\n\t}\n\n\tf = matrixPower(f, index-1)\n\n\treturn f[0][0]\n}", "func (me TxsdFeColorMatrixTypeType) IsMatrix() bool { return me.String() == \"matrix\" }", "func (p *Proc) Matrix(a, b, c, d, e, f float64) {\n\tp.stk.matrix(f32.NewAffine2D(\n\t\tfloat32(a), float32(b), float32(c),\n\t\tfloat32(d), float32(e), float32(f),\n\t))\n}", "func MatrixMode(mode uint32) {\n C.glowMatrixMode(gpMatrixMode, (C.GLenum)(mode))\n}", "func (b *BoolMatrixLinear) SetMatrix(newmat []byte) {\n\tfor i, _ := range b.matrix {\n\t\tif (newmat[i/8]>>(7-(i%8)))&1 == 1 {\n\t\t\tb.matrix[i] = true\n\t\t} else {\n\t\t\tb.matrix[i] = false\n\t\t}\n\t}\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 (m *BoolMatrix) SetMatrix(newmat []byte) {\n\t//\tfor i := 0; i < len(newmat); i++ {\n\t//\t\tm.matrix[i] = newmat[i]\n\t//\t}\n\tm.matrix = newmat\n}", "func setCol(mat *DenseMatrix, which int, col []float64) *DenseMatrix {\n\tif mat.Rows() != len(col) {\n\t\tfmt.Println(\"The column to set needs to be the same dimension as the matrix\")\n\t}\n\t// iterate over rows to set the values for a selected columns\n\tfor i := 0; i < mat.Rows(); i++ {\n\t\tmat.Set(i, which, col[i])\n\t}\n\treturn mat\n}", "func (matrix Matrix4) Mult(other Matrix4) Matrix4 {\n\n\tnewMat := NewMatrix4()\n\n\tnewMat[0][0] = matrix[0][0]*other[0][0] + matrix[0][1]*other[1][0] + matrix[0][2]*other[2][0] + matrix[0][3]*other[3][0]\n\tnewMat[1][0] = matrix[1][0]*other[0][0] + matrix[1][1]*other[1][0] + matrix[1][2]*other[2][0] + matrix[1][3]*other[3][0]\n\tnewMat[2][0] = matrix[2][0]*other[0][0] + matrix[2][1]*other[1][0] + matrix[2][2]*other[2][0] + matrix[2][3]*other[3][0]\n\tnewMat[3][0] = matrix[3][0]*other[0][0] + matrix[3][1]*other[1][0] + matrix[3][2]*other[2][0] + matrix[3][3]*other[3][0]\n\n\tnewMat[0][1] = matrix[0][0]*other[0][1] + matrix[0][1]*other[1][1] + matrix[0][2]*other[2][1] + matrix[0][3]*other[3][1]\n\tnewMat[1][1] = matrix[1][0]*other[0][1] + matrix[1][1]*other[1][1] + matrix[1][2]*other[2][1] + matrix[1][3]*other[3][1]\n\tnewMat[2][1] = matrix[2][0]*other[0][1] + matrix[2][1]*other[1][1] + matrix[2][2]*other[2][1] + matrix[2][3]*other[3][1]\n\tnewMat[3][1] = matrix[3][0]*other[0][1] + matrix[3][1]*other[1][1] + matrix[3][2]*other[2][1] + matrix[3][3]*other[3][1]\n\n\tnewMat[0][2] = matrix[0][0]*other[0][2] + matrix[0][1]*other[1][2] + matrix[0][2]*other[2][2] + matrix[0][3]*other[3][2]\n\tnewMat[1][2] = matrix[1][0]*other[0][2] + matrix[1][1]*other[1][2] + matrix[1][2]*other[2][2] + matrix[1][3]*other[3][2]\n\tnewMat[2][2] = matrix[2][0]*other[0][2] + matrix[2][1]*other[1][2] + matrix[2][2]*other[2][2] + matrix[2][3]*other[3][2]\n\tnewMat[3][2] = matrix[3][0]*other[0][2] + matrix[3][1]*other[1][2] + matrix[3][2]*other[2][2] + matrix[3][3]*other[3][2]\n\n\tnewMat[0][3] = matrix[0][0]*other[0][3] + matrix[0][1]*other[1][3] + matrix[0][2]*other[2][3] + matrix[0][3]*other[3][3]\n\tnewMat[1][3] = matrix[1][0]*other[0][3] + matrix[1][1]*other[1][3] + matrix[1][2]*other[2][3] + matrix[1][3]*other[3][3]\n\tnewMat[2][3] = matrix[2][0]*other[0][3] + matrix[2][1]*other[1][3] + matrix[2][2]*other[2][3] + matrix[2][3]*other[3][3]\n\tnewMat[3][3] = matrix[3][0]*other[0][3] + matrix[3][1]*other[1][3] + matrix[3][2]*other[2][3] + matrix[3][3]*other[3][3]\n\n\treturn newMat\n\n}", "func (m *matrixComplex) Type() reflect.Kind { return m.matrixType }", "func setRow(mat *DenseMatrix, which int, row []float64) *DenseMatrix {\n\tif mat.Cols() != len(row) {\n\t\tfmt.Println(\"The row to set needs to be the same dimension as the matrix\")\n\t}\n\t// iterate over columns to set the values for a selected row\n\tfor i := 0; i < mat.Cols(); i++ {\n\t\tmat.Set(which, i, row[i])\n\t}\n\treturn mat\n}", "func initLocalMatrix(matrix [][]score, s1 string, s2 string) {\n\trows := len(matrix) + 1\n\tcols := len(matrix[0]) + 1\n\tmatrix[0][0].value = 0\n\n\tfor i := 1; i < cols-1; i++ {\n\t\tmatrix[0][i].value = 0\n\t\tmatrix[0][i].direction = left\n\t\tmatrix[0][i].topBase = string(s1[i-1])\n\t}\n\n\tfor j := 1; j < rows-1; j++ {\n\t\tmatrix[j][0].value = 0\n\t\tmatrix[j][0].direction = up\n\t\tmatrix[j][0].leftBase = string(s2[j-1])\n\t}\t\n}", "func initGlobalMatrix(matrix [][]score, gap int, s1 string, s2 string) {\n\trows := len(matrix) + 1\n\tcols := len(matrix[0]) + 1\n\tmatrix[0][0].value = 0\n\n\tfor i := 1; i < cols-1; i++ {\n\t\tmatrix[0][i].value = i * gap\n\t\tmatrix[0][i].direction = left\n\t\tmatrix[0][i].topBase = string(s1[i-1])\n\t}\n\n\tfor j := 1; j < rows-1; j++ {\n\t\tmatrix[j][0].value = j * gap\n\t\tmatrix[j][0].direction = up\n\t\tmatrix[j][0].leftBase = string(s2[j-1])\n\t}\t\n}", "func GetMatrixType(col, row uint8) BareType { return matrixTypes[col][row] }", "func (t *Transform) Matrix(a, b, c, d, e, f float64) {\n\tout := fmt.Sprintf(\"matrix(%g,%g,%g,%g,%g,%g)\", a, b, c, d, e, f)\n\n\tt.transforms = append(t.transforms, out)\n}", "func (vc *topViewViewController) OptimizeLinearMatrix(info *models.SettingInfo) (optMat []float64, deltaE []float64, deltaEAve float64) {\n\n\t// make info\n\t// --- illumination ---\n\tvar illumination models.IlluminationCode\n\tswitch info.LightSource {\n\tcase \"D65\":\n\t\tillumination = models.D65\n\tcase \"IllA\":\n\t\tillumination = models.IllA\n\tdefault:\n\t\tillumination = models.D65\n\t}\n\n\t// --- data path ---\n\tdirHandler := util.NewDirectoryHandler()\n\tdataPath := dirHandler.GetCurrentDirectoryPath() + \"/data/\"\n\n\t// --- ref color chart path ---\n\t//stdCCPath := dirHandler.GetCurrentDirectoryPath() + \"/data/\" + macbethColorCheckerFileName\n\tstdCCPath := dirHandler.GetCurrentDirectoryPath() + \"/data/\" + macbethColorChartCodeFileName\n\n\t// initialize optimizer\n\toptimizer := controllers.NewLinearMatrixOptimizer()\n\toptimizer.SetEnv(\n\t\tinfo.LinearMatrixDataPath,\n\t\tdataPath,\n\t\tinfo.DeiceQEDataPath,\n\t\tillumination,\n\t\tinfo.Gamma,\n\t)\n\toptimizer.SetRefColorCode(stdCCPath)\n\toptimizer.Run(make([]float64, 0), 2.0, 100, 1.0, 5)\n\n\toptLinearMat := optimizer.OptimizedLinearMatrix()\n\toptDeltaE, optDeltaEAve := optimizer.FinalDeltaEInfo()\n\n\treturn optLinearMat, optDeltaE, optDeltaEAve\n}", "func newMat(p C.Mat) Mat {\n\tm := Mat{p: p}\n\tMatProfile.Add(p, 1)\n\treturn m\n}", "func MatrixMode(mode uint32) {\n\tsyscall.Syscall(gpMatrixMode, 1, uintptr(mode), 0, 0)\n}", "func newMatrixFormulaArg(m [][]formulaArg) formulaArg {\n\treturn formulaArg{Type: ArgMatrix, Matrix: m}\n}", "func (ev *evaluator) matrixSelector(node *MatrixSelector) matrix {\n\tinterval := metric.Interval{\n\t\tOldestInclusive: ev.Timestamp.Add(-node.Range - node.Offset),\n\t\tNewestInclusive: ev.Timestamp.Add(-node.Offset),\n\t}\n\n\tsampleStreams := make([]*sampleStream, 0, len(node.iterators))\n\tfor _, it := range node.iterators {\n\t\tsamplePairs := it.RangeValues(interval)\n\t\tif len(samplePairs) == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\tif node.Offset != 0 {\n\t\t\tfor _, sp := range samplePairs {\n\t\t\t\tsp.Timestamp = sp.Timestamp.Add(node.Offset)\n\t\t\t}\n\t\t}\n\n\t\tsampleStream := &sampleStream{\n\t\t\tMetric: it.Metric(),\n\t\t\tValues: samplePairs,\n\t\t}\n\t\tsampleStreams = append(sampleStreams, sampleStream)\n\t}\n\treturn matrix(sampleStreams)\n}", "func matriz(dat *Datos) {\n\n\tdepartamentos := make([]string, len(dat.Seccion[0].Departamento))\n\n\tfor i := 0; i < len(dat.Seccion); i++ {\n\t\tindice[i] = dat.Seccion[i].Indice\n\t}\n\n\tfor i := 0; i < (len(departamentos) - 1); i++ {\n\t\tdepartamentos[i] = dat.Seccion[i].Departamento[i].Nombre\n\t}\n\n\tfmt.Println(\"Esta aqui\")\n\tfmt.Println(departamentos, indice)\n\n\t//Estableciendo tamaño al vector de la matriz linealizada\n\tLinealizacion = make([]ListaD, (len(dat.Seccion) * len(dat.Seccion) * len(dat.Seccion[0].Departamento) * 5))\n\n\t//uso de for por cada dimenasion de la matriz de datos\n\tfor i := 0; i < len(dat.Seccion); i++ {\n\t\tfor j := 0; j < len(dat.Seccion[i].Departamento); j++ {\n\t\t\tfor k := 0; k < len(dat.Seccion[i].Departamento[j].Tiendas); k++ {\n\t\t\t\t//Uso de formual de row-major para linealizacion de matriz\n\t\t\t\tLinealizacion[(i*len(dat.Seccion[i].Departamento)+j)*5+(dat.Seccion[i].Departamento[j].Tiendas[k].Calificacion-1)].agregarTienda(Tienda{Nombre: dat.Seccion[i].Departamento[j].Tiendas[k].Nombre, Descripcion: dat.Seccion[i].Departamento[j].Tiendas[k].Descripcion, Contacto: dat.Seccion[i].Departamento[j].Tiendas[k].Contacto, Calificacion: dat.Seccion[i].Departamento[j].Tiendas[k].Calificacion})\n\t\t\t}\n\t\t}\n\t}\n\n\t//Imprimir matriz linalizada\n\n\tfor i := 0; i < len(Linealizacion); i++ {\n\t\tfmt.Println(i)\n\t\tnodo := Linealizacion[i].inicio\n\t\tif nodo != nil {\n\t\t\tfmt.Println(nodo.tienda)\n\t\t}\n\n\t}\n}", "func (a *matrix) isSquareMatrix() bool {\n\treturn a.cols == a.rows\n}", "func getMatrix(matrix [][][]int) [][]int {\n\n\tvar new_matrix [][]int\n\n\tnew_matrix = make([][]int, len(matrix))\n\n\tfor i := range new_matrix {\n\t\tnew_matrix[i] = make([]int, len(matrix[0]))\n\t}\n\n\tfor i := 0; i < len(matrix); i++ {\n\t\tfor j := 0; j < len(matrix[0]); j++ {\n\t\t\tnew_matrix[i][j] = matrix[i][j][0]\n\t\t}\n\t}\n\n\treturn new_matrix\n}", "func (c *Canvas) SetMatrix(m pixel.Matrix) {\n\tfor i := range m {\n\t\tc.mat[i] = float32(m[i])\n\t}\n}", "func (m *Matrix) Line() {\n\tfmt.Print(m.LineColor)\n\tfmt.Print(m.getLine())\n\tfmt.Print(NONE)\n}", "func (p *planner) CurrentDatabase() string {\n\treturn p.SessionData().Database\n}", "func (m Mat2f) Index(row, col int) int {\n\treturn col*2 + row\n}", "func (m Matrix) Multiply(right Matrix) Matrix {\n\treturn Matrix{\n\t\tM0: m.M0*right.M0 + m.M1*right.M4 + m.M2*right.M8 + m.M3*right.M12,\n\t\tM1: m.M0*right.M1 + m.M1*right.M5 + m.M2*right.M9 + m.M3*right.M13,\n\t\tM2: m.M0*right.M2 + m.M1*right.M6 + m.M2*right.M10 + m.M3*right.M14,\n\t\tM3: m.M0*right.M3 + m.M1*right.M7 + m.M2*right.M11 + m.M3*right.M15,\n\t\tM4: m.M4*right.M0 + m.M5*right.M4 + m.M6*right.M8 + m.M7*right.M12,\n\t\tM5: m.M4*right.M1 + m.M5*right.M5 + m.M6*right.M9 + m.M7*right.M13,\n\t\tM6: m.M4*right.M2 + m.M5*right.M6 + m.M6*right.M10 + m.M7*right.M14,\n\t\tM7: m.M4*right.M3 + m.M5*right.M7 + m.M6*right.M11 + m.M7*right.M15,\n\t\tM8: m.M8*right.M0 + m.M9*right.M4 + m.M10*right.M8 + m.M11*right.M12,\n\t\tM9: m.M8*right.M1 + m.M9*right.M5 + m.M10*right.M9 + m.M11*right.M13,\n\t\tM10: m.M8*right.M2 + m.M9*right.M6 + m.M10*right.M10 + m.M11*right.M14,\n\t\tM11: m.M8*right.M3 + m.M9*right.M7 + m.M10*right.M11 + m.M11*right.M15,\n\t\tM12: m.M12*right.M0 + m.M13*right.M4 + m.M14*right.M8 + m.M15*right.M12,\n\t\tM13: m.M12*right.M1 + m.M13*right.M5 + m.M14*right.M9 + m.M15*right.M13,\n\t\tM14: m.M12*right.M2 + m.M13*right.M6 + m.M14*right.M10 + m.M15*right.M14,\n\t\tM15: m.M12*right.M3 + m.M13*right.M7 + m.M14*right.M11 + m.M15*right.M15,\n\t}\n}", "func addMatrix(matrix1, matrix2 *Matrix) *Matrix {\n\tvar numRows = matrix1.getNumRows()\n\tvar numCols = matrix1.getNumCols()\n\tvar resMatrix = Matrix{NumRows: numRows, NumCols: numCols}\n\tresMatrix.init()\n\tfor row := 0; row < numRows; row++ {\n\t\tfor col := 0; col < numCols; col++ {\n\t\t\tval1, er1 := matrix1.getElementAt(row, col)\n\t\t\tif er1 != nil {\n\t\t\t\tfmt.Println(er1)\n\t\t\t}\n\t\t\tval2, er2 := matrix2.getElementAt(row, col)\n\t\t\tif er2 != nil {\n\t\t\t\tfmt.Println(er2)\n\t\t\t}\n\t\t\tresMatrix.setElementAt(row, col, val1+val2)\n\t\t}\n\t}\n\treturn &resMatrix\n}", "func (t *TriDense) Copy(a Matrix) (r, c int) {\n\tr, c = a.Dims()\n\tr = min(r, t.mat.N)\n\tc = min(c, t.mat.N)\n\tif r == 0 || c == 0 {\n\t\treturn 0, 0\n\t}\n\n\tswitch a := a.(type) {\n\tcase RawMatrixer:\n\t\tamat := a.RawMatrix()\n\t\tif t.isUpper() {\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride+i:i*t.mat.Stride+c], amat.Data[i*amat.Stride+i:i*amat.Stride+c])\n\t\t\t}\n\t\t} else {\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride:i*t.mat.Stride+i+1], amat.Data[i*amat.Stride:i*amat.Stride+i+1])\n\t\t\t}\n\t\t}\n\tcase RawTriangular:\n\t\tamat := a.RawTriangular()\n\t\taIsUpper := isUpperUplo(amat.Uplo)\n\t\ttIsUpper := t.isUpper()\n\t\tswitch {\n\t\tcase tIsUpper && aIsUpper:\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride+i:i*t.mat.Stride+c], amat.Data[i*amat.Stride+i:i*amat.Stride+c])\n\t\t\t}\n\t\tcase !tIsUpper && !aIsUpper:\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride:i*t.mat.Stride+i+1], amat.Data[i*amat.Stride:i*amat.Stride+i+1])\n\t\t\t}\n\t\tdefault:\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tt.set(i, i, amat.Data[i*amat.Stride+i])\n\t\t\t}\n\t\t}\n\tdefault:\n\t\tisUpper := t.isUpper()\n\t\tfor i := 0; i < r; i++ {\n\t\t\tif isUpper {\n\t\t\t\tfor j := i; j < c; j++ {\n\t\t\t\t\tt.set(i, j, a.At(i, j))\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tfor j := 0; j <= i; j++ {\n\t\t\t\t\tt.set(i, j, a.At(i, j))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn r, c\n}", "func (s *BasePlSqlParserListener) EnterCost_matrix_clause(ctx *Cost_matrix_clauseContext) {}", "func (m Matrix) Set(row, col, val int) bool {\n\tif row < 0 || row >= len(m) || col < 0 || col >= len(m[0]) {\n\t\treturn false\n\t}\n\tm[row][col] = val\n\treturn true\n}", "func (me XAttrTypeTxsdFeColorMatrixTypeTypeMatrix) TypeDefault() TxsdFeColorMatrixTypeType {\n\treturn TxsdFeColorMatrixTypeType(\"matrix\")\n}", "func buildMatrix(dataShards, totalShards int) matrix {\n\t// Start with a Vandermonde matrix. This matrix would work, in theory, but\n\t// doesn't have the property that the data shards are unchanged after\n\t// encoding.\n\tvm := vandermonde(totalShards, dataShards)\n\n\t// Multiply by the inverse of the top square of the matrix. This will make\n\t// the top square be the identity matrix, but preserve the property that any\n\t// square subset of rows is invertible.\n\ttop := vm.SubMatrix(0, 0, dataShards, dataShards)\n\ttopInv, _ := top.Invert()\n\treturn vm.Multiply(topInv)\n}", "func (this *NumMatrix) PrintMatrix() {\n\tfmt.Printf(\"[\\n\")\n\tfor i := 0; i < len(this.sum); i++ {\n\t\tfmt.Printf(\" [\")\n\t\tfor j := 0; j < len(this.sum[i]); j++ {\n\t\t\tfmt.Printf(\" %d\", this.sum[i][j])\n\t\t}\n\t\tfmt.Printf(\" ]\\n\")\n\t}\n\tfmt.Printf(\"]\\n\")\n}", "func (o *RAdam[T]) newState(shape ...int) *State {\n\tr, c := shape[0], shape[1]\n\treturn &State{\n\t\tM: mat.NewDense[T](mat.WithShape(r, c)),\n\t\tV: mat.NewDense[T](mat.WithShape(r, c)),\n\t\tBuf1: mat.NewDense[T](mat.WithShape(r, c)),\n\t\tBuf2: mat.NewDense[T](mat.WithShape(r, c)),\n\t\tBuf3: mat.NewDense[T](mat.WithShape(r, c)),\n\t}\n}", "func (matrix *Matrix) fillMatrix(info Information) *Matrix {\n\tvar newIndexes []*IndexLetter\n\n\tdata := info.Data\n\n\t// Llenar la primera dimension\n\n\tfor i, dat := range data { // Recorremos cada dato obtenido del json\n\t\tnewIndex := IndexLetter{\n\t\t\tIndex: dat.Index,\n\t\t}\n\t\tnewIndexes = append(newIndexes, &newIndex)\n\t\t//newIndexes[i].Index = dat.Index // Agrega la letra del indice\n\t\tvar newDepartments []DepartmentMatrix\n\n\t\tfor j, dep := range dat.Departments { // Recorremos cada departamento de cada indice\n\t\t\tnewDepartment := DepartmentMatrix{\n\t\t\t\tName: dep.Name,\n\t\t\t}\n\t\t\tnewDepartments = append(newDepartments, newDepartment)\n\t\t\tvar newRatings [5]Rating\n\n\t\t\tfor l := 1; l <= 5; l++ { // Se le crea una lista a cada posicion\n\t\t\t\tnewRatings[l-1] = Rating{\n\t\t\t\t\tNumber: l,\n\t\t\t\t\tLista: NewDoublyLinkedList(),\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor _, sto := range dep.Stores { // Recorremos cada tienda de cada departamento\n\n\t\t\t\trate := int(sto.Rating) - 1\n\t\t\t\tnode := NewNode(sto)\n\t\t\t\tnewRatings[rate].Lista.Append(node) // Se agrega la nueva tienda a la posicion del arreglo correspondiente a su calificacion\n\t\t\t\tagregarTiendaMerkle(sto)\n\t\t\t}\n\t\t\tnewDepartments[j].Ratings = newRatings\n\t\t}\n\t\tnewIndexes[i].Departments = newDepartments\n\n\t}\n\n\tmatrix.Indexes = newIndexes\n\n\treturn matrix\n}", "func initMatrix(matrix [][]int) [][][]int {\n\tvar new_matrix [][][]int\n\n\tnew_matrix = make([][][]int, len(matrix))\n\n\tfor i := range new_matrix {\n\t\tnew_matrix[i] = make([][]int, len(matrix[0]))\n\t\tfor j := range new_matrix[i] {\n\t\t\tnew_matrix[i][j] = make([]int, 3)\n\t\t}\n\t}\n\n\tfor i := 0; i < len(matrix); i++ {\n\t\tfor j := 0; j < len(matrix[0]); j++ {\n\t\t\tnew_matrix[i][j][0] = matrix[i][j]\n\t\t\t// new_matrix[i][j][1] = float64(i)\n\t\t\tnew_matrix[i][j][1] = (i)\n\t\t\t// new_matrix[i][j][2] = float64(j)\n\t\t\tnew_matrix[i][j][2] = (j)\n\t\t}\n\t}\n\n\treturn new_matrix\n}", "func (mA *Matrix) Set(r, c, val int) bool {\n\tm := *mA\n\tif r < 0 || r >= len(m) {\n\t\treturn false\n\t}\n\tif c < 0 || c >= len(m[0]) {\n\t\treturn false\n\t}\n\tm[r][c] = val\n\treturn true\n}", "func newNumberMatrix(arg formulaArg, phalanx bool) (numMtx [][]float64, ele formulaArg) {\n\trows := len(arg.Matrix)\n\tfor r, row := range arg.Matrix {\n\t\tif phalanx && len(row) != rows {\n\t\t\tele = newErrorFormulaArg(formulaErrorVALUE, formulaErrorVALUE)\n\t\t\treturn\n\t\t}\n\t\tnumMtx = append(numMtx, make([]float64, len(row)))\n\t\tfor c, cell := range row {\n\t\t\tif cell.Type != ArgNumber {\n\t\t\t\tele = newErrorFormulaArg(formulaErrorVALUE, formulaErrorVALUE)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tnumMtx[r][c] = cell.Number\n\t\t}\n\t}\n\treturn\n}", "func LookMatrix(o Vec, to Vec) *Mtx {\n\tf, _ := o.Minus(to).Unit() // forward\n\tr, _ := yAxis.Cross(f) // right\n\tu, _ := f.Cross(r) // up\n\torient := NewMat(\n\t\tr.X, u.X, f.X, 0,\n\t\tr.Y, u.Y, f.Y, 0,\n\t\tr.Z, u.Z, f.Z, 0,\n\t\t0, 0, 0, 1,\n\t)\n\treturn Shift(o).Mult(orient)\n}", "func (m *Matrix) set(w, h int, c qrvalue) error {\n\tif w >= m.width || w < 0 {\n\t\treturn ErrorOutRangeOfW\n\t}\n\tif h >= m.height || h < 0 {\n\t\treturn ErrorOutRangeOfH\n\t}\n\tm.mat[w][h] = c\n\treturn nil\n}", "func (target *Matrix) Copy(m *Matrix) *Matrix {\n\treturn nil\n}", "func (ev *evaluator) evalMatrix(e Expr) matrix {\n\tval := ev.eval(e)\n\tmat, ok := val.(matrix)\n\tif !ok {\n\t\tev.errorf(\"expected range vector but got %s\", documentedType(val.Type()))\n\t}\n\treturn mat\n}", "func (c Cycles) Matrix() Matrix {\n\tm := make(Matrix, c.len())\n\tfor u := range m {\n\t\tm[u] = make([]int8, len(m))\n\t}\n\n\tfor _, cycle := range c {\n\t\tfor i, u := range cycle {\n\t\t\tv := cycle[0]\n\t\t\tif i < len(cycle)-1 {\n\t\t\t\tv = cycle[i+1]\n\t\t\t}\n\t\t\tm[u][v] = 1\n\t\t}\n\t}\n\n\treturn m\n}", "func (m *Matrix) SubMatrix(x1, y1, x2, y2 int) (newM *Matrix) {\n\tnewM = m.Clone()\n\tnewM.SetFocus(x1, y1, x2, y2)\n\treturn\n}", "func MatrixMultiply(left, right Matrix) Matrix {\n\tvar result Matrix\n\n\tresult.M0 = left.M0*right.M0 + left.M1*right.M4 + left.M2*right.M8 + left.M3*right.M12\n\tresult.M1 = left.M0*right.M1 + left.M1*right.M5 + left.M2*right.M9 + left.M3*right.M13\n\tresult.M2 = left.M0*right.M2 + left.M1*right.M6 + left.M2*right.M10 + left.M3*right.M14\n\tresult.M3 = left.M0*right.M3 + left.M1*right.M7 + left.M2*right.M11 + left.M3*right.M15\n\tresult.M4 = left.M4*right.M0 + left.M5*right.M4 + left.M6*right.M8 + left.M7*right.M12\n\tresult.M5 = left.M4*right.M1 + left.M5*right.M5 + left.M6*right.M9 + left.M7*right.M13\n\tresult.M6 = left.M4*right.M2 + left.M5*right.M6 + left.M6*right.M10 + left.M7*right.M14\n\tresult.M7 = left.M4*right.M3 + left.M5*right.M7 + left.M6*right.M11 + left.M7*right.M15\n\tresult.M8 = left.M8*right.M0 + left.M9*right.M4 + left.M10*right.M8 + left.M11*right.M12\n\tresult.M9 = left.M8*right.M1 + left.M9*right.M5 + left.M10*right.M9 + left.M11*right.M13\n\tresult.M10 = left.M8*right.M2 + left.M9*right.M6 + left.M10*right.M10 + left.M11*right.M14\n\tresult.M11 = left.M8*right.M3 + left.M9*right.M7 + left.M10*right.M11 + left.M11*right.M15\n\tresult.M12 = left.M12*right.M0 + left.M13*right.M4 + left.M14*right.M8 + left.M15*right.M12\n\tresult.M13 = left.M12*right.M1 + left.M13*right.M5 + left.M14*right.M9 + left.M15*right.M13\n\tresult.M14 = left.M12*right.M2 + left.M13*right.M6 + left.M14*right.M10 + left.M15*right.M14\n\tresult.M15 = left.M12*right.M3 + left.M13*right.M7 + left.M14*right.M11 + left.M15*right.M15\n\n\treturn result\n}", "func (mat Mat) MultiplyMatrix(mat_2 Mat) (Mat,error) {\n if mat.Shape[1] != mat_2.Shape[0] {\n return mat,&MatrixError{(\"Miss-matched shape.\")}\n }\n Shape := []int{ mat.Shape[1], mat_2.Shape[0]}\n var temp [][]float32\n for i := 0 ; i < Shape[0]; i++ {\n temp_r := make([]float32, Shape[1])\n for j := 0 ; j < Shape[1]; j++ {\n var p_val float32 = 0\n for k := 0; k < Shape[0]; k++ {\n p_val += mat.Value[i][k] * mat_2.Value[k][j]\n }\n temp_r[j] = p_val\n }\n temp = append(temp, temp_r)\n }\n return Mat{temp, Shape},nil\n}", "func (m *Maps) SetCurrent(lvl int) {\n\tlog.WithField(\"lvl\", lvl).Info(\"setting current level\")\n\tm.current = lvl\n\tm.active = m.mazes[m.current]\n}", "func (room Room) GetCurrentIdx() int {\n\tid := -1\n\tif room.State >= IdxTurn {\n\t\tid = room.State - IdxTurn\n\t}\n\treturn id\n}", "func GetMatrix(x, y int, v int64) (m *Matrix) {\n\tm = &Matrix{}\n\tm.x = uint64(x)\n\tm.y = uint64(y)\n\tm.Init(v)\n\tm.ResetFocus()\n\treturn\n}", "func (m *TransposableMatrix) Set(x, y int, slt Slot) {\n\n\txb, yb := m.transposeMapped2Base(x, y)\n\t// pf(\"%v %v => %v %v\\n\", x, y, xm, ym)\n\tif xb == -1 || yb == -1 { // cant set\n\t\treturn\n\t}\n\tm.m[xb][yb] = slt\n\n\tif slt.AmX != nil {\n\t\tm.updateLimits(xb, yb)\n\t}\n\n}", "func (c *Camera) Matrix() mgl32.Mat4 {\n\treturn mgl32.LookAtV(c.pos, c.pos.Add(c.front), c.up)\n}", "func (imd *IMDraw) SetMatrix(m pixel.Matrix) {\n\timd.matrix = m\n\timd.batch.SetMatrix(imd.matrix)\n}", "func Mat2Set(matrix *Mat2, radians float32) {\n\tcos := float32(math.Cos(float64(radians)))\n\tsin := float32(math.Sin(float64(radians)))\n\n\tmatrix.M00 = cos\n\tmatrix.M01 = -sin\n\tmatrix.M10 = sin\n\tmatrix.M11 = cos\n}", "func MatrixLookAt(eye, target, up Vector3) Matrix {\n\tvar result Matrix\n\n\tz := Vector3Subtract(eye, target)\n\tz = Vector3Normalize(z)\n\tx := Vector3CrossProduct(up, z)\n\tx = Vector3Normalize(x)\n\ty := Vector3CrossProduct(z, x)\n\ty = Vector3Normalize(y)\n\n\tresult.M0 = x.X\n\tresult.M1 = x.Y\n\tresult.M2 = x.Z\n\tresult.M3 = -((x.X * eye.X) + (x.Y * eye.Y) + (x.Z * eye.Z))\n\tresult.M4 = y.X\n\tresult.M5 = y.Y\n\tresult.M6 = y.Z\n\tresult.M7 = -((y.X * eye.X) + (y.Y * eye.Y) + (y.Z * eye.Z))\n\tresult.M8 = z.X\n\tresult.M9 = z.Y\n\tresult.M10 = z.Z\n\tresult.M11 = -((z.X * eye.X) + (z.Y * eye.Y) + (z.Z * eye.Z))\n\tresult.M12 = 0.0\n\tresult.M13 = 0.0\n\tresult.M14 = 0.0\n\tresult.M15 = 1.0\n\n\treturn result\n}", "func getNewMatrix(c, r int) (matrix [][]float64) {\n\tfor i := 0; i < c; i++ {\n\t\tfor j := 0; j < r; j++ {\n\t\t\tfor x := len(matrix); x <= i; x++ {\n\t\t\t\tmatrix = append(matrix, []float64{})\n\t\t\t}\n\t\t\tfor y := len(matrix[i]); y <= j; y++ {\n\t\t\t\tmatrix[i] = append(matrix[i], 0)\n\t\t\t}\n\t\t\tmatrix[i][j] = 0\n\t\t}\n\t}\n\treturn\n}", "func Identity() Matrix {\n\treturn Matrix{1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1}\n}", "func (s *TableQuery) CurrentSQL() string {\n\treturn s.getSelectSQL()\n}", "func (m *Matrix) init() {\n\tfor w := 0; w < m.width; w++ {\n\t\tfor h := 0; h < m.height; h++ {\n\t\t\tm.mat[w][h] = QRValue_INIT_V0\n\t\t}\n\t}\n}", "func (rb *ShardsRecordBuilder) GetCurrent(getcurrent string) *ShardsRecordBuilder {\n\trb.v.GetCurrent = &getcurrent\n\treturn rb\n}", "func setInput(grid *datatypes.Grid) int {\n\tsetValue(grid, 0, 4, 4)\n\tsetValue(grid, 0, 5, 5)\n\n\tsetValue(grid, 1, 0, 8)\n\tsetValue(grid, 1, 6, 2)\n\tsetValue(grid, 1, 8, 7)\n\n\tsetValue(grid, 2, 2, 2)\n\tsetValue(grid, 2, 8, 4)\n\n\tsetValue(grid, 3, 2, 6)\n\tsetValue(grid, 3, 6, 3)\n\tsetValue(grid, 3, 8, 2)\n\n\tsetValue(grid, 4, 3, 1)\n\n\tsetValue(grid, 5, 0, 2)\n\tsetValue(grid, 5, 2, 7)\n\tsetValue(grid, 5, 3, 4)\n\tsetValue(grid, 5, 6, 6)\n\n\tsetValue(grid, 6, 0, 6)\n\tsetValue(grid, 6, 1, 4)\n\tsetValue(grid, 6, 4, 9)\n\tsetValue(grid, 6, 5, 8)\n\n\tsetValue(grid, 7, 0, 7)\n\tsetValue(grid, 7, 1, 9)\n\tsetValue(grid, 7, 5, 4)\n\n\tsetValue(grid, 8, 7, 3)\n\n\tgrid.Print()\n\treturn 23\n}", "func (m *Maps) CurrentLevel() int { return m.current }", "func MatrixTrace(mat Matrix) float32 {\n\treturn mat.M0 + mat.M5 + mat.M10 + mat.M15\n}", "func (r *Result) Matrix() (model.Matrix, error) {\n\tif r.Err != nil {\n\t\treturn nil, r.Err\n\t}\n\tv, ok := r.Value.(model.Matrix)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"query result is not a range vector\")\n\t}\n\treturn v, nil\n}", "func IdentityMatrix(s int) Mat {\n var temp [][]float32\n for i := 0; i < s; i++ {\n temp_r := make([]float32, s)\n temp_r[i] = 1\n temp = append(temp, temp_r)\n }\n return Mat{temp, []int{s,s}}\n}", "func (m *Matrix) Set(r, c, val int) bool {\n\tif r < 0 || r >= m.nRows || c < 0 || c >= m.nCols {\n\t\treturn false\n\t}\n\tm.data[r][c] = val\n\treturn true\n}", "func (matrix *Matrix) printMatrix() {\n\n\tfor i := 0; i < len(matrix.Indexes); i++ {\n\t\tfmt.Print(matrix.Indexes[i].Index, \"[ \")\n\t\tfor j := 0; j < len(matrix.Indexes[i].Departments); j++ {\n\t\t\tfmt.Print(\"[ \")\n\t\t\tfor k := 0; k < len(matrix.Indexes[i].Departments[j].Ratings); k++ {\n\t\t\t\ttext, _ := matrix.Indexes[i].Departments[j].Ratings[k].Lista.ToString()\n\t\t\t\tfmt.Print(\"[ \", text, \" ]\")\n\n\t\t\t}\n\t\t\tfmt.Print(\"] \")\n\t\t}\n\t\tfmt.Println(\"]\")\n\t}\n}", "func MatrixOpen(c buffalo.Context) error {\n\t// 从 querystring 中获取参数\n\tvar err error\n\tinfo := struct {\n\t\tMatrixNum string `form:\"num\" json:\"num\" db:\"matrix\"`\n\t\tSubmitUser string `form:\"user\" json:\"user\"`\n\t\tPeriod string `form:\"period\" json:\"period\" db:\"period\"`\n\t\tCompany string `form:\"company\" json:\"company\" db:\"company\"`\n\t\tVersion string `form:\"version\" json:\"version\" db:\"version\"`\n\t}{}\n\terr = c.Bind(&info)\n\tif err != nil {\n\t\treturn errors.WithStack(err)\n\t}\n\tif info.Period == \"\" {\n\t\tinfo.Period = defaultPeriod\n\t}\n\tif info.Company == \"\" {\n\t\tinfo.Company = defaultCompany\n\t}\n\tif info.Version == \"\" {\n\t\tinfo.Version = defaultVersion\n\t}\n\n\t// 根据 matrix,period,company 找到之前提交的数据\n\t// Get the DB connection from the context\n\ttx, ok := c.Value(\"tx\").(*pop.Connection)\n\tif !ok {\n\t\treturn errors.WithStack(errors.New(\"no transaction found\"))\n\t}\n\n\tkv := base.KvCache()\n\tsugar := base.Sugar()\n\tdb := tx.TX\n\n\tcmdSQL := kv.GetCommand(\"matrix.findBy\", nil)\n\tnstmt, err := db.PrepareNamed(cmdSQL)\n\tif err != nil {\n\t\tsugar.Errorw(\"preparedNamed failed\", \"err\", err)\n\t\treturn errors.WithStack(err)\n\t}\n\n\t// 查询参数\n\titems := models.Matrices{}\n\terr = nstmt.Select(&items, info)\n\tif err != nil {\n\t\tsugar.Errorw(\"failed to query index\", \"param\", info, \"err\", err)\n\t\treturn errors.WithStack(err)\n\t}\n\n\ts, err := loadMatrix(info.MatrixNum)\n\tif err != nil {\n\t\treturn errors.WithStack(err)\n\t}\n\n\t// 根据数据库中数据,更新\n\t// for i, _ := range s.Sections {\n\t// \tfor j, _ := range s.Sections[i].Indexes {\n\t// \t\tfor _, v := range items {\n\t// \t\t\tif v.Code == s.Sections[i].Indexes[j].Code {\n\t// \t\t\t\ts.Sections[i].Indexes[j].Value = v.Value\n\t// \t\t\t\tcontinue\n\t// \t\t\t}\n\t// \t\t}\n\t// \t}\n\t// }\n\n\tfor i, section := range s.Sections {\n\t\tfor j := range section.Indexes {\n\t\t\tfor k := range items {\n\t\t\t\tif items[k].Code == section.Indexes[j].Code {\n\t\t\t\t\ts.Sections[i].Indexes[j].Value = items[k].Value\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tp := struct {\n\t\tPeriod string\n\t\tMatrixNum string\n\t\tID string\n\t\tTitle string\n\t\tSections []matrixSectionT\n\t\tPeriodOptions []string\n\t}{\n\t\tPeriod: info.Period,\n\t\tMatrixNum: info.MatrixNum,\n\t\tID: info.SubmitUser,\n\t\tTitle: s.Title,\n\t\tSections: s.Sections,\n\t\tPeriodOptions: []string{\"2016\", \"2017\", \"2018\"},\n\t}\n\tc.Set(\"p\", p)\n\n\treturn c.Render(200, r.HTML(\"matrix/open.html\", \"surveys/simple.html\"))\n}", "func (ev *FSAEnv) TMatReber() {\n\tev.InitTMat(8)\n\tev.SetTMat(0, 1, 1, \"B\") // 0 = start\n\tev.SetTMat(1, 2, 0.5, \"T\") // 1 = state 0 in usu diagram (+1 for all states)\n\tev.SetTMat(1, 3, 0.5, \"P\")\n\tev.SetTMat(2, 2, 0.5, \"S\")\n\tev.SetTMat(2, 4, 0.5, \"X\")\n\tev.SetTMat(3, 3, 0.5, \"T\")\n\tev.SetTMat(3, 5, 0.5, \"V\")\n\tev.SetTMat(4, 6, 0.5, \"S\")\n\tev.SetTMat(4, 3, 0.5, \"X\")\n\tev.SetTMat(5, 6, 0.5, \"V\")\n\tev.SetTMat(5, 4, 0.5, \"P\")\n\tev.SetTMat(6, 7, 1, \"E\") // 7 = end\n\tev.Init(0)\n}", "func GetCurrentNode() *ClusterTopologyNode {\n\treturn currentNode\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 (m *Mat2f) Set(row, col int, v float32) {\n\tm[col*2+row] = v\n}", "func (e *Square10) CurrentBoard(referencePlayer int) []api.Color {\n\treferenceBoard := [100]api.Color{}\n\tfor tile, color := range e.tiles {\n\t\ttargetID := referencePlayer*99 - tile*(referencePlayer*2-1)\n\t\treferenceBoard[targetID] = color\n\t}\n\treturn referenceBoard[:]\n}", "func (m *Matrix) Set(x, y int, val float64) {\n\treturn\n}", "func IsMatrixType(t BareType) bool { col, _ := TypeDimensions(t); return col > 1 }", "func (mat Mat) InverseMatrix() (Mat,error) {\n if mat.Shape[0] != mat.Shape[1] {\n return mat,&MatrixError{\"Not a Square matrix.\"}\n }\n adj_mat,determinant := AdjointMatrix(mat)\n if determinant == 0 {\n return mat,&MatrixError{\"The determinant of the matrix is zero.\"}\n }\n adj_mat = adj_mat.MultiplyScalar(1/determinant)\n return adj_mat,nil\n}", "func (c2d *C2DMatrix) M11() float64 { return c2d.matrix.m11 }", "func subsetMatrix(m *matrix.DenseMatrix, rows []int, cols []int) *matrix.DenseMatrix {\n\telements := make([]float64, len(rows)*len(cols))\n\tsubset := matrix.MakeDenseMatrix(elements, len(rows), len(cols))\n\n\tfor newRowIndex, oldRowIndex := range rows {\n\t\tfor newColIndex, oldColIndex := range cols {\n\t\t\tsubset.Set(newRowIndex, newColIndex, m.Get(oldRowIndex, oldColIndex))\n\t\t}\n\t}\n\n\treturn subset\n}", "func (m *matrixComplex) Set(row int, col int, value complex128) { m.elements[row][col] = value }", "func incrementTransMatrix(transMatrix *[][]float32, prevTagIndex int, currTagIndex int) {\n\t(*transMatrix)[prevTagIndex][currTagIndex]++\n}", "func (leg *Leg) Matrix() math3d.Matrix44 {\n\treturn *math3d.MakeMatrix44(*leg.Origin, *math3d.MakeSingularEulerAngle(math3d.RotationHeading, leg.Angle))\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 searchMatrix(matrix [][]int, target int) bool {\n\tif matrix == nil || len(matrix) == 0 || len(matrix[0]) == 0 {\n\t\treturn false\n\t}\n\tn, m := len(matrix), len(matrix[0])\n\ti, j := 0, m-1\n\tfor i < n && j >= 0 {\n\t\tif matrix[i][j] == target {\n\t\t\treturn true\n\t\t} else if target < matrix[i][j] {\n\t\t\tj--\n\t\t} else {\n\t\t\ti++\n\t\t}\n\t}\n\treturn false\n}", "func (mat Mat) AddMatrix(mat_2 Mat) (Mat,error) {\n if len(mat.Shape) != len(mat_2.Shape) {\n return mat,&MatrixError{\"Miss-matched dimmensions.\"}\n } else {\n for dim := 0 ; dim < len(mat.Shape); dim++ {\n if mat.Shape[dim] != mat_2.Shape[dim] {\n return mat,&MatrixError{(\"Miss-matched shape.\")}\n }\n }\n }\n var temp [][]float32\n for i := 0 ; i < mat.Shape[0]; i++ {\n temp_r := make([]float32, mat.Shape[1])\n for j := 0 ; j < mat.Shape[1]; j++ {\n temp_r[j] = mat.Value[i][j] + mat_2.Value[i][j]\n }\n temp = append(temp, temp_r)\n }\n return Mat{temp, mat.Shape},nil\n}", "func updateCurrentFarm(r int, c int, currentFarm *[]int) {\n\t// fmt.Println(\"update\", r, c, currentFarm)\n\tf := *currentFarm\n\tif r > f[3] {\n\t\tf[3] = r\n\t}\n\n\tif c>f[2] {\n\t\tf[2] = c\n\t}\n\n\t// fmt.Println(\"result\", currentFarm)\n\n}", "func searchMatrix(matrix [][]int, target int) bool {\n if len(matrix) == 0 {\n return false\n }\n for i,j:=0, len(matrix[0])-1; i<len(matrix) && j>=0; {\n if matrix[i][j] == target {\n return true\n } else if matrix[i][j] < target {\n i++\n } else {\n j--\n }\n }\n return false\n}", "func invertMatrix(matrix []byte, k int) error {\n\tpivot_searcher := newPivotSearcher(k)\n\tindxc := make([]int, k)\n\tindxr := make([]int, k)\n\tid_row := make([]byte, k)\n\n\tfor col := 0; col < k; col++ {\n\t\ticol, irow, err := pivot_searcher.search(col, matrix)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif irow != icol {\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tswap(&matrix[irow*k+i], &matrix[icol*k+i])\n\t\t\t}\n\t\t}\n\n\t\tindxr[col] = irow\n\t\tindxc[col] = icol\n\t\tpivot_row := matrix[icol*k:][:k]\n\t\tc := pivot_row[icol]\n\n\t\tif c == 0 {\n\t\t\treturn Error.New(\"singular matrix\")\n\t\t}\n\n\t\tif c != 1 {\n\t\t\tc = gf_inverse[c]\n\t\t\tpivot_row[icol] = 1\n\t\t\tmul_c := gf_mul_table[c][:]\n\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tpivot_row[i] = mul_c[pivot_row[i]]\n\t\t\t}\n\t\t}\n\n\t\tid_row[icol] = 1\n\t\tif !bytes.Equal(pivot_row, id_row) {\n\t\t\tp := matrix\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tif i != icol {\n\t\t\t\t\tc = p[icol]\n\t\t\t\t\tp[icol] = 0\n\t\t\t\t\taddmul(p[:k], pivot_row, c)\n\t\t\t\t}\n\t\t\t\tp = p[k:]\n\t\t\t}\n\t\t}\n\n\t\tid_row[icol] = 0\n\t}\n\n\tfor i := 0; i < k; i++ {\n\t\tif indxr[i] != indxc[i] {\n\t\t\tfor row := 0; row < k; row++ {\n\t\t\t\tswap(&matrix[row*k+indxr[i]], &matrix[row*k+indxc[i]])\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func binaryMatrixOp(c Context, i Value, op string, j Value) Value {\n\tu, v := i.(*Matrix), j.(*Matrix)\n\tshape := u.shape\n\tvar n []Value\n\t// One or the other may be a scalar in disguise.\n\tswitch {\n\tcase isScalar(u):\n\t\t// Scalar op Matrix.\n\t\tshape = v.shape\n\t\tn = make([]Value, len(v.data))\n\t\tfor k := range v.data {\n\t\t\tn[k] = c.EvalBinary(u.data[0], op, v.data[k])\n\t\t}\n\tcase isScalar(v):\n\t\t// Matrix op Scalar.\n\t\tn = make([]Value, len(u.data))\n\t\tfor k := range u.data {\n\t\t\tn[k] = c.EvalBinary(u.data[k], op, v.data[0])\n\t\t}\n\tcase isVector(u, v.shape):\n\t\t// Vector op Matrix.\n\t\tshape = v.shape\n\t\tn = make([]Value, len(v.data))\n\t\tdim := u.shape[0]\n\t\tindex := 0\n\t\tfor k := range v.data {\n\t\t\tn[k] = c.EvalBinary(u.data[index], op, v.data[k])\n\t\t\tindex++\n\t\t\tif index >= dim {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t}\n\tcase isVector(v, u.shape):\n\t\t// Matrix op Vector.\n\t\tn = make([]Value, len(u.data))\n\t\tdim := v.shape[0]\n\t\tindex := 0\n\t\tfor k := range u.data {\n\t\t\tn[k] = c.EvalBinary(u.data[k], op, v.data[index])\n\t\t\tindex++\n\t\t\tif index >= dim {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t}\n\tdefault:\n\t\t// Matrix op Matrix.\n\t\tu.sameShape(v)\n\t\tn = make([]Value, len(u.data))\n\t\tfor k := range u.data {\n\t\t\tn[k] = c.EvalBinary(u.data[k], op, v.data[k])\n\t\t}\n\t}\n\treturn NewMatrix(shape, NewVector(n))\n}", "func Copy(m *Matrix) *Matrix {\n\treturn nil\n}", "func (m *Maps) CurrentMap() [][]io.Runeable {\n\treturn m.active\n}", "func (m *Matrix) Col(cur int) []qrvalue {\n\tif cur >= m.width || cur < 0 {\n\t\treturn nil\n\t}\n\n\treturn m.mat[cur]\n}", "func (mPointer *GF8Matrix) Inv() (*GF8Matrix, error) {\n\tm := NewMatrix(mPointer.numRow, mPointer.numCol)\n\tcopy(m.Matrix, mPointer.Matrix)\n\tif m.numCol != m.numRow {\n\t\tlog.Fatal(ErrNotSquareMatrix)\n\t}\n\t// extend identity matrix to right half\n\tfor r := 0; r < m.numRow; r++ {\n\t\tprepandArray := make([]byte, m.numCol)\n\t\tprepandArray[r] = 1\n\t\tm.Matrix[r] = append(m.Matrix[r], prepandArray...)\n\t}\n\toriginalNumCol := m.numCol\n\tm.numCol += originalNumCol\n\t// make left half identity\n\tfor r := 0; r < m.numRow; r++ {\n\t\t// find head\n\t\tsingularFlag := true\n\t\tfor iFindHead := r; iFindHead < m.numRow; iFindHead++ {\n\t\t\tif m.Matrix[iFindHead][r] != 0 {\n\t\t\t\tif iFindHead != r {\n\t\t\t\t\tm.swapRow(iFindHead, r)\n\t\t\t\t}\n\t\t\t\tsingularFlag = false\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif singularFlag {\n\t\t\treturn nil, ErrSingularMatrix\n\t\t}\n\t\t// make this diagnal unit\n\t\thead := m.Matrix[r][r]\n\t\tm.multRow(r, inverseTbl[head])\n\t\t// erase other rows\n\t\tfor rFollow := 0; rFollow < m.numRow; rFollow++ {\n\t\t\tif rFollow == r || m.Matrix[rFollow][r] == 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tm.mulAddToRow(r, m.Matrix[rFollow][r], rFollow)\n\t\t}\n\t}\n\t//remove left half\n\tfor r := 0; r < m.numRow; r++ {\n\t\tm.Matrix[r] = m.Matrix[r][originalNumCol:]\n\t}\n\tm.numCol = originalNumCol\n\n\tif SanityCheck {\n\t\tshouldBeIdentity := m.Mul(mPointer)\n\t\tshouldBeIdentity.ShowMatrix(SanityCheck)\n\t\tfor r := 0; r < m.numRow; r++ {\n\t\t\tfor c := 0; c < m.numCol; c++ {\n\t\t\t\tif r == c && shouldBeIdentity.Matrix[r][c] != 1 {\n\t\t\t\t\tlog.Fatalf(\"Fail the sanity check, %v != 1\", shouldBeIdentity.Matrix[r][c])\n\t\t\t\t} else if r != c && shouldBeIdentity.Matrix[r][c] != 0 {\n\t\t\t\t\tlog.Fatalf(\"Fail the sanity check, %v != 0\", shouldBeIdentity.Matrix[r][c])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn m, nil\n}", "func (t TransposeTri) T() Matrix {\n\treturn t.Triangular\n}", "func searchMatrix(matrix [][]int, target int) bool {\n\tm := len(matrix)\n\tif m == 0 {\n\t\treturn false\n\t}\n\tn := len(matrix[0])\n\tif n == 0 {\n\t\treturn false\n\t}\n\n\t// now we have m row, and n col\n\t// 1. if k in [0, m-1] and i < j, then a[k][i] < a[k][j]\n\t// 2. for k in [1, m-1], then a[k-1][*] < a[k][*]\n\t// so we can conduct that, if we iter number row by row, and from left to right in each row, the number will in acceding order, so we can use binary search\n\tlow := 0\n\thigh := m*n - 1\n\n\tfor low <= high {\n\t\tmid := (low + high) / 2\n\t\trow, col := extractRowAndColFromIndex(mid, n)\n\t\tif matrix[row][col] == target {\n\t\t\treturn true\n\t\t} else if matrix[row][col] < target {\n\t\t\tlow = mid + 1\n\t\t} else {\n\t\t\thigh = mid - 1\n\t\t}\n\t}\n\n\treturn false\n}", "func newMatrix(width, height int) *Matrix {\n\tmat := make([][]qrvalue, width)\n\tfor w := 0; w < width; w++ {\n\t\tmat[w] = make([]qrvalue, height)\n\t}\n\n\tm := &Matrix{\n\t\tmat: mat,\n\t\twidth: width,\n\t\theight: height,\n\t}\n\n\tm.init()\n\treturn m\n}", "func setObjects(matrix *[]models.Location, object string, amount int) {\n\tseed := rand.NewSource(time.Now().UnixNano()) //setting time as a seed for random\n\trandom := rand.New(seed) //setting seed\n\tvar x, y int\n\tfor col := 0; col < Width/ColumnWidth; col++ { //block is a wide column, which should contain certain amount of objects\n\t\tfor i := 0; i < amount; i++ {\n\t\t\tfor fieldIsEmpty := false; !fieldIsEmpty; fieldIsEmpty = isEmpty(matrix, x, y) { //do-while loop implementation\n\t\t\t\tx = random.Intn(ColumnWidth) + (col * ColumnWidth) //getting random value within current block\n\t\t\t\ty = random.Intn(Height) //getting random value within map height\n\t\t\t}\n\t\t\tswitch object {\n\t\t\tcase \"CakeFactory\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewCakeFactory(x, y)\n\t\t\tcase \"CandyFactory\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewCandyFactory(x, y)\n\t\t\tcase \"CoffeePoint\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewCoffeePoint(x, y)\n\t\t\tcase \"Chest\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewChest(x, y)\n\t\t\tcase \"Sign\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewSign(x, y)\n\t\t\tcase \"Block\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewBlock(x, y)\n\t\t\tcase \"Monster\":\n\t\t\t\t(*matrix)[y*Width+x] = models.NewMonster(x, y)\n\t\t\t}\n\t\t}\n\t}\n}", "func baseRotation(from [][]int, to [][]int) {\n\tto[0][2] = from[0][0]\n\tto[2][2] = from[0][2]\n\tto[2][0] = from[2][2]\n\tto[0][0] = from[2][0]\n\n\tto[1][2] = from[0][1]\n\tto[2][1] = from[1][2]\n\tto[1][0] = from[2][1]\n\tto[0][1] = from[1][0]\n}", "func (matrix *Matrix4) SetInverseOf(m *Matrix4, errorOnDegenerate bool) error {\n\tt11 := m.elements[9 ]*m.elements[14]*m.elements[7 ] - m.elements[13]*m.elements[10]*m.elements[7 ] + m.elements[13]*m.elements[6 ]*m.elements[11] - m.elements[5 ]*m.elements[14]*m.elements[11] - m.elements[9 ]*m.elements[6 ]*m.elements[15] + m.elements[5 ]*m.elements[10]*m.elements[15]\n\tt12 := m.elements[12]*m.elements[10]*m.elements[7 ] - m.elements[8 ]*m.elements[14]*m.elements[7 ] - m.elements[12]*m.elements[6 ]*m.elements[11] + m.elements[4 ]*m.elements[14]*m.elements[11] + m.elements[8 ]*m.elements[6 ]*m.elements[15] - m.elements[4 ]*m.elements[10]*m.elements[15]\n\tt13 := m.elements[8 ]*m.elements[13]*m.elements[7 ] - m.elements[12]*m.elements[9 ]*m.elements[7 ] + m.elements[12]*m.elements[5 ]*m.elements[11] - m.elements[4 ]*m.elements[13]*m.elements[11] - m.elements[8 ]*m.elements[5 ]*m.elements[15] + m.elements[4 ]*m.elements[9 ]*m.elements[15]\n\tt14 := m.elements[12]*m.elements[9 ]*m.elements[6 ] - m.elements[8 ]*m.elements[13]*m.elements[6 ] - m.elements[12]*m.elements[5 ]*m.elements[10] + m.elements[4 ]*m.elements[13]*m.elements[10] + m.elements[8 ]*m.elements[5 ]*m.elements[14] - m.elements[4 ]*m.elements[9 ]*m.elements[14]\n\n\tdet := m.elements[0 ]*t11 + m.elements[1 ]*t12 + m.elements[2 ]*t13 + m.elements[3 ]*t14\n\n\tif det == 0 {\n\t\tif errorOnDegenerate == true {\n\t\t\treturn errors.New(\".getInverse() can't invert matrix, determinant is 0\")\n\t\t} else {\n\t\t\tlog.Println(\".getInverse() can't invert matrix, determinant is 0\")\n\t\t\tmatrix.SetIdentity()\n\t\t\treturn nil\n\t\t}\n\t}\n\n\tdetInv := 1 / det\n\n\tmatrix.elements[0 ] = t11 * detInv\n\tmatrix.elements[1 ] = (m.elements[13]*m.elements[10]*m.elements[3 ] - m.elements[9 ]*m.elements[14]*m.elements[3 ] - m.elements[13]*m.elements[2 ]*m.elements[11] + m.elements[1 ]*m.elements[14]*m.elements[11] + m.elements[9 ]*m.elements[2 ]*m.elements[15] - m.elements[1 ]*m.elements[10]*m.elements[15]) * detInv\n\tmatrix.elements[2 ] = (m.elements[5 ]*m.elements[14]*m.elements[3 ] - m.elements[13]*m.elements[6 ]*m.elements[3 ] + m.elements[13]*m.elements[2 ]*m.elements[7 ] - m.elements[1 ]*m.elements[14]*m.elements[7 ] - m.elements[5 ]*m.elements[2 ]*m.elements[15] + m.elements[1 ]*m.elements[6 ]*m.elements[15]) * detInv\n\tmatrix.elements[3 ] = (m.elements[9 ]*m.elements[6 ]*m.elements[3 ] - m.elements[5 ]*m.elements[10]*m.elements[3 ] - m.elements[9 ]*m.elements[2 ]*m.elements[7 ] + m.elements[1 ]*m.elements[10]*m.elements[7 ] + m.elements[5 ]*m.elements[2 ]*m.elements[11] - m.elements[1 ]*m.elements[6 ]*m.elements[11]) * detInv\n\n\tmatrix.elements[4 ] = t12 * detInv\n\tmatrix.elements[5 ] = (m.elements[8 ]*m.elements[14]*m.elements[3 ] - m.elements[12]*m.elements[10]*m.elements[3 ] + m.elements[12]*m.elements[2 ]*m.elements[11] - m.elements[0 ]*m.elements[14]*m.elements[11] - m.elements[8 ]*m.elements[2 ]*m.elements[15] + m.elements[0 ]*m.elements[10]*m.elements[15]) * detInv\n\tmatrix.elements[6 ] = (m.elements[12]*m.elements[6 ]*m.elements[3 ] - m.elements[4 ]*m.elements[14]*m.elements[3 ] - m.elements[12]*m.elements[2 ]*m.elements[7 ] + m.elements[0 ]*m.elements[14]*m.elements[7 ] + m.elements[4 ]*m.elements[2 ]*m.elements[15] - m.elements[0 ]*m.elements[6 ]*m.elements[15]) * detInv\n\tmatrix.elements[7 ] = (m.elements[4 ]*m.elements[10]*m.elements[3 ] - m.elements[8 ]*m.elements[6 ]*m.elements[3 ] + m.elements[8 ]*m.elements[2 ]*m.elements[7 ] - m.elements[0 ]*m.elements[10]*m.elements[7 ] - m.elements[4 ]*m.elements[2 ]*m.elements[11] + m.elements[0 ]*m.elements[6 ]*m.elements[11]) * detInv\n\n\tmatrix.elements[8 ] = t13 * detInv\n\tmatrix.elements[9 ] = (m.elements[12]*m.elements[9 ]*m.elements[3 ] - m.elements[8 ]*m.elements[13]*m.elements[3 ] - m.elements[12]*m.elements[1 ]*m.elements[11] + m.elements[0 ]*m.elements[13]*m.elements[11] + m.elements[8 ]*m.elements[1 ]*m.elements[15] - m.elements[0 ]*m.elements[9 ]*m.elements[15]) * detInv\n\tmatrix.elements[10] = (m.elements[4 ]*m.elements[13]*m.elements[3 ] - m.elements[12]*m.elements[5 ]*m.elements[3 ] + m.elements[12]*m.elements[1 ]*m.elements[7 ] - m.elements[0 ]*m.elements[13]*m.elements[7 ] - m.elements[4 ]*m.elements[1 ]*m.elements[15] + m.elements[0 ]*m.elements[5 ]*m.elements[15]) * detInv\n\tmatrix.elements[11] = (m.elements[8 ]*m.elements[5 ]*m.elements[3 ] - m.elements[4 ]*m.elements[9 ]*m.elements[3 ] - m.elements[8 ]*m.elements[1 ]*m.elements[7 ] + m.elements[0 ]*m.elements[9 ]*m.elements[7 ] + m.elements[4 ]*m.elements[1 ]*m.elements[11] - m.elements[0 ]*m.elements[5 ]*m.elements[11]) * detInv\n\n\tmatrix.elements[12] = t14 * detInv\n\tmatrix.elements[13] = (m.elements[8 ]*m.elements[13]*m.elements[2 ] - m.elements[12]*m.elements[9 ]*m.elements[2 ] + m.elements[12]*m.elements[1 ]*m.elements[10] - m.elements[0 ]*m.elements[13]*m.elements[10] - m.elements[8 ]*m.elements[1 ]*m.elements[14] + m.elements[0 ]*m.elements[9 ]*m.elements[14]) * detInv\n\tmatrix.elements[14] = (m.elements[12]*m.elements[5 ]*m.elements[2 ] - m.elements[4 ]*m.elements[13]*m.elements[2 ] - m.elements[12]*m.elements[1 ]*m.elements[6 ] + m.elements[0 ]*m.elements[13]*m.elements[6 ] + m.elements[4 ]*m.elements[1 ]*m.elements[14] - m.elements[0 ]*m.elements[5 ]*m.elements[14]) * detInv\n\tmatrix.elements[15] = (m.elements[4 ]*m.elements[9 ]*m.elements[2 ] - m.elements[8 ]*m.elements[5 ]*m.elements[2 ] + m.elements[8 ]*m.elements[1 ]*m.elements[6 ] - m.elements[0 ]*m.elements[9 ]*m.elements[6 ] - m.elements[4 ]*m.elements[1 ]*m.elements[10] + m.elements[0 ]*m.elements[5 ]*m.elements[10]) * detInv\n\n\treturn nil\n}", "func multiplyStuff(finalMatrix *[][][]int64, matrix1 [][]int64, matrix2 [][]int64, i int) {\n\t(*finalMatrix)[i] = multiply(matrix1, matrix2)\n}" ]
[ "0.5732485", "0.5356076", "0.5254913", "0.5192842", "0.5181406", "0.5163377", "0.5084605", "0.50772196", "0.5072032", "0.49939233", "0.49833703", "0.49668446", "0.4955985", "0.49496877", "0.4901383", "0.48587218", "0.48562086", "0.48518017", "0.48500594", "0.4835069", "0.4813739", "0.4808577", "0.47456998", "0.47390798", "0.47106278", "0.468767", "0.46479946", "0.46433997", "0.46245986", "0.4616785", "0.46098536", "0.4606261", "0.4600743", "0.45869464", "0.457182", "0.45608497", "0.45593742", "0.4555974", "0.45410976", "0.45407304", "0.453422", "0.45311946", "0.45298678", "0.4526793", "0.45196", "0.45129794", "0.45062652", "0.45054027", "0.4501363", "0.44993135", "0.44856936", "0.44794074", "0.44710064", "0.44603178", "0.44496572", "0.4437585", "0.44339782", "0.4432394", "0.44220394", "0.4421854", "0.44191417", "0.44067216", "0.44058317", "0.44010314", "0.43921643", "0.43815005", "0.43782592", "0.4371559", "0.43516216", "0.43444535", "0.4340742", "0.43358192", "0.43339622", "0.43333513", "0.43255827", "0.43238875", "0.43188402", "0.43150932", "0.4307644", "0.43064636", "0.4305898", "0.42979115", "0.42905766", "0.4288188", "0.42864874", "0.42848155", "0.4276517", "0.42739275", "0.427309", "0.42617658", "0.4261106", "0.42586216", "0.4258301", "0.4258259", "0.42577818", "0.42576087", "0.4256537", "0.42520016", "0.42499363", "0.42465648" ]
0.46391928
28
defines a barrier ordering memory transactions
func MemoryBarrier(barriers uint32) { C.glowMemoryBarrier(gpMemoryBarrier, (C.GLbitfield)(barriers)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func MemoryBarrier(barriers uint32) {\n\tsyscall.Syscall(gpMemoryBarrier, 1, uintptr(barriers), 0, 0)\n}", "func MemoryBarrier(barriers uint32) {\n C.glowMemoryBarrier(gpMemoryBarrier, (C.GLbitfield)(barriers))\n}", "func (hm *HM) Barrier(b uint8) {\n\thm.LogDebug(\"Barrier(%d)..Start\", b)\n\tmanager := hm.getBarrierManager(b)\n\t// Only the non-manager processors send out the Barrier Request\n\t// to the manager. The manager is the only node receiving these\n\t// messages.\n\tif hm.pid != manager {\n\t\thm.CreateInterval()\n\t\tlastLt := hm.procArray.GetLatestLocalTimestamp(manager)\n\t\t// get local intervals between lastLt and VC[pid]\n\t\tintervals := hm.procArray.GetProcMissingIntervals(hm.pid, lastLt)\n\t\thm.IncorporateIntervals(intervals)\n\t\thm.sendBarrierRequest(manager, b, &hm.VC, intervals)\n\t} else {\n\t\tintervals := make([]IntervalRec, 0)\n\t\thm.sendBarrierRequest(manager, b, &hm.VC, intervals)\n\t}\n\t<-hm.waitChan\n\thm.LogDebug(\"Barrier(%d)..Done\", b)\n}", "func NewBarrier(seqs ...Sequencer) Barrier {\n\tif len(seqs) == 0 {\n\t\tpanic(\"Barrier should contain at least one sequence\")\n\t}\n\n\toffsets := make([]uint32, 0, len(seqs))\n\tfor _, seq := range seqs {\n\t\toffsets = append(offsets, seq.offset)\n\t}\n\treturn Barrier{\n\t\toffsets: offsets,\n\t}\n}", "func (s *StanServer) barrier(f func()) {\n\ts.nc.Barrier(func() {\n\t\t// Ensure all pending acks are received by the connection\n\t\ts.nca.Flush()\n\t\t// Then ensure that all acks have been processed in processAckMsg callbacks\n\t\t// before executing the closing function.\n\t\ts.nca.Barrier(f)\n\t})\n}", "func gcWriteBarrier(dst *uintptr, src uintptr) {\n\tbuf := &getg().m.p.ptr().wbBuf\n\tif !buf.putFast(src, *dst) {\n\t\twbBufFlush(dst, src)\n\t}\n\t*dst = src\n}", "func TestLockOrdering(t *testing.T){\n\tconn1, err := dlock_client.Connect(\"localhost\", \"8422\")\n\tif err != nil {\n\t\tt.Error(\"Connection error \"+err.Error())\n\t}\n\tconn2, err := dlock_client.Connect(\"localhost\", \"8422\")\n\tif err != nil {\n\t\tt.Error(\"Connection error\")\n\t}\n\n\n\tlimit := 1000\n\tfinish_order := make(chan int, limit)\n\tfor i := 0; i < limit; i++ {\n\t\t_i := i // We want the current i, not the final state of i (limit)\n\n\t\t//Sleep between requests to ensure they're received in the correct order\n\t\ttime.Sleep(2 * time.Millisecond)\n\n\t\tgo func(){\n\t\t\tconn := conn1\n\t\t\tif _i % 2 == 0 {\n\t\t\t\tconn = conn2\n\t\t\t}\n\t\t\tentity := \"entity_\"+strconv.Itoa(_i)\n\t\t\tb := dlock_client.AcquireLock(conn, \"lock_test_order\", entity)\n\t\t\tif b != true {\n\t\t\t\tt.Error(\"Acquire lock failed\")\n\t\t\t}\n\t\t\tfinish_order <- _i\n\t\t\tb = dlock_client.ReleaseLock(conn, \"lock_test_order\", entity)\n\t\t\tif b != true {\n\t\t\t\tt.Error(\"Release lock failed\")\n\t\t\t}\n\t\t}()\n\t}\n\n\tfor i := 0; i < limit; i++ {\n\t\tresult := <- finish_order\n\t\tif result != i {\n\t\t\tt.Error(\"Out of order. Got \"+strconv.Itoa(result)+\", Expected \"+strconv.Itoa(i))\n\t\t}\n\t}\n}", "func (x *XcChaincode) lock(stub shim.ChaincodeStubInterface, args []string) pb.Response {\n\tif len(args) < 3 {\n\t\treturn shim.Error(\"Params Error\")\n\t}\n\t//get operator\n\tsender, err := stub.GetSender()\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t} else if sender == \"\" {\n\t\treturn shim.Error(\"Account not exist\")\n\t}\n\ttoPlatform := strings.ToLower(args[0])\n\ttoAccount := strings.ToLower(args[1])\n\tamount := big.NewInt(0)\n\t_, ok := amount.SetString(args[2], 10)\n\tif !ok {\n\t\treturn shim.Error(\"Expecting integer value for amount\")\n\t}\n\n\t//try to get state from book which key is variable toPlatform's value\n\tplatState, err := stub.GetState(toPlatform)\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to get platform: \" + err.Error())\n\t} else if platState == nil {\n\t\treturn shim.Error(\"The platform named \" + toPlatform + \" is not registered\")\n\t}\n\n\t//set txId to be key\n\tkey := stub.GetTxID()\n\t//do transfer\n\terr = stub.Transfer(x.tacTokenAddr, \"TAB\", amount)\n\tif err != nil {\n\t\treturn shim.Error(\"Transfer error \" + err.Error())\n\t}\n\ttxTimestamp, err := stub.GetTxTimestamp()\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t}\n\ttimeStr := fmt.Sprintf(\"%d\", txTimestamp.GetSeconds())\n\t//build turn out state\n\tstate := x.buildTurnOutMessage(sender, toPlatform, toAccount, amount, timeStr)\n\terr = stub.PutState(key, state)\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t}\n\t//build composite key\n\tindexName := \"type~address~datetime~platform~key\"\n\tindexKey, err := stub.CreateCompositeKey(indexName, []string{\"out\", sender, timeStr, x.platName, key})\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t}\n\tvalue := []byte{0x00}\n\tstub.PutState(indexKey, value)\n\n\t//sign\n\tsignJson, err := x.signJson([]byte(\"abc\"), \"60320b8a71bc314404ef7d194ad8cac0bee1e331\")\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t}\n\treturn shim.Success(signJson)\n}", "func TextureBarrier() {\n\tsyscall.Syscall(gpTextureBarrier, 0, 0, 0, 0)\n}", "func (b *OGame) Tx(clb func(tx Prioritizable) error) error {\n\treturn b.WithPriority(taskRunner.Normal).Tx(clb)\n}", "func TestContractSet(t *testing.T) {\n\tif testing.Short() {\n\t\tt.SkipNow()\n\t}\n\tt.Parallel()\n\t// create contract set\n\ttestDir := build.TempDir(t.Name())\n\trl := ratelimit.NewRateLimit(0, 0, 0)\n\tcs, err := NewContractSet(testDir, rl, modules.ProdDependencies)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\theader1 := contractHeader{Transaction: types.Transaction{\n\t\tFileContractRevisions: []types.FileContractRevision{{\n\t\t\tParentID: types.FileContractID{1},\n\t\t\tNewValidProofOutputs: []types.SiacoinOutput{{}, {}},\n\t\t\tUnlockConditions: types.UnlockConditions{\n\t\t\t\tPublicKeys: []types.SiaPublicKey{{}, {}},\n\t\t\t},\n\t\t}},\n\t}}\n\theader2 := contractHeader{Transaction: types.Transaction{\n\t\tFileContractRevisions: []types.FileContractRevision{{\n\t\t\tParentID: types.FileContractID{2},\n\t\t\tNewValidProofOutputs: []types.SiacoinOutput{{}, {}},\n\t\t\tUnlockConditions: types.UnlockConditions{\n\t\t\t\tPublicKeys: []types.SiaPublicKey{{}, {}},\n\t\t\t},\n\t\t}},\n\t}}\n\tid1 := header1.ID()\n\tid2 := header2.ID()\n\n\t_, err = cs.managedInsertContract(header1, []crypto.Hash{})\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\t_, err = cs.managedInsertContract(header2, []crypto.Hash{})\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// uncontested acquire/release\n\tc1 := cs.managedMustAcquire(t, id1)\n\tcs.Return(c1)\n\n\t// 100 concurrent serialized mutations\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < 100; i++ {\n\t\twg.Add(1)\n\t\tgo func() {\n\t\t\tdefer wg.Done()\n\t\t\tc1 := cs.managedMustAcquire(t, id1)\n\t\t\tc1.header.Transaction.FileContractRevisions[0].NewRevisionNumber++\n\t\t\ttime.Sleep(time.Duration(fastrand.Intn(100)))\n\t\t\tcs.Return(c1)\n\t\t}()\n\t}\n\twg.Wait()\n\tc1 = cs.managedMustAcquire(t, id1)\n\tcs.Return(c1)\n\tif c1.header.LastRevision().NewRevisionNumber != 100 {\n\t\tt.Fatal(\"expected exactly 100 increments, got\", c1.header.LastRevision().NewRevisionNumber)\n\t}\n\n\t// a blocked acquire shouldn't prevent a return\n\tc1 = cs.managedMustAcquire(t, id1)\n\tgo func() {\n\t\ttime.Sleep(time.Millisecond)\n\t\tcs.Return(c1)\n\t}()\n\tc1 = cs.managedMustAcquire(t, id1)\n\tcs.Return(c1)\n\n\t// delete and reinsert id2\n\tc2 := cs.managedMustAcquire(t, id2)\n\tcs.Delete(c2)\n\troots, err := c2.merkleRoots.merkleRoots()\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tcs.managedInsertContract(c2.header, roots)\n\n\t// call all the methods in parallel haphazardly\n\tfuncs := []func(){\n\t\tfunc() { cs.Len() },\n\t\tfunc() { cs.IDs() },\n\t\tfunc() { cs.View(id1); cs.View(id2) },\n\t\tfunc() { cs.ViewAll() },\n\t\tfunc() { cs.Return(cs.managedMustAcquire(t, id1)) },\n\t\tfunc() { cs.Return(cs.managedMustAcquire(t, id2)) },\n\t\tfunc() {\n\t\t\theader3 := contractHeader{\n\t\t\t\tTransaction: types.Transaction{\n\t\t\t\t\tFileContractRevisions: []types.FileContractRevision{{\n\t\t\t\t\t\tParentID: types.FileContractID{3},\n\t\t\t\t\t\tNewValidProofOutputs: []types.SiacoinOutput{{}, {}},\n\t\t\t\t\t\tUnlockConditions: types.UnlockConditions{\n\t\t\t\t\t\t\tPublicKeys: []types.SiaPublicKey{{}, {}},\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\tid3 := header3.ID()\n\t\t\t_, err := cs.managedInsertContract(header3, []crypto.Hash{})\n\t\t\tif err != nil {\n\t\t\t\tt.Fatal(err)\n\t\t\t}\n\t\t\tc3 := cs.managedMustAcquire(t, id3)\n\t\t\tcs.Delete(c3)\n\t\t},\n\t}\n\twg = sync.WaitGroup{}\n\tfor _, fn := range funcs {\n\t\twg.Add(1)\n\t\tgo func(fn func()) {\n\t\t\tdefer wg.Done()\n\t\t\tfor i := 0; i < 100; i++ {\n\t\t\t\ttime.Sleep(time.Duration(fastrand.Intn(100)))\n\t\t\t\tfn()\n\t\t\t}\n\t\t}(fn)\n\t}\n\twg.Wait()\n}", "func NewBarrier() *Barrier {\n\treturn &Barrier{}\n}", "func (tx *batch) CmpAndSwap(bucket, key, value []byte) {\n\ttx.Operations = append(tx.Operations, &TxnEntry{\n\t\tTimestamp: tx.Timestamp,\n\t\tBatchId: tx.Id,\n\t\tBucket: bucket,\n\t\tKey: key,\n\t\tValue: value,\n\t\tCmd: CmpAndSwap,\n\t})\n}", "func TestContractSet(t *testing.T) {\n\t// create contract set\n\tc1 := &SafeContract{header: contractHeader{Transaction: types.Transaction{\n\t\tFileContractRevisions: []types.FileContractRevision{{\n\t\t\tParentID: types.FileContractID{1},\n\t\t\tNewValidProofOutputs: []types.SiacoinOutput{{}, {}},\n\t\t\tUnlockConditions: types.UnlockConditions{\n\t\t\t\tPublicKeys: []types.SiaPublicKey{{}, {}},\n\t\t\t},\n\t\t}},\n\t}}}\n\tid1 := c1.header.ID()\n\tc2 := &SafeContract{header: contractHeader{Transaction: types.Transaction{\n\t\tFileContractRevisions: []types.FileContractRevision{{\n\t\t\tParentID: types.FileContractID{2},\n\t\t\tNewValidProofOutputs: []types.SiacoinOutput{{}, {}},\n\t\t\tUnlockConditions: types.UnlockConditions{\n\t\t\t\tPublicKeys: []types.SiaPublicKey{{}, {}},\n\t\t\t},\n\t\t}},\n\t}}}\n\tid2 := c2.header.ID()\n\tcs := &ContractSet{\n\t\tcontracts: map[types.FileContractID]*SafeContract{\n\t\t\tid1: c1,\n\t\t\tid2: c2,\n\t\t},\n\t}\n\n\t// uncontested acquire/release\n\tc1 = cs.mustAcquire(t, id1)\n\tcs.Return(c1)\n\n\t// 100 concurrent serialized mutations\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < 100; i++ {\n\t\twg.Add(1)\n\t\tgo func() {\n\t\t\tdefer wg.Done()\n\t\t\tc1 := cs.mustAcquire(t, id1)\n\t\t\tc1.header.Transaction.FileContractRevisions[0].NewRevisionNumber++\n\t\t\ttime.Sleep(time.Duration(fastrand.Intn(100)))\n\t\t\tcs.Return(c1)\n\t\t}()\n\t}\n\twg.Wait()\n\tc1 = cs.mustAcquire(t, id1)\n\tcs.Return(c1)\n\tif c1.header.LastRevision().NewRevisionNumber != 100 {\n\t\tt.Fatal(\"expected exactly 100 increments, got\", c1.header.LastRevision().NewRevisionNumber)\n\t}\n\n\t// a blocked acquire shouldn't prevent a return\n\tc1 = cs.mustAcquire(t, id1)\n\tgo func() {\n\t\ttime.Sleep(time.Millisecond)\n\t\tcs.Return(c1)\n\t}()\n\tc1 = cs.mustAcquire(t, id1)\n\tcs.Return(c1)\n\n\t// delete and reinsert id2\n\tc2 = cs.mustAcquire(t, id2)\n\tcs.Delete(c2)\n\tcs.mu.Lock()\n\tcs.contracts[id2] = c2\n\tcs.mu.Unlock()\n\n\t// call all the methods in parallel haphazardly\n\tfuncs := []func(){\n\t\tfunc() { cs.Len() },\n\t\tfunc() { cs.IDs() },\n\t\tfunc() { cs.View(id1); cs.View(id2) },\n\t\tfunc() { cs.ViewAll() },\n\t\tfunc() { cs.Return(cs.mustAcquire(t, id1)) },\n\t\tfunc() { cs.Return(cs.mustAcquire(t, id2)) },\n\t\tfunc() {\n\t\t\tc3 := &SafeContract{header: contractHeader{\n\t\t\t\tTransaction: types.Transaction{\n\t\t\t\t\tFileContractRevisions: []types.FileContractRevision{{\n\t\t\t\t\t\tParentID: types.FileContractID{3},\n\t\t\t\t\t\tNewValidProofOutputs: []types.SiacoinOutput{{}, {}},\n\t\t\t\t\t\tUnlockConditions: types.UnlockConditions{\n\t\t\t\t\t\t\tPublicKeys: []types.SiaPublicKey{{}, {}},\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\tid3 := c3.header.ID()\n\t\t\tcs.mu.Lock()\n\t\t\tcs.contracts[id3] = c3\n\t\t\tcs.mu.Unlock()\n\t\t\tcs.mustAcquire(t, id3)\n\t\t\tcs.Delete(c3)\n\t\t},\n\t}\n\twg = sync.WaitGroup{}\n\tfor _, fn := range funcs {\n\t\twg.Add(1)\n\t\tgo func(fn func()) {\n\t\t\tdefer wg.Done()\n\t\t\tfor i := 0; i < 100; i++ {\n\t\t\t\ttime.Sleep(time.Duration(fastrand.Intn(100)))\n\t\t\t\tfn()\n\t\t\t}\n\t\t}(fn)\n\t}\n\twg.Wait()\n}", "func Synchronize(onlineIds, activeIds []int) {\n\tif len(onlineIds) == 0 {\n\t\treturn\n\t}\n\tfor f := 0; f < def.FloorCount; f++ {\n\t\tfor b := driver.ButtonType(0); b < def.ButtonCount; b++ {\n\t\t\tif b == driver.BT_Cab {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tswitch om.GetOrders(def.LocalId).GetStatus(f, b) {\n\t\t\tcase om.OS_Empty:\n\t\t\t\tif anyRemoving(onlineIds, f, b) {\n\t\t\t\t\t// do nothing\n\t\t\t\t} else if anyCompleted(onlineIds, f, b) { // an order has been completed\n\t\t\t\t\tsetStatus(om.OS_Completed, f, b)\n\t\t\t\t} else if anyExisting(onlineIds, f, b) { // there exists an order which we don't know about and want to add to our orders\n\t\t\t\t\tif owner := getOwner(onlineIds, f, b); owner >= 0 {\n\t\t\t\t\t\taddOrderWithOwner(f, b, owner)\n\t\t\t\t\t} else {\n\t\t\t\t\t\taddOrder(f, b)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\tcase om.OS_Existing:\n\t\t\t\tif anyRemoving(onlineIds, f, b) { // the order has been completed\n\t\t\t\t\tsetStatus(om.OS_Removing, f, b)\n\t\t\t\t} else if anyCompleted(onlineIds, f, b) { // the order has been completed\n\t\t\t\t\tsetStatus(om.OS_Completed, f, b)\n\t\t\t\t} else if anyExisting(onlineIds, f, b) && om.GetOrders(def.LocalId).GetOwner(f, b) < 0 { // set owner if any or we should take it ourselves\n\t\t\t\t\tif owner := getOwner(onlineIds, f, b); owner >= 0 {\n\t\t\t\t\t\tsetOwner(f, b, owner)\n\t\t\t\t\t} else if shouldTakeOrder(f, b, onlineIds, activeIds) {\n\t\t\t\t\t\ttakeOrder(f, b)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\tcase om.OS_Completed:\n\t\t\t\tif !anyExisting(onlineIds, f, b) && !anyEmpty(onlineIds, f, b) { // if everyone agrees the order is completed, start removing\n\t\t\t\t\tsetStatus(om.OS_Removing, f, b)\n\t\t\t\t}\n\t\t\tcase om.OS_Removing:\n\t\t\t\tif !anyExisting(onlineIds, f, b) && !anyCompleted(onlineIds, f, b) { // if everyone is ready to remove, remove\n\t\t\t\t\tsetStatus(om.OS_Empty, f, b)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func (tangle *Tangle) setupDAGSynchronization() {\n\ttangle.branchManager.Events.BranchPreferred.Attach(events.NewClosure(tangle.onBranchPreferred))\n\ttangle.branchManager.Events.BranchUnpreferred.Attach(events.NewClosure(tangle.onBranchUnpreferred))\n\ttangle.branchManager.Events.BranchLiked.Attach(events.NewClosure(tangle.onBranchLiked))\n\ttangle.branchManager.Events.BranchDisliked.Attach(events.NewClosure(tangle.onBranchDisliked))\n\ttangle.branchManager.Events.BranchFinalized.Attach(events.NewClosure(tangle.onBranchFinalized))\n\ttangle.branchManager.Events.BranchConfirmed.Attach(events.NewClosure(tangle.onBranchConfirmed))\n\ttangle.branchManager.Events.BranchRejected.Attach(events.NewClosure(tangle.onBranchRejected))\n}", "func (m *Measure) preBarrier(t time.Time) {\n\tm.preRunners = append(m.preRunners, Runner{PreTime: t})\n\tfmt.Printf(\"Now there is %v runners qualifying\\n\", len(m.preRunners))\n\tfmt.Printf(\"Now there is %v runners running\\n\", len(m.runners))\n\n}", "func (m *cmap) lock_in_order(bins ...int) {\n\tlocks := make([]int, len(bins))\n\tfor i := range bins {\n\t\tlocks[i] = bins[i]\n\t}\n\n\tsort.Ints(locks)\n\tlast := -1\n\tfor _, bin := range locks {\n\t\tif bin != last {\n\t\t\tm.bins[bin].mx.Lock()\n\t\t\tlast = bin\n\t\t}\n\t}\n}", "func (_Onesplitaudit *OnesplitauditTransactor) Swap(opts *bind.TransactOpts, fromToken common.Address, toToken common.Address, amount *big.Int, minReturn *big.Int, distribution []*big.Int, featureFlags *big.Int) (*types.Transaction, error) {\n\treturn _Onesplitaudit.contract.Transact(opts, \"swap\", fromToken, toToken, amount, minReturn, distribution, featureFlags)\n}", "func TestMemTombstonesConcurrency(t *testing.T) {\n\ttomb := NewMemTombstones()\n\ttotalRuns := 100\n\tvar wg sync.WaitGroup\n\twg.Add(2)\n\n\tgo func() {\n\t\tfor x := 0; x < totalRuns; x++ {\n\t\t\ttomb.AddInterval(storage.SeriesRef(x), Interval{int64(x), int64(x)})\n\t\t}\n\t\twg.Done()\n\t}()\n\tgo func() {\n\t\tfor x := 0; x < totalRuns; x++ {\n\t\t\t_, err := tomb.Get(storage.SeriesRef(x))\n\t\t\trequire.NoError(t, err)\n\t\t}\n\t\twg.Done()\n\t}()\n\twg.Wait()\n}", "func TestContendedIntentWithDependencyCycle(t *testing.T) {\n\tdefer leaktest.AfterTest(t)()\n\tdefer log.Scope(t).Close(t)\n\tctx := context.Background()\n\tstopper := stop.NewStopper()\n\tdefer stopper.Stop(ctx)\n\tstore, _ := createTestStore(t, testStoreOpts{createSystemRanges: true}, stopper)\n\n\tkeyA := roachpb.Key(\"a\")\n\tkeyB := roachpb.Key(\"b\")\n\tspanA := roachpb.Span{Key: keyA}\n\tspanB := roachpb.Span{Key: keyB}\n\n\t// Create the three transactions; at this point, none of them have\n\t// conflicts. Txn1 has written \"b\", Txn3 has written \"a\".\n\ttxn1 := beginTransaction(t, store, -3, keyB, true /* putKey */)\n\ttxn2 := beginTransaction(t, store, -2, keyB, false /* putKey */)\n\ttxn3 := beginTransaction(t, store, -1, keyA, true /* putKey */)\n\n\t// Send txn1 put, followed by an end transaction.\n\ttxnCh1 := make(chan error, 1)\n\tgo func() {\n\t\tput := putArgs(keyA, []byte(\"value\"))\n\t\tassignSeqNumsForReqs(txn1, &put)\n\t\tif _, pErr := kv.SendWrappedWith(ctx, store.TestSender(), roachpb.Header{Txn: txn1}, &put); pErr != nil {\n\t\t\ttxnCh1 <- pErr.GoError()\n\t\t\treturn\n\t\t}\n\n\t\tet, h := endTxnArgs(txn1, true)\n\t\tet.LockSpans = []roachpb.Span{spanA, spanB}\n\t\tassignSeqNumsForReqs(txn1, &et)\n\t\th.CanForwardReadTimestamp = true\n\t\t_, pErr := kv.SendWrappedWith(ctx, store.TestSender(), h, &et)\n\t\ttxnCh1 <- pErr.GoError()\n\t}()\n\n\t// Send a non-transactional read to keyB. This adds an early waiter\n\t// to the intent resolver on keyB which txn2 must skip in order to\n\t// properly register itself as a dependency by pushing txn1.\n\treadCh1 := make(chan error, 1)\n\tgo func() {\n\t\tget := getArgs(keyB)\n\t\t_, pErr := kv.SendWrapped(ctx, store.TestSender(), &get)\n\t\treadCh1 <- pErr.GoError()\n\t}()\n\n\t// Send txn2 put, followed by an end transaction.\n\ttxnCh2 := make(chan error, 1)\n\tgo func() {\n\t\tput := putArgs(keyB, []byte(\"value\"))\n\t\tassignSeqNumsForReqs(txn2, &put)\n\t\trepl, pErr := kv.SendWrappedWith(ctx, store.TestSender(), roachpb.Header{Txn: txn2}, &put)\n\t\tif pErr != nil {\n\t\t\ttxnCh2 <- pErr.GoError()\n\t\t\treturn\n\t\t}\n\n\t\ttxn2Copy := *repl.Header().Txn\n\t\ttxn2 = &txn2Copy\n\t\tet, h := endTxnArgs(txn2, true)\n\t\tet.LockSpans = []roachpb.Span{spanB}\n\t\tassignSeqNumsForReqs(txn2, &et)\n\t\th.CanForwardReadTimestamp = true\n\t\t_, pErr = kv.SendWrappedWith(ctx, store.TestSender(), h, &et)\n\t\ttxnCh2 <- pErr.GoError()\n\t}()\n\n\t// Send another non-transactional read to keyB to add a waiter in\n\t// between txn2 and txn3. Txn3 must wait on txn2, instead of getting\n\t// queued behind this reader, in order to establish the dependency cycle.\n\treadCh2 := make(chan error, 1)\n\tgo func() {\n\t\tget := getArgs(keyB)\n\t\t_, pErr := kv.SendWrapped(ctx, store.TestSender(), &get)\n\t\treadCh2 <- pErr.GoError()\n\t}()\n\n\t// Send txn3. Pause for 10ms to make it more likely that we have a\n\t// dependency cycle of length 3, although we don't mind testing\n\t// either way.\n\ttime.Sleep(10 * time.Millisecond)\n\ttxnCh3 := make(chan error, 1)\n\tgo func() {\n\t\tput := putArgs(keyB, []byte(\"value\"))\n\t\tassignSeqNumsForReqs(txn3, &put)\n\t\t_, pErr := kv.SendWrappedWith(ctx, store.TestSender(), roachpb.Header{Txn: txn3}, &put)\n\t\ttxnCh3 <- pErr.GoError()\n\t}()\n\n\t// The third transaction will always be aborted.\n\terr := <-txnCh3\n\tif !errors.HasType(err, (*roachpb.UnhandledRetryableError)(nil)) {\n\t\tt.Fatalf(\"expected transaction aborted error; got %T\", err)\n\t}\n\tif err := <-txnCh1; err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif err := <-txnCh2; err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif err := <-readCh1; err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif err := <-readCh2; err != nil {\n\t\tt.Fatal(err)\n\t}\n}", "func TestCommitConflictRace4A(t *testing.T) {\n}", "func NewBarrier(n int) *Barrier {\n\tif n <= 0 {\n\t\tpanic(\"Group must be >= 1\")\n\t}\n\n\tb := &Barrier{0, n, make(chan bool, n), make(chan bool, n)}\n\n\tgo controller(b)\n\n\treturn b\n}", "func CMPXCHG8B(m operand.Op) { ctx.CMPXCHG8B(m) }", "func XlaOptimizationBarrier(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: \"XlaOptimizationBarrier\",\n\t\tInput: []tf.Input{\n\t\t\ttf.OutputList(input),\n\t\t},\n\t}\n\top := scope.AddOperation(opspec)\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tvar idx int\n\tvar err error\n\tif output, idx, err = makeOutputList(op, idx, \"output\"); err != nil {\n\t\tscope.UpdateErr(\"XlaOptimizationBarrier\", err)\n\t\treturn\n\t}\n\treturn output\n}", "func (s *BasevhdlListener) EnterBranch_quantity_declaration(ctx *Branch_quantity_declarationContext) {\n}", "func TestConcurrencyManagerBasic(t *testing.T) {\n\tdefer leaktest.AfterTest(t)()\n\tdefer log.Scope(t).Close(t)\n\n\tdatadriven.Walk(t, \"testdata/concurrency_manager\", func(t *testing.T, path string) {\n\t\tc := newCluster()\n\t\tc.enableTxnPushes()\n\t\tm := concurrency.NewManager(c.makeConfig())\n\t\tm.OnRangeLeaseUpdated(1, true /* isLeaseholder */) // enable\n\t\tc.m = m\n\t\tmon := newMonitor()\n\t\tdatadriven.RunTest(t, path, func(t *testing.T, d *datadriven.TestData) string {\n\t\t\tswitch d.Cmd {\n\t\t\tcase \"new-txn\":\n\t\t\t\tvar txnName string\n\t\t\t\td.ScanArgs(t, \"name\", &txnName)\n\t\t\t\tts := scanTimestamp(t, d)\n\n\t\t\t\tvar epoch int\n\t\t\t\td.ScanArgs(t, \"epoch\", &epoch)\n\n\t\t\t\tuncertaintyLimit := ts\n\t\t\t\tif d.HasArg(\"uncertainty-limit\") {\n\t\t\t\t\tuncertaintyLimit = scanTimestampWithName(t, d, \"uncertainty-limit\")\n\t\t\t\t}\n\n\t\t\t\ttxn, ok := c.txnsByName[txnName]\n\t\t\t\tvar id uuid.UUID\n\t\t\t\tif ok {\n\t\t\t\t\tid = txn.ID\n\t\t\t\t} else {\n\t\t\t\t\tid = c.newTxnID()\n\t\t\t\t}\n\t\t\t\ttxn = &roachpb.Transaction{\n\t\t\t\t\tTxnMeta: enginepb.TxnMeta{\n\t\t\t\t\t\tID: id,\n\t\t\t\t\t\tEpoch: enginepb.TxnEpoch(epoch),\n\t\t\t\t\t\tWriteTimestamp: ts,\n\t\t\t\t\t\tMinTimestamp: ts,\n\t\t\t\t\t\tPriority: 1, // not min or max\n\t\t\t\t\t},\n\t\t\t\t\tReadTimestamp: ts,\n\t\t\t\t\tGlobalUncertaintyLimit: uncertaintyLimit,\n\t\t\t\t}\n\t\t\t\tc.registerTxn(txnName, txn)\n\t\t\t\treturn \"\"\n\n\t\t\tcase \"new-request\":\n\t\t\t\tvar reqName string\n\t\t\t\td.ScanArgs(t, \"name\", &reqName)\n\t\t\t\tif _, ok := c.requestsByName[reqName]; ok {\n\t\t\t\t\td.Fatalf(t, \"duplicate request: %s\", reqName)\n\t\t\t\t}\n\n\t\t\t\tvar txnName string\n\t\t\t\td.ScanArgs(t, \"txn\", &txnName)\n\t\t\t\ttxn, ok := c.txnsByName[txnName]\n\t\t\t\tif !ok && txnName != \"none\" {\n\t\t\t\t\td.Fatalf(t, \"unknown txn %s\", txnName)\n\t\t\t\t}\n\n\t\t\t\tts := scanTimestamp(t, d)\n\t\t\t\tif txn != nil {\n\t\t\t\t\ttxn = txn.Clone()\n\t\t\t\t\ttxn.ReadTimestamp = ts\n\t\t\t\t\ttxn.WriteTimestamp = ts\n\t\t\t\t}\n\n\t\t\t\treadConsistency := roachpb.CONSISTENT\n\t\t\t\tif d.HasArg(\"inconsistent\") {\n\t\t\t\t\treadConsistency = roachpb.INCONSISTENT\n\t\t\t\t}\n\n\t\t\t\twaitPolicy := scanWaitPolicy(t, d, false /* required */)\n\n\t\t\t\t// Each roachpb.Request is provided on an indented line.\n\t\t\t\tvar reqs []roachpb.Request\n\t\t\t\tsingleReqLines := strings.Split(d.Input, \"\\n\")\n\t\t\t\tfor _, line := range singleReqLines {\n\t\t\t\t\treq := scanSingleRequest(t, d, line, c.txnsByName)\n\t\t\t\t\treqs = append(reqs, req)\n\t\t\t\t}\n\t\t\t\treqUnions := make([]roachpb.RequestUnion, len(reqs))\n\t\t\t\tfor i, req := range reqs {\n\t\t\t\t\treqUnions[i].MustSetInner(req)\n\t\t\t\t}\n\t\t\t\tlatchSpans, lockSpans := c.collectSpans(t, txn, ts, reqs)\n\n\t\t\t\tc.requestsByName[reqName] = testReq{\n\t\t\t\t\tRequest: concurrency.Request{\n\t\t\t\t\t\tTxn: txn,\n\t\t\t\t\t\tTimestamp: ts,\n\t\t\t\t\t\t// TODO(nvanbenschoten): test Priority\n\t\t\t\t\t\tReadConsistency: readConsistency,\n\t\t\t\t\t\tWaitPolicy: waitPolicy,\n\t\t\t\t\t\tRequests: reqUnions,\n\t\t\t\t\t\tLatchSpans: latchSpans,\n\t\t\t\t\t\tLockSpans: lockSpans,\n\t\t\t\t\t}}\n\t\t\t\treturn \"\"\n\n\t\t\tcase \"sequence\":\n\t\t\t\tvar reqName string\n\t\t\t\td.ScanArgs(t, \"req\", &reqName)\n\t\t\t\treq, ok := c.requestsByName[reqName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown request: %s\", reqName)\n\t\t\t\t}\n\n\t\t\t\tc.mu.Lock()\n\t\t\t\tprev := c.guardsByReqName[reqName]\n\t\t\t\tdelete(c.guardsByReqName, reqName)\n\t\t\t\tc.mu.Unlock()\n\n\t\t\t\topName := fmt.Sprintf(\"sequence %s\", reqName)\n\t\t\t\tcancel := mon.runAsync(opName, func(ctx context.Context) {\n\t\t\t\t\tguard, resp, err := m.SequenceReq(ctx, prev, req.Request)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tlog.Eventf(ctx, \"sequencing complete, returned error: %v\", err)\n\t\t\t\t\t} else if resp != nil {\n\t\t\t\t\t\tlog.Eventf(ctx, \"sequencing complete, returned response: %v\", resp)\n\t\t\t\t\t} else if guard != nil {\n\t\t\t\t\t\tlog.Event(ctx, \"sequencing complete, returned guard\")\n\t\t\t\t\t\tc.mu.Lock()\n\t\t\t\t\t\tc.guardsByReqName[reqName] = guard\n\t\t\t\t\t\tc.mu.Unlock()\n\t\t\t\t\t} else {\n\t\t\t\t\t\tlog.Event(ctx, \"sequencing complete, returned no guard\")\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t\treq.cancel = cancel\n\t\t\t\tc.requestsByName[reqName] = req\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"finish\":\n\t\t\t\tvar reqName string\n\t\t\t\td.ScanArgs(t, \"req\", &reqName)\n\t\t\t\tguard, ok := c.guardsByReqName[reqName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown request: %s\", reqName)\n\t\t\t\t}\n\n\t\t\t\topName := fmt.Sprintf(\"finish %s\", reqName)\n\t\t\t\tmon.runSync(opName, func(ctx context.Context) {\n\t\t\t\t\tlog.Event(ctx, \"finishing request\")\n\t\t\t\t\tm.FinishReq(guard)\n\t\t\t\t\tc.mu.Lock()\n\t\t\t\t\tdelete(c.guardsByReqName, reqName)\n\t\t\t\t\tc.mu.Unlock()\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"handle-write-intent-error\":\n\t\t\t\tvar reqName string\n\t\t\t\td.ScanArgs(t, \"req\", &reqName)\n\t\t\t\tprev, ok := c.guardsByReqName[reqName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown request: %s\", reqName)\n\t\t\t\t}\n\n\t\t\t\tvar leaseSeq int\n\t\t\t\td.ScanArgs(t, \"lease-seq\", &leaseSeq)\n\n\t\t\t\t// Each roachpb.Intent is provided on an indented line.\n\t\t\t\tvar intents []roachpb.Intent\n\t\t\t\tsingleReqLines := strings.Split(d.Input, \"\\n\")\n\t\t\t\tfor _, line := range singleReqLines {\n\t\t\t\t\tvar err error\n\t\t\t\t\td.Cmd, d.CmdArgs, err = datadriven.ParseLine(line)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\td.Fatalf(t, \"error parsing single intent: %v\", err)\n\t\t\t\t\t}\n\t\t\t\t\tif d.Cmd != \"intent\" {\n\t\t\t\t\t\td.Fatalf(t, \"expected \\\"intent\\\", found %s\", d.Cmd)\n\t\t\t\t\t}\n\n\t\t\t\t\tvar txnName string\n\t\t\t\t\td.ScanArgs(t, \"txn\", &txnName)\n\t\t\t\t\ttxn, ok := c.txnsByName[txnName]\n\t\t\t\t\tif !ok {\n\t\t\t\t\t\td.Fatalf(t, \"unknown txn %s\", txnName)\n\t\t\t\t\t}\n\n\t\t\t\t\tvar key string\n\t\t\t\t\td.ScanArgs(t, \"key\", &key)\n\n\t\t\t\t\tintents = append(intents, roachpb.MakeIntent(&txn.TxnMeta, roachpb.Key(key)))\n\t\t\t\t}\n\n\t\t\t\topName := fmt.Sprintf(\"handle write intent error %s\", reqName)\n\t\t\t\tmon.runAsync(opName, func(ctx context.Context) {\n\t\t\t\t\tseq := roachpb.LeaseSequence(leaseSeq)\n\t\t\t\t\twiErr := &roachpb.WriteIntentError{Intents: intents}\n\t\t\t\t\tguard, err := m.HandleWriterIntentError(ctx, prev, seq, wiErr)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tlog.Eventf(ctx, \"handled %v, returned error: %v\", wiErr, err)\n\t\t\t\t\t\tc.mu.Lock()\n\t\t\t\t\t\tdelete(c.guardsByReqName, reqName)\n\t\t\t\t\t\tc.mu.Unlock()\n\t\t\t\t\t} else {\n\t\t\t\t\t\tlog.Eventf(ctx, \"handled %v, released latches\", wiErr)\n\t\t\t\t\t\tc.mu.Lock()\n\t\t\t\t\t\tc.guardsByReqName[reqName] = guard\n\t\t\t\t\t\tc.mu.Unlock()\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-lock-acquired\":\n\t\t\t\tvar reqName string\n\t\t\t\td.ScanArgs(t, \"req\", &reqName)\n\t\t\t\tguard, ok := c.guardsByReqName[reqName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown request: %s\", reqName)\n\t\t\t\t}\n\t\t\t\ttxn := guard.Req.Txn\n\n\t\t\t\tvar key string\n\t\t\t\td.ScanArgs(t, \"key\", &key)\n\n\t\t\t\tvar seq int\n\t\t\t\tif d.HasArg(\"seq\") {\n\t\t\t\t\td.ScanArgs(t, \"seq\", &seq)\n\t\t\t\t}\n\t\t\t\tseqNum := enginepb.TxnSeq(seq)\n\n\t\t\t\tdur := lock.Unreplicated\n\t\t\t\tif d.HasArg(\"dur\") {\n\t\t\t\t\tdur = scanLockDurability(t, d)\n\t\t\t\t}\n\n\t\t\t\t// Confirm that the request has a corresponding write request.\n\t\t\t\tfound := false\n\t\t\t\tfor _, ru := range guard.Req.Requests {\n\t\t\t\t\treq := ru.GetInner()\n\t\t\t\t\tkeySpan := roachpb.Span{Key: roachpb.Key(key)}\n\t\t\t\t\tif roachpb.IsLocking(req) &&\n\t\t\t\t\t\treq.Header().Span().Contains(keySpan) &&\n\t\t\t\t\t\treq.Header().Sequence == seqNum {\n\t\t\t\t\t\tfound = true\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif !found {\n\t\t\t\t\td.Fatalf(t, \"missing corresponding write request\")\n\t\t\t\t}\n\n\t\t\t\ttxnAcquire := txn.Clone()\n\t\t\t\ttxnAcquire.Sequence = seqNum\n\n\t\t\t\tmon.runSync(\"acquire lock\", func(ctx context.Context) {\n\t\t\t\t\tlog.Eventf(ctx, \"txn %s @ %s\", txn.ID.Short(), key)\n\t\t\t\t\tacq := roachpb.MakeLockAcquisition(txnAcquire, roachpb.Key(key), dur)\n\t\t\t\t\tm.OnLockAcquired(ctx, &acq)\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-lock-updated\":\n\t\t\t\tvar reqName string\n\t\t\t\td.ScanArgs(t, \"req\", &reqName)\n\t\t\t\tguard, ok := c.guardsByReqName[reqName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown request: %s\", reqName)\n\t\t\t\t}\n\n\t\t\t\tvar txnName string\n\t\t\t\td.ScanArgs(t, \"txn\", &txnName)\n\t\t\t\ttxn, ok := c.txnsByName[txnName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown txn %s\", txnName)\n\t\t\t\t}\n\n\t\t\t\tvar key string\n\t\t\t\td.ScanArgs(t, \"key\", &key)\n\n\t\t\t\tstatus, verb := scanTxnStatus(t, d)\n\t\t\t\tvar ts hlc.Timestamp\n\t\t\t\tif d.HasArg(\"ts\") {\n\t\t\t\t\tts = scanTimestamp(t, d)\n\t\t\t\t}\n\n\t\t\t\t// Confirm that the request has a corresponding ResolveIntent.\n\t\t\t\tfound := false\n\t\t\t\tfor _, ru := range guard.Req.Requests {\n\t\t\t\t\tif riReq := ru.GetResolveIntent(); riReq != nil &&\n\t\t\t\t\t\triReq.IntentTxn.ID == txn.ID &&\n\t\t\t\t\t\triReq.Key.Equal(roachpb.Key(key)) &&\n\t\t\t\t\t\triReq.Status == status {\n\t\t\t\t\t\tfound = true\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif !found {\n\t\t\t\t\td.Fatalf(t, \"missing corresponding resolve intent request\")\n\t\t\t\t}\n\n\t\t\t\ttxnUpdate := txn.Clone()\n\t\t\t\ttxnUpdate.Status = status\n\t\t\t\ttxnUpdate.WriteTimestamp.Forward(ts)\n\n\t\t\t\tmon.runSync(\"update lock\", func(ctx context.Context) {\n\t\t\t\t\tlog.Eventf(ctx, \"%s txn %s @ %s\", verb, txn.ID.Short(), key)\n\t\t\t\t\tspan := roachpb.Span{Key: roachpb.Key(key)}\n\t\t\t\t\tup := roachpb.MakeLockUpdate(txnUpdate, span)\n\t\t\t\t\tm.OnLockUpdated(ctx, &up)\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-txn-updated\":\n\t\t\t\tvar txnName string\n\t\t\t\td.ScanArgs(t, \"txn\", &txnName)\n\t\t\t\ttxn, ok := c.txnsByName[txnName]\n\t\t\t\tif !ok {\n\t\t\t\t\td.Fatalf(t, \"unknown txn %s\", txnName)\n\t\t\t\t}\n\n\t\t\t\tstatus, verb := scanTxnStatus(t, d)\n\t\t\t\tvar ts hlc.Timestamp\n\t\t\t\tif d.HasArg(\"ts\") {\n\t\t\t\t\tts = scanTimestamp(t, d)\n\t\t\t\t}\n\n\t\t\t\tmon.runSync(\"update txn\", func(ctx context.Context) {\n\t\t\t\t\tlog.Eventf(ctx, \"%s %s\", verb, txnName)\n\t\t\t\t\tif err := c.updateTxnRecord(txn.ID, status, ts); err != nil {\n\t\t\t\t\t\td.Fatalf(t, err.Error())\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-lease-updated\":\n\t\t\t\tvar isLeaseholder bool\n\t\t\t\td.ScanArgs(t, \"leaseholder\", &isLeaseholder)\n\n\t\t\t\tvar leaseSeq int\n\t\t\t\td.ScanArgs(t, \"lease-seq\", &leaseSeq)\n\n\t\t\t\tmon.runSync(\"transfer lease\", func(ctx context.Context) {\n\t\t\t\t\tif isLeaseholder {\n\t\t\t\t\t\tlog.Event(ctx, \"acquired\")\n\t\t\t\t\t} else {\n\t\t\t\t\t\tlog.Event(ctx, \"released\")\n\t\t\t\t\t}\n\t\t\t\t\tm.OnRangeLeaseUpdated(roachpb.LeaseSequence(leaseSeq), isLeaseholder)\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-split\":\n\t\t\t\tmon.runSync(\"split range\", func(ctx context.Context) {\n\t\t\t\t\tlog.Event(ctx, \"complete\")\n\t\t\t\t\tm.OnRangeSplit()\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-merge\":\n\t\t\t\tmon.runSync(\"merge range\", func(ctx context.Context) {\n\t\t\t\t\tlog.Event(ctx, \"complete\")\n\t\t\t\t\tm.OnRangeMerge()\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"on-snapshot-applied\":\n\t\t\t\tmon.runSync(\"snapshot replica\", func(ctx context.Context) {\n\t\t\t\t\tlog.Event(ctx, \"applied\")\n\t\t\t\t\tm.OnReplicaSnapshotApplied()\n\t\t\t\t})\n\t\t\t\treturn c.waitAndCollect(t, mon)\n\n\t\t\tcase \"debug-latch-manager\":\n\t\t\t\tglobal, local := m.LatchMetrics()\n\t\t\t\toutput := []string{\n\t\t\t\t\tfmt.Sprintf(\"write count: %d\", global.WriteCount+local.WriteCount),\n\t\t\t\t\tfmt.Sprintf(\" read count: %d\", global.ReadCount+local.ReadCount),\n\t\t\t\t}\n\t\t\t\treturn strings.Join(output, \"\\n\")\n\n\t\t\tcase \"debug-lock-table\":\n\t\t\t\treturn m.LockTableDebug()\n\n\t\t\tcase \"debug-disable-txn-pushes\":\n\t\t\t\tc.disableTxnPushes()\n\t\t\t\treturn \"\"\n\n\t\t\tcase \"debug-set-clock\":\n\t\t\t\tvar secs int\n\t\t\t\td.ScanArgs(t, \"ts\", &secs)\n\n\t\t\t\tnanos := int64(secs) * time.Second.Nanoseconds()\n\t\t\t\tif nanos < c.manual.UnixNano() {\n\t\t\t\t\td.Fatalf(t, \"manual clock must advance\")\n\t\t\t\t}\n\t\t\t\tc.manual.Set(nanos)\n\t\t\t\treturn \"\"\n\n\t\t\tcase \"reset\":\n\t\t\t\tif n := mon.numMonitored(); n > 0 {\n\t\t\t\t\td.Fatalf(t, \"%d requests still in flight\", n)\n\t\t\t\t}\n\t\t\t\tmon.resetSeqNums()\n\t\t\t\tif err := c.reset(); err != nil {\n\t\t\t\t\td.Fatalf(t, \"could not reset cluster: %v\", err)\n\t\t\t\t}\n\t\t\t\t// Reset request and txn namespace?\n\t\t\t\tif d.HasArg(\"namespace\") {\n\t\t\t\t\tc.resetNamespace()\n\t\t\t\t}\n\t\t\t\treturn \"\"\n\n\t\t\tdefault:\n\t\t\t\treturn fmt.Sprintf(\"unknown command: %s\", d.Cmd)\n\t\t\t}\n\t\t})\n\t})\n}", "func (w *worker) fillTransactions(interrupt *int32, env *environment) error {\n\t// Split the pending transactions into locals and remotes\n\t// Fill the block with all available pending transactions.\n\tpending := w.entropy.TxPool().Pending(true)\n\tlocalTxs, remoteTxs := make(map[common.Address]model.Transactions), pending\n\tfor _, account := range w.entropy.TxPool().Locals() {\n\t\tif txs := remoteTxs[account]; len(txs) > 0 {\n\t\t\tdelete(remoteTxs, account)\n\t\t\tlocalTxs[account] = txs\n\t\t}\n\t}\n\tif len(localTxs) > 0 {\n\t\ttxs := model.NewTransactionsByPriceAndNonce(env.signer, localTxs, env.header.BaseFee)\n\t\tif err := w.commitTransactions(env, txs, interrupt); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tif len(remoteTxs) > 0 {\n\t\ttxs := model.NewTransactionsByPriceAndNonce(env.signer, remoteTxs, env.header.BaseFee)\n\t\tif err := w.commitTransactions(env, txs, interrupt); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (buf *CommandBuffer) PipelineBarrier(\n\tsrcStageMask PipelineStageFlags,\n\tdstStageMask PipelineStageFlags,\n\tdependencyFlags DependencyFlags,\n\tmemoryBarriers []MemoryBarrier,\n\tbufferMemoryBarriers []BufferMemoryBarrier,\n\timageMemoryBarriers []ImageMemoryBarrier,\n) {\n\tcmem, cbuf, cimg := barriers(memoryBarriers, bufferMemoryBarriers, imageMemoryBarriers)\n\tC.domVkCmdPipelineBarrier(\n\t\tbuf.fps[vkCmdPipelineBarrier],\n\t\tbuf.hnd,\n\t\tC.VkPipelineStageFlags(srcStageMask),\n\t\tC.VkPipelineStageFlags(dstStageMask),\n\t\tC.VkDependencyFlags(dependencyFlags),\n\t\tC.uint32_t(len(memoryBarriers)),\n\t\tcmem,\n\t\tC.uint32_t(len(bufferMemoryBarriers)),\n\t\tcbuf,\n\t\tC.uint32_t(len(imageMemoryBarriers)),\n\t\tcimg)\n\tfree(uptr(cmem))\n}", "func (_TokensNetwork *TokensNetworkTransactor) Settle(opts *bind.TransactOpts, token common.Address, participant1 common.Address, participant1_transferred_amount *big.Int, participant1_locksroot [32]byte, participant2 common.Address, participant2_transferred_amount *big.Int, participant2_locksroot [32]byte) (*types.Transaction, error) {\n\treturn _TokensNetwork.contract.Transact(opts, \"settle\", token, participant1, participant1_transferred_amount, participant1_locksroot, participant2, participant2_transferred_amount, participant2_locksroot)\n}", "func Barrier(ch chan<- struct{}) rinq.CommandHandler {\n\treturn BarrierN(ch, 2)\n}", "func (m *multiNode) Reserve() int64 {\n\tvar previous, next, gate int64\n\n\t// Loop and allocate\n\tfor {\n\t\tprevious = atomic.LoadInt64(&m.cursor) // Get the previous pointer.\n\t\tnext = previous + 1 // Increment to get next index.\n\t\tgate = next - m.barrier // Calculate the dependency marker.\n\n\t\t// Validate that the dependency has completed processing on this cell and it's free for use.\n\t\t// If not, wait until it is.\n\t\tfor m.dependency[next&m.mask] != int32(gate>>m.shift) {\n\t\t\ttime.Sleep(time.Microsecond)\n\t\t}\n\n\t\t// Try and update the new sequence number. If successful, then return,\n\t\t// otherwise loop and try this process again (some other caller got the index first).\n\t\tif atomic.CompareAndSwapInt64(&m.cursor, previous, next) {\n\t\t\treturn next\n\t\t}\n\t}\n}", "func (p OpenFlow10Protocol) NewBarrierRequest() goloxi.Message {\n\treturn of10.NewBarrierRequest()\n}", "func TestMoveMultipleToSameBlock(t *testing.T) {\n\tt.Parallel()\n\n\ts, db, teardown, err := testStore()\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tdefer teardown()\n\n\tdbtx, err := db.BeginReadWriteTx()\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tdefer dbtx.Commit()\n\tns := dbtx.ReadWriteBucket(namespaceKey)\n\n\tb100 := BlockMeta{\n\t\tBlock: Block{Height: 100},\n\t\tTime: time.Now(),\n\t}\n\n\tcb := newCoinBase(20e8, 30e8)\n\tcbRec, err := NewTxRecordFromMsgTx(cb, b100.Time)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Insert coinbase and mark both outputs as credits.\n\terr = s.InsertTx(ns, cbRec, &b100)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.AddCredit(ns, cbRec, &b100, 0, false)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.AddCredit(ns, cbRec, &b100, 1, false)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Create and insert two unmined transactions which spend both coinbase\n\t// outputs.\n\tspenderATime := time.Now()\n\tspenderA := spendOutput(&cbRec.Hash, 0, 1e8, 2e8, 18e8)\n\tspenderARec, err := NewTxRecordFromMsgTx(spenderA, spenderATime)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.InsertTx(ns, spenderARec, nil)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.AddCredit(ns, spenderARec, nil, 0, false)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.AddCredit(ns, spenderARec, nil, 1, false)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tspenderBTime := time.Now()\n\tspenderB := spendOutput(&cbRec.Hash, 1, 4e8, 8e8, 18e8)\n\tspenderBRec, err := NewTxRecordFromMsgTx(spenderB, spenderBTime)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.InsertTx(ns, spenderBRec, nil)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.AddCredit(ns, spenderBRec, nil, 0, false)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.AddCredit(ns, spenderBRec, nil, 1, false)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tcoinbaseMaturity := int32(chaincfg.TestNet3Params.CoinbaseMaturity)\n\n\t// Mine both transactions in the block that matures the coinbase.\n\tbMaturity := BlockMeta{\n\t\tBlock: Block{Height: b100.Height + coinbaseMaturity},\n\t\tTime: time.Now(),\n\t}\n\terr = s.InsertTx(ns, spenderARec, &bMaturity)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\terr = s.InsertTx(ns, spenderBRec, &bMaturity)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Check that both transactions can be queried at the maturity block.\n\tdetailsA, err := s.UniqueTxDetails(ns, &spenderARec.Hash, &bMaturity.Block)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif detailsA == nil {\n\t\tt.Fatal(\"No details found for first spender\")\n\t}\n\tdetailsB, err := s.UniqueTxDetails(ns, &spenderBRec.Hash, &bMaturity.Block)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif detailsB == nil {\n\t\tt.Fatal(\"No details found for second spender\")\n\t}\n\n\t// Verify that the balance was correctly updated on the block record\n\t// append and that no unmined transactions remain.\n\tbalTests := []struct {\n\t\theight int32\n\t\tminConf int32\n\t\tbal btcutil.Amount\n\t}{\n\t\t// Maturity height\n\t\t{\n\t\t\theight: bMaturity.Height,\n\t\t\tminConf: 0,\n\t\t\tbal: 15e8,\n\t\t},\n\t\t{\n\t\t\theight: bMaturity.Height,\n\t\t\tminConf: 1,\n\t\t\tbal: 15e8,\n\t\t},\n\t\t{\n\t\t\theight: bMaturity.Height,\n\t\t\tminConf: 2,\n\t\t\tbal: 0,\n\t\t},\n\n\t\t// Next block after maturity height\n\t\t{\n\t\t\theight: bMaturity.Height + 1,\n\t\t\tminConf: 0,\n\t\t\tbal: 15e8,\n\t\t},\n\t\t{\n\t\t\theight: bMaturity.Height + 1,\n\t\t\tminConf: 2,\n\t\t\tbal: 15e8,\n\t\t},\n\t\t{\n\t\t\theight: bMaturity.Height + 1,\n\t\t\tminConf: 3,\n\t\t\tbal: 0,\n\t\t},\n\t}\n\tfor i, tst := range balTests {\n\t\tbal, err := s.Balance(ns, tst.minConf, tst.height)\n\t\tif err != nil {\n\t\t\tt.Fatalf(\"Balance test %d: Store.Balance failed: %v\", i, err)\n\t\t}\n\t\tif bal != tst.bal {\n\t\t\tt.Errorf(\"Balance test %d: Got %v Expected %v\", i, bal, tst.bal)\n\t\t}\n\t}\n\tif t.Failed() {\n\t\tt.Fatal(\"Failed balance checks after moving both coinbase spenders\")\n\t}\n\tunminedTxs, err := s.UnminedTxs(ns)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif len(unminedTxs) != 0 {\n\t\tt.Fatalf(\"Should have no unmined transactions mining both, found %d\", len(unminedTxs))\n\t}\n}", "func (_TokensNetwork *TokensNetworkSession) Settle(token common.Address, participant1 common.Address, participant1_transferred_amount *big.Int, participant1_locksroot [32]byte, participant2 common.Address, participant2_transferred_amount *big.Int, participant2_locksroot [32]byte) (*types.Transaction, error) {\n\treturn _TokensNetwork.Contract.Settle(&_TokensNetwork.TransactOpts, token, participant1, participant1_transferred_amount, participant1_locksroot, participant2, participant2_transferred_amount, participant2_locksroot)\n}", "func (_PlasmaFramework *PlasmaFrameworkTransactor) Enqueue(opts *bind.TransactOpts, vaultId *big.Int, token common.Address, exitableAt uint64, txPos PosLibPosition, exitId *big.Int, exitProcessor common.Address) (*types.Transaction, error) {\n\treturn _PlasmaFramework.contract.Transact(opts, \"enqueue\", vaultId, token, exitableAt, txPos, exitId, exitProcessor)\n}", "func TestEnforcement(t *testing.T) {\r\n\tdefer tests.Recover(t)\r\n\r\n\tt.Run(\"freeze\", freezeOrder)\r\n\tt.Run(\"authority\", freezeAuthorityOrder)\r\n\tt.Run(\"thaw\", thawOrder)\r\n\tt.Run(\"confiscate\", confiscateOrder)\r\n\tt.Run(\"reconcile\", reconcileOrder)\r\n}", "func sendOrdersWhenComeback(netCh config.NetworkChannels, elevatorMap map[int]*config.Elevator, comebackElev string, senderElev int, cabOrdersBackup map[string][config.NUM_FLOORS]bool){\n comebackElevInt,_ := strconv.Atoi(comebackElev)\n order := config.Order{}\n order.Sender_elev_ID = senderElev\n order.Sender_elev_rank = elevatorMap[senderElev].ElevRank\n order.Should_add = true\n order.Receiver_elev = comebackElevInt\n\n for i := 0; i < config.NUM_FLOORS; i++{\n if cabOrdersBackup[comebackElev][i]{\n \torder.Floor = i\n \torder.ButtonType = elevio.BT_Cab\n \tfor i:=0;i<config.NUM_PACKETS_SENT;i++{\n \tnetCh.TransmittOrderCh <- order\n } \n }\n for j := elevio.BT_HallUp; j != elevio.BT_Cab; j++{\n if elevatorMap[senderElev].HallOrders[i][j]{\n order.Floor = i\n order.ButtonType = j\n for i:=0;i<config.NUM_PACKETS_SENT;i++{\n \tnetCh.TransmittOrderCh <- order\n } \n }\n }\n }\n}", "func mustSequentialUpdateSingle(re *require.Assertions, spaceID uint32, group *LockGroup) {\n\tconcurrency := 50\n\ttotal := 0\n\tvar wg sync.WaitGroup\n\twg.Add(concurrency)\n\tfor i := 0; i < concurrency; i++ {\n\t\tgo func() {\n\t\t\tdefer wg.Done()\n\t\t\tgroup.Lock(spaceID)\n\t\t\tdefer group.Unlock(spaceID)\n\t\t\ttotal++\n\t\t}()\n\t}\n\twg.Wait()\n\tre.Equal(concurrency, total)\n}", "func (_TokensNetwork *TokensNetworkTransactorSession) Settle(token common.Address, participant1 common.Address, participant1_transferred_amount *big.Int, participant1_locksroot [32]byte, participant2 common.Address, participant2_transferred_amount *big.Int, participant2_locksroot [32]byte) (*types.Transaction, error) {\n\treturn _TokensNetwork.Contract.Settle(&_TokensNetwork.TransactOpts, token, participant1, participant1_transferred_amount, participant1_locksroot, participant2, participant2_transferred_amount, participant2_locksroot)\n}", "func (t *Thereum) Commit() {\n\t// TODO: 1)this is fugly 2) add custom delay 3) add ability to pause\n\t// create a new block using existing transaction in the pool\n\tblock, state := t.nextBlock()\n\tt.mu.Lock()\n\tt.pendingBlock = block\n\tt.pendingState = state\n\tt.mu.Unlock()\n\t// add optional delay before adding block to simulate pending state\n\ttime.Sleep(time.Millisecond * time.Duration(t.Delay))\n\tt.appendBlock(block)\n\n}", "func beq(cpu *CPU, step *runStep) {\n\tif cpu.z != 0 {\n\t\tcpu.pc = step.address\n\t\tcpu.addBranchCycles(step)\n\t}\n}", "func (T *Transaction) excecuteTransaction() {\n\tT.TransactionState = InProgress\n\n\tMutexesMap := new(sync.Map)\n\n\t//ADD A RWMUTEX FOR EACH TABLE INVOLVED IN THIS TRANSACTION EXCECUTION QUEUE.\n\tfor i := 0; i < len(T.commandsInTransaction); i++ {\n\t\tMutexesMap.Store(T.commandsInTransaction[i].TableName(), &sync.RWMutex{})\n\t}\n\n\t//INSERT LOCKS IN-BETWEEN COMMANDS.\n\tXSLOCKEDTRANSACTION := make([]interface{}, 0)\n\n\tfor i := 0; i < len(T.commandsInTransaction); i++ {\n\t\tif T.commandsInTransaction[i].InstructionType == 1 {\n\t\t\tXSLOCKEDTRANSACTION = append(XSLOCKEDTRANSACTION, \"RLOCK\")\n\t\t\tXSLOCKEDTRANSACTION = append(XSLOCKEDTRANSACTION, T.commandsInTransaction[i])\n\t\t\tXSLOCKEDTRANSACTION = append(XSLOCKEDTRANSACTION, \"RUNLOCK\")\n\t\t} else {\n\t\t\tXSLOCKEDTRANSACTION = append(XSLOCKEDTRANSACTION, \"LOCK\")\n\t\t\tXSLOCKEDTRANSACTION = append(XSLOCKEDTRANSACTION, T.commandsInTransaction[i])\n\t\t\tXSLOCKEDTRANSACTION = append(XSLOCKEDTRANSACTION, \"UNLOCK\")\n\t\t}\n\t}\n\n\t//EXCECUTE TRANSACTION EXCECUTION QUEUE.\n\tfor i := 0; i < len(XSLOCKEDTRANSACTION); i++ {\n\t\tswitch C := XSLOCKEDTRANSACTION[i].(type) {\n\t\tcase string:\n\t\t\tif C == \"RLOCK\" {\n\t\t\t\tLock, _ := MutexesMap.Load((XSLOCKEDTRANSACTION[i+1].(common.Command)).TableName())\n\t\t\t\t(Lock.(*sync.RWMutex)).RLock()\n\t\t\t} else if C == \"RUNLOCK\" {\n\t\t\t\tLock, _ := MutexesMap.Load((XSLOCKEDTRANSACTION[i-1].(common.Command)).TableName())\n\t\t\t\t(Lock.(*sync.RWMutex)).RUnlock()\n\t\t\t} else if C == \"LOCK\" {\n\t\t\t\tLock, _ := MutexesMap.Load((XSLOCKEDTRANSACTION[i+1].(common.Command)).TableName())\n\t\t\t\t(Lock.(*sync.RWMutex)).Lock()\n\t\t\t} else if C == \"UNLOCK\" {\n\t\t\t\tLock, _ := MutexesMap.Load((XSLOCKEDTRANSACTION[i-1].(common.Command)).TableName())\n\t\t\t\t(Lock.(*sync.RWMutex)).Unlock()\n\t\t\t}\n\t\tcase common.Command:\n\t\t\tT.CurrentComand = C.String()\n\t\t\tC.Instruction()\n\t\t\tDelay, _ := config.CommandsDelay.Int64()\n\t\t\ttime.Sleep(time.Second * time.Duration(Delay))\n\t\t\tT.CurrentComand = \"Waiting...\"\n\t\tdefault:\n\t\t\tlog.Println(\"Transaction Manager: Expected string or common.Command object\")\n\t\t}\n\n\t}\n\n\tT.TransactionState = Done\n\tT.CurrentComand = \"Transaction Finished.\"\n\texecWaitGroup.Done()\n\n}", "func main() {\n\n\tvar counter int64 = 0\n\n\tvar wg sync.WaitGroup\n\n\tfor i := 0; i < 100; i++ {\n\t\twg.Add(1)\n\t\tgo func() {\n\n\t\t\t//this will make and atomic operation over the given memory space\n\t\t\tatomic.AddInt64(&counter, 1)\n\n\t\t\twg.Done()\n\t\t}()\n\t}\n\twg.Wait()\n\n\tfmt.Println(counter)\n}", "func (*txDriver) Commit() error { return nil }", "func (*txDriver) Commit() error { return nil }", "func (_Onesplitaudit *OnesplitauditTransactorSession) Swap(fromToken common.Address, toToken common.Address, amount *big.Int, minReturn *big.Int, distribution []*big.Int, featureFlags *big.Int) (*types.Transaction, error) {\n\treturn _Onesplitaudit.Contract.Swap(&_Onesplitaudit.TransactOpts, fromToken, toToken, amount, minReturn, distribution, featureFlags)\n}", "func (hm *HM) handleBarrierRequest(srcID uint8, req *BarrierRequest) {\n\n\t// Save request for this srcID\n\thm.barrierReq[srcID] = req\n\n\t// Increment the count and return if all messages have not been received\n\thm.barrierCnt++\n\tif hm.barrierCnt < hm.nrProc {\n\t\treturn\n\t}\n\n\t// We got all requests. First process the requests and then send responses\n\t// back to each client. Don't send response to the manager.\n\thm.LogDebug(\"Barrier Received Reqs: %v\", hm.VC)\n\tlastLt := *hm.VC.Copy()\n\thm.CreateInterval()\n\tintervals := hm.procArray.GetProcMissingIntervals(hm.pid, &lastLt)\n\thm.IncorporateIntervals(intervals)\n\n\tfor p, req := range hm.barrierReq {\n\t\tif uint8(p) != hm.pid {\n\t\t\thm.IncorporateIntervals(req.Intervals)\n\t\t}\n\t}\n\tvar i uint8\n\tfor i = 0; i < hm.nrProc; i++ {\n\t\tif i != hm.pid {\n\t\t\thm.sendBarrierResponse(i, &hm.barrierReq[i].Vc)\n\t\t}\n\t}\n\thm.barrierCnt = 0\n\thm.waitChan <- true\n}", "func (_Onesplitaudit *OnesplitauditSession) Swap(fromToken common.Address, toToken common.Address, amount *big.Int, minReturn *big.Int, distribution []*big.Int, featureFlags *big.Int) (*types.Transaction, error) {\n\treturn _Onesplitaudit.Contract.Swap(&_Onesplitaudit.TransactOpts, fromToken, toToken, amount, minReturn, distribution, featureFlags)\n}", "func (sm *ShardMaster) Commit(op Op) {\n\tswitch op.Op {\n\tcase \"Join\":\n\t\tif _, ok := sm.previous[op.GID]; !ok {\n\t\t\toldConfig := sm.configs[len(sm.configs)-1]\n\t\t\tnewGroups := make(map[int64][]string)\n\t\t\tnewGroups[op.GID] = op.Servers\n\t\t\tnewShards := [NShards]int64{}\n\t\t\t// Copy over old maps/arrays\n\t\t\tfor gid, servers := range oldConfig.Groups {\n\t\t\t\tnewGroups[gid] = servers\n\t\t\t}\n\t\t\tcountTable := make(map[int64]int)\n\n\t\t\tfor shard, gid := range oldConfig.Shards {\n\t\t\t\tnewShards[shard] = gid\n\t\t\t\tcountTable[gid]++\n\t\t\t}\n\n\t\t\t// Find # of shards per group needed to be balanced\n\t\t\tshardsPerGroup := NShards / len(newGroups)\n\t\t\tif shardsPerGroup == 0 {\n\t\t\t\tshardsPerGroup = 1\n\t\t\t}\n\t\t\tkeys := []int64{}\n\t\t\tfor key, _ := range newGroups {\n\t\t\t\tkeys = append(keys, key)\n\t\t\t}\n\n\t\t\tfor newgid, _ := range newGroups {\n\t\t\t\tcount := countTable[newgid]\n\t\t\t\t// Keep track of how many reassigned to new group\n\t\t\t\tif count < shardsPerGroup+1 {\n\t\t\t\t\tfor shard, gid := range newShards {\n\t\t\t\t\t\tif (gid != newgid && countTable[newgid] < shardsPerGroup && countTable[gid] > shardsPerGroup) || gid == 0 {\n\t\t\t\t\t\t\tnewShards[shard] = newgid\n\t\t\t\t\t\t\tcountTable[gid]--\n\t\t\t\t\t\t\tcountTable[newgid]++\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// DPrintf(\"JOINING, keys= %+v, \\n %+v \\n op= %+v, counts= %+v, pergroup= %+v\", keys, newShards, op, countTable, shardsPerGroup)\n\t\t\t// Find shards not assigned to new group, and if new group still needs shards, assign current shard to new group\n\n\t\t\tnewConfig := Config{Num: len(sm.configs), Shards: newShards, Groups: newGroups}\n\n\t\t\tsm.configs = append(sm.configs, newConfig)\n\t\t\tsm.previous[op.GID] = true\n\t\t}\n\tcase \"Leave\":\n\t\toldConfig := sm.configs[len(sm.configs)-1]\n\t\tnewGroups := make(map[int64][]string)\n\t\tnewGroups[op.GID] = op.Servers\n\t\tnewShards := [NShards]int64{}\n\n\t\tgroupList := []int64{}\n\t\t// Copy over old maps/arrays\n\t\tfor gid, servers := range oldConfig.Groups {\n\t\t\tnewGroups[gid] = servers\n\t\t\tif gid != op.GID {\n\t\t\t\tgroupList = append(groupList, gid)\n\t\t\t}\n\t\t}\n\t\t// Delete group\n\t\tdelete(newGroups, op.GID)\n\t\tdelete(sm.previous, op.GID)\n\t\tcountTable := make(map[int64]int)\n\n\t\tfor shard, gid := range oldConfig.Shards {\n\t\t\tnewShards[shard] = gid\n\t\t\tcountTable[gid]++\n\t\t}\n\t\tdelete(countTable, op.GID)\n\t\t// Find # of shards per group needed to be balanced\n\t\tshardsPerGroup := NShards / len(newGroups)\n\t\tif shardsPerGroup == 0 {\n\t\t\tshardsPerGroup = 1\n\t\t}\n\t\t// Find shards not assigned to new group, and if new group still needs shards, assign current shard to new group\n\n\t\tfor shard, gid := range newShards {\n\t\t\tif gid == op.GID {\n\t\t\t\tfor group, count := range countTable {\n\t\t\t\t\tif count < shardsPerGroup {\n\t\t\t\t\t\tnewShards[shard] = group\n\t\t\t\t\t\tcountTable[group]++\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// start round robin to distribute rest\n\t\tgroupIndex := 0\n\t\tfor shard, gid := range newShards {\n\t\t\tif gid == op.GID {\n\t\t\t\tnewShards[shard] = groupList[groupIndex]\n\t\t\t\tgroupIndex = (groupIndex + 1) % len(groupList)\n\t\t\t}\n\t\t}\n\t\tcountTable = make(map[int64]int)\n\n\t\tfor shard, gid := range newShards {\n\t\t\tnewShards[shard] = gid\n\t\t\tcountTable[gid]++\n\t\t}\n\t\tfor newgid, _ := range newGroups {\n\t\t\tcount := countTable[newgid]\n\t\t\t// Keep track of how many reassigned to new group\n\t\t\tif count < shardsPerGroup+1 {\n\t\t\t\tfor shard, gid := range newShards {\n\t\t\t\t\tif (gid != newgid && countTable[newgid] < shardsPerGroup && countTable[gid] > shardsPerGroup) || gid == 0 {\n\t\t\t\t\t\tnewShards[shard] = newgid\n\t\t\t\t\t\tcountTable[gid]--\n\t\t\t\t\t\tcountTable[newgid]++\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tnewConfig := Config{Num: len(sm.configs), Shards: newShards, Groups: newGroups}\n\t\tsm.configs = append(sm.configs, newConfig)\n\t\tkeys := []int64{}\n\t\tfor key, _ := range newConfig.Groups {\n\t\t\tkeys = append(keys, key)\n\t\t}\n\t\t// DPrintf(\"LEAVING, groups= %+v, \\n countTable= %+v,\\n gid leaving= %v,\\n shards= %+v,\\n pergroup=%v, groups=%v, shards=%v\", keys, countTable, op.GID, newShards, shardsPerGroup, len(newGroups), NShards)\n\t\tdelete(sm.previous, op.GID)\n\tcase \"Move\":\n\t\toldConfig := sm.configs[len(sm.configs)-1]\n\t\tnewGroups := make(map[int64][]string)\n\t\tnewGroups[op.GID] = op.Servers\n\t\tnewShards := [NShards]int64{}\n\t\t// Copy over old maps/arrays\n\t\tfor gid, servers := range oldConfig.Groups {\n\t\t\tnewGroups[gid] = servers\n\t\t}\n\t\tfor shard, gid := range oldConfig.Shards {\n\t\t\tif shard == op.Shard {\n\t\t\t\tnewShards[shard] = op.GID\n\t\t\t} else {\n\t\t\t\tnewShards[shard] = gid\n\t\t\t}\n\t\t}\n\n\t\tnewConfig := Config{Num: len(sm.configs), Shards: newShards, Groups: newGroups}\n\n\t\tsm.configs = append(sm.configs, newConfig)\n\tcase \"Query\":\n\t\tif op.Num > -1 && op.Num < len(sm.configs) {\n\t\t\tsm.requests[op.ID] = sm.configs[op.Num]\n\t\t} else {\n\t\t\tsm.requests[op.ID] = sm.configs[len(sm.configs)-1]\n\t\t}\n\t}\n}", "func (ba *buddyAllocator) Mark(addr, order uint32) {\n\tindex, first := ba.getIndex(addr, order)\n\n\tif order >= MaxOrder {\n\t\t// we need to mark order / _maxOrder pages\n\t\tn := order / MaxOrder\n\t\t// Mark n pages from index as allocated\n\t\tfor i := uint32(0); i < n; i++ {\n\t\t\tba.buddies[MaxOrder].freeMap.Reset(index + i)\n\t\t}\n\t\treturn\n\t}\n\n\t// Mark index as allocated\n\tba.buddies[order].freeMap.Toggle(index)\n\t// If buddy is free add it to free list\n\tif ba.buddies[order].freeMap.IsSet(index) {\n\t\tbuddyAddress := ba.getBuddyAddress(index, order, first)\n\t\tba.buddies[order].freeList.Append(buddyAddress)\n\t}\n\treturn\n}", "func TestMempool(t *testing.T) {\n\tm := newMempool()\n\n\t// Create a transaction.\n\ttx1 := &wire.MsgTx{LockTime: 1}\n\n\t// Check that mempool doesn't have the tx yet.\n\trequire.False(t, m.contains(tx1.TxHash()))\n\n\t// Now add the tx.\n\tm.add(tx1.TxHash())\n\n\t// Mempool should now contain the tx.\n\trequire.True(t, m.contains(tx1.TxHash()))\n\n\t// Add another tx to the mempool.\n\ttx2 := &wire.MsgTx{LockTime: 2}\n\tm.add(tx2.TxHash())\n\trequire.True(t, m.contains(tx2.TxHash()))\n\n\t// Clean the mempool of tx1 (this simulates a block being confirmed\n\t// with tx1 in the block).\n\tm.clean([]*wire.MsgTx{tx1})\n\n\t// Ensure that tx1 is no longer in the mempool but that tx2 still is.\n\trequire.False(t, m.contains(tx1.TxHash()))\n\trequire.True(t, m.contains(tx2.TxHash()))\n\n\t// Lastly, we test that only marked transactions are deleted from the\n\t// mempool.\n\n\t// Let's first re-add tx1 so that we have more txs to work with.\n\tm.add(tx1.TxHash())\n\n\t// Now, we unmark all the transactions.\n\tm.unmarkAll()\n\n\t// Add tx3. This should automatically mark tx3.\n\ttx3 := &wire.MsgTx{LockTime: 3}\n\tm.add(tx3.TxHash())\n\n\t// Let us now manually mark tx2.\n\tm.mark(tx2.TxHash())\n\n\t// Now we delete all unmarked txs. This should leave only tx2 and tx3\n\t// in the mempool.\n\tm.deleteUnmarked()\n\n\trequire.False(t, m.contains(tx1.TxHash()))\n\trequire.True(t, m.contains(tx2.TxHash()))\n\trequire.True(t, m.contains(tx3.TxHash()))\n}", "func (tangle *Tangle) moveTransactionToBranch(cachedTransaction *transaction.CachedTransaction, cachedTransactionMetadata *CachedTransactionMetadata, cachedTargetBranch *branchmanager.CachedBranch) (err error) {\n\t// push transaction that shall be moved to the stack\n\ttransactionStack := list.New()\n\tbranchStack := list.New()\n\tbranchStack.PushBack([3]interface{}{cachedTransactionMetadata.Unwrap().BranchID(), cachedTargetBranch, transactionStack})\n\ttransactionStack.PushBack([2]interface{}{cachedTransaction, cachedTransactionMetadata})\n\n\t// iterate through all transactions (grouped by their branch)\n\tfor branchStack.Len() >= 1 {\n\t\tif err = func() error {\n\t\t\t// retrieve branch details from stack\n\t\t\tcurrentSolidificationEntry := branchStack.Front()\n\t\t\tcurrentSourceBranch := currentSolidificationEntry.Value.([3]interface{})[0].(branchmanager.BranchID)\n\t\t\tcurrentCachedTargetBranch := currentSolidificationEntry.Value.([3]interface{})[1].(*branchmanager.CachedBranch)\n\t\t\ttransactionStack := currentSolidificationEntry.Value.([3]interface{})[2].(*list.List)\n\t\t\tbranchStack.Remove(currentSolidificationEntry)\n\t\t\tdefer currentCachedTargetBranch.Release()\n\n\t\t\t// unpack target branch\n\t\t\ttargetBranch := currentCachedTargetBranch.Unwrap()\n\t\t\tif targetBranch == nil {\n\t\t\t\treturn errors.New(\"failed to unpack branch\")\n\t\t\t}\n\n\t\t\t// iterate through transactions\n\t\t\tfor transactionStack.Len() >= 1 {\n\t\t\t\tif err = func() error {\n\t\t\t\t\t// retrieve transaction details from stack\n\t\t\t\t\tcurrentSolidificationEntry := transactionStack.Front()\n\t\t\t\t\tcurrentCachedTransaction := currentSolidificationEntry.Value.([2]interface{})[0].(*transaction.CachedTransaction)\n\t\t\t\t\tcurrentCachedTransactionMetadata := currentSolidificationEntry.Value.([2]interface{})[1].(*CachedTransactionMetadata)\n\t\t\t\t\ttransactionStack.Remove(currentSolidificationEntry)\n\t\t\t\t\tdefer currentCachedTransaction.Release()\n\t\t\t\t\tdefer currentCachedTransactionMetadata.Release()\n\n\t\t\t\t\t// unwrap transaction\n\t\t\t\t\tcurrentTransaction := currentCachedTransaction.Unwrap()\n\t\t\t\t\tif currentTransaction == nil {\n\t\t\t\t\t\treturn errors.New(\"failed to unwrap transaction\")\n\t\t\t\t\t}\n\n\t\t\t\t\t// unwrap transaction metadata\n\t\t\t\t\tcurrentTransactionMetadata := currentCachedTransactionMetadata.Unwrap()\n\t\t\t\t\tif currentTransactionMetadata == nil {\n\t\t\t\t\t\treturn errors.New(\"failed to unwrap transaction metadata\")\n\t\t\t\t\t}\n\n\t\t\t\t\t// if we arrived at a nested branch\n\t\t\t\t\tif currentTransactionMetadata.BranchID() != currentSourceBranch {\n\t\t\t\t\t\t// abort if we the branch is a conflict branch or an error occurred while trying to elevate\n\t\t\t\t\t\tisConflictBranch, _, elevateErr := tangle.branchManager.ElevateConflictBranch(currentTransactionMetadata.BranchID(), targetBranch.ID())\n\t\t\t\t\t\tif elevateErr != nil || isConflictBranch {\n\t\t\t\t\t\t\treturn elevateErr\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// determine the new branch of the transaction\n\t\t\t\t\t\tnewCachedTargetBranch, branchErr := tangle.calculateBranchOfTransaction(currentTransaction)\n\t\t\t\t\t\tif branchErr != nil {\n\t\t\t\t\t\t\treturn branchErr\n\t\t\t\t\t\t}\n\t\t\t\t\t\tdefer newCachedTargetBranch.Release()\n\n\t\t\t\t\t\t// unwrap the branch\n\t\t\t\t\t\tnewTargetBranch := newCachedTargetBranch.Unwrap()\n\t\t\t\t\t\tif newTargetBranch == nil {\n\t\t\t\t\t\t\treturn errors.New(\"failed to unwrap branch\")\n\t\t\t\t\t\t}\n\t\t\t\t\t\tnewTargetBranch.Persist()\n\n\t\t\t\t\t\t// add the new branch (with the current transaction as a starting point to the branch stack)\n\t\t\t\t\t\tnewTransactionStack := list.New()\n\t\t\t\t\t\tnewTransactionStack.PushBack([2]interface{}{currentCachedTransaction.Retain(), currentCachedTransactionMetadata.Retain()})\n\t\t\t\t\t\tbranchStack.PushBack([3]interface{}{currentTransactionMetadata.BranchID(), newCachedTargetBranch.Retain(), newTransactionStack})\n\n\t\t\t\t\t\treturn nil\n\t\t\t\t\t}\n\n\t\t\t\t\t// abort if we did not modify the branch of the transaction\n\t\t\t\t\tif !currentTransactionMetadata.SetBranchID(targetBranch.ID()) {\n\t\t\t\t\t\treturn nil\n\t\t\t\t\t}\n\n\t\t\t\t\t// iterate through the outputs of the moved transaction\n\t\t\t\t\tcurrentTransaction.Outputs().ForEach(func(address address.Address, balances []*balance.Balance) bool {\n\t\t\t\t\t\t// create reference to the output\n\t\t\t\t\t\toutputID := transaction.NewOutputID(address, currentTransaction.ID())\n\n\t\t\t\t\t\t// load output from database\n\t\t\t\t\t\tcachedOutput := tangle.TransactionOutput(outputID)\n\t\t\t\t\t\tdefer cachedOutput.Release()\n\n\t\t\t\t\t\t// unwrap output\n\t\t\t\t\t\toutput := cachedOutput.Unwrap()\n\t\t\t\t\t\tif output == nil {\n\t\t\t\t\t\t\terr = fmt.Errorf(\"failed to load output '%s'\", outputID)\n\n\t\t\t\t\t\t\treturn false\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// abort if the output was moved already\n\t\t\t\t\t\tif !output.SetBranchID(targetBranch.ID()) {\n\t\t\t\t\t\t\treturn true\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// schedule consumers for further checks\n\t\t\t\t\t\tconsumingTransactions := make(map[transaction.ID]types.Empty)\n\t\t\t\t\t\ttangle.Consumers(transaction.NewOutputID(address, currentTransaction.ID())).Consume(func(consumer *Consumer) {\n\t\t\t\t\t\t\tconsumingTransactions[consumer.TransactionID()] = types.Void\n\t\t\t\t\t\t})\n\t\t\t\t\t\tfor transactionID := range consumingTransactions {\n\t\t\t\t\t\t\ttransactionStack.PushBack([2]interface{}{tangle.Transaction(transactionID), tangle.TransactionMetadata(transactionID)})\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\treturn true\n\t\t\t\t\t})\n\n\t\t\t\t\treturn nil\n\t\t\t\t}(); 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}(); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\treturn\n}", "func (c *Chain) GiveTxBackFromBlock() {\n\n}", "func (ia *idAllocator) allocateBlock(incr int64) {\n\tvar newValue int64\n\tretryOpts := idAllocationRetryOpts\n\terr := retry.WithBackoff(retryOpts, func() (retry.Status, error) {\n\t\tidKey := ia.idKey.Load().(proto.Key)\n\t\tr, err := ia.db.Inc(idKey, incr)\n\t\tif err != nil {\n\t\t\tlog.Warningf(\"unable to allocate %d ids from %s: %s\", incr, idKey, err)\n\t\t\treturn retry.Continue, err\n\t\t}\n\t\tnewValue = r.ValueInt()\n\t\treturn retry.Break, nil\n\t})\n\tif err != nil {\n\t\tpanic(fmt.Sprintf(\"unexpectedly exited id allocation retry loop: %s\", err))\n\t}\n\n\tif newValue <= ia.minID {\n\t\tlog.Warningf(\"allocator key is currently set at %d; minID is %d; allocating again to skip %d IDs\",\n\t\t\tnewValue, ia.minID, ia.minID-newValue)\n\t\tia.allocateBlock(ia.minID - newValue + ia.blockSize - 1)\n\t\treturn\n\t}\n\n\t// Add all new ids to the channel for consumption.\n\tstart := newValue - ia.blockSize + 1\n\tend := newValue + 1\n\tif start < ia.minID {\n\t\tstart = ia.minID\n\t}\n\n\tfor i := start; i < end; i++ {\n\t\tia.ids <- i\n\t\tif i == (start+end)/2 {\n\t\t\tia.ids <- allocationTrigger\n\t\t}\n\t}\n}", "func (tm *TabletManager) lock(ctx context.Context) error {\n\treturn tm.actionSema.Acquire(ctx, 1)\n}", "func TextureBarrier() {\n\tC.glowTextureBarrier(gpTextureBarrier)\n}", "func TextureBarrier() {\n\tC.glowTextureBarrier(gpTextureBarrier)\n}", "func (s *Solver) ClearBarriers() {\n\tfor y := 0; y < s.ydim; y++ {\n\t\tfor x := 0; x < s.xdim; x++ {\n\t\t\ts.barrier[x+y*s.xdim] = false\n\t\t}\n\t}\n}", "func atomicSwapContract(pkhMe, pkhThem *[ripemd160.Size]byte, locktime int64, secretHash []byte) ([]byte, error) {\n\tbuilder := txscript.NewScriptBuilder()\n\n\tbuilder.AddOp(txscript.OP_IF) // if top of stack value is not False, execute. The top stack value is removed.\n\t{\n\t\t// require initiator's secret to be a known length that the redeeming party can audit.\n\t\t// this is used to prevent fraud attacks between 2 currencies that have different maximum data sizes\n\t\tbuilder.AddOp(txscript.OP_SIZE) // pushes the string length of the top element of the stack (without popping it)\n\t\tbuilder.AddInt64(secretSize) // pushes initiator secret length\n\t\tbuilder.AddOp(txscript.OP_EQUALVERIFY) // if inputs are equal, mark tx as valid\n\n\t\t// require initiator's secret to be known to redeem the output\n\t\tbuilder.AddOp(txscript.OP_SHA256) // pushes the length of a SHA25 size\n\t\tbuilder.AddData(secretHash) // push the data to the end of the script\n\t\tbuilder.AddOp(txscript.OP_EQUALVERIFY) // if inputs are equal, mark tx as valid\n\n\t\t// verify their signature is used to redeem the ouput\n\t\t// normally it ends with OP_EQUALVERIFY OP_CHECKSIG but\n\t\t// this has been moved outside of the branch to save a couple bytes\n\t\tbuilder.AddOp(txscript.OP_DUP) // duplicates the stack of the top item\n\t\tbuilder.AddOp(txscript.OP_HASH160) // input has been hashed with SHA-256 and then with RIPEMD160 after\n\t\tbuilder.AddData(pkhThem[:]) // push the data to the end of the script\n\t}\n\n\tbuilder.AddOp(txscript.OP_ELSE) // refund path\n\t{\n\t\t// verify the locktime & drop if off the stack\n\t\tbuilder.AddInt64(locktime) // pushes locktime\n\t\tbuilder.AddOp(txscript.OP_CHECKLOCKTIMEVERIFY) // verify locktime\n\t\tbuilder.AddOp(txscript.OP_DROP) // remove the top stack item (locktime)\n\n\t\t// verify our signature is being used to redeem the output\n\t\t// normally it ends with OP_EQUALVERIFY OP_CHECKSIG but\n\t\t// this has been moved outside of the branch to save a couple bytes\n\t\tbuilder.AddOp(txscript.OP_DUP) // duplicates the stack of the top item\n\t\tbuilder.AddOp(txscript.OP_HASH160) // input has been hashed with SHA-256 and then with RIPEMD160 after\n\t\tbuilder.AddData(pkhMe[:]) // push the data to the end of the script\n\n\t}\n\tbuilder.AddOp(txscript.OP_ENDIF) // all blocks must end, or the transaction is invalid\n\n\t// returns 1 if the inputs are exactly equal, 0 otherwise.\n\t// mark transaction as invalid if top of stack is not true. The top stack value is removed.\n\tbuilder.AddOp(txscript.OP_EQUALVERIFY)\n\n\t// The entire transaction's outputs, inputs, and script are hashed.\n\t// The signature used by OP_CHECKSIG must be a valid signature for this hash\n\t// and public key. If it is, 1 is returned, 0 otherwise.\n\tbuilder.AddOp(txscript.OP_CHECKSIG)\n\treturn builder.Script()\n}", "func (m *Synchronization) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {\n err := m.Entity.Serialize(writer)\n if err != nil {\n return err\n }\n if m.GetJobs() != nil {\n cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetJobs()))\n for i, v := range m.GetJobs() {\n if v != nil {\n cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)\n }\n }\n err = writer.WriteCollectionOfObjectValues(\"jobs\", cast)\n if err != nil {\n return err\n }\n }\n if m.GetSecrets() != nil {\n cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetSecrets()))\n for i, v := range m.GetSecrets() {\n if v != nil {\n cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)\n }\n }\n err = writer.WriteCollectionOfObjectValues(\"secrets\", cast)\n if err != nil {\n return err\n }\n }\n if m.GetTemplates() != nil {\n cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetTemplates()))\n for i, v := range m.GetTemplates() {\n if v != nil {\n cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)\n }\n }\n err = writer.WriteCollectionOfObjectValues(\"templates\", cast)\n if err != nil {\n return err\n }\n }\n return nil\n}", "func JB(r operand.Op) { ctx.JB(r) }", "func (txs *TxSerializer) lockLocked(ctx context.Context, key, table string) (bool, error) {\n\tq, ok := txs.queues[key]\n\tif !ok {\n\t\t// First transaction in the queue i.e. we don't wait and return immediately.\n\t\ttxs.queues[key] = newQueueForFirstTransaction(txs.concurrentTransactions)\n\t\ttxs.globalSize++\n\t\treturn false, nil\n\t}\n\n\tif txs.globalSize >= txs.maxGlobalQueueSize {\n\t\tif txs.dryRun {\n\t\t\ttxs.globalQueueExceededDryRun.Add(1)\n\t\t\ttxs.logGlobalQueueExceededDryRun.Warningf(\"Would have rejected BeginExecute RPC because there are too many queued transactions (%d >= %d)\", txs.globalSize, txs.maxGlobalQueueSize)\n\t\t} else {\n\t\t\ttxs.globalQueueExceeded.Add(1)\n\t\t\treturn false, vterrors.Errorf(vtrpcpb.Code_RESOURCE_EXHAUSTED,\n\t\t\t\t\"hot row protection: too many queued transactions (%d >= %d)\", txs.globalSize, txs.maxGlobalQueueSize)\n\t\t}\n\t}\n\n\tif q.size >= txs.maxQueueSize {\n\t\tif txs.dryRun {\n\t\t\ttxs.queueExceededDryRun.Add(table, 1)\n\t\t\tif txs.env.Config().SanitizeLogMessages {\n\t\t\t\ttxs.logQueueExceededDryRun.Warningf(\"Would have rejected BeginExecute RPC because there are too many queued transactions (%d >= %d) for the same row (table + WHERE clause: '%v')\", q.size, txs.maxQueueSize, txs.sanitizeKey(key))\n\t\t\t} else {\n\t\t\t\ttxs.logQueueExceededDryRun.Warningf(\"Would have rejected BeginExecute RPC because there are too many queued transactions (%d >= %d) for the same row (table + WHERE clause: '%v')\", q.size, txs.maxQueueSize, key)\n\t\t\t}\n\t\t} else {\n\t\t\ttxs.queueExceeded.Add(table, 1)\n\t\t\tif txs.env.Config().TerseErrors {\n\t\t\t\treturn false, vterrors.Errorf(vtrpcpb.Code_RESOURCE_EXHAUSTED,\n\t\t\t\t\t\"hot row protection: too many queued transactions (%d >= %d) for the same row (table + WHERE clause: '%v')\", q.size, txs.maxQueueSize, txs.sanitizeKey(key))\n\t\t\t}\n\t\t\treturn false, vterrors.Errorf(vtrpcpb.Code_RESOURCE_EXHAUSTED,\n\t\t\t\t\"hot row protection: too many queued transactions (%d >= %d) for the same row (table + WHERE clause: '%v')\", q.size, txs.maxQueueSize, key)\n\t\t}\n\t}\n\n\tif q.availableSlots == nil {\n\t\t// Hot row detected: A second, concurrent transaction is seen for the\n\t\t// first time.\n\n\t\t// As an optimization, we deferred the creation of the channel until now.\n\t\tq.availableSlots = make(chan struct{}, txs.concurrentTransactions)\n\t\tq.availableSlots <- struct{}{}\n\n\t\t// Include first transaction in the count at /debug/hotrows. (It was not\n\t\t// recorded on purpose because it did not wait.)\n\t\ttxs.Record(key)\n\t}\n\n\ttxs.globalSize++\n\tq.size++\n\tq.count++\n\tif q.size > q.max {\n\t\tq.max = q.size\n\t}\n\t// Publish the number of waits at /debug/hotrows.\n\ttxs.Record(key)\n\n\tif txs.dryRun {\n\t\ttxs.waitsDryRun.Add(table, 1)\n\t\tif txs.env.Config().SanitizeLogMessages {\n\t\t\ttxs.logWaitsDryRun.Warningf(\"Would have queued BeginExecute RPC for row (range): '%v' because another transaction to the same range is already in progress.\", txs.sanitizeKey(key))\n\t\t} else {\n\t\t\ttxs.logWaitsDryRun.Warningf(\"Would have queued BeginExecute RPC for row (range): '%v' because another transaction to the same range is already in progress.\", key)\n\t\t}\n\t\treturn false, nil\n\t}\n\n\t// Unlock before the wait and relock before returning because our caller\n\t// Wait() holds the lock and assumes it still has it.\n\ttxs.mu.Unlock()\n\tdefer txs.mu.Lock()\n\n\t// Non-blocking write attempt to get a slot.\n\tselect {\n\tcase q.availableSlots <- struct{}{}:\n\t\t// Return waited=false because a slot was immediately available.\n\t\treturn false, nil\n\tdefault:\n\t}\n\n\t// Blocking wait for the next available slot.\n\ttxs.waits.Add(table, 1)\n\tselect {\n\tcase q.availableSlots <- struct{}{}:\n\t\treturn true, nil\n\tcase <-ctx.Done():\n\t\treturn true, ctx.Err()\n\t}\n}", "func Brcom(op Op) Op", "func brcom(op Op) Op {\n\tswitch op {\n\tcase OEQ:\n\t\treturn ONE\n\tcase ONE:\n\t\treturn OEQ\n\tcase OLT:\n\t\treturn OGE\n\tcase OGT:\n\t\treturn OLE\n\tcase OLE:\n\t\treturn OGT\n\tcase OGE:\n\t\treturn OLT\n\t}\n\tFatalf(\"brcom: no com for %v\\n\", op)\n\treturn op\n}", "func BTCL(ir, mr operand.Op) { ctx.BTCL(ir, mr) }", "func (c *ConsensusState) orderTxn() {\n\t// should copy to a new list\n\t// the original list (c.bgStateResponse) is used for state response look up\n\t// if modify the original list, GetBGStateResponseById will return a wrong state response\n\tc.orderedStateResponse = make([]*pb.StateResponseMessage, len(c.bgStateResponse))\n\tfor i, sr := range c.bgStateResponse {\n\t\tc.orderedStateResponse[i] = sr\n\t\t//logger.Debugf(\"NONCE cycle %v random %v from server %v\", c.cycleId, sr.BgRandom, sr.SenderId)\n\t}\n\n\t// sort by the random number in place\n\tsort.Slice(c.orderedStateResponse, func(i, j int) bool {\n\t\tif c.orderedStateResponse[i].Result.Nonce == c.orderedStateResponse[j].Result.Nonce {\n\t\t\treturn c.orderedStateResponse[i].BgId < c.orderedStateResponse[i].BgId\n\t\t}\n\t\treturn c.orderedStateResponse[i].Result.Nonce < c.orderedStateResponse[j].Result.Nonce\n\t})\n}", "func (s *slotted) Reserve() { atomic.AddInt32((*int32)(s), 1) }", "func (m *DataManager) OpTxCommit() error {\n\tif m.opNeedLock {\n\t\tm.opLock.Lock()\n\t\tdefer m.opLock.Unlock()\n\t}\n\n\treturn m.opdb.Commit()\n}", "func TestCommandQueueTransitiveDependencies(t *testing.T) {\n\tdefer leaktest.AfterTest(t)()\n\n\tspansAB := []roachpb.Span{\n\t\tmkSpan(\"a\", \"b\"),\n\t}\n\tspansAC := []roachpb.Span{\n\t\tmkSpan(\"a\", \"c\"),\n\t}\n\tspansBC := []roachpb.Span{\n\t\tmkSpan(\"b\", \"c\"),\n\t}\n\n\t// forEachCmdOpsPerm calls the provided closure in a subtest for each permutation\n\t// of different command options.\n\tforEachCmdOpsPerm := func(t *testing.T, f func(*testing.T, cmdOps)) {\n\t\tfor _, readOnly := range []bool{false, true} {\n\t\t\tfor _, ts := range []hlc.Timestamp{zeroTS, makeTS(1, 0), makeTS(2, 0)} {\n\t\t\t\tfor _, spans := range [][]roachpb.Span{spansAB, spansAC, spansBC} {\n\t\t\t\t\tf(t, cmdOps{readOnly: readOnly, ts: ts, spans: spans})\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Permute over all possible options for three different commands.\n\tforEachCmdOpsPerm(t, func(t *testing.T, ops1 cmdOps) {\n\t\tforEachCmdOpsPerm(t, func(t *testing.T, ops2 cmdOps) {\n\t\t\tforEachCmdOpsPerm(t, func(t *testing.T, ops3 cmdOps) {\n\t\t\t\t// First we add only the first and third command and test\n\t\t\t\t// whether the third depends on the first. This will\n\t\t\t\t// tell us whether a transitive relation should be expected.\n\t\t\t\t{\n\t\t\t\t\tcq := NewCommandQueue(true)\n\n\t\t\t\t\tcq.add(ops1.readOnly, ops1.ts, nil, ops1.spans)\n\n\t\t\t\t\tpre3 := cq.getPrereqs(ops3.readOnly, ops3.ts, ops3.spans)\n\t\t\t\t\tif expectDependency := len(pre3) > 0; !expectDependency {\n\t\t\t\t\t\t// Adding a new command between two independent commands\n\t\t\t\t\t\t// can result in all three becoming dependent. For instance,\n\t\t\t\t\t\t// adding a write between two reads. This means that we can't\n\t\t\t\t\t\t// assert that no dependency will later exist in the case\n\t\t\t\t\t\t// where we see none before, so we have nothing to test here.\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Next we add all three commands to the command queue and\n\t\t\t\t// verify that a dependency still exists between the first\n\t\t\t\t// and third command.\n\t\t\t\t{\n\t\t\t\t\tcq := NewCommandQueue(true)\n\n\t\t\t\t\t// Add command 1.\n\t\t\t\t\tcmd1 := cq.add(ops1.readOnly, ops1.ts, nil, ops1.spans)\n\n\t\t\t\t\t// Add command 2, taking note of whether it depends on command 1.\n\t\t\t\t\tpre2 := cq.getPrereqs(ops2.readOnly, ops2.ts, ops2.spans)\n\t\t\t\t\tdependency2to1 := len(pre2) > 0\n\t\t\t\t\tcmd2 := cq.add(ops2.readOnly, ops2.ts, pre2, ops2.spans)\n\n\t\t\t\t\t// Add command 3, taking note of whether it depends on command 1\n\t\t\t\t\t// or on command 2.\n\t\t\t\t\tpre3 := cq.getPrereqs(ops3.readOnly, ops3.ts, ops3.spans)\n\t\t\t\t\tpre3Set := make(map[*cmd]struct{}, len(pre3))\n\t\t\t\t\tfor _, prereq := range pre3 {\n\t\t\t\t\t\tpre3Set[prereq] = struct{}{}\n\t\t\t\t\t}\n\t\t\t\t\t_, dependency3to1 := pre3Set[cmd1]\n\t\t\t\t\t_, dependency3to2 := pre3Set[cmd2]\n\n\t\t\t\t\t// Assert that a dependency still exists between command 3\n\t\t\t\t\t// and command 1, either directly or through command 2.\n\t\t\t\t\tif !(dependency3to1 || (dependency3to2 && dependency2to1)) {\n\t\t\t\t\t\tt.Errorf(\"1=%s, 2=%s, 3=%s: expected transitive dependency, found: \"+\n\t\t\t\t\t\t\t\"3->1=%t, 2->1=%t, 3->2=%t\", ops1, ops2, ops2,\n\t\t\t\t\t\t\tdependency3to1, dependency2to1, dependency3to2)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})\n\t\t})\n\t})\n}", "func (m *DataManager) OpTxBegin() error {\n\tif m.opNeedLock {\n\t\tm.opLock.Lock()\n\t\tdefer m.opLock.Unlock()\n\t}\n\n\treturn m.opdb.Begin()\n}", "func MarkAsFree(c client.Client, watchNamespace string, recorder record.EventRecorder, controllerName string) error {\n\t// Check if operator is OLM-managed\n\tif opCondName == \"\" {\n\t\treturn nil\n\t}\n\n\topCondBusyControllersLock.Lock()\n\tdefer opCondBusyControllersLock.Unlock()\n\n\t// Remove given controller from busy controllers set\n\tdelete(busyControllers, controllerName)\n\t// If at least one other controller is still busy, no-op as Upgradeable should not be set to True yet\n\tif len(busyControllers) > 0 {\n\t\treturn nil\n\t}\n\n\topCond, err := get(c, watchNamespace)\n\tif err != nil {\n\t\trecorder.Eventf(opCond, core.EventTypeWarning, \"OperatorConditionError\",\n\t\t\t\"Failed to get OperatorCondition CR: %v\", err)\n\t\treturn err\n\t}\n\t// If Upgradeable condition is already True, no-op to avoid redundant API calls\n\tif Validate(opCond.Spec.Conditions, operators.Upgradeable, meta.ConditionTrue) {\n\t\treturn nil\n\t}\n\n\terr = set(c, opCond, operators.Upgradeable, meta.ConditionTrue, upgradeableTrueReason, upgradeableTrueMessage)\n\tif err != nil {\n\t\trecorder.Eventf(opCond, core.EventTypeWarning, \"OperatorConditionError\",\n\t\t\t\"Failed to patch OperatorCondition CR. Manual operator upgrades may be needed: %v\", err)\n\t\treturn err\n\t}\n\treturn nil\n}", "func TestConcurrentTransactionsSQLite(t *testing.T) {\n\tserver := startServer(t)\n\tdefer server.Close()\n\tstarted := time.Now()\n\ttx1, _ := server.DB.Begin()\n\tt.Log(time.Since(started))\n\tgo func() {\n\t\ttime.Sleep(10 * time.Millisecond)\n\t\ttx1.Rollback()\n\t}()\n\tstarted = time.Now()\n\ttx2, _ := server.DB.Begin()\n\ttx2.Rollback()\n\ttook := time.Since(started)\n\tt.Log(took)\n\tif took < 10*time.Millisecond {\n\t\tt.Fatal(\"transactions did not lock each other out\")\n\t}\n}", "func setPriorityRequest(c *xgb.Conn, Id uint32, Priority int32) []byte {\n\tsize := 12\n\tb := 0\n\tbuf := make([]byte, size)\n\n\tbuf[b] = c.Extensions[\"SYNC\"]\n\tb += 1\n\n\tbuf[b] = 12 // request opcode\n\tb += 1\n\n\txgb.Put16(buf[b:], uint16(size/4)) // write request size in 4-byte units\n\tb += 2\n\n\txgb.Put32(buf[b:], Id)\n\tb += 4\n\n\txgb.Put32(buf[b:], uint32(Priority))\n\tb += 4\n\n\treturn buf\n}", "func (_EtherDelta *EtherDeltaTransactor) Order(opts *bind.TransactOpts, tokenGet common.Address, amountGet *big.Int, tokenGive common.Address, amountGive *big.Int, expires *big.Int, nonce *big.Int) (*types.Transaction, error) {\n\treturn _EtherDelta.contract.Transact(opts, \"order\", tokenGet, amountGet, tokenGive, amountGive, expires, nonce)\n}", "func VPERMQ_BCST(ops ...operand.Op) { ctx.VPERMQ_BCST(ops...) }", "func TestTransMessageOrder(t *testing.T) {\n\n\tn, _ := openConn(t)\n\tch := check11(TEST_HEADERS)\n\tconn, _ := Connect(n, ch)\n\n\td := tdest(TEST_TDESTPREF + \"3\")\n\tth := Headers{HK_TRANSACTION, TEST_TRANID,\n\t\tHK_DESTINATION, d}\n\tsbh := Headers{HK_DESTINATION, d}\n\tsh := sbh\n\tmst := \"Message in transaction\"\n\n\t// Subscribe\n\tsc, e := conn.Subscribe(sbh)\n\tif e != nil {\n\t\tt.Fatalf(\"SUBSCRIBE expected [nil], got: [%v]\\n\", e)\n\t}\n\n\t// Then begin\n\te = conn.Begin(th)\n\tif e != nil {\n\t\tt.Fatalf(\"BEGIN expected [nil], got: [%v]\\n\", e)\n\t}\n\t// Then send in transaction\n\te = conn.Send(th, mst) // in transaction\n\tif e != nil {\n\t\tt.Fatalf(\"SEND expected [nil], got: [%v]\\n\", e)\n\t}\n\t//\n\tmsn := \"Message NOT in transaction\"\n\t// Then send NOT in transaction\n\te = conn.Send(sh, msn) // NOT in transaction\n\tif e != nil {\n\t\tt.Fatalf(\"SEND expected [nil], got: [%v]\\n\", e)\n\t}\n\t// First receive - should be second message\n\tmd := getMessageData(sc, conn, t)\n\n\tif md.Error != nil {\n\t\tt.Fatalf(\"Read error: expected [nil], got: [%v]\\n\", md.Error)\n\t}\n\tif msn != md.Message.BodyString() {\n\t\tt.Fatalf(\"Message error TMO1: expected: [%v] got: [%v]\", msn, md.Message.BodyString())\n\t}\n\n\t// Now commit\n\te = conn.Commit(th)\n\tif e != nil {\n\t\tt.Fatalf(\"COMMIT expected [nil], got: [%v]\\n\", e)\n\t}\n\n\t// Second receive - should be first message\n\tmd = getMessageData(sc, conn, t)\n\n\tif md.Error != nil {\n\t\tt.Fatalf(\"Read error: expected [nil], got: [%v]\\n\", md.Error)\n\t}\n\tif mst != md.Message.BodyString() {\n\t\tt.Fatalf(\"Message error TMO2: expected: [%v] got: [%v]\", mst, md.Message.BodyString())\n\t}\n\t//\n\t_ = conn.Disconnect(empty_headers)\n\t_ = closeConn(t, n)\n\n}", "func (pool *TxPool) confirm(seq *tx_types.Sequencer) error {\n\tlog.WithField(\"seq\", seq).Trace(\"start confirm seq\")\n\n\tvar err error\n\tvar batch *ConfirmBatch\n\tvar elders map[common.Hash]types.Txi\n\tif pool.cached != nil && seq.GetTxHash() == pool.cached.SeqHash() {\n\t\tbatch = &ConfirmBatch{\n\t\t\tSeq: seq,\n\t\t\tTxs: pool.cached.Txs(),\n\t\t}\n\t\telders = pool.cached.elders\n\t} else {\n\t\telders, batch, err = pool.confirmHelper(seq)\n\t\tif err != nil {\n\t\t\tlog.WithField(\"error\", err).Errorf(\"confirm error: %v\", err)\n\t\t\treturn err\n\t\t}\n\t}\n\tpool.cached = nil\n\n\t// push batch to dag\n\tif err := pool.dag.Push(batch); err != nil {\n\t\tlog.WithField(\"error\", err).Errorf(\"dag Push error: %v\", err)\n\t\treturn err\n\t}\n\n\tfor _, tx := range batch.Txs {\n\t\tif normalTx, ok := tx.(*tx_types.Tx); ok {\n\t\t\tpool.confirmStatus.AddConfirm(normalTx.GetConfirm())\n\t\t}\n\t}\n\n\t// solve conflicts of txs in pool\n\tpool.solveConflicts(batch)\n\t// add seq to txpool\n\tif pool.flows.Get(seq.Sender()) == nil {\n\t\tpool.flows.ResetFlow(seq.Sender(), state.NewBalanceSet())\n\t}\n\tpool.flows.Add(seq)\n\tpool.tips.Add(seq)\n\tpool.txLookup.SwitchStatus(seq.GetTxHash(), TxStatusTip)\n\n\t// notification\n\tfor _, c := range pool.OnBatchConfirmed {\n\t\tif status.NodeStopped {\n\t\t\tbreak\n\t\t}\n\t\tc <- elders\n\t}\n\tfor _, c := range pool.OnNewLatestSequencer {\n\t\tif status.NodeStopped {\n\t\t\tbreak\n\t\t}\n\t\tc <- true\n\t}\n\n\tlog.WithField(\"seq height\", seq.Height).WithField(\"seq\", seq).Trace(\"finished confirm seq\")\n\treturn nil\n}", "func TestInsertMempoolDoubleSpendConfirmedFirstTx(t *testing.T) {\n\tt.Parallel()\n\ttestInsertMempoolDoubleSpendTx(t, true)\n}", "func (ma *markAllocator) put(mark uint32) {\n\tma.lock.Lock()\n\tdefer ma.lock.Unlock()\n\tma.marks = append(ma.marks, mark)\n}", "func main() {\n\tbase := initBTree()\n\tfmt.Println(\"pre order\")\n\tbase.preOrder()\n\tfmt.Println(\"in order\")\n\tbase.inOrder()\n\tfmt.Println(\"post order\")\n\tbase.postOrder()\n}", "func TestReadOnlyTransaction_UseAfterClose(t *testing.T) {\n\tt.Parallel()\n\tctx := context.Background()\n\t_, client, teardown := setupMockedTestServer(t)\n\tdefer teardown()\n\n\ttxn := client.ReadOnlyTransaction()\n\ttxn.Close()\n\n\t_, _, e := txn.acquire(ctx)\n\tif wantErr := errTxClosed(); !testEqual(e, wantErr) {\n\t\tt.Fatalf(\"Second acquire for multi use, got %v, want %v.\", e, wantErr)\n\t}\n}", "func lockTrans(multiport bool, portConfig int) {\n\tif multiport && portConfig >= 0 && portConfig < 128 {\n\t\tmultiportTransLock[portConfig].Lock()\n\t} else {\n\t\ttransLock.Lock()\n\t}\n}", "func Commitment(G, msg *RingMartix, bound int) (*RingMartix, *RingMartix, error) {\n\tif msg.row != 1 {\n\t\treturn nil, nil, errors.New(\"m should be a v*1-size Rq vector\")\n\t}\n\tif G.row < msg.col {\n\t\treturn nil, nil, errors.New(\"G.row should >= msg.col\")\n\t}\n\n\t// build r (we allow r == nil for test)\n\tnttParams := settings.nttParams\n\tm := G.row - msg.col\n\tr, _ := NewRingMartix(m, 1, nttParams)\n\tif r != nil {\n\t\tseed := time.Now().UnixNano() // may consider more secure seeds\n\t\tif bound < 0 {\n\t\t\tr.SetRandomQRingMartix(&G.ringvectors[0].rings[0], seed, settings.d, settings.q)\n\t\t} else {\n\t\t\tr.SetRandomBRingMartix(&G.ringvectors[0].rings[0], seed, settings.d, bound, false)\n\t\t}\n\t}\n\n\tcom, err := CommitmentWithRandom(G, msg, r)\n\treturn com, r, err\n}", "func (trd *trxDispatcher) waitAndStore(evt *eventTrx, wg *sync.WaitGroup) {\n\t// wait until all the sub-processors finish their job\n\twg.Wait()\n\tif err := repo.StoreTransaction(evt.blk, evt.trx); err != nil {\n\t\tlog.Errorf(\"can not store trx %s from block #%d\", evt.trx.Hash.String(), evt.blk.Number)\n\t}\n\n\trepo.IncTrxCountEstimate(1)\n\trepo.CacheTransaction(evt.trx)\n\ttrd.blkObserver.Store(uint64(evt.blk.Number))\n}", "func TestConcurrentLockTables(t *testing.T) {\n\tstore, dom := testkit.CreateMockStoreAndDomainWithSchemaLease(t, tableModifyLease)\n\ttk1 := testkit.NewTestKit(t, store)\n\ttk2 := testkit.NewTestKit(t, store)\n\ttk1.MustExec(\"use test\")\n\ttk2.MustExec(\"use test\")\n\ttk1.MustExec(\"create table t1 (a int)\")\n\n\t// Test concurrent lock tables read.\n\tsql1 := \"lock tables t1 read\"\n\tsql2 := \"lock tables t1 read\"\n\ttestParallelExecSQL(t, store, dom, sql1, sql2, tk1.Session(), tk2.Session(), func(t *testing.T, err1, err2 error) {\n\t\trequire.NoError(t, err1)\n\t\trequire.NoError(t, err2)\n\t})\n\ttk1.MustExec(\"unlock tables\")\n\ttk2.MustExec(\"unlock tables\")\n\n\t// Test concurrent lock tables write.\n\tsql1 = \"lock tables t1 write\"\n\tsql2 = \"lock tables t1 write\"\n\ttestParallelExecSQL(t, store, dom, sql1, sql2, tk1.Session(), tk2.Session(), func(t *testing.T, err1, err2 error) {\n\t\trequire.NoError(t, err1)\n\t\trequire.True(t, terror.ErrorEqual(err2, infoschema.ErrTableLocked))\n\t})\n\ttk1.MustExec(\"unlock tables\")\n\ttk2.MustExec(\"unlock tables\")\n\n\t// Test concurrent lock tables write local.\n\tsql1 = \"lock tables t1 write local\"\n\tsql2 = \"lock tables t1 write local\"\n\ttestParallelExecSQL(t, store, dom, sql1, sql2, tk1.Session(), tk2.Session(), func(t *testing.T, err1, err2 error) {\n\t\trequire.NoError(t, err1)\n\t\trequire.True(t, terror.ErrorEqual(err2, infoschema.ErrTableLocked))\n\t})\n\n\ttk1.MustExec(\"unlock tables\")\n\ttk2.MustExec(\"unlock tables\")\n}", "func (o *Operation) MarkerOrder(order string, gid GoogleID) error {\n\tstmt, err := db.Prepare(\"UPDATE marker SET oporder = ? WHERE opID = ? AND ID = ?\")\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\n\tpos := 1\n\tmarkers := strings.Split(order, \",\")\n\tfor i := range markers {\n\t\tif markers[i] == \"000\" { // the header, could be anyplace in the order if the user was being silly\n\t\t\tcontinue\n\t\t}\n\t\tif _, err := stmt.Exec(pos, o.ID, markers[i]); err != nil {\n\t\t\tLog.Error(err)\n\t\t\tcontinue\n\t\t}\n\t\tpos++\n\t}\n\tif err = o.Touch(); err != nil {\n\t\tLog.Error(err)\n\t}\n\treturn nil\n}", "func (_LockProxy *LockProxyTransactor) Lock(opts *bind.TransactOpts, sourceAssetHash common.Address, toChainId uint64, toAddress []byte, amount *big.Int) (*types.Transaction, error) {\n\treturn _LockProxy.contract.Transact(opts, \"lock\", sourceAssetHash, toChainId, toAddress, amount)\n}", "func (m *Mantle) order(sell bool, qty, rate uint64) error {\n\t_, err := m.Trade(pass, coreLimitOrder(sell, qty, rate))\n\tif err != nil {\n\t\tif isOverLimitError(err) {\n\t\t\tm.log.Infof(\"Over-limit error. Order not placed.\")\n\t\t} else {\n\t\t\tm.fatalError(\"Trade error (limit order, sell = %t, qty = %d, rate = %d): %v\", sell, qty, rate, err)\n\t\t}\n\t\treturn err\n\t}\n\tatomic.AddUint32(&orderCounter, 1)\n\treturn nil\n}", "func TestCommit(t *testing.T) {\n\tconst n = 4\n\tctrl := gomock.NewController(t)\n\ths := New()\n\tkeys := testutil.GenerateKeys(t, n, testutil.GenerateECDSAKey)\n\tbl := testutil.CreateBuilders(t, ctrl, n, keys...)\n\tacceptor := mocks.NewMockAcceptor(ctrl)\n\texecutor := mocks.NewMockExecutor(ctrl)\n\tsynchronizer := synchronizer.New(testutil.FixedTimeout(1000))\n\tcfg, replicas := testutil.CreateMockConfigWithReplicas(t, ctrl, n, keys...)\n\tbl[0].Register(hs, cfg, acceptor, executor, synchronizer, leaderrotation.NewFixed(2))\n\thl := bl.Build()\n\tsigners := hl.Signers()\n\n\t// create the needed blocks and QCs\n\tgenesisQC := hotstuff.NewQuorumCert(nil, 0, hotstuff.GetGenesis().Hash())\n\tb1 := testutil.NewProposeMsg(hotstuff.GetGenesis().Hash(), genesisQC, \"1\", 1, 2)\n\tb1QC := testutil.CreateQC(t, b1.Block, signers)\n\tb2 := testutil.NewProposeMsg(b1.Block.Hash(), b1QC, \"2\", 2, 2)\n\tb2QC := testutil.CreateQC(t, b2.Block, signers)\n\tb3 := testutil.NewProposeMsg(b2.Block.Hash(), b2QC, \"3\", 3, 2)\n\tb3QC := testutil.CreateQC(t, b3.Block, signers)\n\tb4 := testutil.NewProposeMsg(b3.Block.Hash(), b3QC, \"4\", 4, 2)\n\n\t// the second replica will be the leader, so we expect it to receive votes\n\treplicas[1].EXPECT().Vote(gomock.Any()).AnyTimes()\n\treplicas[1].EXPECT().NewView(gomock.Any()).AnyTimes()\n\n\t// executor will check that the correct command is executed\n\texecutor.EXPECT().Exec(gomock.Any()).Do(func(arg interface{}) {\n\t\tif arg.(hotstuff.Command) != b1.Block.Command() {\n\t\t\tt.Errorf(\"Wrong command executed: got: %s, want: %s\", arg, b1.Block.Command())\n\t\t}\n\t})\n\n\t// acceptor expects to receive the commands in order\n\tgomock.InOrder(\n\t\tacceptor.EXPECT().Proposed(gomock.Any()),\n\t\tacceptor.EXPECT().Accept(hotstuff.Command(\"1\")).Return(true),\n\t\tacceptor.EXPECT().Proposed(hotstuff.Command(\"1\")),\n\t\tacceptor.EXPECT().Accept(hotstuff.Command(\"2\")).Return(true),\n\t\tacceptor.EXPECT().Proposed(hotstuff.Command(\"2\")),\n\t\tacceptor.EXPECT().Accept(hotstuff.Command(\"3\")).Return(true),\n\t\tacceptor.EXPECT().Proposed(hotstuff.Command(\"3\")),\n\t\tacceptor.EXPECT().Accept(hotstuff.Command(\"4\")).Return(true),\n\t)\n\n\ths.OnPropose(b1)\n\ths.OnPropose(b2)\n\ths.OnPropose(b3)\n\ths.OnPropose(b4)\n}", "func TestInsertMempoolTxAndConfirm(t *testing.T) {\n\tt.Parallel()\n\n\tstore, db, teardown, err := testStore()\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tdefer teardown()\n\n\t// Create a transaction which we'll insert into the store as\n\t// unconfirmed.\n\ttx := newCoinBase(1e8)\n\ttxRec, err := NewTxRecordFromMsgTx(tx, time.Now())\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tcommitDBTx(t, store, db, func(ns walletdb.ReadWriteBucket) {\n\t\tif err := store.InsertTx(ns, txRec, nil); err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t\terr := store.AddCredit(ns, txRec, nil, 0, false)\n\t\tif err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t})\n\n\t// Then, proceed to confirm it.\n\tcommitDBTx(t, store, db, func(ns walletdb.ReadWriteBucket) {\n\t\tblock := &BlockMeta{\n\t\t\tBlock: Block{Height: 1337},\n\t\t\tTime: time.Now(),\n\t\t}\n\t\tif err := store.InsertTx(ns, txRec, block); err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t\terr := store.AddCredit(ns, txRec, block, 0, false)\n\t\tif err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t})\n\n\t// We should not see any lingering unconfirmed records for it once it's\n\t// been confirmed.\n\tcommitDBTx(t, store, db, func(ns walletdb.ReadWriteBucket) {\n\t\tfor _, input := range tx.TxIn {\n\t\t\tprevOut := input.PreviousOutPoint\n\t\t\tk := canonicalOutPoint(&prevOut.Hash, prevOut.Index)\n\t\t\tif existsRawUnminedInput(ns, k) != nil {\n\t\t\t\tt.Fatalf(\"found transaction input %v as \"+\n\t\t\t\t\t\"unconfirmed\", prevOut)\n\t\t\t}\n\t\t}\n\t\tif existsRawUnmined(ns, txRec.Hash[:]) != nil {\n\t\t\tt.Fatal(\"found transaction as unconfirmed\")\n\t\t}\n\t\tfor i := range tx.TxOut {\n\t\t\tk := canonicalOutPoint(&txRec.Hash, uint32(i))\n\t\t\tif existsRawUnminedCredit(ns, k) != nil {\n\t\t\t\tt.Fatalf(\"found transaction output %v as \"+\n\t\t\t\t\t\"unconfirmed\", i)\n\t\t\t}\n\t\t}\n\t})\n}", "func (to *TxOutput) Lock(address []byte) {\n\tpubHashKey := internal.Base58Decode(address)\n\tpubHashKey = pubHashKey[1 : len(pubHashKey)-4]\n\tto.PubHashKey = pubHashKey\n}", "func XCHGW(amr, amr1 operand.Op) { ctx.XCHGW(amr, amr1) }", "func TccBarrierTransOutCancel(c *gin.Context) (interface{}, error) {\n\tbarrier := MustBarrierFromGin(c)\n\treturn dtmcli.MapSuccess, barrier.Call(txGet(), func(db dtmcli.DB) error {\n\t\treturn adjustTrading(db, transOutUID, reqFrom(c).Amount)\n\t})\n}", "func (heap *SkewHeap) lock() { heap.mutex.Lock() }", "func TestSetPreferenceRace(t *testing.T) {\n\t// Create two VMs which will agree on block A and then\n\t// build the two distinct preferred chains above\n\tissuer1, vm1, _, sharedMemory1 := GenesisVM(t, true, genesisJSONApricotPhase0, \"\", \"\")\n\tissuer2, vm2, _, sharedMemory2 := GenesisVM(t, true, genesisJSONApricotPhase0, \"\", \"\")\n\n\tdefer func() {\n\t\tif err := vm1.Shutdown(); err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\n\t\tif err := vm2.Shutdown(); err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t}()\n\n\tkey, err := accountKeystore.NewKey(rand.Reader)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Import 1 AVAX\n\timportAmount := uint64(1000000000)\n\tutxoID := avax.UTXOID{\n\t\tTxID: ids.ID{\n\t\t\t0x0f, 0x2f, 0x4f, 0x6f, 0x8e, 0xae, 0xce, 0xee,\n\t\t\t0x0d, 0x2d, 0x4d, 0x6d, 0x8c, 0xac, 0xcc, 0xec,\n\t\t\t0x0b, 0x2b, 0x4b, 0x6b, 0x8a, 0xaa, 0xca, 0xea,\n\t\t\t0x09, 0x29, 0x49, 0x69, 0x88, 0xa8, 0xc8, 0xe8,\n\t\t},\n\t}\n\n\tutxo := &avax.UTXO{\n\t\tUTXOID: utxoID,\n\t\tAsset: avax.Asset{ID: vm1.ctx.LUVAssetID},\n\t\tOut: &secp256k1fx.TransferOutput{\n\t\t\tAmt: importAmount,\n\t\t\tOutputOwners: secp256k1fx.OutputOwners{\n\t\t\t\tThreshold: 1,\n\t\t\t\tAddrs: []ids.ShortID{testKeys[0].PublicKey().Address()},\n\t\t\t},\n\t\t},\n\t}\n\tutxoBytes, err := vm1.codec.Marshal(codecVersion, utxo)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\txChainSharedMemory1 := sharedMemory1.NewSharedMemory(vm1.ctx.XChainID)\n\txChainSharedMemory2 := sharedMemory2.NewSharedMemory(vm2.ctx.XChainID)\n\tinputID := utxo.InputID()\n\tif err := xChainSharedMemory1.Put(vm1.ctx.ChainID, []*atomic.Element{{\n\t\tKey: inputID[:],\n\t\tValue: utxoBytes,\n\t\tTraits: [][]byte{\n\t\t\ttestKeys[0].PublicKey().Address().Bytes(),\n\t\t},\n\t}}); err != nil {\n\t\tt.Fatal(err)\n\t}\n\tif err := xChainSharedMemory2.Put(vm2.ctx.ChainID, []*atomic.Element{{\n\t\tKey: inputID[:],\n\t\tValue: utxoBytes,\n\t\tTraits: [][]byte{\n\t\t\ttestKeys[0].PublicKey().Address().Bytes(),\n\t\t},\n\t}}); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\timportTx, err := vm1.newImportTx(vm1.ctx.XChainID, key.Address, []*crypto.PrivateKeySECP256K1R{testKeys[0]})\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tif err := vm1.issueTx(importTx); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t<-issuer1\n\n\tvm1BlkA, err := vm1.BuildBlock()\n\tif err != nil {\n\t\tt.Fatalf(\"Failed to build block with import transaction: %s\", err)\n\t}\n\n\tif err := vm1BlkA.Verify(); err != nil {\n\t\tt.Fatalf(\"Block failed verification on VM1: %s\", err)\n\t}\n\n\tif status := vm1BlkA.Status(); status != choices.Processing {\n\t\tt.Fatalf(\"Expected status of built block to be %s, but found %s\", choices.Processing, status)\n\t}\n\n\tif err := vm1.SetPreference(vm1BlkA.ID()); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tvm2BlkA, err := vm2.ParseBlock(vm1BlkA.Bytes())\n\tif err != nil {\n\t\tt.Fatalf(\"Unexpected error parsing block from vm2: %s\", err)\n\t}\n\tif err := vm2BlkA.Verify(); err != nil {\n\t\tt.Fatalf(\"Block failed verification on VM2: %s\", err)\n\t}\n\tif status := vm2BlkA.Status(); status != choices.Processing {\n\t\tt.Fatalf(\"Expected status of block on VM2 to be %s, but found %s\", choices.Processing, status)\n\t}\n\tif err := vm2.SetPreference(vm2BlkA.ID()); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tif err := vm1BlkA.Accept(); err != nil {\n\t\tt.Fatalf(\"VM1 failed to accept block: %s\", err)\n\t}\n\tif err := vm2BlkA.Accept(); err != nil {\n\t\tt.Fatalf(\"VM2 failed to accept block: %s\", err)\n\t}\n\n\t// Create list of 10 successive transactions to build block A on vm1\n\t// and to be split into two separate blocks on VM2\n\ttxs := make([]*types.Transaction, 10)\n\tfor i := 0; i < 10; i++ {\n\t\ttx := types.NewTransaction(uint64(i), key.Address, big.NewInt(10), 21000, params.LaunchMinGasPrice, nil)\n\t\tsignedTx, err := types.SignTx(tx, types.NewEIP155Signer(vm1.chainID), key.PrivateKey)\n\t\tif err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t\ttxs[i] = signedTx\n\t}\n\n\tvar errs []error\n\n\t// Add the remote transactions, build the block, and set VM1's preference for block A\n\terrs = vm1.chain.AddRemoteTxs(txs)\n\tfor i, err := range errs {\n\t\tif err != nil {\n\t\t\tt.Fatalf(\"Failed to add transaction to VM1 at index %d: %s\", i, err)\n\t\t}\n\t}\n\n\t<-issuer1\n\n\tvm1BlkB, err := vm1.BuildBlock()\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tif err := vm1BlkB.Verify(); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tif status := vm1BlkB.Status(); status != choices.Processing {\n\t\tt.Fatalf(\"Expected status of built block to be %s, but found %s\", choices.Processing, status)\n\t}\n\n\tif err := vm1.SetPreference(vm1BlkB.ID()); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Split the transactions over two blocks, and set VM2's preference to them in sequence\n\t// after building each block\n\t// Block C\n\terrs = vm2.chain.AddRemoteTxs(txs[0:5])\n\tfor i, err := range errs {\n\t\tif err != nil {\n\t\t\tt.Fatalf(\"Failed to add transaction to VM2 at index %d: %s\", i, err)\n\t\t}\n\t}\n\n\t<-issuer2\n\tvm2BlkC, err := vm2.BuildBlock()\n\tif err != nil {\n\t\tt.Fatalf(\"Failed to build BlkC on VM2: %s\", err)\n\t}\n\n\tif err := vm2BlkC.Verify(); err != nil {\n\t\tt.Fatalf(\"BlkC failed verification on VM2: %s\", err)\n\t}\n\n\tif status := vm2BlkC.Status(); status != choices.Processing {\n\t\tt.Fatalf(\"Expected status of built block C to be %s, but found %s\", choices.Processing, status)\n\t}\n\n\tif err := vm2.SetPreference(vm2BlkC.ID()); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Block D\n\terrs = vm2.chain.AddRemoteTxs(txs[5:10])\n\tfor i, err := range errs {\n\t\tif err != nil {\n\t\t\tt.Fatalf(\"Failed to add transaction to VM2 at index %d: %s\", i, err)\n\t\t}\n\t}\n\n\t<-issuer2\n\tvm2BlkD, err := vm2.BuildBlock()\n\tif err != nil {\n\t\tt.Fatalf(\"Failed to build BlkD on VM2: %s\", err)\n\t}\n\n\tif err := vm2BlkD.Verify(); err != nil {\n\t\tt.Fatalf(\"BlkD failed verification on VM2: %s\", err)\n\t}\n\n\tif status := vm2BlkD.Status(); status != choices.Processing {\n\t\tt.Fatalf(\"Expected status of built block D to be %s, but found %s\", choices.Processing, status)\n\t}\n\n\tif err := vm2.SetPreference(vm2BlkD.ID()); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// VM1 receives blkC and blkD from VM1\n\t// and happens to call SetPreference on blkD without ever calling SetPreference\n\t// on blkC\n\t// Here we parse them in reverse order to simulate receiving a chain from the tip\n\t// back to the last accepted block as would typically be the case in the consensus\n\t// engine\n\tvm1BlkD, err := vm1.ParseBlock(vm2BlkD.Bytes())\n\tif err != nil {\n\t\tt.Fatalf(\"VM1 errored parsing blkD: %s\", err)\n\t}\n\tvm1BlkC, err := vm1.ParseBlock(vm2BlkC.Bytes())\n\tif err != nil {\n\t\tt.Fatalf(\"VM1 errored parsing blkC: %s\", err)\n\t}\n\n\t// The blocks must be verified in order. This invariant is maintained\n\t// in the consensus engine.\n\tif err := vm1BlkC.Verify(); err != nil {\n\t\tt.Fatalf(\"VM1 BlkC failed verification: %s\", err)\n\t}\n\tif err := vm1BlkD.Verify(); err != nil {\n\t\tt.Fatalf(\"VM1 BlkD failed verification: %s\", err)\n\t}\n\n\t// Set VM1's preference to blockD, skipping blockC\n\tif err := vm1.SetPreference(vm1BlkD.ID()); err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\t// Accept the longer chain on both VMs and ensure there are no errors\n\t// VM1 Accepts the blocks in order\n\tif err := vm1BlkC.Accept(); err != nil {\n\t\tt.Fatalf(\"VM1 BlkC failed on accept: %s\", err)\n\t}\n\tif err := vm1BlkD.Accept(); err != nil {\n\t\tt.Fatalf(\"VM1 BlkC failed on accept: %s\", err)\n\t}\n\n\t// VM2 Accepts the blocks in order\n\tif err := vm2BlkC.Accept(); err != nil {\n\t\tt.Fatalf(\"VM2 BlkC failed on accept: %s\", err)\n\t}\n\tif err := vm2BlkD.Accept(); err != nil {\n\t\tt.Fatalf(\"VM2 BlkC failed on accept: %s\", err)\n\t}\n\n\tlog.Info(\"Validating canonical chain\")\n\t// Verify the Canonical Chain for Both VMs\n\tif err := vm2.chain.ValidateCanonicalChain(); err != nil {\n\t\tt.Fatalf(\"VM2 failed canonical chain verification due to: %s\", err)\n\t}\n\n\tif err := vm1.chain.ValidateCanonicalChain(); err != nil {\n\t\tt.Fatalf(\"VM1 failed canonical chain verification due to: %s\", err)\n\t}\n}", "func (facade *BranchManagerFacade) createTransaction(srcAccountId, destAccountId string, amount float32) *Transaction {\n\n\tvar transaction = facade.transaction.create(srcAccountId, destAccountId, amount)\n\n\treturn transaction\n}", "func TestInsertMempoolDoubleSpendConfirmSecondTx(t *testing.T) {\n\tt.Parallel()\n\ttestInsertMempoolDoubleSpendTx(t, false)\n}", "func (cpu *Mos6502) brk() uint8 {\n\tcpu.pc++\n\n\tcpu.setStatusFlag(I, true)\n\tcpu.write(0x0100+word(cpu.stkp), byte((cpu.pc>>8)&0x00ff))\n\tcpu.stkp--\n\tcpu.write(0x0100+word(cpu.stkp), byte(cpu.pc&0x00ff))\n\tcpu.stkp--\n\n\tcpu.setStatusFlag(B, true)\n\tcpu.write(0x0100+word(cpu.stkp), cpu.status)\n\tcpu.stkp--\n\tcpu.setStatusFlag(B, false)\n\n\tcpu.pc = word(cpu.read(0xfffe)) | (word(cpu.read(0xffff)) << 8)\n\treturn 0\n}" ]
[ "0.66405576", "0.6607772", "0.554108", "0.5448886", "0.54120886", "0.53874964", "0.5366685", "0.5359955", "0.52475274", "0.5233689", "0.5108794", "0.50655013", "0.50646555", "0.506174", "0.49999192", "0.4976629", "0.4927358", "0.48909366", "0.48884553", "0.486731", "0.48570716", "0.4850142", "0.48376608", "0.48248813", "0.4815984", "0.48153377", "0.48127106", "0.47894424", "0.47872946", "0.47795644", "0.47693607", "0.47588652", "0.47470385", "0.47418204", "0.47236976", "0.47132114", "0.47074085", "0.4706868", "0.47054556", "0.4700303", "0.4697699", "0.46948552", "0.46910584", "0.4686853", "0.4672487", "0.4672487", "0.46717793", "0.46590814", "0.46536714", "0.4643201", "0.46327478", "0.46248907", "0.46209785", "0.46133044", "0.46101466", "0.4609069", "0.4591654", "0.4591654", "0.45912486", "0.45907724", "0.4581388", "0.45800695", "0.45792493", "0.4575821", "0.4573753", "0.45649022", "0.45627818", "0.4551695", "0.45515272", "0.45377374", "0.45345554", "0.45292118", "0.45290348", "0.45205227", "0.44975618", "0.44950795", "0.4493505", "0.44913083", "0.44859737", "0.44855744", "0.44850078", "0.44837004", "0.44796333", "0.44705945", "0.4462993", "0.4461753", "0.44547582", "0.44541022", "0.44503102", "0.44445103", "0.44429052", "0.44328594", "0.4427172", "0.44252762", "0.44205472", "0.44182074", "0.4414139", "0.439408", "0.43864134" ]
0.6305867
3
specifies minimum rate at which sample shading takes place
func MinSampleShading(value float32) { C.glowMinSampleShading(gpMinSampleShading, (C.GLfloat)(value)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func MinSampleShading(value float32) {\n C.glowMinSampleShading(gpMinSampleShading, (C.GLfloat)(value))\n}", "func (r SampleRateRange) Min() int {\n\treturn r.min\n}", "func sampledByRate(n uint64, rate float64) bool {\n\tif rate < 1 {\n\t\treturn n*knuthFactor < uint64(rate*math.MaxUint64)\n\t}\n\treturn true\n}", "func (pipe *pipe) SampleRate() uint {\n\treturn pipe.samplesPerSecond\n}", "func (info TrackInfo) SampleRate() int {\n\t// bits 23-0 - audio sample rate\n\treturn int(info & 0xFFFFFF)\n}", "func (e *Engine) SampleRate() int { return e.backend.SampleRate() }", "func (s *UniformSample) Min() int64 {\n\ts.mutex.Lock()\n\tdefer s.mutex.Unlock()\n\treturn gometrics.SampleMin(s.values)\n}", "func (self Source) SetMinGain(gain float32) {\n\tself.Setf(AlMinGain, gain)\n}", "func (t Track) SampleRate() int {\n\tpanic(\"implement me\")\n}", "func (s *Slider) Min(min float32) *Slider {\n\ts.min = min\n\treturn s\n}", "func (benchmark *BenchmarkStat) setLowest(lowest float64) {\n\tbenchmark.lowest = lowest\n}", "func (t *Track) MinBufferTime() float64 {\n\tsize := 0\n\tfor i := 0; i < len(t.samples); i++ {\n\t\tif int(t.samples[i].size) > size {\n\t\t\tsize = int(t.samples[i].size)\n\t\t}\n\t}\n\treturn float64(size) / float64(t.bandwidth)\n}", "func (s *maxEPSSampler) getSampleRate() float64 {\n\trate := 1.0\n\tcurrentEPS := s.rateCounter.GetRate()\n\tif currentEPS > s.maxEPS {\n\t\trate = s.maxEPS / currentEPS\n\t}\n\treturn rate\n}", "func (s *Source) Samplerate() (n uint) {\n\ts.ifOpen(func() {\n\t\tn = uint(C.aubio_source_get_samplerate(s.s))\n\t})\n\treturn\n}", "func (audio *Audio) SampleRate() int {\n\treturn audio.sampleRate\n}", "func (s *Sink) Samplerate() uint {\n\treturn s.samplerate\n}", "func SetSmoothing(s float32) {\n\tsmoothing = s\n}", "func (h *Halo) MinR() float64 { return 0.0001 * h.Rs }", "func Samplerate(s float64) Option {\n\treturn func(args *Options) {\n\t\targs.Samplerate = s\n\t}\n}", "func MinFadeExtent(value int) *SimpleElement { return newSEInt(\"minFadeExtent\", value) }", "func (this *Stats) InputBitRate() float32 { return float32(this.ptr.f_input_bitrate) }", "func (s *maxEPSSampler) Sample(event *pb.Span) (sampled bool, rate float64) {\n\t// Count that we saw a new event\n\ts.rateCounter.Count()\n\trate = 1.0\n\tcurrentEPS := s.rateCounter.GetRate()\n\tif currentEPS > s.maxEPS {\n\t\trate = s.maxEPS / currentEPS\n\t}\n\tsampled = sampler.SampleByRate(event.TraceID, rate)\n\treturn\n}", "func (self Source) GetMinGain() (gain float32) {\n\treturn self.Getf(AlMinGain)\n}", "func (r *Reader) setRate(lim rate.Limit) bool {\n\tmin := rate.Every(r.starvationLatency)\n\tmax := r.globalLimit.Limit()\n\n\tif lim < min {\n\t\tlim = min\n\t} else if lim > max {\n\t\tlim = max\n\t}\n\n\tprev := r.adaptiveLimit.Limit()\n\n\tif lim != prev {\n\t\tr.adaptiveLimit.SetLimit(lim)\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (m *MeterSnapshot) RateMean() float64 { return m.rateMean }", "func (stab *adaptiveStabilize) rand() time.Duration {\n\tr := rand.Float64()\n\td := time.Duration((r * float64(stab.max-stab.min)) + float64(stab.min))\n\n\t// check if adaptive stabilize is enabled\n\tif stab.min < stab.threshold {\n\t\tif stab.c > stab.stayCount {\n\t\t\tstab.step()\n\t\t} else {\n\t\t\tstab.c++\n\t\t}\n\t}\n\n\treturn d\n}", "func (r *rateSampler) SetRate(rate float64) {\n\tr.Lock()\n\tr.rate = rate\n\tr.Unlock()\n}", "func (skeleton *Skeleton) SmoothingFactor() float32 {\n\n\tvar value C.float\n\n\tC.getObjParamFloat((C.gpointer)(skeleton.skeleton), C.CString(\"smoothing-factor\"), &value)\n\n\treturn float32(value)\n}", "func (NilTimer) RateMean() float64 { return 0.0 }", "func (r *rateSampler) Rate() float64 {\n\tr.RLock()\n\tdefer r.RUnlock()\n\treturn r.rate\n}", "func (m *MeterSnapshot) Rate1() float64 { return m.rate1 }", "func Quantize(buf *audio.PCMBuffer, bitDepth int) {\n\tif buf == nil {\n\t\treturn\n\t}\n\tmax := math.Pow(2, float64(bitDepth)) - 1\n\n\tbuf.SwitchPrimaryType(audio.Float)\n\tbufLen := buf.Len()\n\tfor i := 0; i < bufLen; i++ {\n\t\tbuf.Floats[i] = round((buf.Floats[i]+1)*max)/max - 1.0\n\t}\n}", "func (r *RecordStream) SampleRate() int {\n\treturn int(r.createReply.Rate)\n}", "func (t *TimerSnapshot) RateMean() float64 { return t.meter.RateMean() }", "func extrapolatedRate(samples []promql.Point, selRange time.Duration, isCounter, isRate bool) float64 {\n\t// No sense in trying to compute a rate without at least two points. Drop\n\t// this Vector element.\n\tif len(samples) < 2 {\n\t\treturn 0\n\t}\n\tvar (\n\t\trangeStart = samples[0].T - durationMilliseconds(selRange)\n\t\trangeEnd = samples[len(samples)-1].T\n\t)\n\n\tresultValue := samples[len(samples)-1].V - samples[0].V\n\tif isCounter {\n\t\tvar lastValue float64\n\t\tfor _, sample := range samples {\n\t\t\tif sample.V < lastValue {\n\t\t\t\tresultValue += lastValue\n\t\t\t}\n\t\t\tlastValue = sample.V\n\t\t}\n\t}\n\n\t// Duration between first/last samples and boundary of range.\n\tdurationToStart := float64(samples[0].T-rangeStart) / 1000\n\tdurationToEnd := float64(rangeEnd-samples[len(samples)-1].T) / 1000\n\n\tsampledInterval := float64(samples[len(samples)-1].T-samples[0].T) / 1000\n\taverageDurationBetweenSamples := sampledInterval / float64(len(samples)-1)\n\n\tif isCounter && resultValue > 0 && samples[0].V >= 0 {\n\t\t// Counters cannot be negative. If we have any slope at\n\t\t// all (i.e. resultValue went up), we can extrapolate\n\t\t// the zero point of the counter. If the duration to the\n\t\t// zero point is shorter than the durationToStart, we\n\t\t// take the zero point as the start of the series,\n\t\t// thereby avoiding extrapolation to negative counter\n\t\t// values.\n\t\tdurationToZero := sampledInterval * (samples[0].V / resultValue)\n\t\tif durationToZero < durationToStart {\n\t\t\tdurationToStart = durationToZero\n\t\t}\n\t}\n\n\t// If the first/last samples are close to the boundaries of the range,\n\t// extrapolate the result. This is as we expect that another sample\n\t// will exist given the spacing between samples we've seen thus far,\n\t// with an allowance for noise.\n\textrapolationThreshold := averageDurationBetweenSamples * 1.1\n\textrapolateToInterval := sampledInterval\n\n\tif durationToStart < extrapolationThreshold {\n\t\textrapolateToInterval += durationToStart\n\t} else {\n\t\textrapolateToInterval += averageDurationBetweenSamples / 2\n\t}\n\tif durationToEnd < extrapolationThreshold {\n\t\textrapolateToInterval += durationToEnd\n\t} else {\n\t\textrapolateToInterval += averageDurationBetweenSamples / 2\n\t}\n\tresultValue = resultValue * (extrapolateToInterval / sampledInterval)\n\tif isRate {\n\t\tseconds := selRange.Seconds()\n\t\tresultValue = resultValue / seconds\n\t}\n\n\treturn resultValue\n}", "func (t *tracer) sample(span *span) {\n\tif _, ok := span.context.samplingPriority(); ok {\n\t\t// sampling decision was already made\n\t\treturn\n\t}\n\tsampler := t.config.sampler\n\tif !sampler.Sample(span) {\n\t\tspan.context.trace.drop()\n\t\treturn\n\t}\n\tif rs, ok := sampler.(RateSampler); ok && rs.Rate() < 1 {\n\t\tspan.setMetric(sampleRateMetricKey, rs.Rate())\n\t}\n\tif t.rulesSampling.SampleTrace(span) {\n\t\treturn\n\t}\n\tt.prioritySampling.apply(span)\n}", "func newAudioSampler(clockRate uint32, latency time.Duration) samplerFunc {\n\tsamples := uint32(math.Round(float64(clockRate) * latency.Seconds()))\n\treturn samplerFunc(func() uint32 {\n\t\treturn samples\n\t})\n}", "func (t *Sampler) SampleRate() Rate {\n\treturn t.sampleRate\n}", "func (a *AudioData) SampleRate() int {\n\treturn a.format.SampleRate\n}", "func SampleCoverage(value float32, invert bool) {\n C.glowSampleCoverage(gpSampleCoverage, (C.GLfloat)(value), (C.GLboolean)(boolToInt(invert)))\n}", "func (o *SyntheticMonitorUpdate) SetFrequencyMin(v int32) {\n\to.FrequencyMin = v\n}", "func (a *StandardEWMA) Tick(t time.Time) {\n\tdiff_time := t.Sub(a.lastUpdate)\n\tif diff_time > 0 {\n\t\tdiff_time_sec := diff_time / 1e9\n\n\t\tinstantRate := float64(a.uncounted) / float64(diff_time_sec)\n\n\t\t//Recalculate alpha\n\t\talpha := float64(1 - math.Exp(float64(-diff_time_sec)/60.0/float64(a.over)))\n\n\t\t//fmt.Printf(\"instant: %f / %f = %f\\n\", float64(a.uncounted), float64(diff_time/1e9), float64(a.uncounted)/float64(diff_time/1e9))\n\t\t//fmt.Printf(\"alpha: (1 - Exp(%f / 30 / %f) ) = %f\\n\", float64(-diff_time_sec), float64(a.over), float64(1-math.Exp(float64(-diff_time)/60.0/float64(a.over))))\n\t\t//fmt.Printf(\"rate: %f * (%f - %f) = %f -> +%f = %f\\n\", alpha, instantRate, a.rate, alpha*(instantRate-a.rate), a.rate, a.rate+alpha*(instantRate-a.rate))\n\t\tif a.init {\n\t\t\ta.rate += alpha * (instantRate - a.rate)\n\t\t} else {\n\t\t\ta.init = true\n\t\t\ta.rate = instantRate\n\t\t}\n\t\ta.uncounted = 0\n\t\ta.lastUpdate = t\n\t}\n}", "func detune(in rate.Limit) rate.Limit {\n\tif in <= 1 {\n\t\treturn in / 2\n\t}\n\treturn in - 1\n}", "func (t *TimerSnapshot) Min() int64 { return t.histogram.Min() }", "func rate(read int64, t time.Duration) float64 {\n\treturn float64(read) / (1024 * 1024) / t.Seconds()\n}", "func steeringPowerCurve(percent float32) float32 {\n\tif percent < 0 {\n\t\treturn (2*percent + 100)\n\t} else {\n\t\treturn 100\n\t}\n}", "func (client *Client) isSendAcceptedBySampleRate(sampleRate float32) bool {\n\tif sampleRate >= 1 {\n\t\treturn true\n\t}\n\trandomNumber := client.rand.Float32()\n\treturn randomNumber <= sampleRate\n}", "func (t *TimerSnapshot) Rate1() float64 { return t.meter.Rate1() }", "func MaxSamplingRate(r int) middleware.TraceOption {\n\treturn middleware.MaxSamplingRate(r)\n}", "func (filter *Saturation) IsScalable() {\n}", "func (r *rateSampler) Sample(spn ddtrace.Span) bool {\n\tif r.rate == 1 {\n\t\t// fast path\n\t\treturn true\n\t}\n\ts, ok := spn.(*span)\n\tif !ok {\n\t\treturn false\n\t}\n\tr.RLock()\n\tdefer r.RUnlock()\n\treturn sampledByRate(s.TraceID, r.rate)\n}", "func (b Backoff) jitterLow() float64 {\n\treturn -b.Jitter * rand.Float64()\n}", "func (cp *ConstantPacer) Rate(elapsed time.Duration) float64 {\n\treturn cp.hitsPerNs() * 1e9\n}", "func (t *StandardTimer) Min() int64 {\n\treturn t.histogram.Min()\n}", "func (x *Float) MinPrec() uint {}", "func (NilTimer) Rate1() float64 { return 0.0 }", "func (m *MeterSnapshot) Rate15() float64 { return m.rate15 }", "func (s *State) Minus() {\n\ts.DataInc(-int(s.mem[s.ptr+1]), 0)\n\ts.mem[s.ptr+1] = 0\n\n\tif statistics {\n\t\ts.stats.minOp++\n\t}\n}", "func (bucket *Bucket) Rate() float64 {\n\treturn 1e9 / float64(bucket.fillInterval)\n}", "func (z *Float64) Minus(y *Float64, a float64) *Float64 {\n\tz.l = y.l - a\n\tz.r = y.r\n\treturn z\n}", "func AlwaysSample() Sampler {\n\treturn alwaysOnSampler{}\n}", "func MakeLowPass(h []float64, wf window.Func, cutoff float64) {\n\tn := len(h)\n\tfor i := range h {\n\t\tx := 2 * math.Pi * cutoff\n\t\tif i == n/2 {\n\t\t\th[i] = x\n\t\t} else {\n\t\t\ty := float64(i) - float64(n)/2\n\t\t\th[i] = (math.Sin(x*y) / y) * wf(float64(i), n)\n\t\t}\n\t}\n\tnormalize(h)\n}", "func (d *Detector) SetSampleRate(x int) error {\n\terrno := C.fvad_set_sample_rate(d.fvad, C.int(x))\n\tif errno != 0 {\n\t\treturn fmt.Errorf(\"invalid sample rate: %v\", x)\n\t}\n\treturn nil\n}", "func (cma *CMA) AddSample(s int) float64 {\n\tcma.avg = cma.avg + (float64(s)-cma.avg)/float64(cma.n+1)\n\tcma.n++\n\treturn cma.avg\n}", "func INC_MED0(wps *WavpackStream, channel int) {\n\twps.w.median[0][channel] += (((wps.w.median[0][channel] + DIV0) / DIV0) * 5)\n}", "func (p *StepPacer) Rate(elapsed time.Duration) float64 {\n\tp.initialize()\n\n\tt := elapsed\n\n\tif p.constAt > 0 && elapsed >= p.constAt {\n\t\treturn float64(p.Stop.Freq)\n\t}\n\n\tsteps := t.Nanoseconds() / p.StepDuration.Nanoseconds()\n\n\trate := (p.Start.hitsPerNs() + float64(int64(p.Step)*steps)/nano) * 1e9\n\n\tif rate < 0 {\n\t\trate = 0\n\t}\n\n\treturn rate\n}", "func (skeleton *Skeleton) SetSmoothingFactor(value float32) {\n\n\tC.setObjParamFloat((C.gpointer)(skeleton.skeleton), C.CString(\"smoothing-factor\"), C.float(value))\n}", "func (t *TimerSnapshot) Rate15() float64 { return t.meter.Rate15() }", "func (self Source) SetRolloffFactor(gain float32) {\n\tself.Setf(AlRolloffFactor, gain)\n}", "func (NilTimer) Rate15() float64 { return 0.0 }", "func MinFilter(a, b int64) bool {\n\treturn a <= b\n}", "func NextSample() []Value {\n\tsmp := make([]Value, masterSpec.Channels)\n\tvar fireSample []Value\n\tfor _, fire := range mixLiveFires {\n\t\tif fireTz := fire.FireAt(nowTz); fireTz > 0 {\n\t\t\tfireSample = mixSourceAt(fire.Source, fire.Volume, fire.Pan, fireTz)\n\t\t\tfor c := 0; c < masterSpec.Channels; c++ {\n\t\t\t\tsmp[c] += fireSample[c]\n\t\t\t}\n\t\t}\n\t}\n\t//\tdebug.Printf(\"*Mixer.nextSample %+v\\n\", sample)\n\tnowTz++\n\tout := make([]Value, masterSpec.Channels)\n\tfor c := 0; c < masterSpec.Channels; c++ {\n\t\tout[c] = mixLogarithmicRangeCompression(smp[c])\n\t}\n\tif nowTz > nextCycleTz {\n\t\tmixCycle()\n\t}\n\treturn out\n}", "func ParseSamplingRate(s string) (float64, error) {\n\tv, err := ParseFloat64(s)\n\tif err != nil {\n\t\treturn 0.0, err\n\t}\n\tif v < 0.0 {\n\t\treturn -1.0 / v, nil\n\t}\n\treturn v, nil\n}", "func (a Energy) RandomGain(rnd *rand.Rand) Energy {\n\tgreatest := geom.Vector3(a).Greatest()\n\tif rnd.Float64() > greatest {\n\t\treturn Energy{}\n\t}\n\treturn a.Amplified(1 / greatest)\n}", "func (skeleton *Skeleton) SetSmoothing(value bool) {\n\n\tC.setObjParamBool((C.gpointer)(skeleton.skeleton), C.CString(\"enable-smoothing\"), C.bool(value))\n}", "func (m *ParameterMutator) Minimum(v float64) *ParameterMutator {\n\tm.proxy.minimum = &v\n\treturn m\n}", "func (m Metric) MinLevel(val float64) int {\n\tif val < 0 {\n\t\treturn maxLevel\n\t}\n\n\tlevel := -(math.Ilogb(val/m.Deriv) >> uint(m.Dim-1))\n\tif level > maxLevel {\n\t\tlevel = maxLevel\n\t}\n\tif level < 0 {\n\t\tlevel = 0\n\t}\n\treturn level\n}", "func (d *Device) UseLowPower(power bool) {\n\tif power {\n\t\td.bwRate.lowPower = 1\n\t} else {\n\t\td.bwRate.lowPower = 0\n\t}\n\td.bus.WriteRegister(uint8(d.Address), REG_BW_RATE, []byte{d.bwRate.toByte()})\n}", "func GetMultisamplefv(pname uint32, index uint32, val *float32) {\n C.glowGetMultisamplefv(gpGetMultisamplefv, (C.GLenum)(pname), (C.GLuint)(index), (*C.GLfloat)(unsafe.Pointer(val)))\n}", "func (o BackendServiceLogConfigOutput) SampleRate() pulumi.Float64PtrOutput {\n\treturn o.ApplyT(func(v BackendServiceLogConfig) *float64 { return v.SampleRate }).(pulumi.Float64PtrOutput)\n}", "func increaseBetweenSamples(previousSample, sample model.SamplePair) float64 {\n\tif sample.Value < previousSample.Value {\n\t\t// counter reset\n\t\treturn float64(sample.Value)\n\t}\n\treturn float64(sample.Value) - float64(previousSample.Value)\n}", "func min(a, b float64) float64 {\n\tif a < b {\n\t\treturn a\n\t}\n\treturn b\n}", "func Min(a, b float64) float64 {\n\tif a < b {\n\t\treturn a\n\t}\n\treturn b\n}", "func Min(a, b float64) float64 {\n\tif a < b {\n\t\treturn a\n\t}\n\treturn b\n}", "func Min(a, b float64) float64 {\n\tif a < b {\n\t\treturn a\n\t}\n\treturn b\n}", "func shouldKeep(rate uint) bool {\n\tif rate <= 1 {\n\t\treturn true\n\t}\n\n\treturn rand.Intn(int(rate)) == 0\n}", "func Ramp(x float64) float64 {\n\tif x < 0.0 {\n\t\treturn 0.0\n\t}\n\treturn x\n}", "func (r *ASF) AmplRampRate() uint16 {\n\treturn binary.BigEndian.Uint16(r[:2])\n}", "func extractSampleRate(data []byte) uint32 {\n\t// Skip 40 bits (28 of the OGG header + 12 of the Opus header) and read the\n\t// next 4 bits to extract the sample rate as an int.\n\tif len(data) < 44 {\n\t\tlog.Panicf(\"unexpected data length: %v\", len(data))\n\t}\n\n\treturn binary.LittleEndian.Uint32(data[40:44])\n}", "func funcClampMin(vals []parser.Value, args parser.Expressions, enh *EvalNodeHelper) Vector {\n\tvec := vals[0].(Vector)\n\tmin := vals[1].(Vector)[0].F\n\tfor _, el := range vec {\n\t\tenh.Out = append(enh.Out, Sample{\n\t\t\tMetric: enh.DropMetricName(el.Metric),\n\t\t\tF: math.Max(min, el.F),\n\t\t})\n\t}\n\treturn enh.Out\n}", "func isSilent(audio []int16) bool {\n\tvar max int16 = audio[0]\n\tfor _, value := range audio {\n\t\tif value > max {\n\t\t\tmax = value\n\t\t}\n\t}\n\treturn max < SilentThresh\n}", "func blockSize(rate int) int {\n\tconst playbackBufferedTimeUs = 5000\n\treturn rate * playbackBufferedTimeUs / 1000000\n}", "func (this *NurbsCurve) adaptiveSample(tol *float64, includeU *bool) []CurvePoint {\n\tvar _tol float64\n\tif tol == nil {\n\t\t_tol = 1e-6\n\t} else {\n\t\t_tol = *tol\n\t}\n\n\tvar _includeU bool\n\tif includeU != nil {\n\t\t_includeU = *includeU\n\t}\n\n\t// if degree is 1, just return the dehomogenized control points\n\tif this.degree == 1 {\n\t\tsamples := make([]CurvePoint, len(this.controlPoints))\n\t\t// the first element of each array is the parameter\n\t\tfor i := range this.controlPoints {\n\t\t\tsamples[i] = CurvePoint{this.knots[i+1], this.controlPoints[i].Dehomogenized()}\n\t\t}\n\t\treturn samples\n\t}\n\n\treturn this.adaptiveSampleRange(this.knots[0], this.knots[len(this.knots)-1], _tol, _includeU)\n}", "func (o BackendServiceLogConfigResponseOutput) SampleRate() pulumi.Float64Output {\n\treturn o.ApplyT(func(v BackendServiceLogConfigResponse) float64 { return v.SampleRate }).(pulumi.Float64Output)\n}", "func (snd *HwSound) step() (uint16, uint16) {\n\tvar lmix, rmix int64\n\tvar chbuf [4]int64\n\n\t// Master enable\n\tif snd.SndGCnt.Value&(1<<15) == 0 {\n\t\treturn uint16(snd.SndBias.Value), uint16(snd.SndBias.Value)\n\t}\n\n\tscans := []int{\n\t\thw.SCANCODE_0,\n\t\thw.SCANCODE_1,\n\t\thw.SCANCODE_2,\n\t\thw.SCANCODE_3,\n\t\thw.SCANCODE_4,\n\t\thw.SCANCODE_5,\n\t\thw.SCANCODE_6,\n\t\thw.SCANCODE_7,\n\t\thw.SCANCODE_8,\n\t\thw.SCANCODE_9,\n\t}\n\n\tkeys := hw.GetKeyboardState()\n\tmask := 0xFFFF\n\tpressed := 0\n\tfor i := 0; i < len(scans); i++ {\n\t\tif keys[scans[i]] != 0 {\n\t\t\tpressed |= 1 << uint(i)\n\t\t}\n\t}\n\tif pressed != 0 {\n\t\tmask = pressed\n\t}\n\n\tfor i := 0; i < 16; i++ {\n\t\tvar sample int64\n\n\t\tcntrl := snd.Ch[i].SndCnt.Value\n\t\tvoice := &snd.voice[i]\n\n\t\tif !voice.on {\n\t\t\tcontinue\n\t\t}\n\t\tif mask&(1<<uint(i)) == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\tvoice.tmr += cTimerStepPerSample\n\t\tfor voice.tmr >= 0x10000 {\n\t\t\tif voice.delay >= 0 {\n\t\t\t\tvoice.delay--\n\t\t\t} else {\n\t\t\t\tvoice.pos++\n\t\t\t}\n\t\t\tvoice.tmr = uint32(snd.Ch[i].SndTmr.Value) + (voice.tmr - 0x10000)\n\t\t}\n\t\tif voice.delay >= 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\tswitch voice.mode {\n\t\tcase kMode8bit:\n\t\t\tif int(voice.pos) >= len(voice.mem) {\n\t\t\t\tvoice.pos = voice.pos + snd.loopChannel(i) - uint(len(voice.mem))\n\t\t\t\tif voice.pos == kPosNoLoop {\n\t\t\t\t\tsnd.stopChannel(i)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tsample = int64(int8(voice.mem[voice.pos])) << 8\n\t\tcase kMode16bit, kModeAdpcm:\n\t\t\tif int(voice.pos*2+1) >= len(voice.mem) {\n\t\t\t\tvoice.pos = voice.pos + snd.loopChannel(i) - uint(len(voice.mem)/2)\n\t\t\t\tif voice.pos == kPosNoLoop || int(voice.pos*2+1) >= len(voice.mem) {\n\t\t\t\t\tsnd.stopChannel(i)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tsample = int64(int16(binary.LittleEndian.Uint16(voice.mem[voice.pos*2:])))\n\t\tcase kModePsgNoise:\n\t\t\tfor int(voice.pos*2+1) >= len(voice.mem) {\n\t\t\t\tvoice.pos -= uint(len(voice.mem)) / 2\n\t\t\t}\n\t\t\tsample = int64(int16(binary.LittleEndian.Uint16(voice.mem[voice.pos*2:])))\n\t\t}\n\n\t\t// Convert into fixed point to keep some precision\n\t\tsample <<= 8\n\n\t\t// Apply volume divider\n\t\tsample >>= voldiv[(cntrl>>8)&3]\n\n\t\t// Apply channel volume\n\t\tsample = mulvol64(sample, int64(cntrl&127))\n\n\t\tif i < 4 {\n\t\t\t// Save copy of channels used in capture\n\t\t\tchbuf[i] = sample\n\n\t\t\t// Check specific \"Channel 1/3 disable\" bit\n\t\t\tif i == 1 && snd.SndGCnt.Value&(1<<12) != 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif i == 3 && snd.SndGCnt.Value&(1<<13) != 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\n\t\t// Apply panning\n\t\tpan := int64((cntrl >> 16) & 127)\n\t\tlsample := mulvol64(sample, 127-pan)\n\t\trsample := mulvol64(sample, pan)\n\n\t\t// Mix\n\t\tlmix += int64(lsample)\n\t\trmix += int64(rsample)\n\t}\n\n\t// Handle capture\n\tfor i := 0; i < 2; i++ {\n\t\tcap := &snd.capture[i]\n\t\tif cap.on {\n\t\t\tvar sample int64\n\t\t\tif !cap.single {\n\t\t\t\tif i == 0 {\n\t\t\t\t\tsample = lmix\n\t\t\t\t} else {\n\t\t\t\t\tsample = rmix\n\t\t\t\t}\n\t\t\t\tif sample > 0x7FFF00 {\n\t\t\t\t\tsample = 0x7FFF00\n\t\t\t\t}\n\t\t\t\tif sample < -0x800000 {\n\t\t\t\t\tsample = -0x800000\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tsample = chbuf[i*2]\n\t\t\t}\n\t\t\tif cap.add {\n\t\t\t\tpanic(\"capture with addition\")\n\t\t\t}\n\n\t\t\tcap.tmr += cTimerStepPerSample\n\t\t\tfor cap.tmr >= 0x10000 {\n\t\t\t\tif cap.bit8 {\n\t\t\t\t\tsnd.Bus.Write8(cap.wpos, uint8(sample>>16))\n\t\t\t\t\tcap.wpos++\n\t\t\t\t} else {\n\t\t\t\t\tsnd.Bus.Write16(cap.wpos, uint16(sample>>8))\n\t\t\t\t\tcap.wpos += 2\n\t\t\t\t}\n\n\t\t\t\tcap.tmr = uint32(cap.reset) + (cap.tmr - 0x10000)\n\t\t\t\tif cap.wpos >= *cap.regdad+*cap.reglen*4 {\n\t\t\t\t\tif cap.loop {\n\t\t\t\t\t\tcap.wpos = *cap.regdad\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcap.on = false\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tswitch (snd.SndGCnt.Value >> 8) & 3 {\n\tcase 1:\n\t\tlmix = chbuf[1]\n\tcase 2:\n\t\tlmix = chbuf[3]\n\tcase 3:\n\t\tlmix = chbuf[1] + chbuf[3]\n\t}\n\tswitch (snd.SndGCnt.Value >> 10) & 3 {\n\tcase 1:\n\t\trmix = chbuf[1]\n\tcase 2:\n\t\trmix = chbuf[3]\n\tcase 3:\n\t\trmix = chbuf[1] + chbuf[3]\n\t}\n\n\t// Apply master volume\n\tgvol := int64(snd.SndGCnt.Value & 127)\n\tlmix = mulvol64(lmix, gvol)\n\trmix = mulvol64(rmix, gvol)\n\n\t// Adjust volume after mixing\n\tlmix >>= 6\n\trmix >>= 6\n\n\t// Convert from fixed into integer (strip fraction)\n\tlmix >>= 8\n\trmix >>= 8\n\n\t// Bias\n\tlmix += int64(snd.SndBias.Value)\n\trmix += int64(snd.SndBias.Value)\n\n\t// Clamp\n\tif lmix < 0 {\n\t\tlmix = 0\n\t} else if lmix > 0x3FF {\n\t\tlmix = 0x3FF\n\t}\n\tif rmix < 0 {\n\t\trmix = 0\n\t} else if rmix > 0x3FF {\n\t\trmix = 0x3FF\n\t}\n\n\treturn uint16(lmix), uint16(rmix)\n}", "func (p *LinearPacer) Rate(elapsed time.Duration) float64 {\n\n\tp.initialize()\n\n\treturn p.sp.Rate(elapsed)\n}", "func (ps *prioritySampler) apply(spn *span) {\n\trate := ps.getRate(spn)\n\tif sampledByRate(spn.TraceID, rate) {\n\t\tspn.setSamplingPriority(ext.PriorityAutoKeep, samplernames.AgentRate, rate)\n\t} else {\n\t\tspn.setSamplingPriority(ext.PriorityAutoReject, samplernames.AgentRate, rate)\n\t}\n\tspn.SetTag(keySamplingPriorityRate, rate)\n}", "func (p *PhongMaterial) SampleSource(gen *rand.Rand, normal, dest model3d.Coord3D) model3d.Coord3D {\n\tif (p.DiffuseColor == Color{}) || gen.Intn(2) == 0 {\n\t\treturn p.sampleSpecular(gen, normal, dest)\n\t} else {\n\t\treturn (&LambertMaterial{}).SampleSource(gen, normal, dest)\n\t}\n}", "func RenderbufferStorageMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32) {\n C.glowRenderbufferStorageMultisample(gpRenderbufferStorageMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}" ]
[ "0.69525874", "0.5761213", "0.5586719", "0.5427825", "0.53727233", "0.52970135", "0.52669567", "0.525126", "0.52380306", "0.5237382", "0.52358687", "0.5217763", "0.51991206", "0.5196979", "0.51644117", "0.515831", "0.5077799", "0.5074383", "0.5047952", "0.500161", "0.49871653", "0.4971175", "0.49653643", "0.4959544", "0.49067", "0.48916206", "0.48870352", "0.48641202", "0.48620018", "0.48590088", "0.4845989", "0.48421767", "0.48333776", "0.48267227", "0.48104715", "0.47965363", "0.4785941", "0.47713736", "0.47625694", "0.4733181", "0.47283655", "0.4707921", "0.46885213", "0.46859786", "0.46848434", "0.46743554", "0.46712562", "0.46690798", "0.4668909", "0.4655052", "0.4654565", "0.462872", "0.4625069", "0.46231514", "0.46007046", "0.45951846", "0.4593783", "0.4591716", "0.4579909", "0.45771858", "0.45731962", "0.45687228", "0.45599332", "0.45559266", "0.45559126", "0.45558244", "0.4552233", "0.45462772", "0.45356986", "0.45345706", "0.45338044", "0.4531835", "0.4517788", "0.45174706", "0.44996235", "0.44959107", "0.4478122", "0.447003", "0.44698727", "0.4466861", "0.44662744", "0.4465049", "0.44631243", "0.44631243", "0.44631243", "0.4462661", "0.44581988", "0.44567943", "0.44559374", "0.44545215", "0.44521153", "0.4440039", "0.44397944", "0.4434717", "0.44334465", "0.44298404", "0.44296044", "0.4429385", "0.44286665" ]
0.6701467
2
render multiple sets of primitives from array data
func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) { C.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount)) }
{ "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 (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 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 (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 (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 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 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 DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\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\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 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 (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 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 (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 *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 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 (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 DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\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 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 (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 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 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 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 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 C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\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 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 (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\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 RenderSetChoice(resp http.ResponseWriter, req *http.Request, ext string, mode primitive.Mode, fileSeeker io.ReadSeeker) {\n\n\top := []OptStruct{\n\t\t{20, mode},\n\t\t{30, mode},\n\t\t{40, mode},\n\t\t{50, mode},\n\t}\n\topFileList, err := GenImgList(ext, fileSeeker, op...)\n\tif err != nil {\n http.Error(resp, err.Error(), http.StatusInternalServerError)\n return\n\t}\n\thtmlist := `<html>\n <body>\n {{range .}}\n <a href=\"/modify/{{.Name}}?mode={{.Mode}}&n={{.Numshapes}}\">\n <img style =\"width 30%\" src=\"/pics/{{.Name}}\">\n {{end}}\n </body>\n </html>\n `\n\ttempl := template.Must(template.New(\"\").Parse(htmlist))\n\n\ttype Opts struct {\n\t\tName string\n\t\tMode primitive.Mode\n\t\tNumshapes int\n\t}\n\tvar opts []Opts\n\tfor index, val := range opFileList {\n\t\topts = append(opts, Opts{Name: filepath.Base(val), Mode: op[index].mode, Numshapes: op[index].num})\n\t}\n\n\t// err = templ.Execute(resp, opts)\n\t// if err != nil {\n\t// \tpanic(err)\n\t// }\n checkError(templ.Execute(resp,opts))\n}", "func (sl SprintList) renderPlain(w io.Writer) error {\n\treturn renderPlain(w, sl.tableData())\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 (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 (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 *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 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 output3d(values []int) {\n\tfor _, v := range values {\n\t\tfmt.Printf(\"%03d \",v)\n\t}\n\tfmt.Println()\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 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 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 (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 (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 RenderInitialChoices(resp http.ResponseWriter, req *http.Request, ext string, fileSeeker io.ReadSeeker) {\n\top := []OptStruct{\n\t\t{22, primitive.TriangleMode},\n\t\t{22, primitive.CircleMode},\n\t\t{22, primitive.ComboMode},\n\t\t{22, primitive.PolygonMode},\n\t}\n\topFileList, err := GenImgList(ext, fileSeeker, op...)\n\tif err != nil {\n http.Error(resp, err.Error(), http.StatusInternalServerError)\n return\n\t}\n\thtmlist := `<html>\n <body>\n {{range .}}\n <a href=\"/modify/{{.Name}}?mode={{.Mode}}\">\n <img style =\"width 30%\" src=\"/pics/{{.Name}}\">\n {{end}}\n </body>\n </html>\n `\n\ttempl := template.Must(template.New(\"\").Parse(htmlist))\n \ntype Opts struct {\n Name string\n Mode primitive.Mode\n}\n\tvar opts []Opts\n\tfor index, val := range opFileList {\n\t\topts = append(opts, Opts{Name: filepath.Base(val), Mode: op[index].mode})\n\t}\n\n\t// err = templ.Execute(resp, opts)\n\t// if err != nil {\n\t// \tpanic(err)\n // }\n checkError(templ.Execute(resp, opts))\n \n\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 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 (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 (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 (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 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 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 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 (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 (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 (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 (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 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 (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 (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func renderTable(v *gocui.View, columns []string, resultSet [][]string) {\n\ttable := tablewriter.NewWriter(v)\n\ttable.SetBorders(tablewriter.Border{Left: true, Top: false, Right: true, Bottom: true})\n\ttable.SetHeader(columns)\n\t// Add Bulk Data.\n\ttable.AppendBulk(resultSet)\n\ttable.Render()\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 *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 (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 (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 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 renderAlerts(level uint8, alerts []check.Alert) {\n\ttotalAlerts := len(alerts)\n\n\tfor index, alert := range alerts {\n\t\trenderAlert(alert)\n\n\t\tif index+1 < totalAlerts {\n\t\t\tfmtc.Printf(fgColor[level] + \"│{!}\\n\")\n\t\t}\n\t}\n\n\tfmtc.NewLine()\n}", "func main() {\n\tnames := [...]string{\"Einstein\", \"Tesla\", \"Shepard\"}\n\tdistances := [...]int{50, 40, 75, 30, 125}\n\tdata := [...]uint8{'H', 'E', 'L', 'L', 'O'}\n\tratios := [...]float64{3.14145}\n\talives := [...]bool{true, false, true, false}\n\tzero := [...]uint8{}\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(names); i++ {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, names[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(distances); i++ {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, distances[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(data); i++ {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, data[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"ratios\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(ratios); i++ {\n\t\tfmt.Printf(\"rations[%d]: %v\\n\", i, ratios[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(alives); i++ {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, alives[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(zero); i++ {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, zero[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Printf(`\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nFOR RANGES\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n`)\n\tfmt.Println()\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range names {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range distances {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range data {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"rations\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range ratios {\n\t\tfmt.Printf(\"ratios[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range alives {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range zero {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n}", "func (self *StraightLineTrack) Render(render chan Object) {\n\tfor _, val := range self.Childs() {\n\t\trender <- val\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 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 (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 (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 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 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 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 *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 DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\n}", "func FormatInts[T constraints.Integer](slice []T, base int) []string {\n\tif len(slice) == 0 {\n\t\treturn nil\n\t}\n\tout := make([]string, len(slice))\n\tfor i, x := range slice {\n\t\tout[i] = strconv.FormatInt(int64(x), base)\n\t}\n\treturn out\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 (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 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 (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "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 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 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 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 RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\treturn defaultCtrl.RenderList(w, r, l)\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 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 (g *Grid) RenderCli() {\n\tw := tabwriter.NewWriter(os.Stdout, 2, 0, 0, '.', tabwriter.AlignRight|tabwriter.Debug|tabwriter.TabIndent)\n\tfor _, row := range g.Objects {\n\t\tdisplay := []string{}\n\t\tfor _, gridObject := range row {\n\t\t\tdisplay = append(display, gridObject.DecorateSquare())\n\t\t}\n\t\tfmt.Fprintln(w, strings.Join(display, \"\\t\")+\"\\t\")\n\t}\n\tw.Flush()\n}", "func ShowSufarr(str string, sufarr []int) {\n\tfor _, i := range sufarr {\n\t\tfmt.Printf(\"%s\\n\", str[i:])\n\t}\n\tfmt.Println(\"\")\n}", "func WriteASCII(w io.Writer, t []Triangle) error {\n\tbw := bufio.NewWriterSize(w, writeBufSize)\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(bw, 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\tif err != nil {\n\t\treturn err\n\t}\n\treturn bw.Flush()\n}" ]
[ "0.5906377", "0.52453035", "0.5175279", "0.51635957", "0.51350826", "0.5121694", "0.5097551", "0.50642985", "0.5053005", "0.50115776", "0.5006846", "0.4989256", "0.4967802", "0.4967802", "0.49592203", "0.49281752", "0.49254173", "0.4884338", "0.48837307", "0.48833853", "0.48816642", "0.48629007", "0.4817944", "0.48169824", "0.47991586", "0.4788592", "0.4788592", "0.47814375", "0.47400254", "0.47376847", "0.473743", "0.4715761", "0.47064203", "0.46936637", "0.46593976", "0.46493557", "0.46482804", "0.46479204", "0.46353564", "0.46286702", "0.46268466", "0.46186593", "0.46136972", "0.46081463", "0.45998856", "0.4596616", "0.4596616", "0.4596025", "0.45816624", "0.45771062", "0.45720172", "0.45657572", "0.45639965", "0.455725", "0.45540276", "0.45500195", "0.45500195", "0.45484293", "0.45477343", "0.4541535", "0.45312676", "0.45286247", "0.4526366", "0.45243147", "0.45216775", "0.4519572", "0.45067278", "0.45063138", "0.4499752", "0.449912", "0.4489057", "0.44812185", "0.44801685", "0.4475621", "0.44694906", "0.44668624", "0.44612324", "0.4451125", "0.4451125", "0.44511", "0.44508585", "0.44508225", "0.44504994", "0.4448873", "0.444249", "0.4440323", "0.44352478", "0.44268867", "0.4415026", "0.44141707", "0.44138014", "0.43905595", "0.43893468", "0.43838573", "0.43807206", "0.43792936", "0.4377372", "0.43727472", "0.43706408", "0.43634456", "0.4362123" ]
0.0
-1
render multiple sets of primitives from array data, taking parameters from memory
func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) { C.glowMultiDrawArraysIndirect(gpMultiDrawArraysIndirect, (C.GLenum)(mode), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride)) }
{ "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 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 DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\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 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 DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\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 (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 Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\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 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 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 DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, 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 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 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) 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 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 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 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 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 (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 (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 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 (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 (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 (self *Graphics) _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 (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 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 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 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 DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\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 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 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 output3d(values []int) {\n\tfor _, v := range values {\n\t\tfmt.Printf(\"%03d \",v)\n\t}\n\tfmt.Println()\n}", "func (self *TileSprite) _renderWebGLI(args ...interface{}) {\n self.Object.Call(\"_renderWebGL\", args)\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 (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 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 (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\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 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 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 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 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 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 (s *Scene) RenderParallel(img *image.RGBA, n int) {\n\tvar wg sync.WaitGroup\n\twg.Add(n)\n\n\tfor _, col := range ToColumns(img.Bounds(), n) {\n\t\tsub := img.SubImage(col).(*image.RGBA)\n\n\t\t// Render!\n\t\tgo func() {\n\t\t\ts.Render(sub)\n\t\t\twg.Done()\n\t\t}()\n\t}\n\n\twg.Wait()\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\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 (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 (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 (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 (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 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 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 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 (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 (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 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 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 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 Data(w http.ResponseWriter, r *http.Request, v []byte) {\n\trender.Data(w, r, v)\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 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 main() {\n\tnames := [...]string{\"Einstein\", \"Tesla\", \"Shepard\"}\n\tdistances := [...]int{50, 40, 75, 30, 125}\n\tdata := [...]uint8{'H', 'E', 'L', 'L', 'O'}\n\tratios := [...]float64{3.14145}\n\talives := [...]bool{true, false, true, false}\n\tzero := [...]uint8{}\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(names); i++ {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, names[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(distances); i++ {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, distances[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(data); i++ {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, data[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"ratios\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(ratios); i++ {\n\t\tfmt.Printf(\"rations[%d]: %v\\n\", i, ratios[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(alives); i++ {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, alives[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(zero); i++ {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, zero[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Printf(`\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nFOR RANGES\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n`)\n\tfmt.Println()\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range names {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range distances {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range data {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"rations\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range ratios {\n\t\tfmt.Printf(\"ratios[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range alives {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range zero {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\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 (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 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 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 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 (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 (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "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 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 (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 (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 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 InterleavedArrays(format uint32, stride int32, pointer unsafe.Pointer) {\n C.glowInterleavedArrays(gpInterleavedArrays, (C.GLenum)(format), (C.GLsizei)(stride), pointer)\n}", "func (h *Helm3Client) Render(releaseName string, chart string, valuesPaths []string, setValues []string, namespace string, debug bool) (string, error) {\n\targs := make([]string, 0)\n\targs = append(args, \"template\")\n\targs = append(args, releaseName)\n\targs = append(args, chart)\n\n\tif debug {\n\t\targs = append(args, \"--debug\")\n\t}\n\n\tif namespace != \"\" {\n\t\targs = append(args, \"--namespace\")\n\t\targs = append(args, namespace)\n\t}\n\n\tfor _, valuesPath := range valuesPaths {\n\t\targs = append(args, \"--values\")\n\t\targs = append(args, valuesPath)\n\t}\n\n\tfor _, setValue := range setValues {\n\t\targs = append(args, \"--set\")\n\t\targs = append(args, setValue)\n\t}\n\n\th.LogEntry.Debugf(\"Render helm templates for chart '%s' in namespace '%s' ...\", chart, namespace)\n\tstdout, stderr, err := h.cmd(args...)\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"helm upgrade failed: %s:\\n%s %s\", err, stdout, stderr)\n\t}\n\th.LogEntry.Infof(\"Render helm templates for chart '%s' was successful\", chart)\n\n\treturn stdout, nil\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 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 renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "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 RenderInitialChoices(resp http.ResponseWriter, req *http.Request, ext string, fileSeeker io.ReadSeeker) {\n\top := []OptStruct{\n\t\t{22, primitive.TriangleMode},\n\t\t{22, primitive.CircleMode},\n\t\t{22, primitive.ComboMode},\n\t\t{22, primitive.PolygonMode},\n\t}\n\topFileList, err := GenImgList(ext, fileSeeker, op...)\n\tif err != nil {\n http.Error(resp, err.Error(), http.StatusInternalServerError)\n return\n\t}\n\thtmlist := `<html>\n <body>\n {{range .}}\n <a href=\"/modify/{{.Name}}?mode={{.Mode}}\">\n <img style =\"width 30%\" src=\"/pics/{{.Name}}\">\n {{end}}\n </body>\n </html>\n `\n\ttempl := template.Must(template.New(\"\").Parse(htmlist))\n \ntype Opts struct {\n Name string\n Mode primitive.Mode\n}\n\tvar opts []Opts\n\tfor index, val := range opFileList {\n\t\topts = append(opts, Opts{Name: filepath.Base(val), Mode: op[index].mode})\n\t}\n\n\t// err = templ.Execute(resp, opts)\n\t// if err != nil {\n\t// \tpanic(err)\n // }\n checkError(templ.Execute(resp, opts))\n \n\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 PaintFields(fields []InputField, foreground int8, background int8) {\n\tSetColor(foreground, background)\n\tfor i := range fields {\n\t\tLocate(fields[i].row, fields[i].col)\n\t\tfmt.Print(str.LeftPad(fields[i].value, fields[i].size, \" \"))\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 (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 visualization(lo int, hi int,p *plot.Plot, shots []Shot, Specs []string, m map[string]int, plottingComplete chan bool, parallel bool){\n\n\t// XY's for Shots made\n\tvar xysMake plotter.XYs\n\n\t// XY's for Shots missed\n\tvar xysMiss plotter.XYs\n\n\t// Loop through specified shots\n\tfor i:=lo; i<hi; i++{\n\n\t\t// Boolean that determines if we should plot or not\n\t\twrite := true\n\n\t\t// Followed Advice Found on StackOverFlow:\n\t\t// https://stackoverflow.com/questions/20170275/how-to-find-the-type-of-an-object-in-go\n\t\t// Get the Value\n\t\tf := reflect.ValueOf(&shots[i]).Elem()\n\n\t\t// Loop through the Specification the User Specifies\n\t\tfor j:=0; j<len(Specs); j++{\n\n\t\t\t// Get the Key and Value\n\t\t\ttemp := strings.Split(Specs[j], \":\")\n\n\t\t\t// Use our Mapping to get the Key\n\t\t\tkey := m[strings.TrimSpace(temp[0])]\n\n\t\t\t// Followed Advice Found on StackOverFlow:\n\t\t\t// https://stackoverflow.com/questions/54191322/go-reflect-field-name-to-specific-interface\n\t\t\tdataValue := f.Field(key).Interface()\n\n\t\t\t// Strip the white spaces\n\t\t\ttemp_val := strings.TrimSpace(temp[1])\n\n\t\t\t// Using Function Made by Asaskvich\n\t\t\t// Github Page: https://github.com/asaskevich/govalidator\n\t\t\t// If our Value is an Integer\n\t\t\tif govalidator.IsInt(temp_val){\n\t\t\t\tvalue, _ := strconv.Atoi(temp[1])\n\n\t\t\t\t// If the data point doesn't meet the criteria\n\t\t\t\t// Set write bool to false, exit for loop\n\t\t\t\tif value != dataValue {\n\t\t\t\t\twrite = false\n\t\t\t\t\tbreak\n\t\t\t\t}\n\n\t\t\t// If our Value is a string\n\t\t\t}else{\n\t\t\t\tvalue := strings.TrimSpace(temp[1])\n\n\t\t\t\t// If the data point doesn't meet the criteria\n\t\t\t\t// Set write bool to false, exit for loop\n\t\t\t\tif value != dataValue {\n\t\t\t\t\twrite = false\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\t// If our data point meets all the criteria, plot\n\t\tif write{\n\n\t\t\t// If the Shot was Made, add to xysMake array\n\t\t\tif shots[i].ShotMadeFlag == 1{\n\t\t\t\tx := shots[i].X\n\t\t\t\ty := shots[i].Y\n\t\t\t\txysMake = append(xysMake, struct{X, Y float64 }{x,y})\n\n\t\t\t// If the Shot was Missed, add to the xysMiss array\n\t\t\t}else{\n\t\t\t\tx := shots[i].X\n\t\t\t\ty := shots[i].Y\n\t\t\t\txysMiss = append(xysMiss, struct{X, Y float64 }{x,y})\n\t\t\t}\n\n\t\t}\n\n\n\t}\n\n\t// Plot our Resulting Data Points\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// Turn our Miss array into XY points to plot\n\tmiss, _ := plotter.NewScatter(plotter.XYs(xysMiss))\n\n\t// Format the Points to be purple X's\n\tmiss.GlyphStyle = draw.GlyphStyle{\n\t\tColor: color.RGBA{R:137, G:68, B:202, A:255},\n\t\tRadius: 5.5,\n\t\tShape: draw.CrossGlyph{},\n\n\t}\n\t// Add the Points to the Plot\n\tp.Add(miss)\n\n\t// Turn our array into XY points to plot\n\tmade, _ := plotter.NewScatter(plotter.XYs(xysMake))\n\n\t// Format the Point to be Gold O's\n\tmade.GlyphStyle = draw.GlyphStyle{\n\t\tColor: color.RGBA{R:253, G:185, B:39, A:255},\n\t\tRadius: 4.5,\n\t\tShape: draw.RingGlyph{},\n\t}\n\t// Add the Points to the Plot\n\tp.Add(made)\n\n\n\t// If this was done in parallel,\n\t// Synchronize with the Channel\n\tif parallel{\n\t\tplottingComplete <- true\n\t}\n\n}" ]
[ "0.588656", "0.54614055", "0.54295397", "0.5350041", "0.53137356", "0.53006786", "0.5282439", "0.5253161", "0.523419", "0.5211031", "0.5206587", "0.5203438", "0.5178633", "0.51602924", "0.5136783", "0.5103861", "0.5103528", "0.50965685", "0.50965685", "0.50513583", "0.50471807", "0.50365674", "0.50365674", "0.5034124", "0.50083023", "0.4985065", "0.49758598", "0.49754906", "0.49726617", "0.4958779", "0.4934506", "0.49010223", "0.49007916", "0.48998266", "0.4882128", "0.48567867", "0.48512164", "0.48512164", "0.48483616", "0.48392347", "0.48245877", "0.48245877", "0.48141375", "0.48087582", "0.47936398", "0.47842366", "0.47784626", "0.47765166", "0.47765166", "0.4774402", "0.4773171", "0.47663462", "0.47629622", "0.47597092", "0.47514588", "0.47389165", "0.473183", "0.47062352", "0.46970466", "0.46941745", "0.46919286", "0.46894994", "0.46820748", "0.467845", "0.46729594", "0.46528664", "0.46524325", "0.46500587", "0.46423426", "0.46384802", "0.46384802", "0.46324554", "0.4631576", "0.46301603", "0.46249443", "0.46194434", "0.46098498", "0.4604241", "0.46038365", "0.4601863", "0.46016484", "0.45938605", "0.45842153", "0.45792636", "0.457789", "0.45718727", "0.45712692", "0.45680588", "0.45612246", "0.45559904", "0.45450696", "0.4533836", "0.45287728", "0.4522699", "0.45204467", "0.45167667", "0.45156756", "0.45148644", "0.45024154", "0.45004568", "0.44965607" ]
0.0
-1
render multiple sets of primitives by specifying indices of array data elements
func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) { C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 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 DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\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 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 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 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 DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\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 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 (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\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 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 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 DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\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 (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\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 (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\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 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 (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 (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 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 (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 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 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 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 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 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 output3d(values []int) {\n\tfor _, v := range values {\n\t\tfmt.Printf(\"%03d \",v)\n\t}\n\tfmt.Println()\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 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 DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\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 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 (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 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 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 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 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 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 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 (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 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 ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\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 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 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 (d *drawingsVML) buildIndexes() {\n\tfor id, s := range d.ml.Shape {\n\t\t_ = d.shapeIndex.Add(s, id)\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 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 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 main() {\n\tnames := [...]string{\"Einstein\", \"Tesla\", \"Shepard\"}\n\tdistances := [...]int{50, 40, 75, 30, 125}\n\tdata := [...]uint8{'H', 'E', 'L', 'L', 'O'}\n\tratios := [...]float64{3.14145}\n\talives := [...]bool{true, false, true, false}\n\tzero := [...]uint8{}\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(names); i++ {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, names[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(distances); i++ {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, distances[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(data); i++ {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, data[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"ratios\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(ratios); i++ {\n\t\tfmt.Printf(\"rations[%d]: %v\\n\", i, ratios[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(alives); i++ {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, alives[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(zero); i++ {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, zero[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Printf(`\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nFOR RANGES\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n`)\n\tfmt.Println()\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range names {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range distances {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range data {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"rations\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range ratios {\n\t\tfmt.Printf(\"ratios[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range alives {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range zero {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\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 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 (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 (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 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 (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\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 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 InterleavedArrays(format uint32, stride int32, pointer unsafe.Pointer) {\n C.glowInterleavedArrays(gpInterleavedArrays, (C.GLenum)(format), (C.GLsizei)(stride), pointer)\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 DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\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 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 DrawArraysIndirect(mode uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawArraysIndirect, 2, uintptr(mode), uintptr(indirect), 0)\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 ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (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 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 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 drawingWorker(pkg *workerPackage, indices chan int, wg *sync.WaitGroup) {\n\tvar (\n\t\tmvert, mnrm, mtex tdraw.Triangle\n\t)\n\n\tfor i := range indices {\n\n\t\t// Vertex Normals.\n\t\tmnrm = tdraw.Triangle{\n\t\t\tA: pkg.outNormals[i],\n\t\t\tB: pkg.outNormals[i+1],\n\t\t\tC: pkg.outNormals[i+2],\n\t\t}.ViewNrm(pkg.x, pkg.y, pkg.z)\n\n\t\t// Model Coordinates.\n\t\tmvert = tdraw.Triangle{\n\t\t\tA: pkg.outVertices[i],\n\t\t\tB: pkg.outVertices[i+1],\n\t\t\tC: pkg.outVertices[i+2],\n\t\t}.ViewTri(pkg.x, pkg.y, pkg.z, pkg.eye)\n\n\t\t// Texture Coordinates.\n\t\tmtex = tdraw.Triangle{\n\t\t\tA: pkg.outUVs[i],\n\t\t\tB: pkg.outUVs[i+1],\n\t\t\tC: pkg.outUVs[i+2],\n\t\t}\n\n\t\t// Perspective Vertices.\n\t\tvew := tdraw.Triangle{\n\t\t\tA: mgl64.Project(\n\t\t\t\tmvert.A, pkg.transform, pkg.proj, 0, 0, pkg.spriteDimensions.X, pkg.spriteDimensions.Y),\n\t\t\tB: mgl64.Project(\n\t\t\t\tmvert.B, pkg.transform, pkg.proj, 0, 0, pkg.spriteDimensions.X, pkg.spriteDimensions.Y),\n\t\t\tC: mgl64.Project(\n\t\t\t\tmvert.C, pkg.transform, pkg.proj, 0, 0, pkg.spriteDimensions.X, pkg.spriteDimensions.Y),\n\t\t}\n\n\t\t// Draw the triangles into the buffer.\n\t\ttdraw.TDraw(\n\t\t\tpkg.spriteRGBA,\n\t\t\tpkg.zbuff,\n\t\t\tvew,\n\t\t\tmnrm,\n\t\t\tmtex,\n\t\t\tpkg.textureData,\n\t\t)\n\t}\n\n\twg.Done()\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 (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 (g *Geometry) Draw() {\n\tgl.BindVertexArray(g.handle)\n\tif g.hasIndices {\n\t\tgl.DrawElements(\n\t\t\tg.PrimType,\n\t\t\tg.numIndices,\n\t\t\tg.IndexBuffer.ComponentType,\n\t\t\tgl.PtrOffset(g.IndexBuffer.ByteOffset),\n\t\t)\n\t} else {\n\t\tgl.DrawArrays(g.PrimType, 0, g.numIndices)\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 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 (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 WriteASCII(w io.Writer, t []Triangle) error {\n\tbw := bufio.NewWriterSize(w, writeBufSize)\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(bw, 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\tif err != nil {\n\t\treturn err\n\t}\n\treturn bw.Flush()\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 *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 (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 (arguments Sequence) Index(c *Compiler, this Expression, indices ...Expression) (expression Expression, err error) {\n\texpression = c.NewExpression()\n\n\tif len(indices) != 1 {\n\t\treturn expression, c.NewError(\"arguments takes 1 integer index\")\n\t}\n\tvar index = indices[0]\n\n\texpression.Type = arguments.Subtype()\n\texpression.Go.WriteB(this.Go)\n\texpression.Go.WriteString(`[I.IndexList(`)\n\texpression.Go.WriteB(index.Go)\n\texpression.Go.WriteString(`,len(`)\n\texpression.Go.WriteB(this.Go)\n\texpression.Go.WriteString(`))]`)\n\n\treturn expression, nil\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}" ]
[ "0.5861605", "0.5784999", "0.5747321", "0.57291377", "0.5687483", "0.5484014", "0.5482405", "0.54794174", "0.5470084", "0.5448841", "0.54251385", "0.5419804", "0.5397457", "0.52956325", "0.52938634", "0.5274171", "0.52344435", "0.52344435", "0.5221605", "0.51766086", "0.5173119", "0.5159397", "0.5147958", "0.5143517", "0.51055366", "0.51055366", "0.5054963", "0.5053713", "0.5043452", "0.5030252", "0.50147915", "0.5008961", "0.5003133", "0.50008553", "0.49959046", "0.498053", "0.49794197", "0.49781024", "0.49531934", "0.4931782", "0.4902747", "0.4883812", "0.48617837", "0.48584446", "0.4841398", "0.48378283", "0.4820034", "0.481342", "0.48097858", "0.4806656", "0.48063433", "0.47967207", "0.4791679", "0.4791679", "0.47880825", "0.47880825", "0.47762573", "0.47762573", "0.47693685", "0.47533977", "0.47501296", "0.4733148", "0.4680042", "0.46689346", "0.46604836", "0.46568084", "0.4646885", "0.4645007", "0.46395054", "0.4628315", "0.4628315", "0.46269953", "0.46193123", "0.46135858", "0.4612916", "0.46111447", "0.46106836", "0.46045676", "0.45949155", "0.4591895", "0.45885658", "0.45885658", "0.45550355", "0.45550355", "0.45377854", "0.4537266", "0.4535897", "0.45332992", "0.45290813", "0.45253518", "0.45169407", "0.45169407", "0.45158598", "0.4510168", "0.4501473", "0.44927642", "0.44790542", "0.44736025", "0.44732457" ]
0.53663975
14
render multiple sets of primitives by specifying indices of array data elements and an index to apply to each index
func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) { C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 (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 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 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 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 (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 (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 C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (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 (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(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 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 (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 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 (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\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 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 (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 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 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 (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\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 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 DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\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 (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 (arguments Sequence) Index(c *Compiler, this Expression, indices ...Expression) (expression Expression, err error) {\n\texpression = c.NewExpression()\n\n\tif len(indices) != 1 {\n\t\treturn expression, c.NewError(\"arguments takes 1 integer index\")\n\t}\n\tvar index = indices[0]\n\n\texpression.Type = arguments.Subtype()\n\texpression.Go.WriteB(this.Go)\n\texpression.Go.WriteString(`[I.IndexList(`)\n\texpression.Go.WriteB(index.Go)\n\texpression.Go.WriteString(`,len(`)\n\texpression.Go.WriteB(this.Go)\n\texpression.Go.WriteString(`))]`)\n\n\treturn expression, nil\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 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 (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 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 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 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 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 output3d(values []int) {\n\tfor _, v := range values {\n\t\tfmt.Printf(\"%03d \",v)\n\t}\n\tfmt.Println()\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 (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 (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 (d *drawingsVML) buildIndexes() {\n\tfor id, s := range d.ml.Shape {\n\t\t_ = d.shapeIndex.Add(s, id)\n\t}\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 (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 DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\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 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 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 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 drawingWorker(pkg *workerPackage, indices chan int, wg *sync.WaitGroup) {\n\tvar (\n\t\tmvert, mnrm, mtex tdraw.Triangle\n\t)\n\n\tfor i := range indices {\n\n\t\t// Vertex Normals.\n\t\tmnrm = tdraw.Triangle{\n\t\t\tA: pkg.outNormals[i],\n\t\t\tB: pkg.outNormals[i+1],\n\t\t\tC: pkg.outNormals[i+2],\n\t\t}.ViewNrm(pkg.x, pkg.y, pkg.z)\n\n\t\t// Model Coordinates.\n\t\tmvert = tdraw.Triangle{\n\t\t\tA: pkg.outVertices[i],\n\t\t\tB: pkg.outVertices[i+1],\n\t\t\tC: pkg.outVertices[i+2],\n\t\t}.ViewTri(pkg.x, pkg.y, pkg.z, pkg.eye)\n\n\t\t// Texture Coordinates.\n\t\tmtex = tdraw.Triangle{\n\t\t\tA: pkg.outUVs[i],\n\t\t\tB: pkg.outUVs[i+1],\n\t\t\tC: pkg.outUVs[i+2],\n\t\t}\n\n\t\t// Perspective Vertices.\n\t\tvew := tdraw.Triangle{\n\t\t\tA: mgl64.Project(\n\t\t\t\tmvert.A, pkg.transform, pkg.proj, 0, 0, pkg.spriteDimensions.X, pkg.spriteDimensions.Y),\n\t\t\tB: mgl64.Project(\n\t\t\t\tmvert.B, pkg.transform, pkg.proj, 0, 0, pkg.spriteDimensions.X, pkg.spriteDimensions.Y),\n\t\t\tC: mgl64.Project(\n\t\t\t\tmvert.C, pkg.transform, pkg.proj, 0, 0, pkg.spriteDimensions.X, pkg.spriteDimensions.Y),\n\t\t}\n\n\t\t// Draw the triangles into the buffer.\n\t\ttdraw.TDraw(\n\t\t\tpkg.spriteRGBA,\n\t\t\tpkg.zbuff,\n\t\t\tvew,\n\t\t\tmnrm,\n\t\t\tmtex,\n\t\t\tpkg.textureData,\n\t\t)\n\t}\n\n\twg.Done()\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 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 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 build_index(pss []Post, index, pre, next int, indexname string) {\n\n\tvar doc bytes.Buffer\n\tvar body, name string\n\tvar ips Indexposts\n\tvar tml *template.Template\n\tvar err error\n\tips.Conf = conf\n\tips.Posts = pss\n\tips.Slug = indexname\n\tif pre != 0 {\n\t\tips.PreviousF = true\n\t\tips.Previous = pre\n\t} else {\n\t\tips.PreviousF = false\n\t}\n\tif next > 0 {\n\t\tips.NextF = true\n\t\tips.Next = next\n\t} else if next == -1 {\n\t\tips.NextF = false\n\t} else {\n\t\tips.NextF = true\n\t\tips.Next = next\n\t}\n\tif next == 0 {\n\t\tips.NextLast = true\n\t}\n\n\tips.Links = conf.Links\n\tips.Logo = conf.Logo\n\tif indexname == \"index\" {\n\t\tips.Main = true\n\t} else {\n\t\tips.Main = false\n\t}\n\tips.Disqus = false\n\tif indexname == \"index\" {\n\t\ttml, err = template.ParseFiles(\"./templates/index.html\", \"./templates/base.html\")\n\t} else {\n\t\ttml, err = template.ParseFiles(\"./templates/cat-index.html\", \"./templates/base.html\")\n\t}\n\tif err != nil {\n\t\tfmt.Println(\"Error in parsing: \", err)\n\t}\n\terr = tml.ExecuteTemplate(&doc, \"base\", ips)\n\tif err != nil {\n\t\tfmt.Println(\"Error in executing the template: \", err)\n\t}\n\tbody = doc.String()\n\tif next == -1 {\n\t\tif indexname == \"index\" {\n\t\t\tname = fmt.Sprintf(\"./output/%s.html\", indexname)\n\t\t} else {\n\t\t\tname = fmt.Sprintf(\"./output/categories/%s.html\", indexname)\n\t\t}\n\t} else {\n\t\tif indexname == \"index\" {\n\t\t\tname = fmt.Sprintf(\"./output/%s-%d.html\", indexname, index)\n\t\t} else {\n\t\t\tname = fmt.Sprintf(\"./output/categories/%s-%d.html\", indexname, index)\n\t\t}\n\t}\n\tf, err := os.Create(name)\n\tdefer f.Close()\n\tn, err := io.WriteString(f, body)\n\n\tif err != nil {\n\t\tfmt.Println(\"Write error: \", n, err)\n\t}\n\t// For Sitemap\n\tsmap := Sitemap{Loc: conf.URL + name[9:], Lastmod: current_time.Format(\"2006-01-02\"), Priority: \"0.5\"}\n\tSDB[smap.Loc] = smap\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 (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 (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 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 (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 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 indexEnc() {\n\tfor i := 0; i < indexSize; i++ {\n\t\tindexItemEnc(testData[i], i)\n\t}\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 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 (c *Plain) RenderIndexContent(content interface{}) (string, error) {\n\treturn content.(string), nil\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 (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 main() {\n\tnames := [...]string{\"Einstein\", \"Tesla\", \"Shepard\"}\n\tdistances := [...]int{50, 40, 75, 30, 125}\n\tdata := [...]uint8{'H', 'E', 'L', 'L', 'O'}\n\tratios := [...]float64{3.14145}\n\talives := [...]bool{true, false, true, false}\n\tzero := [...]uint8{}\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(names); i++ {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, names[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(distances); i++ {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, distances[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(data); i++ {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, data[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"ratios\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(ratios); i++ {\n\t\tfmt.Printf(\"rations[%d]: %v\\n\", i, ratios[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(alives); i++ {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, alives[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i := 0; i < len(zero); i++ {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, zero[i])\n\t}\n\tfmt.Println()\n\n\tfmt.Printf(`\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nFOR RANGES\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n`)\n\tfmt.Println()\n\n\tfmt.Println(\"names\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range names {\n\t\tfmt.Printf(\"names[%d]: %q\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"distances\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range distances {\n\t\tfmt.Printf(\"distances[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"data\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range data {\n\t\tfmt.Printf(\"data[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"rations\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range ratios {\n\t\tfmt.Printf(\"ratios[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"alives\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range alives {\n\t\tfmt.Printf(\"alives[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n\tfmt.Println(\"zero\")\n\tfmt.Println(\"====================\")\n\tfor i, v := range zero {\n\t\tfmt.Printf(\"zero[%d]: %v\\n\", i, v)\n\t}\n\tfmt.Println()\n\n}", "func PrimitiveRestartIndex(index uint32) {\n C.glowPrimitiveRestartIndex(gpPrimitiveRestartIndex, (C.GLuint)(index))\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 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 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 (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 Index(w http.ResponseWriter, data interface{}) {\n\trender(tpIndex, w, data)\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\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 DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\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 InterleavedArrays(format uint32, stride int32, pointer unsafe.Pointer) {\n C.glowInterleavedArrays(gpInterleavedArrays, (C.GLenum)(format), (C.GLsizei)(stride), pointer)\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func (s *Scene) RenderParallel(img *image.RGBA, n int) {\n\tvar wg sync.WaitGroup\n\twg.Add(n)\n\n\tfor _, col := range ToColumns(img.Bounds(), n) {\n\t\tsub := img.SubImage(col).(*image.RGBA)\n\n\t\t// Render!\n\t\tgo func() {\n\t\t\ts.Render(sub)\n\t\t\twg.Done()\n\t\t}()\n\t}\n\n\twg.Wait()\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\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 (na *NArray) Index(indices ...int) int {\n\n\tidx := 0\n\tfor k, v := range indices {\n\t\tidx += v * na.Strides[k]\n\t}\n\treturn idx\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 (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 (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 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}" ]
[ "0.5799086", "0.5615862", "0.5611049", "0.5590899", "0.55510855", "0.5539775", "0.54828286", "0.5362288", "0.5360491", "0.52815163", "0.52697814", "0.52682126", "0.52682126", "0.5238092", "0.5219102", "0.51847696", "0.5143207", "0.5143207", "0.5132846", "0.50818354", "0.50717115", "0.5044255", "0.5026256", "0.5014827", "0.5006263", "0.49971586", "0.4996856", "0.4993645", "0.4946941", "0.4938601", "0.49355468", "0.4908885", "0.4905584", "0.4905584", "0.48987985", "0.48892337", "0.4881592", "0.4878823", "0.48698494", "0.48568887", "0.48463485", "0.48402527", "0.48225972", "0.48220003", "0.48148602", "0.47967774", "0.47762534", "0.4754635", "0.47404483", "0.47378242", "0.47299558", "0.47108462", "0.469931", "0.46976528", "0.46882913", "0.46882913", "0.4687225", "0.46786356", "0.46744666", "0.46689236", "0.46634144", "0.46568888", "0.46517655", "0.46467224", "0.4629645", "0.46207193", "0.46191317", "0.46084675", "0.4603422", "0.46032014", "0.46026963", "0.46026963", "0.46024388", "0.4598732", "0.4597468", "0.45880473", "0.458722", "0.45749965", "0.45749965", "0.45580658", "0.45536718", "0.45447275", "0.45432812", "0.4543085", "0.45416096", "0.45412222", "0.45376247", "0.45236114", "0.4513007", "0.45113346", "0.4504776", "0.4504776", "0.44897225", "0.4488219", "0.4483403", "0.4483403", "0.44825503", "0.44799617", "0.44780666" ]
0.47146812
52
render indexed primitives from array data, taking parameters from memory
func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) { C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride)) }
{ "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
creates and initializes a buffer object's data store
func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) { C.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 newBuffer(buf []byte) *Buffer {\n\treturn &Buffer{data: buf}\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 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 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 (b *BatchBuffer) Init() {}", "func newBuffer(b []byte) *buffer {\n\treturn &buffer{proto.NewBuffer(b), 0}\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func newBuffer() Buffer {\n\treturn &buffer{\n\t\tbytes: make([]byte, 0, 64),\n\t}\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 (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 NewBuffer() *Buffer {\n\treturn NewBufferWithSize(initialSize)\n}", "func NewBuffer(o *Options) (*Buffer, error) {\n\tif o == nil {\n\t\to = &Options{}\n\t}\n\tret := &Buffer{opts: *o} // copy o before normalizing it\n\n\tif err := ret.opts.normalize(); err != nil {\n\t\treturn nil, errors.Annotate(err, \"normalizing buffer.Options\").Err()\n\t}\n\n\tret.unleased.onlyID = o.FIFO\n\tret.batchItemsGuess = newMovingAverage(10, ret.opts.batchItemsGuess())\n\tret.liveLeases = map[*Batch]struct{}{}\n\tret.unAckedLeases = map[*Batch]struct{}{}\n\treturn ret, nil\n}", "func (buf *ListBuffer) Init() {\n\tbuf.Buffer = make([]Node, defaultBufferLength)\n\tbuf.FreeHead = 0\n\tbuf.Count = 0\n\n\tfor i := 0; i < len(buf.Buffer); i++ {\n\t\tbuf.Buffer[i].Item.Clear()\n\t\tbuf.Buffer[i].Prev = BufferIndex(i - 1)\n\t\tbuf.Buffer[i].Next = BufferIndex(i + 1)\n\t}\n\n\tbuf.Buffer[0].Prev = NilIndex\n\tbuf.Buffer[len(buf.Buffer)-1].Next = NilIndex\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 NewBuffer() *Buffer { return globalPool.NewBuffer() }", "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 (_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 New(b []byte) *Buffer {\n\treturn &Buffer{b: b}\n}", "func NewBuffer(e []byte) *Buffer {\n\treturn &Buffer{buf: e}\n}", "func NewBuffer(aSlice interface{}) *Buffer {\n return &Buffer{buffer: sliceValue(aSlice, false), handler: valueHandler{}}\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 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 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 NewBuffer(player *Player, conn net.Conn, ctrl chan bool) *Buffer {\r\n\tmax := DEFAULT_QUEUE_SIZE\r\n\r\n\tbuf := Buffer{conn: conn}\r\n\tbuf.pending = make(chan []byte, max)\r\n\tbuf.ctrl = ctrl\r\n\tbuf.max = max\r\n\treturn &buf\r\n}", "func NewBuffer(e []byte) *Buffer {\n\treturn &Buffer{buf: e, length: len(e)}\n}", "func (m *metricMysqlBufferPoolUsage) init() {\n\tm.data.SetName(\"mysql.buffer_pool.usage\")\n\tm.data.SetDescription(\"The number of bytes in the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"By\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func NewBuffer() Buffer {\n\treturn &buffer{}\n}", "func NewBuffer() *Buffer {\n\treturn &Buffer{Line: []byte{}, Val: make([]byte, 0, 32)}\n}", "func createBuffer() *bytes.Buffer {\n\tbuf := bytes.Buffer{}\n\treturn &buf\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func init() {\n\tstore = cache.NewMemoryCache()\n}", "func init() {\n\tMemory = &memoryStorage{\n\t\ttraces: make(map[string]tracer.Trace),\n\t\tservices: make(map[string]string),\n\t\tserviceDeps: make(map[string]*tracer.Dependencies),\n\t}\n}", "func (m *Manager) NewBuffer(conf buffer.Config) (buffer.Streamed, error) {\n\treturn nil, component.ErrInvalidType(\"buffer\", conf.Type)\n}", "func FakeTdsBufferCtor(r io.ReadWriteCloser) io.ReadWriteCloser {\n\treturn r\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\n}", "func NewBuffer(size int) *Buffer {\n\tif size <= 0 {\n\t\treturn &Buffer{}\n\t}\n\treturn &Buffer{\n\t\tstorage: make([]byte, size),\n\t\tsize: size,\n\t}\n}", "func NewEmptyBuffer() *Buffer {\n return &Buffer{data: make([]byte, 0)}\n}", "func (r *Record) NewBuffer() *bytes.Buffer {\n\tif r.Buffer == nil {\n\t\treturn &bytes.Buffer{}\n\t}\n\n\treturn r.Buffer\n}", "func (b *BadgerStore) init(dir string) error {\n\n\topts := badger.DefaultOptions(dir)\n\tif dir == \"\" {\n\t\topts = opts.WithInMemory(true)\n\t}\n\topts.Logger = &common.NoopLogger{}\n\tdb, err := badger.Open(opts)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"failed to open database\")\n\t}\n\n\t// Set the database\n\tb.db = db\n\n\t// Initialize the default transaction that auto commits\n\t// on success ops or discards on failure.\n\t// It also enables the renewal of the underlying transaction\n\t// after executing a read/write operation\n\tb.Tx = NewTx(db, true, true)\n\n\treturn nil\n}", "func (m *metricMysqlBufferPoolOperations) init() {\n\tm.data.SetName(\"mysql.buffer_pool.operations\")\n\tm.data.SetDescription(\"The number of operations on the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"1\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(true)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\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 NewBuffer(reader io.Reader, size int64, path string, cursorPosition []string) *Buffer {\n\tb := new(Buffer)\n\tb.LineArray = NewLineArray(size, reader)\n\n\tb.Settings = DefaultLocalSettings()\n\t//\tfor k, v := range globalSettings {\n\t//\t\tif _, ok := b.Settings[k]; ok {\n\t//\t\t\tb.Settings[k] = v\n\t//\t\t}\n\t//\t}\n\n\tif fileformat == 1 {\n\t\tb.Settings[\"fileformat\"] = \"unix\"\n\t} else if fileformat == 2 {\n\t\tb.Settings[\"fileformat\"] = \"dos\"\n\t}\n\n\tb.Path = path\n\n\tb.EventHandler = NewEventHandler(b)\n\n\tb.update()\n\n\tb.Cursor = Cursor{\n\t\tLoc: Loc{0, 0},\n\t\tbuf: b,\n\t}\n\n\t//InitLocalSettings(b)\n\n\tb.cursors = []*Cursor{&b.Cursor}\n\n\treturn b\n}", "func New(capacity int, fn func(series []*influxdb.Series)) *Buffer {\n\treturn NewBuffer(capacity, fn)\n}", "func initBuffer(size int) {\n\tif len(buffer) == size {\n\t\treturn\n\t}\n\tbuffer = make([]uint8, size)\n}", "func NewBuffer(conn *net.TCPConn, buffOb chan bool, maxQueueSize int) *Buffer {\n\tsize := maxQueueSize\n\n\tif size == -1 {\n\t\tsize = DEFAULT_QUEUE_SIZE\n\t}\n\n\tbuf := new(Buffer)\n\tbuf.conn = conn\n\tbuf.pending = make(chan []byte, size)\n\tbuf.ctrl = make(chan bool)\n\tbuf.ob = buffOb\n\tbuf.max = size\n\n\treturn buf\n}", "func NewBuffer() Buffer {\n\treturn Buffer{\n\t\tCellMap: make(map[image.Point]Cell),\n\t\tArea: image.Rectangle{}}\n}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 0\n}", "func NewBuffer(length int) *Buffer {\n\treturn &Buffer{\n\t\titems: make([]unsafe.Pointer, length),\n\t}\n}", "func NewBuffer(conn *sqlite.Conn) (*Buffer, error) {\n\treturn NewBufferSize(conn, 16*1024)\n}", "func NewBuffer(size int) *Buffer {\n\treturn &Buffer{\n\t\tdata: make([]byte, size),\n\t}\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 (m *metricMysqlBufferPoolDataPages) init() {\n\tm.data.SetName(\"mysql.buffer_pool.data_pages\")\n\tm.data.SetDescription(\"The number of data pages in the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"1\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func NewBuffer(inp []byte) *ByteBuffer {\n\tif inp == nil {\n\t\tinp = make([]byte, 0, 512)\n\t}\n\treturn &ByteBuffer{Buffer: bytes.NewBuffer(inp)}\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 NewCapacityBuffer(capacity int) *Buffer {\n return &Buffer{data: make([]byte, capacity)}\n}", "func newEventBuffer(size int64) *eventBuffer {\n\tzero := int64(0)\n\tb := &eventBuffer{\n\t\tmaxSize: size,\n\t\tsize: &zero,\n\t}\n\n\titem := newBufferItem(&structs.Events{Index: 0, Events: nil})\n\n\tb.head.Store(item)\n\tb.tail.Store(item)\n\n\treturn b\n}", "func New(w, h int) *Buffer {\n\tb := &Buffer{\n\t\tWidth: w,\n\t\tHeight: h,\n\t\tCursor: NewCursor(0, 0),\n\t\tTiles: make([]*Tile, w*h),\n\t}\n\tb.Resize(w, h)\n\treturn b\n}", "func NewBuffer() *Buffer {\n\treturn &Buffer{B: &strings.Builder{}}\n}", "func NewTelemetryBuffer() (*TelemetryBuffer, error) {\n\tvar tb TelemetryBuffer\n\ttb.data = make(chan interface{})\n\ttb.cancel = make(chan bool, 1)\n\ttb.connections = make([]net.Conn, 1)\n\terr := tb.Listen(FdName)\n\tif err != nil {\n\t\ttb.fdExists = strings.Contains(err.Error(), \"in use\") || strings.Contains(err.Error(), \"Access is denied\")\n\t} else {\n\t\t// Spawn server goroutine to handle incoming connections\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\t// Spawn worker goroutines to communicate with client\n\t\t\t\tconn, err := tb.listener.Accept()\n\t\t\t\tif err == nil {\n\t\t\t\t\ttb.connections = append(tb.connections, conn)\n\t\t\t\t\tgo func() {\n\t\t\t\t\t\tfor {\n\t\t\t\t\t\t\treportStr, err := read(conn)\n\t\t\t\t\t\t\tif err == nil {\n\t\t\t\t\t\t\t\tvar tmp map[string]interface{}\n\t\t\t\t\t\t\t\tjson.Unmarshal(reportStr, &tmp)\n\t\t\t\t\t\t\t\tif _, ok := tmp[\"NpmVersion\"]; ok {\n\t\t\t\t\t\t\t\t\tvar npmReport NPMReport\n\t\t\t\t\t\t\t\t\tjson.Unmarshal([]byte(reportStr), &npmReport)\n\t\t\t\t\t\t\t\t\ttb.data <- npmReport\n\t\t\t\t\t\t\t\t} else if _, ok := tmp[\"CniSucceeded\"]; ok {\n\t\t\t\t\t\t\t\t\tvar cniReport CNIReport\n\t\t\t\t\t\t\t\t\tjson.Unmarshal([]byte(reportStr), &cniReport)\n\t\t\t\t\t\t\t\t\ttb.data <- cniReport\n\t\t\t\t\t\t\t\t} else if _, ok := tmp[\"Allocations\"]; ok {\n\t\t\t\t\t\t\t\t\tvar dncReport DNCReport\n\t\t\t\t\t\t\t\t\tjson.Unmarshal([]byte(reportStr), &dncReport)\n\t\t\t\t\t\t\t\t\ttb.data <- dncReport\n\t\t\t\t\t\t\t\t} else if _, ok := tmp[\"DncPartitionKey\"]; ok {\n\t\t\t\t\t\t\t\t\tvar cnsReport CNSReport\n\t\t\t\t\t\t\t\t\tjson.Unmarshal([]byte(reportStr), &cnsReport)\n\t\t\t\t\t\t\t\t\ttb.data <- cnsReport\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\t\t\t}\n\t\t}()\n\t}\n\n\terr = tb.Dial(FdName)\n\tif err == nil {\n\t\ttb.connected = true\n\t\ttb.payload.DNCReports = make([]DNCReport, 0)\n\t\ttb.payload.CNIReports = make([]CNIReport, 0)\n\t\ttb.payload.NPMReports = make([]NPMReport, 0)\n\t\ttb.payload.CNSReports = make([]CNSReport, 0)\n\t} else if tb.fdExists {\n\t\ttb.cleanup(FdName)\n\t}\n\n\treturn &tb, err\n}", "func NewAttached(buffer []byte) *Buffer {\n result := NewEmptyBuffer()\n result.Attach(buffer)\n return result\n}", "func NewLocalBuffer(b bytes.Buffer) *LocalBuffer { return &LocalBuffer{b: b} }", "func NewBufferBuilder() *BufferBuilder {\n\treturn &BufferBuilder{}\n}", "func NewBuffer(m []byte, skip, size int64) (*Buffer, error) {\n\tb := &Buffer{\n\t\toffset: skip,\n\t\tsize: size,\n\t\tdata: m,\n\t}\n\treturn b, nil\n}", "func NewAttachedBuffer(buffer *Buffer) *Buffer {\n result := NewEmptyBuffer()\n result.AttachBuffer(buffer)\n return result\n}", "func DefaultBufferStoreSize() int {\n\treturn 100\n}", "func (m *metricMysqlBufferPoolLimit) init() {\n\tm.data.SetName(\"mysql.buffer_pool.limit\")\n\tm.data.SetDescription(\"The configured size of the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"By\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n}", "func (m *metricMysqlBufferPoolPages) init() {\n\tm.data.SetName(\"mysql.buffer_pool.pages\")\n\tm.data.SetDescription(\"The number of pages in the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"1\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func (c *HTTPCollector) createBuffer() []*zipkincore.Span {\n\treturn c.batchPool.Get().([]*zipkincore.Span)\n}", "func (pool *BufferPool) New() (buf *bytes.Buffer) {\n\tselect {\n\tcase buf = <-pool.Buffers:\n\tdefault:\n\t\tbuf = &bytes.Buffer{}\n\t}\n\treturn\n}", "func NewDistributedObjectWithData() {}", "func (db *DB) init() error {\n\t// Create two meta pages on a buffer.\n\tbuf := make([]byte, db.pageSize*4)\n\tfor i := 0; i < 2; i++ {\n\t\tp := db.pageInBuffer(buf, pgid(i))\n\t\tp.id = pgid(i)\n\t\tp.flags = metaPageFlag\n\n\t\t// Initialize the meta page.\n\t\tm := p.meta()\n\t\tm.magic = magic\n\t\tm.version = version\n\t\tm.pageSize = uint32(db.pageSize)\n\t\tm.freelist = 2\n\t\tm.root = bucket{root: 3}\n\t\tm.pgid = 4\n\t\tm.txid = txid(i)\n\t\tm.checksum = m.sum64()\n\t}\n\n\t// Write an empty freelist at page 3.\n\tp := db.pageInBuffer(buf, pgid(2))\n\tp.id = pgid(2)\n\tp.flags = freelistPageFlag\n\tp.count = 0\n\n\t// Write an empty leaf page at page 4.\n\tp = db.pageInBuffer(buf, pgid(3))\n\tp.id = pgid(3)\n\tp.flags = leafPageFlag\n\tp.count = 0\n\n\t// Write the buffer to our data file.\n\tif _, err := db.ops.writeAt(buf, 0); err != nil {\n\t\treturn err\n\t}\n\tif err := fdatasync(db); err != nil {\n\t\treturn err\n\t}\n\tdb.filesz = len(buf)\n\n\treturn nil\n}", "func (src *Source) SetNewBuffer() {\n\tsrc.buf = make([]byte, 64)\n}", "func (s *seqBuf) init(length time.Duration, maxSeqNum, maxSeqNumDiff seqNum, entryChan chan seqBufEntry) {\n\ts.length = length\n\ts.maxSeqNum = maxSeqNum\n\ts.maxSeqNumDiff = maxSeqNumDiff\n\ts.entryChan = entryChan\n\n\ts.entryAddedChan = make(chan bool)\n\ts.watcherCloseNeededChan = make(chan bool)\n\ts.watcherCloseDoneChan = make(chan bool)\n\tgo s.watcher()\n}", "func NewMemoryStorage() *MemoryStorage {\n return &MemoryStorage{tickets: make(map[string]*types.Ticket)}\n}", "func newBuffer(br *Reader) (*buffer, error) {\n\tn, err := io.ReadFull(br.r, br.buf[:4])\n\t// br.r.Chunk() is only valid after the call the Read(), so this\n\t// must come after the first read in the record.\n\ttx := br.r.Begin()\n\tdefer func() {\n\t\tbr.lastChunk = tx.End()\n\t}()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif n != 4 {\n\t\treturn nil, errors.New(\"bam: invalid record: short block size\")\n\t}\n\tb := &buffer{data: br.buf[:4]}\n\tsize := int(b.readInt32())\n\tif size == 0 {\n\t\treturn nil, io.EOF\n\t}\n\tif size < 0 {\n\t\treturn nil, errors.New(\"bam: invalid record: invalid block size\")\n\t}\n\tif size > cap(br.buf) {\n\t\tb.off, b.data = 0, make([]byte, size)\n\t} else {\n\t\tb.off, b.data = 0, br.buf[:size]\n\t\tb.shared = true\n\t}\n\tn, err = io.ReadFull(br.r, b.data)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif n != size {\n\t\treturn nil, errors.New(\"bam: truncated record\")\n\t}\n\treturn b, nil\n}", "func (kvstore *KVStore) init_db() {\n\t/*\n\t\tdifference between make and new?\n\t\t1. make(T) always return type T; new(T) returns type *T\n\t\t2. new works for all types,\n\tand dynamically allocates space for a variable of that type,\n\tinitialized to the zero value of that type, and returns a pointer to it;\n\t\t make works as a kind of \"constructor\" for certain bult-in types(\n\tslice, map, channel)\n\t*/\n\tfmt.Println(\"initializing kvstore\")\n\tkvstore.kvstore = make(map[string][]byte)\n}", "func New(capacity int64) chainstore.Store {\n\tmemStore := &memStore{\n\t\tdata: make(map[string][]byte, 1000),\n\t}\n\tstore := lrumgr.New(capacity, memStore)\n\treturn store\n}", "func NewBuffer(ssrc uint32, vp, ap *sync.Pool) *Buffer {\n\tb := &Buffer{\n\t\tmediaSSRC: ssrc,\n\t\tvideoPool: vp,\n\t\taudioPool: ap,\n\t\tpacketChan: make(chan rtp.Packet, 100),\n\t}\n\treturn b\n}", "func New(i int) *Buffer {\n\treturn &Buffer{\n\t\tsize: i,\n\t}\n}", "func (db *DB) init() error {\n\tdb.pageSize = os.Getpagesize()\n\n\tbuf := make([]byte, db.pageSize*4)\n\t//将第0页和第1页初始化meta页,\n\t// 并指定root bucket的page id为3, freelist记录的page id为2,\n\t// 当前数据库总页数为4,同时txid分别为0和1\n\tfor i := 0; i < 2; i++ {\n\t\tp := (*page)(unsafe.Pointer(&buf[pgid(i)*pgid(db.pageSize)]))\n\t\tp.id = pgid(i)\n\t\tp.flags = metaPageFlag\n\n\t\t// initialize the meta page\n\t\tm := p.meta()\n\n\t\tm.magic = magic\n\t\tm.version = version\n\t\tm.pageSize = uint32(db.pageSize)\n\t\tm.freelist = 2\n\t\tm.root = bucket{root: 3}\n\t\tm.pgid = 4\n\n\t\tm.txid = txid(i)\n\t\tm.chckksum = m.sum64()\n\t}\n\t// 将第2页初始化为freelist页,即freelist的记录将会存在第2页;\n\tp := db.pageInBuffer(buf[:], pgid(2))\n\tp.id = pgid(2)\n\tp.flags = freelistPageFlag\n\tp.count = 0\n\t// 将第3页初始化为一个空页,它可以用来写入K/V记录,请注意它必须是B+ Tree中的叶子节点\n\tp = db.pageInBuffer(buf[:], pgid(3))\n\tp.id = pgid(3)\n\tp.flags = leafPageFlag\n\tp.count = 0\n\t//调用写文件函数将buffer中的数据写入文件\n\t// 在open函数中已经设定 db.ops.writeAt = db.file.writeAt.\n\t// 所以现在写数据就是往db.file中写数据\n\tif _, err := db.ops.writeAt(buf, 0); err != nil {\n\t\treturn err\n\t}\n\t//通过fdatasync()调用将内核中磁盘页缓冲立即写入磁盘\n\tif err := fdatasync(db); err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (self *MessageStore) Init() {\n\tself.in = make(map[string]*MsgEntry)\n\tself.out = make(map[string]*MsgEntry)\n}", "func newBufferItem(events *structs.Events) *bufferItem {\n\treturn &bufferItem{\n\t\tlink: &bufferLink{\n\t\t\tnextCh: make(chan struct{}),\n\t\t\tdroppedCh: make(chan struct{}),\n\t\t},\n\t\tEvents: events,\n\t\tcreatedAt: time.Now(),\n\t}\n}", "func (m *Memory) Init(size int) {\n\tcontent := make([]byte, size)\n\tm.content = content\n}", "func init() {\n\tos.RemoveAll(DataPath)\n\n\tdc := DatabaseConfig{\n\t\tDataPath: DataPath,\n\t\tIndexDepth: 4,\n\t\tPayloadSize: 16,\n\t\tBucketDuration: 3600000000000,\n\t\tResolution: 60000000000,\n\t\tSegmentSize: 100000,\n\t}\n\n\tcfg := &ServerConfig{\n\t\tVerboseLogs: true,\n\t\tRemoteDebug: true,\n\t\tListenAddress: Address,\n\t\tDatabases: map[string]DatabaseConfig{\n\t\t\tDatabase: dc,\n\t\t},\n\t}\n\n\tdbs := map[string]kdb.Database{}\n\tdb, err := dbase.New(dbase.Options{\n\t\tDatabaseName: Database,\n\t\tDataPath: dc.DataPath,\n\t\tIndexDepth: dc.IndexDepth,\n\t\tPayloadSize: dc.PayloadSize,\n\t\tBucketDuration: dc.BucketDuration,\n\t\tResolution: dc.Resolution,\n\t\tSegmentSize: dc.SegmentSize,\n\t})\n\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tdbs[\"test\"] = db\n\td = db\n\to = dc\n\n\ts = NewServer(dbs, cfg)\n\tgo s.Listen()\n\n\t// wait for the server to start\n\ttime.Sleep(time.Second * 2)\n\n\tc = NewClient(Address)\n\tif err := c.Connect(); err != nil {\n\t\tpanic(err)\n\t}\n}", "func New() *MemStore {\n\ts := new(MemStore)\n\ts.did = make(map[string]common.Role)\n\ts.act = make(map[string]common.Role)\n\ts.tkt = make(map[string]common.Ticket)\n\t// initialize random gen\n\ts.rand = rand.New(rand.NewSource(time.Now().UnixNano() + 9999999))\n\treturn s\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 NewBufferFromString(text string) *Buffer {\n\treturn NewBuffer(strings.NewReader(text), int64(len(text)), \"1.msg\", nil)\n}", "func NewTelemetryBuffer(hostReportURL string) *TelemetryBuffer {\n\tvar tb TelemetryBuffer\n\n\tif hostReportURL == \"\" {\n\t\ttb.azureHostReportURL = azureHostReportURL\n\t}\n\n\ttb.data = make(chan interface{}, MaxNumReports)\n\ttb.cancel = make(chan bool, 1)\n\ttb.connections = make([]net.Conn, 0)\n\ttb.buffer.DNCReports = make([]DNCReport, 0, MaxNumReports)\n\ttb.buffer.CNIReports = make([]CNIReport, 0, MaxNumReports)\n\ttb.buffer.NPMReports = make([]NPMReport, 0, MaxNumReports)\n\ttb.buffer.CNSReports = make([]CNSReport, 0, MaxNumReports)\n\n\treturn &tb\n}", "func (p *MemProvider) Init(maxLifetime int64, _ string) error {\n\tp.lock.Lock()\n\tp.list = list.New()\n\tp.data = make(map[string]*list.Element)\n\tp.maxLifetime = maxLifetime\n\tp.lock.Unlock()\n\treturn nil\n}", "func NewBuffer(size int) *Buffer {\n\treturn &Buffer{size: size, tail: 0, head: 0, buf: make([]byte, size)}\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 newSafeBuffer(bufsize int) ([]byte, error) {\n\t// Max BSON document size is 16MB.\n\t// https://docs.mongodb.com/manual/reference/limits/\n\t// For simplicity, bound buffer size at 32MB so that headers and so on fit\n\t// too.\n\t// TODO: Can you put multiple large documents in one insert or reply and\n\t// exceed this limit?\n\tif (bufsize < 0) || (bufsize > 32*1024*1024) {\n\t\treturn nil, fmt.Errorf(\"Invalid buffer size %d\", bufsize)\n\t}\n\treturn make([]byte, bufsize), nil\n}", "func newBufferPool() *bufferPool {\n\treturn &bufferPool{&sync.Pool{\n\t\tNew: func() interface{} {\n\t\t\treturn &bytes.Buffer{}\n\t\t},\n\t}}\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func NewTelemetryBuffer(hostReportURL string) *TelemetryBuffer {\n\tvar tb TelemetryBuffer\n\n\tif hostReportURL == \"\" {\n\t\ttb.azureHostReportURL = azureHostReportURL\n\t}\n\n\ttb.data = make(chan interface{})\n\ttb.cancel = make(chan bool, 1)\n\ttb.connections = make([]net.Conn, 1)\n\ttb.payload.DNCReports = make([]DNCReport, 0)\n\ttb.payload.CNIReports = make([]CNIReport, 0)\n\ttb.payload.NPMReports = make([]NPMReport, 0)\n\ttb.payload.CNSReports = make([]CNSReport, 0)\n\n\terr := telemetryLogger.SetTarget(log.TargetLogfile)\n\tif err != nil {\n\t\tfmt.Printf(\"Failed to configure logging: %v\\n\", err)\n\t}\n\n\treturn &tb\n}", "func (p *Pool) NewBuffer() *Buffer {\n\treturn &Buffer{pool: p, bufs: make([][]byte, 0, 128), curBufIdx: -1}\n}", "func (b *defaultByteBuffer) NewBuffer() ByteBuffer {\n\treturn NewWriterBuffer(256)\n}", "func newDownloadBuffer(length, sectorSize uint64) downloadBuffer {\n\t// Completion the length multiple of sector size(4MB)\n\tif length%sectorSize != 0 {\n\t\tlength += sectorSize - length%sectorSize\n\t}\n\n\tddb := downloadBuffer{\n\t\tbuf: make([][]byte, 0, length/sectorSize),\n\t\tsectorSize: sectorSize,\n\t}\n\tfor length > 0 {\n\t\tddb.buf = append(ddb.buf, make([]byte, sectorSize))\n\t\tlength -= sectorSize\n\t}\n\treturn ddb\n}", "func New(handler Action, options ...Option) *Buffer {\n\tafb := Buffer{\n\t\tLatch: async.NewLatch(),\n\t\tHandler: handler,\n\t\tParallelism: runtime.NumCPU(),\n\t\tMaxFlushes: DefaultMaxFlushes,\n\t\tMaxLen: DefaultMaxLen,\n\t\tInterval: DefaultFlushInterval,\n\t\tShutdownGracePeriod: DefaultShutdownGracePeriod,\n\t}\n\tfor _, option := range options {\n\t\toption(&afb)\n\t}\n\tafb.contents = collections.NewRingBufferWithCapacity(afb.MaxLen)\n\treturn &afb\n}" ]
[ "0.6452763", "0.62074417", "0.6085602", "0.6062877", "0.60546154", "0.6051158", "0.6039646", "0.6039385", "0.60212064", "0.593024", "0.58833855", "0.5863987", "0.58623064", "0.58622515", "0.58257276", "0.5825609", "0.5809823", "0.57785004", "0.5771321", "0.5759343", "0.5755475", "0.57512695", "0.5751264", "0.5740081", "0.5736525", "0.5721855", "0.571137", "0.56983644", "0.56968445", "0.56959856", "0.56942254", "0.56913084", "0.5661283", "0.5642236", "0.56211495", "0.56153333", "0.5610583", "0.56062853", "0.5556813", "0.55565697", "0.5552949", "0.5541792", "0.55362093", "0.55336887", "0.5525886", "0.55175424", "0.54931766", "0.5469633", "0.5456069", "0.5452697", "0.5450981", "0.5447555", "0.5445897", "0.5443028", "0.54316", "0.54167944", "0.5411943", "0.54110825", "0.53649944", "0.53617525", "0.5345403", "0.5345295", "0.53450096", "0.5322516", "0.5307159", "0.529712", "0.52747643", "0.5248277", "0.5241659", "0.523649", "0.5234859", "0.5232545", "0.522374", "0.5221605", "0.5218385", "0.521391", "0.52130455", "0.5199346", "0.51931405", "0.5192627", "0.5189877", "0.5176763", "0.5173783", "0.5150649", "0.5145779", "0.5137598", "0.5136657", "0.51261795", "0.510372", "0.5091024", "0.5088641", "0.508824", "0.50850075", "0.5084109", "0.5077823", "0.50759894", "0.50746435", "0.50692624", "0.50684327", "0.5068185", "0.5064972" ]
0.0
-1
creates and initializes a buffer object's immutable data store
func NamedBufferStorage(buffer uint32, size int, data unsafe.Pointer, flags uint32) { C.glowNamedBufferStorage(gpNamedBufferStorage, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 newBuffer(b []byte) *buffer {\n\treturn &buffer{proto.NewBuffer(b), 0}\n}", "func newBuffer(buf []byte) *Buffer {\n\treturn &Buffer{data: buf}\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 newBuffer() Buffer {\n\treturn &buffer{\n\t\tbytes: make([]byte, 0, 64),\n\t}\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\n}", "func NewBuffer(aSlice interface{}) *Buffer {\n return &Buffer{buffer: sliceValue(aSlice, false), handler: valueHandler{}}\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 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 NewBuffer() *Buffer {\n\treturn NewBufferWithSize(initialSize)\n}", "func New(b []byte) *Buffer {\n\treturn &Buffer{b: b}\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 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 NewBuffer() Buffer {\n\treturn &buffer{}\n}", "func NewBuffer() *Buffer {\n\treturn &Buffer{Line: []byte{}, Val: make([]byte, 0, 32)}\n}", "func NewBuffer(e []byte) *Buffer {\n\treturn &Buffer{buf: e}\n}", "func NewBuffer(o *Options) (*Buffer, error) {\n\tif o == nil {\n\t\to = &Options{}\n\t}\n\tret := &Buffer{opts: *o} // copy o before normalizing it\n\n\tif err := ret.opts.normalize(); err != nil {\n\t\treturn nil, errors.Annotate(err, \"normalizing buffer.Options\").Err()\n\t}\n\n\tret.unleased.onlyID = o.FIFO\n\tret.batchItemsGuess = newMovingAverage(10, ret.opts.batchItemsGuess())\n\tret.liveLeases = map[*Batch]struct{}{}\n\tret.unAckedLeases = map[*Batch]struct{}{}\n\treturn ret, nil\n}", "func NewBuffer(size int) *Buffer {\n\tif size <= 0 {\n\t\treturn &Buffer{}\n\t}\n\treturn &Buffer{\n\t\tstorage: make([]byte, size),\n\t\tsize: size,\n\t}\n}", "func NewBuffer() *Buffer { return globalPool.NewBuffer() }", "func NewBuffer(e []byte) *Buffer {\n\treturn &Buffer{buf: e, length: len(e)}\n}", "func NewBuffer() Buffer {\n\treturn Buffer{\n\t\tCellMap: make(map[image.Point]Cell),\n\t\tArea: image.Rectangle{}}\n}", "func createBuffer() *bytes.Buffer {\n\tbuf := bytes.Buffer{}\n\treturn &buf\n}", "func NewEmptyBuffer() *Buffer {\n return &Buffer{data: make([]byte, 0)}\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 NewCapacityBuffer(capacity int) *Buffer {\n return &Buffer{data: make([]byte, capacity)}\n}", "func FakeTdsBufferCtor(r io.ReadWriteCloser) io.ReadWriteCloser {\n\treturn r\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func New(capacity int, fn func(series []*influxdb.Series)) *Buffer {\n\treturn NewBuffer(capacity, fn)\n}", "func (r *Record) NewBuffer() *bytes.Buffer {\n\tif r.Buffer == nil {\n\t\treturn &bytes.Buffer{}\n\t}\n\n\treturn r.Buffer\n}", "func init() {\n\tstore = cache.NewMemoryCache()\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 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 New(capacity int64) chainstore.Store {\n\tmemStore := &memStore{\n\t\tdata: make(map[string][]byte, 1000),\n\t}\n\tstore := lrumgr.New(capacity, memStore)\n\treturn store\n}", "func NewBuffer(player *Player, conn net.Conn, ctrl chan bool) *Buffer {\r\n\tmax := DEFAULT_QUEUE_SIZE\r\n\r\n\tbuf := Buffer{conn: conn}\r\n\tbuf.pending = make(chan []byte, max)\r\n\tbuf.ctrl = ctrl\r\n\tbuf.max = max\r\n\treturn &buf\r\n}", "func NewBuffer(size int) *Buffer {\n\treturn &Buffer{\n\t\tdata: make([]byte, size),\n\t}\n}", "func newEventBuffer(size int64) *eventBuffer {\n\tzero := int64(0)\n\tb := &eventBuffer{\n\t\tmaxSize: size,\n\t\tsize: &zero,\n\t}\n\n\titem := newBufferItem(&structs.Events{Index: 0, Events: nil})\n\n\tb.head.Store(item)\n\tb.tail.Store(item)\n\n\treturn b\n}", "func NewBuffer() *Buffer {\n\treturn &Buffer{B: &strings.Builder{}}\n}", "func NewBuffer(reader io.Reader, size int64, path string, cursorPosition []string) *Buffer {\n\tb := new(Buffer)\n\tb.LineArray = NewLineArray(size, reader)\n\n\tb.Settings = DefaultLocalSettings()\n\t//\tfor k, v := range globalSettings {\n\t//\t\tif _, ok := b.Settings[k]; ok {\n\t//\t\t\tb.Settings[k] = v\n\t//\t\t}\n\t//\t}\n\n\tif fileformat == 1 {\n\t\tb.Settings[\"fileformat\"] = \"unix\"\n\t} else if fileformat == 2 {\n\t\tb.Settings[\"fileformat\"] = \"dos\"\n\t}\n\n\tb.Path = path\n\n\tb.EventHandler = NewEventHandler(b)\n\n\tb.update()\n\n\tb.Cursor = Cursor{\n\t\tLoc: Loc{0, 0},\n\t\tbuf: b,\n\t}\n\n\t//InitLocalSettings(b)\n\n\tb.cursors = []*Cursor{&b.Cursor}\n\n\treturn b\n}", "func NewBuffer(length int) *Buffer {\n\treturn &Buffer{\n\t\titems: make([]unsafe.Pointer, length),\n\t}\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func New(w, h int) *Buffer {\n\tb := &Buffer{\n\t\tWidth: w,\n\t\tHeight: h,\n\t\tCursor: NewCursor(0, 0),\n\t\tTiles: make([]*Tile, w*h),\n\t}\n\tb.Resize(w, h)\n\treturn b\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 initBuffer(size int) {\n\tif len(buffer) == size {\n\t\treturn\n\t}\n\tbuffer = make([]uint8, size)\n}", "func (b *BatchBuffer) Init() {}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 0\n}", "func New(i int) *Buffer {\n\treturn &Buffer{\n\t\tsize: i,\n\t}\n}", "func newBufferItem(events *structs.Events) *bufferItem {\n\treturn &bufferItem{\n\t\tlink: &bufferLink{\n\t\t\tnextCh: make(chan struct{}),\n\t\t\tdroppedCh: make(chan struct{}),\n\t\t},\n\t\tEvents: events,\n\t\tcreatedAt: time.Now(),\n\t}\n}", "func NewAttached(buffer []byte) *Buffer {\n result := NewEmptyBuffer()\n result.Attach(buffer)\n return result\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 newSafeBuffer() *safeBuffer {\n\treturn &safeBuffer{\n\t\tbuf: bytes.NewBuffer(nil),\n\t}\n}", "func NewLocalBuffer(b bytes.Buffer) *LocalBuffer { return &LocalBuffer{b: b} }", "func (m *metricMysqlBufferPoolUsage) init() {\n\tm.data.SetName(\"mysql.buffer_pool.usage\")\n\tm.data.SetDescription(\"The number of bytes in the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"By\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func (buf *ListBuffer) Init() {\n\tbuf.Buffer = make([]Node, defaultBufferLength)\n\tbuf.FreeHead = 0\n\tbuf.Count = 0\n\n\tfor i := 0; i < len(buf.Buffer); i++ {\n\t\tbuf.Buffer[i].Item.Clear()\n\t\tbuf.Buffer[i].Prev = BufferIndex(i - 1)\n\t\tbuf.Buffer[i].Next = BufferIndex(i + 1)\n\t}\n\n\tbuf.Buffer[0].Prev = NilIndex\n\tbuf.Buffer[len(buf.Buffer)-1].Next = NilIndex\n}", "func NewBuffer(inp []byte) *ByteBuffer {\n\tif inp == nil {\n\t\tinp = make([]byte, 0, 512)\n\t}\n\treturn &ByteBuffer{Buffer: bytes.NewBuffer(inp)}\n}", "func New(buffer, backing sorted.KeyValue, maxBufferBytes int64) *KeyValue {\n\treturn &KeyValue{\n\t\tbuffer: buffer,\n\t\tback: backing,\n\t\tmaxBuffer: maxBufferBytes,\n\t}\n}", "func (src *Source) SetNewBuffer() {\n\tsrc.buf = make([]byte, 64)\n}", "func NewBufferBuilder() *BufferBuilder {\n\treturn &BufferBuilder{}\n}", "func (m *metricMysqlBufferPoolOperations) init() {\n\tm.data.SetName(\"mysql.buffer_pool.operations\")\n\tm.data.SetDescription(\"The number of operations on the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"1\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(true)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func (m *Manager) NewBuffer(conf buffer.Config) (buffer.Streamed, error) {\n\treturn nil, component.ErrInvalidType(\"buffer\", conf.Type)\n}", "func NewBuffer(conn *net.TCPConn, buffOb chan bool, maxQueueSize int) *Buffer {\n\tsize := maxQueueSize\n\n\tif size == -1 {\n\t\tsize = DEFAULT_QUEUE_SIZE\n\t}\n\n\tbuf := new(Buffer)\n\tbuf.conn = conn\n\tbuf.pending = make(chan []byte, size)\n\tbuf.ctrl = make(chan bool)\n\tbuf.ob = buffOb\n\tbuf.max = size\n\n\treturn buf\n}", "func New() *MemStore {\n\ts := new(MemStore)\n\ts.did = make(map[string]common.Role)\n\ts.act = make(map[string]common.Role)\n\ts.tkt = make(map[string]common.Ticket)\n\t// initialize random gen\n\ts.rand = rand.New(rand.NewSource(time.Now().UnixNano() + 9999999))\n\treturn s\n}", "func NewAttachedBuffer(buffer *Buffer) *Buffer {\n result := NewEmptyBuffer()\n result.AttachBuffer(buffer)\n return result\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\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 (_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 NewBuffer(m []byte, skip, size int64) (*Buffer, error) {\n\tb := &Buffer{\n\t\toffset: skip,\n\t\tsize: size,\n\t\tdata: m,\n\t}\n\treturn b, 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 newBuffer(br *Reader) (*buffer, error) {\n\tn, err := io.ReadFull(br.r, br.buf[:4])\n\t// br.r.Chunk() is only valid after the call the Read(), so this\n\t// must come after the first read in the record.\n\ttx := br.r.Begin()\n\tdefer func() {\n\t\tbr.lastChunk = tx.End()\n\t}()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif n != 4 {\n\t\treturn nil, errors.New(\"bam: invalid record: short block size\")\n\t}\n\tb := &buffer{data: br.buf[:4]}\n\tsize := int(b.readInt32())\n\tif size == 0 {\n\t\treturn nil, io.EOF\n\t}\n\tif size < 0 {\n\t\treturn nil, errors.New(\"bam: invalid record: invalid block size\")\n\t}\n\tif size > cap(br.buf) {\n\t\tb.off, b.data = 0, make([]byte, size)\n\t} else {\n\t\tb.off, b.data = 0, br.buf[:size]\n\t\tb.shared = true\n\t}\n\tn, err = io.ReadFull(br.r, b.data)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif n != size {\n\t\treturn nil, errors.New(\"bam: truncated record\")\n\t}\n\treturn b, nil\n}", "func (b *defaultByteBuffer) NewBuffer() ByteBuffer {\n\treturn NewWriterBuffer(256)\n}", "func (m *Memory) Init(size int) {\n\tcontent := make([]byte, size)\n\tm.content = content\n}", "func NewBuffer(conn *sqlite.Conn) (*Buffer, error) {\n\treturn NewBufferSize(conn, 16*1024)\n}", "func (b *Buffer) Mutable() bool { return b.mutable }", "func (s *seqBuf) init(length time.Duration, maxSeqNum, maxSeqNumDiff seqNum, entryChan chan seqBufEntry) {\n\ts.length = length\n\ts.maxSeqNum = maxSeqNum\n\ts.maxSeqNumDiff = maxSeqNumDiff\n\ts.entryChan = entryChan\n\n\ts.entryAddedChan = make(chan bool)\n\ts.watcherCloseNeededChan = make(chan bool)\n\ts.watcherCloseDoneChan = make(chan bool)\n\tgo s.watcher()\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 New(size int) *MsgBuffer {\r\n\r\n\treturn &MsgBuffer{\r\n\t\tb: make([]byte, size),\r\n\t}\r\n}", "func newSafeBuffer(bufsize int) ([]byte, error) {\n\t// Max BSON document size is 16MB.\n\t// https://docs.mongodb.com/manual/reference/limits/\n\t// For simplicity, bound buffer size at 32MB so that headers and so on fit\n\t// too.\n\t// TODO: Can you put multiple large documents in one insert or reply and\n\t// exceed this limit?\n\tif (bufsize < 0) || (bufsize > 32*1024*1024) {\n\t\treturn nil, fmt.Errorf(\"Invalid buffer size %d\", bufsize)\n\t}\n\treturn make([]byte, bufsize), nil\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func New(handler Action, options ...Option) *Buffer {\n\tafb := Buffer{\n\t\tLatch: async.NewLatch(),\n\t\tHandler: handler,\n\t\tParallelism: runtime.NumCPU(),\n\t\tMaxFlushes: DefaultMaxFlushes,\n\t\tMaxLen: DefaultMaxLen,\n\t\tInterval: DefaultFlushInterval,\n\t\tShutdownGracePeriod: DefaultShutdownGracePeriod,\n\t}\n\tfor _, option := range options {\n\t\toption(&afb)\n\t}\n\tafb.contents = collections.NewRingBufferWithCapacity(afb.MaxLen)\n\treturn &afb\n}", "func (kvstore *KVStore) init_db() {\n\t/*\n\t\tdifference between make and new?\n\t\t1. make(T) always return type T; new(T) returns type *T\n\t\t2. new works for all types,\n\tand dynamically allocates space for a variable of that type,\n\tinitialized to the zero value of that type, and returns a pointer to it;\n\t\t make works as a kind of \"constructor\" for certain bult-in types(\n\tslice, map, channel)\n\t*/\n\tfmt.Println(\"initializing kvstore\")\n\tkvstore.kvstore = make(map[string][]byte)\n}", "func NewBufferFromString(text string) *Buffer {\n\treturn NewBuffer(strings.NewReader(text), int64(len(text)), \"1.msg\", nil)\n}", "func NewMemoryStorage() *MemoryStorage {\n return &MemoryStorage{tickets: make(map[string]*types.Ticket)}\n}", "func NewBuffer(size int) *Buffer {\n\treturn &Buffer{size: size, tail: 0, head: 0, buf: make([]byte, size)}\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func (pool *BufferPool) New() (buf *bytes.Buffer) {\n\tselect {\n\tcase buf = <-pool.Buffers:\n\tdefault:\n\t\tbuf = &bytes.Buffer{}\n\t}\n\treturn\n}", "func (t *table) allocateBuffer(l int) *colReader {\n\tif t.colBufs == nil || atomic.LoadInt64(&t.colBufs.refCount) > 0 {\n\t\t// The current buffer is still being used so we should\n\t\t// generate a new one.\n\t\tt.colBufs = &colReader{\n\t\t\tkey: t.key,\n\t\t\tcolMeta: t.cols,\n\t\t\tcols: make([]array.Interface, len(t.cols)),\n\t\t}\n\t}\n\tt.colBufs.refCount = 1\n\tt.colBufs.l = l\n\treturn t.colBufs\n}", "func NewPtrBuffer(aSlice interface{}) *Buffer {\n aSliceValue := sliceValue(aSlice, true)\n return &Buffer{\n buffer: aSliceValue,\n handler: overwriteNilPtrHandler{\n creater: newCreaterFunc(nil, aSliceValue.Type())}}\n}", "func newObject(db *StateDB, key math.Hash, data meta.Account) *StateObject {\n\treturn &StateObject{\n\t\tdb: db,\n\t\tkey: key,\n\t\tdata: data,\n\t\toriginStorage: make(Storage),\n\t\tdirtyStorage: make(Storage),\n\t}\n}", "func NewDistributedObjectWithData() {}", "func New() *ListBuffer {\n\tbuf := new(ListBuffer)\n\tbuf.Init()\n\treturn buf\n}", "func TestGetSingletonBuffer(t *testing.T) {\n\tasserter := assert.New(t)\n\tbuffer := GetBuffer()\n\tbuf := buffer.(*TaskBuffer)\n\tasserter.Equal(100, cap(buf.Channel))\n\tasserter.Equal(10, buf.Tx)\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 NewSafeBuffer() *SafeBuffer {\n\treturn &SafeBuffer{\n\t\tb: bytes.NewBuffer(nil),\n\t\tm: sync.RWMutex{},\n\t}\n}", "func newBufferPool() *bufferPool {\n\treturn &bufferPool{&sync.Pool{\n\t\tNew: func() interface{} {\n\t\t\treturn &bytes.Buffer{}\n\t\t},\n\t}}\n}", "func (b *BadgerStore) init(dir string) error {\n\n\topts := badger.DefaultOptions(dir)\n\tif dir == \"\" {\n\t\topts = opts.WithInMemory(true)\n\t}\n\topts.Logger = &common.NoopLogger{}\n\tdb, err := badger.Open(opts)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"failed to open database\")\n\t}\n\n\t// Set the database\n\tb.db = db\n\n\t// Initialize the default transaction that auto commits\n\t// on success ops or discards on failure.\n\t// It also enables the renewal of the underlying transaction\n\t// after executing a read/write operation\n\tb.Tx = NewTx(db, true, true)\n\n\treturn nil\n}", "func NewBuilder(buffer []byte) *Builder {\n\treturn &Builder{\n\t\tresult: buffer,\n\t}\n}", "func TestNewTaskBuffer(t *testing.T) {\n\tasserter := assert.New(t)\n\tbuffer := NewTaskBuffer(10, 1)\n\n\tbuf := buffer.(*TaskBuffer)\n\tasserter.Equal(cap(buf.Channel), 10)\n\tasserter.Equal(buf.Tx, 1)\n}", "func NewCompactableBuffer(config *CompatbleBufferConfig) (*CompactableBuffer, error) {\n\taddressableBuffer, err := newAddressableBuffer(config.BufferConfig)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"Failed to create compatable buffer - unable to create addressable buffer %v\", err)\n\t}\n\tcompatableBuffer, err := loadCompactingBufferIdNeeded(config.BufferConfig)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"Failed to create compatable buffer, %v\", err)\n\t}\n\n\tresult := &CompactableBuffer{config: config}\n\tresult.setReadableBuffer(addressableBuffer)\n\tresult.setWritableBuffer(addressableBuffer)\n\n\tif compatableBuffer != nil && compatableBuffer.Count() > 0 {\n\t\terr = result.compactWithBuffer(compatableBuffer)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"Failed to create buffer - unable compact %v\", err)\n\t\t}\n\t}\n\n\tresult.count = int64(addressableBuffer.Count())\n\tresult.removedCount = addressableBuffer.removedCount\n\tresult.dataSize = addressableBuffer.dataSize\n\tresult.entrySize = addressableBuffer.entrySize\n\tresult.compactionWaitGroup = &sync.WaitGroup{}\n\tresult.notification = make(chan bool, 1)\n\tresult.manageAutoCompaction()\n\n\treturn result, nil\n}", "func init() {\n\tMemory = &memoryStorage{\n\t\ttraces: make(map[string]tracer.Trace),\n\t\tservices: make(map[string]string),\n\t\tserviceDeps: make(map[string]*tracer.Dependencies),\n\t}\n}", "func newStorage() *storage {\n\tr := make(map[string][]byte)\n\treturn &storage{\n\t\trepository: r,\n\t}\n}", "func (p *MemProvider) Init(maxLifetime int64, _ string) error {\n\tp.lock.Lock()\n\tp.list = list.New()\n\tp.data = make(map[string]*list.Element)\n\tp.maxLifetime = maxLifetime\n\tp.lock.Unlock()\n\treturn nil\n}", "func (r *DBReader) SetBuffer(buffer io.Reader) {\n\tr.buffer = buffer\n}" ]
[ "0.6349263", "0.6268834", "0.6243279", "0.6195426", "0.61694556", "0.601713", "0.5932492", "0.5875461", "0.5873252", "0.58522457", "0.5843238", "0.58288723", "0.5812875", "0.568097", "0.5639489", "0.56271803", "0.5614063", "0.5613734", "0.5606573", "0.55912125", "0.5575135", "0.55185974", "0.5516182", "0.5504612", "0.5484755", "0.546681", "0.54478246", "0.54478216", "0.54390895", "0.54377943", "0.5432694", "0.54238373", "0.538923", "0.5387694", "0.5373588", "0.5371471", "0.5370617", "0.5353238", "0.53506994", "0.5343122", "0.5337203", "0.5336538", "0.5330275", "0.53042126", "0.5299109", "0.52942294", "0.528354", "0.5283134", "0.5275738", "0.5271442", "0.5266598", "0.5261546", "0.5254997", "0.5232468", "0.52298075", "0.5229553", "0.5217864", "0.5191744", "0.51869196", "0.51857007", "0.5173917", "0.517207", "0.51707196", "0.51657134", "0.5163538", "0.51578736", "0.5142169", "0.51415724", "0.5139734", "0.51270914", "0.5120826", "0.51199836", "0.5110191", "0.5104892", "0.5101042", "0.5089884", "0.5070503", "0.50694305", "0.5060653", "0.5056164", "0.50517243", "0.50503725", "0.5045627", "0.5045109", "0.5034378", "0.5029515", "0.5021194", "0.499628", "0.49943373", "0.4987921", "0.49807605", "0.49639478", "0.49623626", "0.49597922", "0.493431", "0.4931683", "0.4923737", "0.4916679", "0.49129346", "0.4900499", "0.4891589" ]
0.0
-1
Parameter clientBuffer has type C.GLeglClientBufferEXT.
func NamedBufferStorageExternalEXT(buffer uint32, offset int, size int, clientBuffer unsafe.Pointer, flags uint32) { C.glowNamedBufferStorageExternalEXT(gpNamedBufferStorageExternalEXT, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLeglClientBufferEXT)(clientBuffer), (C.GLbitfield)(flags)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n C.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tC.glowTextureBuffer(gpTextureBuffer, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tC.glowTextureBuffer(gpTextureBuffer, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n\tC.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n\tC.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tsyscall.Syscall(gpTextureBuffer, 3, uintptr(texture), uintptr(internalformat), uintptr(buffer))\n}", "func DeleteBuffer(v Buffer) {\n\tgl.DeleteBuffers(1, &v.Value)\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 IsBuffer(buffer uint32) bool {\n ret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n return ret == TRUE\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tsyscall.Syscall(gpVertexArrayElementBuffer, 2, uintptr(vaobj), uintptr(buffer), 0)\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\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 IsBuffer(buffer uint32) bool {\n\tret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func IsBuffer(buffer uint32) bool {\n\tret := C.glowIsBuffer(gpIsBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func DrawBuffer(buf uint32) {\n\tsyscall.Syscall(gpDrawBuffer, 1, uintptr(buf), 0, 0)\n}", "func IsBuffer(buffer Uint) Boolean {\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\t__ret := C.glIsBuffer(cbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func ReadBuffer(src uint32) {\n\tC.glowReadBuffer(gpReadBuffer, (C.GLenum)(src))\n}", "func ReadBuffer(src uint32) {\n\tC.glowReadBuffer(gpReadBuffer, (C.GLenum)(src))\n}", "func SelectBuffer(size int32, buffer *uint32) {\n C.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\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 DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func BufferStorageExternalEXT(target uint32, offset int, size int, clientBuffer unsafe.Pointer, flags uint32) {\n\tC.glowBufferStorageExternalEXT(gpBufferStorageExternalEXT, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLeglClientBufferEXT)(clientBuffer), (C.GLbitfield)(flags))\n}", "func GenBuffer() Buffer {\n\tvar b gl.Uint\n\tgl.GenBuffers(1, &b)\n\treturn Buffer(b)\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 BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n C.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\n}", "func (native *OpenGL) BindBuffer(target uint32, buffer uint32) {\n\tgl.BindBuffer(target, buffer)\n}", "func SelectBuffer(size int32, buffer *uint32) {\n\tC.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func CreateBuffer() Buffer {\n\tvar b Buffer\n\tgl.GenBuffers(1, &b.Value)\n\treturn b\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n\tC.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n\tC.glowGetBufferPointerv(gpGetBufferPointerv, (C.GLenum)(target), (C.GLenum)(pname), params)\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 IsBuffer(b Buffer) bool {\n\treturn gl.IsBuffer(b.Value)\n}", "func ReadBuffer(src uint32) {\n\tsyscall.Syscall(gpReadBuffer, 1, uintptr(src), 0, 0)\n}", "func BindBuffer(target Enum, b Buffer) {\n\tgl.BindBuffer(uint32(target), b.Value)\n}", "func BufferStorageExternalEXT(target uint32, offset int, size int, clientBuffer unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpBufferStorageExternalEXT, 5, uintptr(target), uintptr(offset), uintptr(size), uintptr(clientBuffer), uintptr(flags), 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 (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 BindBuffer(target Enum, buffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\tC.glBindBuffer(ctarget, cbuffer)\n}", "func NewWlBuffer(c *wire.Conn) *WlBuffer {\n\treturn NewWlBufferWithID(c, c.NewID())\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func InvalidateBufferData(buffer uint32) {\n\tC.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func NewBufferGeometry() BufferGeometry {\n\treturn NewBufferGeometryFromJSValue(\n\t\tThreejs(\"BufferGeometry\").New(),\n\t)\n}", "func ReadBuffer(mode uint32) {\n C.glowReadBuffer(gpReadBuffer, (C.GLenum)(mode))\n}", "func (n *BufferView) AddBuffer() *Buffer {\n\tn.UnfocusBuffers()\n\n\tconf := n.conf\n\tc := NewBuffer(conf, BufferConfig{\n\t\tconf.Theme.Background,\n\t\tconf.Theme.Foreground,\n\t\tconf.Theme.Cursor,\n\t\tconf.Theme.CursorInvert,\n\t\tconf.Theme.HighlightLineBackground,\n\t\tconf.Theme.GutterBackground,\n\t\tconf.Theme.GutterForeground,\n\t\tgui.GetDefaultFont(),\n\t}, n, len(n.buffers))\n\n\tc.SetFocus(true)\n\n\tw, h := n.GetSize()\n\n\tn.focusedBuff = c.index\n\tn.buffers = append(n.buffers, NewBufferPane(c))\n\tn.Resize(w, h)\n\n\treturn c\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 PushClientAttrib(mask uint32) {\n\tC.glowPushClientAttrib(gpPushClientAttrib, (C.GLbitfield)(mask))\n}", "func (gl *WebGL) BindBuffer(target GLEnum, buffer WebGLBuffer) {\n\tgl.context.Call(\"bindBuffer\", target, buffer)\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 (gl *WebGL) BufferData(target GLEnum, data interface{}, usage GLEnum) {\n\tvalues := sliceToTypedArray(data)\n\tgl.context.Call(\"bufferData\", target, values, usage)\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewEnumsModel(buffer),\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyEnumsFunc(func(model *EnumsModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func Buffer() string {\n\treturn C.GoString(C.rl_line_buffer)\n}", "func PushClientAttrib(mask uint32) {\n C.glowPushClientAttrib(gpPushClientAttrib, (C.GLbitfield)(mask))\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 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 GetBufferParameteriv(target uint32, pname uint32, params *int32) {\n\tC.glowGetBufferParameteriv(gpGetBufferParameteriv, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetBufferParameteriv(target uint32, pname uint32, params *int32) {\n\tC.glowGetBufferParameteriv(gpGetBufferParameteriv, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (gl *WebGL) CreateBuffer() WebGLBuffer {\n\treturn WebGLBuffer(gl.context.Call(\"createBuffer\"))\n}", "func (debugging *debuggingOpenGL) BindBuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindBuffer\", target, buffer)\n\tdebugging.gl.BindBuffer(target, buffer)\n\tdebugging.recordExit(\"BindBuffer\")\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func GetBufferParameteriv(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.glGetBufferParameteriv(ctarget, cpname, cparams)\n}", "func GetBufferPointerv(target uint32, pname uint32, params *unsafe.Pointer) {\n\tsyscall.Syscall(gpGetBufferPointerv, 3, uintptr(target), uintptr(pname), uintptr(unsafe.Pointer(params)))\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 (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 GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n C.glowGetBufferSubData(gpGetBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBuffer, 2, uintptr(target), uintptr(buffer), 0)\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 MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n\tret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n\treturn (unsafe.Pointer)(ret)\n}", "func GetNamedBufferPointerv(buffer uint32, pname uint32, params *unsafe.Pointer) {\n\tC.glowGetNamedBufferPointerv(gpGetNamedBufferPointerv, (C.GLuint)(buffer), (C.GLenum)(pname), params)\n}", "func GetNamedBufferPointerv(buffer uint32, pname uint32, params *unsafe.Pointer) {\n\tC.glowGetNamedBufferPointerv(gpGetNamedBufferPointerv, (C.GLuint)(buffer), (C.GLenum)(pname), params)\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 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 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 IsBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpIsBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func BindVertexBuffer(bindingindex uint32, buffer uint32, offset int, stride int32) {\n C.glowBindVertexBuffer(gpBindVertexBuffer, (C.GLuint)(bindingindex), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizei)(stride))\n}", "func NewBufferBuilder() *BufferBuilder {\n\treturn &BufferBuilder{}\n}", "func (b *VBO) GenBuffer() {\n\tgl.GenBuffers(1, &b.vboID)\n\tb.genBound = true\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 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 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 GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowGetBufferSubData(gpGetBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowGetBufferSubData(gpGetBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func NewBuffer(e []byte) *Buffer {\n\treturn &Buffer{buf: e}\n}", "func GetBufferParameteriv(target gl.Enum, pname gl.Enum, params []int32) {\n\tgl.GetBufferParameteriv(gl.Enum(target), gl.Enum(pname), (*gl.Int)(&params[0]))\n}", "func GetBufferParameteriv(target uint32, pname uint32, params *int32) {\n\tsyscall.Syscall(gpGetBufferParameteriv, 3, uintptr(target), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}" ]
[ "0.6129524", "0.6076844", "0.6076844", "0.605947", "0.605947", "0.59893376", "0.5952124", "0.59304", "0.59304", "0.5906616", "0.58735174", "0.58511", "0.5824264", "0.5824264", "0.5819625", "0.5819625", "0.5741683", "0.5729403", "0.5707841", "0.5707841", "0.56797343", "0.56639266", "0.55866504", "0.5585445", "0.55833787", "0.5515174", "0.5501898", "0.5491528", "0.5473454", "0.5472669", "0.54259074", "0.5410465", "0.5410192", "0.5410192", "0.53577346", "0.53577346", "0.53468966", "0.53347176", "0.53240955", "0.53185815", "0.53184545", "0.52991974", "0.5297454", "0.5293912", "0.52933866", "0.5288243", "0.5288243", "0.5265202", "0.52644753", "0.5263083", "0.52368087", "0.5232616", "0.5216459", "0.52164346", "0.52048045", "0.5203941", "0.51795197", "0.5175985", "0.5175174", "0.5155234", "0.514939", "0.514784", "0.514784", "0.51418126", "0.5136249", "0.5125972", "0.5112448", "0.5097006", "0.5097006", "0.50799966", "0.50748825", "0.50647223", "0.504952", "0.50409293", "0.5040314", "0.5032818", "0.50247085", "0.50247085", "0.501761", "0.501761", "0.5010264", "0.49870598", "0.49838316", "0.49825624", "0.4968726", "0.49529853", "0.49464563", "0.49421284", "0.49421284", "0.4937845", "0.4937845", "0.49258032", "0.49257094", "0.49257094", "0.49032545", "0.48957658", "0.4894646", "0.48932597", "0.48837373", "0.48837373" ]
0.5158884
59
updates a subset of a buffer object's data store
func NamedBufferSubData(buffer uint32, offset int, size int, data unsafe.Pointer) { C.glowNamedBufferSubData(gpNamedBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 (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 BufferSubData(target Enum, offset int, data []byte) {\n\tgl.BufferSubData(uint32(target), offset, int(len(data)), gl.Ptr(&data[0]))\n}", "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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n C.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tsyscall.Syscall(gpInvalidateBufferSubData, 3, uintptr(buffer), uintptr(offset), uintptr(length))\n}", "func (gl *WebGL) BufferSubData(target GLEnum, offset int, data interface{}) {\n\tvalues := sliceToTypedArray(data)\n\tgl.context.Call(\"bufferSubData\", target, offset, values)\n}", "func (c *Cache) recordUpdate(p *partition, bytesAdded, bytesGuessed, entriesAdded int32) {\n\t// This method is always called while p.mu is held.\n\t// The below code takes care to ensure that all bytes in c due to p are\n\t// updated appropriately.\n\n\t// NB: The loop and atomics are used because p.size can be modified\n\t// concurrently to calls to recordUpdate. In all cases where p.size is updated\n\t// outside of this function occur while c.mu is held inside of c.Add. These\n\t// occur when either:\n\t//\n\t// 1) a new write adds its guessed write size to p\n\t// 2) p is evicted to make room for a write\n\t//\n\t// Thus p.size is either increasing or becomes evicted while we attempt to\n\t// record the update to p. Once p is evicted it stays evicted forever.\n\t// These facts combine to ensure that p.size never becomes negative from the\n\t// below call to add.\n\n\tdelta := bytesAdded - bytesGuessed\n\tfor {\n\t\tcurSize := p.loadSize()\n\t\tif curSize == evicted {\n\t\t\treturn\n\t\t}\n\t\tnewSize := curSize.add(delta, entriesAdded)\n\t\tif updated := p.setSize(curSize, newSize); updated {\n\t\t\tc.updateGauges(c.addBytes(delta), c.addEntries(entriesAdded))\n\t\t\treturn\n\t\t}\n\t}\n}", "func (s *EntityStorage) update() {\n\ts.outdated = false\n\ts.occupied = s.occupied[:0]\n\tl := len(s.vec)\n\tfor i := 0; i < l; i++ {\n\t\tif s.vec[i].occupied {\n\t\t\ts.occupied = append(s.occupied, i)\n\t\t}\n\t}\n}", "func (s *IndexablePartitionClockStorage) update(clock PartitionClock) {\n\ts.VbNos = s.VbNos[:0]\n\ts.Seqs = s.Seqs[:0]\n\tfor vb, seq := range clock {\n\t\ts.VbNos = append(s.VbNos, vb)\n\t\ts.Seqs = append(s.Seqs, seq)\n\t}\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 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 (t *Terminal) updateBuffer() {\n\tcopy(termbox.CellBuffer(), t.buffer)\n\tif err := termbox.Flush(); err != nil {\n\t\tlog.Fatal(err)\n\t}\n}", "func (b *Buffer) update() {\n\tb.NumLines = len(b.lines)\n}", "func (g *gcm) update(y *gcmFieldElement, data []byte) {\n\tfullBlocks := (len(data) >> 4) << 4\n\tg.updateBlocks(y, data[:fullBlocks])\n\n\tif len(data) != fullBlocks {\n\t\tvar partialBlock [gcmBlockSize]byte\n\t\tcopy(partialBlock[:], data[fullBlocks:])\n\t\tg.updateBlocks(y, partialBlock[:])\n\t}\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 (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\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 (m *metricMysqlBufferPoolOperations) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (b *Buffer) reload() error {\n\tstat, err := os.Stat(b.filename)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfsize := uint64(stat.Size())\n\tb.capacity = fsize - metadata\n\n\tf, err := os.OpenFile(b.filename, os.O_RDWR, 0600)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tdata, err := syscall.Mmap(\n\t\tint(f.Fd()), 0, int(fsize),\n\t\tsyscall.PROT_READ|syscall.PROT_WRITE, syscall.MAP_SHARED,\n\t)\n\tif err != nil {\n\t\treturn err\n\t}\n\tb.data = data\n\n\toff := int(b.capacity)\n\tb.first = binary.GetLittleEndianUint64(b.data, off)\n\tb.last = binary.GetLittleEndianUint64(b.data, off+8)\n\tb.nextSeq = binary.GetLittleEndianUint64(b.data, off+16)\n\tb.biggest = binary.GetLittleEndianUint32(b.data, off+24)\n\tb.length = binary.GetLittleEndianUint64(b.data, off+28)\n\n\treturn nil\n}", "func (this *DatastoreOperations) Append(transactionBytes []byte, state *DatastoreState, commitTimestamp int64, flushAfterWrite bool, maxFlushDelay int64) (err error) {\n\t// Clone the given state into a new state object\n\tnewState := state.Clone()\n\n\t// Append the transaction to the file\n\t_, err = newState.File.WriteAt(transactionBytes, state.Size())\n\n\t// If an error occured while writing to the file\n\tif err != nil {\n\t\t// Return the error\n\t\treturn\n\t}\n\n\t// Update the index with the timestamps and offsets of the new entries\n\terr = newState.Index.AppendFromBuffer(transactionBytes, nil)\n\n\t// If an error occured while updating the index\n\tif err != nil {\n\t\t// Return the error\n\t\treturn\n\t}\n\n\t// If the datastore should be cached\n\tif this.IsCached {\n\t\t// Update its data cache\n\t\terr = newState.UpdateDataCache(bytes.NewReader(transactionBytes), 0, int64(len(transactionBytes)))\n\n\t\t// If an error has occurred while updating the cache, return\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\t// Schedule a flush, if needed.\n\tif flushAfterWrite {\n\t\tthis.ScheduleFlushIfNeeded(newState, maxFlushDelay)\n\t}\n\n\t// Atomically replace the current state object with the new state object\n\tthis.ReplaceState(newState)\n\n\t// Announce the update\n\tthis.UpdateNotifier.AnnounceUpdate(commitTimestamp)\n\n\treturn\n}", "func (buf *ListBuffer) Set(idx BufferIndex, item Item) (*error.Error) {\n\tinRange, initialized := buf.legalIndex(idx)\n\tif !inRange {\n\t\tdesc := fmt.Sprintf(\n\t\t\t\"idx, %d, is out of range for IndexBuffer of length %d.\",\n\t\t\tidx, len(buf.Buffer),\n\t\t)\n\t\treturn error.New(error.Value, desc)\n\t} else if !initialized {\n\t\tdesc := fmt.Sprintf(\n\t\t\t\"Item at idx, %d, has the Type value Uninitialized.\", idx,\n\t\t)\n\t\treturn error.New(error.Value, desc)\n\t}\n\n\tbuf.Buffer[idx].Item = item\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 (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 (d *adapterMemoryData) Update(key interface{}, value interface{}) (oldValue interface{}, exist bool, err error) {\n\td.mu.Lock()\n\tdefer d.mu.Unlock()\n\tif item, ok := d.data[key]; ok {\n\t\td.data[key] = adapterMemoryItem{\n\t\t\tv: value,\n\t\t\te: item.e,\n\t\t}\n\t\treturn item.v, true, nil\n\t}\n\treturn nil, false, nil\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 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 InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func InvalidateBufferSubData(buffer uint32, offset int, length int) {\n\tC.glowInvalidateBufferSubData(gpInvalidateBufferSubData, (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(length))\n}", "func BufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowBufferSubData(gpBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func BufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tC.glowBufferSubData(gpBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func (p *MemProvider) update(sid string) error {\n\tp.lock.Lock()\n\tdefer p.lock.Unlock()\n\n\tif e, ok := p.data[sid]; ok {\n\t\te.Value.(*MemStore).lastAccess = time.Now()\n\t\tp.list.MoveToFront(e)\n\t\treturn nil\n\t}\n\treturn nil\n}", "func storeDataUsageInBackend(ctx context.Context, objAPI ObjectLayer, gui <-chan DataUsageInfo) {\n\tfor dataUsageInfo := range gui {\n\t\tdataUsageJSON, err := json.Marshal(dataUsageInfo)\n\t\tif err != nil {\n\t\t\tlogger.LogIf(ctx, err)\n\t\t\tcontinue\n\t\t}\n\t\tsize := int64(len(dataUsageJSON))\n\t\tr, err := hash.NewReader(bytes.NewReader(dataUsageJSON), size, \"\", \"\", size, false)\n\t\tif err != nil {\n\t\t\tlogger.LogIf(ctx, err)\n\t\t\tcontinue\n\t\t}\n\n\t\t_, err = objAPI.PutObject(ctx, dataUsageBucket, dataUsageObjName, NewPutObjReader(r, nil, nil), ObjectOptions{})\n\t\tif !isErrBucketNotFound(err) {\n\t\t\tlogger.LogIf(ctx, err)\n\t\t}\n\t}\n}", "func (m *metricMysqlBufferPoolUsage) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (k Keeper) UpdateTickersBuffer(startTS, endTS int64, productList []string) {\n\n\tdefer types.PrintStackIfPanic()\n\n\tk.Orm.Debug(fmt.Sprintf(\"[backend] entering UpdateTickersBuffer, latestTickers: %+v, TickerTimeRange: [%d, %d)=[%s, %s), productList: %v\",\n\t\tk.Cache.LatestTicker, startTS, endTS, types.TimeString(startTS), types.TimeString(endTS), productList))\n\n\tlatestProducts := []string{}\n\tfor p := range k.Cache.LatestTicker {\n\t\tlatestProducts = append(latestProducts, p)\n\t}\n\ttickerMap, err := k.Orm.RefreshTickers(startTS, endTS, productList)\n\tif err != nil {\n\t\tk.Orm.Error(fmt.Sprintf(\"generateTicker error %+v, latestTickers %+v, returnTickers: %+v\", err, k.Cache.LatestTicker, tickerMap))\n\t\treturn\n\t}\n\n\tif len(tickerMap) > 0 {\n\t\tfor product, ticker := range tickerMap {\n\t\t\tk.Cache.LatestTicker[product] = ticker\n\t\t\tk.pushWSItem(ticker)\n\t\t\tk.pushTickerItems(ticker)\n\t\t}\n\n\t\tk.Orm.Debug(fmt.Sprintf(\"UpdateTickersBuffer LatestTickerMap: %+v\", k.Cache.LatestTicker))\n\t} else {\n\t\tk.Orm.Debug(fmt.Sprintf(\"UpdateTickersBuffer No product's deal refresh in [%d, %d), latestTicker: %+v\", startTS, endTS, k.Cache.LatestTicker))\n\t}\n\n\t// Case: No deals produced in last 24 hours.\n\tfor _, p := range latestProducts {\n\t\trefreshedTicker := tickerMap[p]\n\t\tif refreshedTicker == nil {\n\t\t\tpreviousTicker := k.Cache.LatestTicker[p]\n\t\t\tif previousTicker != nil && (endTS > previousTicker.Timestamp+types.SecondsInADay) {\n\t\t\t\tpreviousTicker.Open = previousTicker.Close\n\t\t\t\tpreviousTicker.High = previousTicker.Close\n\t\t\t\tpreviousTicker.Low = previousTicker.Close\n\t\t\t\tpreviousTicker.Volume = 0\n\t\t\t\tpreviousTicker.Change = 0\n\t\t\t\tpreviousTicker.ChangePercentage = \"0.00%\"\n\t\t\t}\n\n\t\t}\n\t}\n}", "func (c *AdapterMemory) Update(ctx context.Context, key interface{}, value interface{}) (oldValue *gvar.Var, exist bool, err error) {\n\tv, exist, err := c.data.Update(key, value)\n\treturn gvar.New(v), exist, err\n}", "func (o StreamOptimizer) batch(ctx context.Context, chq <-chan *tree.SyncChange) <-chan *ChangeBuffer {\n\tcbQ := make(chan *ChangeBuffer, 1)\n\n\tvar nid string\n\tvar change *tree.SyncChange\n\tbuf := newBuffer()\n\n\tgo func() {\n\t\tdefer func() { close(cbQ) }()\n\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase <-ctx.Done():\n\t\t\t\treturn\n\t\t\tcase change = <-chq:\n\t\t\t\t// TODO why do we sometimes receive nil?\n\t\t\t\tif change == nil {\n\t\t\t\t\tif !buf.isEmpty() {\n\t\t\t\t\t\t// transmit the last buffer before returning\n\t\t\t\t\t\tcbQ <- buf\n\t\t\t\t\t}\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif nid != change.NodeId {\n\t\t\t\t\tif buf.isEmpty() {\n\t\t\t\t\t\t// Drop it on the floor: it happens on the very first iteration\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcbQ <- buf\n\t\t\t\t\t}\n\t\t\t\t\tbuf = newBuffer()\n\t\t\t\t\tnid = change.NodeId\n\t\t\t\t}\n\t\t\t\tbuf.Append(change)\n\t\t\t}\n\t\t}\n\t}()\n\n\treturn cbQ\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 (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func (s BoltStore) BatchUpdate(ids []interface{}, data []interface{}, store string, opts ObjectStoreOptions) (err error) {\n\treturn ErrNotImplemented\n}", "func (m *DBMem) Update(idToUpdate int, data Person) {\n m.Lock()\n defer m.Unlock()\n\n\tif len(m.data) <= idToUpdate {\n\t\tfmt.Println(\"ID is out of range\")\n\t\treturn\n\t}\n m.data[idToUpdate] = data\n m.history.Append(\"UPDATE\", idToUpdate, data)\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 (m *metricRedisClientsMaxInputBuffer) updateCapacity() {\n\tif m.data.Gauge().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Gauge().DataPoints().Len()\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) 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 (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 (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 (b *Binding) Set(buf uint32) {\n\tgl.BindBufferBase(gl.SHADER_STORAGE_BUFFER, b.uint32, buf)\n}", "func (b *Buffer) Sync() {\n\tb.SetArea(b.Bounds())\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 (ob *OrderBook) BatchUpdate() {\n\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 (shp *SHPImpl) SetNewWithBuffer() (ret bool) {\n\tret = false\n\tfor i := 0; i < int(shp.tf.bufferSize); i++ {\n\t\tvertex := shp.tf.buffer[i]\n\t\tif shp.vertex2Target[vertex] != shp.vertex2Bucket[vertex] &&\n\t\t\trand.Float64() < shp.probability[shp.vertex2Bucket[vertex]][shp.vertex2Target[vertex]] {\n\t\t\tshp.vertex2Bucket[vertex] = shp.vertex2Target[vertex]\n\t\t\tret = true\n\t\t}\n\t}\n\treturn\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 (pool *FixedBytePool) Set(index int32, key []byte) error {\n\tif int(index) >= pool.maxElemNum {\n\t\treturn fmt.Errorf(\"index out of range %d %d\", index, pool.maxElemNum)\n\t}\n\n\tif len(key) != pool.elemSize {\n\t\treturn fmt.Errorf(\"length must be %d while %d\", pool.elemSize, len(key))\n\t}\n\tstart := int(index) * pool.elemSize\n\tcopy(pool.buf[start:], key)\n\n\treturn nil\n}", "func UpdateBatch(conf *Configuration, result interface{}) (chan interface{}, error) {\n\telemt := internal.VerifyStructPointer(result)\n\n\tsession, err := mgo.Dial(connectString(conf))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\t// query db\n\tc := session.DB(conf.Database).C(conf.Collection)\n\n\tch := make(chan interface{})\n\ts := reflect.MakeSlice(reflect.SliceOf(elemt), 0, 0)\n\n\tvar ticker *time.Ticker\n\tvar t <-chan time.Time\n\tif conf.UpdateStrategy.UseMinRecords && conf.UpdateStrategy.UseTimeInterval {\n\t\tticker, t = internal.NewTicker(conf.UpdateStrategy.MaxInterval)\n\t}\n\n\tgo func() {\n\t\tdefer session.Close()\n\t\tminr := int(conf.UpdateStrategy.MinRecords)\n\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase v := <-ch: // receiving stream\n\t\t\t\tif !conf.UpdateStrategy.UseMinRecords {\n\t\t\t\t\t//update as they arrive\n\t\t\t\t\tgo updateSingleRecord(conf, v, c)\n\t\t\t\t} else {\n\t\t\t\t\trv := reflect.ValueOf(v)\n\t\t\t\t\tif rv.Type() == elemt {\n\t\t\t\t\t\ts = reflect.Append(s, rv)\n\t\t\t\t\t}\n\n\t\t\t\t\tif s.Len() >= minr {\n\t\t\t\t\t\ts = updateAndClear(conf, s, c)\n\n\t\t\t\t\t\t// reset the timer\n\t\t\t\t\t\tif conf.UpdateStrategy.UseTimeInterval {\n\t\t\t\t\t\t\tif ticker != nil {\n\t\t\t\t\t\t\t\tticker.Stop()\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tticker, t = internal.NewTicker(conf.UpdateStrategy.MaxInterval)\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\tcase <-t: // the max interval to go without updating records. nil channel if disabled.\n\t\t\t\tif s.Len() > 0 {\n\t\t\t\t\ts = updateAndClear(conf, s, c)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}()\n\n\treturn ch, nil\n}", "func (m *metricMysqlBufferPoolDataPages) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\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 (s *PntSubset) Refresh() {\n\tL := len(s.index)\n\tif s.input == nil {\n\t\ts.input = make([]Point, L)\n\t}\n\tif s.output == nil {\n\t\ts.output = make([]Point, L)\n\t}\n\n\tfor i := 0; i < L; i++ {\n\t\ts.input[i] = *s.ds.Point(s.index[i])\n\t\tif s.index[i]+1 >= s.ds.NumPoints() {\n\t\t\tcontinue\n\t\t}\n\t\ts.output[i] = *s.ds.Point(s.index[i] + 1)\n\t}\n}", "func (r *Buffer) Put(item []byte) {\n\tatomic.StorePointer(&r.items[atomic.LoadUint32(&r.writeIndex)], unsafe.Pointer(&item))\n\tincrementIndex(&r.writeIndex, len(r.items)-1)\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 (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 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) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func (m *metricMysqlBufferPoolLimit) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[: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 TestReplicatedCmdBuf(t *testing.T) {\n\tdefer leaktest.AfterTest(t)()\n\tdefer log.Scope(t).Close(t)\n\tvar buf replicatedCmdBuf\n\t// numStates is chosen arbitrarily.\n\tconst numStates = 5*replicatedCmdBufNodeSize + 1\n\t// Test that the len field is properly updated.\n\tvar states []*replicatedCmd\n\tfor i := 0; i < numStates; i++ {\n\t\tassert.Equal(t, i, int(buf.len))\n\t\tstates = append(states, buf.allocate())\n\t\tassert.Equal(t, i+1, int(buf.len))\n\t}\n\t// Test the iterator.\n\tvar it replicatedCmdBufSlice\n\ti := 0\n\tfor it.init(&buf); it.Valid(); it.Next() {\n\t\tassert.Equal(t, states[i], it.cur())\n\t\ti++\n\t}\n\tassert.Equal(t, i, numStates) // make sure we saw them all\n\t// Test clear.\n\tbuf.clear()\n\tassert.EqualValues(t, buf, replicatedCmdBuf{})\n\tassert.Equal(t, 0, int(buf.len))\n\tit.init(&buf)\n\tassert.False(t, it.Valid())\n\t// Test clear on an empty buffer.\n\tbuf.clear()\n\tassert.EqualValues(t, buf, replicatedCmdBuf{})\n}", "func (q *Queue) Update(id int, data []byte) error {\n\tif _, ok := q.data[id]; !ok {\n\t\treturn fmt.Errorf(\"could not find any job with id : %d\", id)\n\t}\n\tq.lock.Lock()\n\tq.data[id] = data\n\tq.lock.Unlock()\n\treturn nil\n}", "func (r *Ring) set(p int, v interface{}) {\n\tr.buff[r.mod(p)] = v\n}", "func (m *metricActiveDirectoryDsReplicationSyncObjectPending) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\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 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 (m *metricRedisClientsMaxOutputBuffer) updateCapacity() {\n\tif m.data.Gauge().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Gauge().DataPoints().Len()\n\t}\n}", "func (m *metricAerospikeNodeQueryTracked) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (b *Backend) Update() (c context.Context, err error) {\n\tvar m Mutation\n\tfor {\n\t\terr = b.cursor.Next(c, &m)\n\t\tif err == scroll.Done {\n\t\t\tbreak\n\t\t} else if err != nil {\n\t\t\treturn\n\t\t}\n\t\tm.Update(b)\n\t}\n\treturn\n}", "func (b *Buffer) Overwrite(c byte) {\n\tb.mux.Lock()\n\tdefer b.mux.Unlock()\n\n\tif b.isFull() {\n\t\tb.data[b.tail] = c\n\t\tb.advance(&b.tail)\n\t} else {\n\t\tb.data[b.head] = c\n\t\tb.advance(&b.head)\n\t\tb.dataSize++\n\t}\n}", "func (w *Windowed) Set(data []StatusAndTime) {\n\tif w.data != nil {\n\t\tw.data = w.data[:0]\n\t}\n\n\tw.data = append(w.data, data...)\n\n\tw.head = 0\n\tw.length = len(data)\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 (m *metricRedisRdbChangesSinceLastSave) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (m *metricMysqlBufferPoolPages) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\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) SetBuffer(buf []byte) {\n\tsrc.buf = buf\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 (self *Ring) bulkDataSendToReplicas(maxRingPos int) {\n\n\tmin := self.KeyValTable.Min()\n\tkey := self.getKey()\n\n\t//Tree is empty\n\tif min.Equal(self.KeyValTable.Limit()) {\n\t\treturn\n\t}\n\tfor min != self.KeyValTable.Limit() {\n\t\titem := min.Item().(data.DataStore)\n if item.Key > maxRingPos {\n return\n }\n\t\tself.writeToReplicas(&item, key)\n\t\tfmt.Println(min.Item().(data.DataStore))\n\t\tmin = min.Next()\n\t}\n\n}", "func (m *metricAerospikeNamespaceGeojsonRegionQueryPoints) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (obj *Object) UpdateObjectInArray(query map[string]interface{}, data map[string]interface{}) *Object {\n\t// just allow update element,\n\t// so clear all another updates\n\tobj.changedData = map[string]interface{}{}\n\tobj.changedData[\"query\"] = query\n\tobj.changedData[\"data\"] = data\n\tobj.addtionalURL = \"/array\"\n\treturn obj\n}", "func GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetBufferSubData, 4, uintptr(target), uintptr(offset), uintptr(size), uintptr(data), 0, 0)\n}", "func (o MempoolBinSlice) UpdateAll(ctx context.Context, exec boil.ContextExecutor, cols M) (int64, error) {\n\tln := int64(len(o))\n\tif ln == 0 {\n\t\treturn 0, nil\n\t}\n\n\tif len(cols) == 0 {\n\t\treturn 0, errors.New(\"models: update all requires at least one column argument\")\n\t}\n\n\tcolNames := make([]string, len(cols))\n\targs := make([]interface{}, len(cols))\n\n\ti := 0\n\tfor name, value := range cols {\n\t\tcolNames[i] = name\n\t\targs[i] = value\n\t\ti++\n\t}\n\n\t// Append all of the primary key values for each column\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 := fmt.Sprintf(\"UPDATE \\\"mempool_bin\\\" SET %s WHERE %s\",\n\t\tstrmangle.SetParamNames(\"\\\"\", \"\\\"\", 1, colNames),\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), len(colNames)+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 update all in mempoolBin slice\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to retrieve rows affected all in update all mempoolBin\")\n\t}\n\treturn rowsAff, nil\n}", "func (m *metricAerospikeNamespaceGeojsonRegionQueryRequests) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (a *Adapter) Set(key uint64, response []byte, expiration time.Time) {\n\ta.mutex.Lock()\n\tdefer a.mutex.Unlock()\n\n\tif _, ok := a.store[key]; ok {\n\t\t// Known key, overwrite previous item.\n\t\ta.store[key] = response\n\t\treturn\n\t}\n\n\t// New key, make sure we have the capacity.\n\tif len(a.store) == a.capacity {\n\t\ta.evict()\n\t}\n\n\ta.store[key] = response\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (m *metricMysqlBufferPoolPageFlushes) updateCapacity() {\n\tif m.data.Sum().DataPoints().Len() > m.capacity {\n\t\tm.capacity = m.data.Sum().DataPoints().Len()\n\t}\n}", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\n}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func InvalidateBufferData(buffer uint32) {\n\tsyscall.Syscall(gpInvalidateBufferData, 1, uintptr(buffer), 0, 0)\n}", "func (s *SoBlockSummaryObjectWrap) update(sa *SoBlockSummaryObject) bool {\n\tif s.dba == nil || sa == nil {\n\t\treturn false\n\t}\n\tbuf, err := proto.Marshal(sa)\n\tif err != nil {\n\t\treturn false\n\t}\n\n\tkeyBuf, err := s.encodeMainKey()\n\tif err != nil {\n\t\treturn false\n\t}\n\n\treturn s.dba.Put(keyBuf, buf) == nil\n}", "func (q *dStarLiteQueue) update(n *dStarLiteNode, k key) {\n\tn.key = k\n\theap.Fix(q, n.idx)\n}" ]
[ "0.61363894", "0.55746704", "0.55625856", "0.55297506", "0.5502453", "0.54961836", "0.5488957", "0.5467326", "0.54561", "0.54425097", "0.5409052", "0.53852016", "0.5373626", "0.5347997", "0.52788514", "0.52782774", "0.52771676", "0.5224479", "0.5222405", "0.5214", "0.520048", "0.5199201", "0.51817966", "0.517158", "0.5167703", "0.5166961", "0.516684", "0.5166126", "0.5135386", "0.5135386", "0.511962", "0.511962", "0.511541", "0.50857985", "0.50715375", "0.5070971", "0.5049436", "0.5032609", "0.50234145", "0.50190246", "0.5016608", "0.5015994", "0.50095254", "0.5006581", "0.49956688", "0.4991704", "0.49916548", "0.4988015", "0.49711743", "0.49678716", "0.49603558", "0.49576092", "0.49425614", "0.49411565", "0.49390355", "0.49250546", "0.49138552", "0.49086416", "0.4907527", "0.48897776", "0.48887706", "0.48863414", "0.48806506", "0.48794508", "0.48788208", "0.48704213", "0.4864477", "0.4862227", "0.48589608", "0.48448914", "0.48433647", "0.4842126", "0.48396683", "0.48393658", "0.48373044", "0.48373044", "0.48361498", "0.48359257", "0.48338214", "0.4831853", "0.48286137", "0.48262328", "0.4821649", "0.48168844", "0.48165527", "0.4813864", "0.48085424", "0.48081595", "0.48064387", "0.47997677", "0.47991505", "0.4786803", "0.47862607", "0.47861463", "0.47858632", "0.4782091", "0.47806585", "0.47806087", "0.47779512", "0.47671637", "0.4765332" ]
0.0
-1
specify which color buffers are to be drawn into
func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) { C.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (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 (native *OpenGL) DrawBuffers(n int32, bufs *uint32) {\n\tgl.DrawBuffers(n, bufs)\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 (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 DrawBuffer(buf uint32) {\n\tC.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf))\n}", "func DrawBuffer(buf uint32) {\n\tC.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf))\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 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 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 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 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 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 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 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 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 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.602377", "0.59869295", "0.5963311", "0.59032893", "0.5872589", "0.58582133", "0.58195484", "0.58195484", "0.5760336", "0.5678843", "0.56414473", "0.56365794", "0.56333274", "0.56167203", "0.5505331", "0.5504353", "0.5503617", "0.54833513", "0.54690176", "0.54690176", "0.54485244", "0.5442503", "0.543667", "0.543667", "0.54332393", "0.5336414", "0.53266376", "0.53250617", "0.529253", "0.526499", "0.526499", "0.5262338", "0.5262338", "0.52345157", "0.5225247", "0.5225247", "0.5224412", "0.52127343", "0.51926416", "0.51891387", "0.5188898", "0.5183991", "0.5161954", "0.51605177", "0.51605177", "0.51576763", "0.51576763", "0.5144358", "0.51424253", "0.51337796", "0.50856096", "0.50856096", "0.5078143", "0.5074374", "0.5054759", "0.50541586", "0.5024699", "0.49997413", "0.49997413", "0.49861738", "0.49768394", "0.49753582", "0.497489", "0.4973631", "0.49682888", "0.49672937", "0.4956121", "0.49469003", "0.4941399", "0.49013847", "0.48984802", "0.48935694", "0.4884408", "0.48800683", "0.48765388", "0.48623532", "0.48538035", "0.48537353", "0.48487848", "0.48473385", "0.48467916", "0.48445573", "0.48445573", "0.48436555", "0.48432887", "0.4835281", "0.48217604", "0.48077396", "0.48012242", "0.47930917", "0.47895813", "0.47833574", "0.47832698", "0.4777621", "0.47757062", "0.4773911", "0.47687566", "0.47687566", "0.47552058", "0.47442776", "0.47406045" ]
0.0
-1
Specifies a list of color buffers to be drawn into
func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) { C.glowNamedFramebufferDrawBuffers(gpNamedFramebufferDrawBuffers, (C.GLuint)(framebuffer), (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 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 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 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.5949", "0.5949", "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.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.5488479
25
set a named parameter of a framebuffer object
func NamedFramebufferParameteri(framebuffer uint32, pname uint32, param int32) { C.glowNamedFramebufferParameteri(gpNamedFramebufferParameteri, (C.GLuint)(framebuffer), (C.GLenum)(pname), (C.GLint)(param)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func NamedFramebufferParameteri(framebuffer uint32, pname uint32, param int32) {\n\tsyscall.Syscall(gpNamedFramebufferParameteri, 3, uintptr(framebuffer), uintptr(pname), uintptr(param))\n}", "func (t Texture3D) SetParameter(paramName uint32, param int32) {\n\tt.Bind()\n\tgl.TexParameteri(gl.TEXTURE_3D, paramName, param)\n\tt.Unbind()\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n C.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tsyscall.Syscall(gpFramebufferParameteri, 3, uintptr(target), uintptr(pname), uintptr(param))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func (b *Binding) Set(buf uint32) {\n\tgl.BindBufferBase(gl.SHADER_STORAGE_BUFFER, b.uint32, buf)\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func (self *TileSprite) SetFrameNameA(member string) {\n self.Object.Set(\"frameName\", member)\n}", "func (self *Graphics) SetNameA(member string) {\n self.Object.Set(\"name\", member)\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 TexParameterf(target, pname Enum, param float32) {\n\tgl.TexParameterf(uint32(target), uint32(pname), param)\n}", "func (self *TileSprite) SetFrameA(member int) {\n self.Object.Set(\"frame\", member)\n}", "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tsyscall.Syscall12(gpBlitNamedFramebuffer, 12, uintptr(readFramebuffer), uintptr(drawFramebuffer), uintptr(srcX0), uintptr(srcY0), uintptr(srcX1), uintptr(srcY1), uintptr(dstX0), uintptr(dstY0), uintptr(dstX1), uintptr(dstY1), uintptr(mask), uintptr(filter))\n}", "func (native *OpenGL) TexParameterf(target uint32, pname uint32, param float32) {\n\tgl.TexParameterf(target, pname, param)\n}", "func TexParameterf(target, pname GLEnum, param float32) {\n\tgl.TexParameterf(uint32(target), uint32(pname), param)\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n C.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitNamedFramebuffer(gpBlitNamedFramebuffer, (C.GLuint)(readFramebuffer), (C.GLuint)(drawFramebuffer), (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 BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitNamedFramebuffer(gpBlitNamedFramebuffer, (C.GLuint)(readFramebuffer), (C.GLuint)(drawFramebuffer), (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 (j *Jsonnet) SetParam(path []string, value interface{}) error {\n\t// TODO: make this work at the env level too\n\tparamsData, err := j.readParams(\"\")\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tupdatedParams, err := params.SetInObject(path, paramsData, j.Name(false), value, paramsComponentRoot)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif err = j.writeParams(updatedParams); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (s *Shader) SetUniformBlock(name string, value interface{}, size int) {\n\t// check if the uniform buffer object already exists\n\tubo, ok := s.uniformBOs[name]\n\tif !ok {\n\t\t// if not, generate one\n\t\tgl.GenBuffers(1, &ubo)\n\t\ts.uniformBOs[name] = ubo\n\t}\n\n\tgl.BindBuffer(gl.UNIFORM_BUFFER, ubo)\n\n\t// set the new data\n\tgl.BufferData(gl.UNIFORM_BUFFER, size, nil, gl.DYNAMIC_DRAW)\n\tgl.BindBufferBase(gl.UNIFORM_BUFFER, s.getUniformBlockLocation(name), ubo)\n}", "func (self *Graphics) SetInCameraA(member bool) {\n self.Object.Set(\"inCamera\", member)\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 (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func (self *Tween) SetFrameBasedA(member bool) {\n self.Object.Set(\"frameBased\", member)\n}", "func (self *Graphics) SetYA(member int) {\n self.Object.Set(\"y\", member)\n}", "func (dev *Device) SetVideobuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_video_buffer(dev.ptr(), buf))\n}", "func (self *TileSprite) SetFrame(frame *Frame) {\n self.Object.Call(\"setFrame\", frame)\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffers, 3, uintptr(framebuffer), uintptr(n), uintptr(unsafe.Pointer(bufs)))\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpNamedFramebufferRenderbuffer, 4, uintptr(framebuffer), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (self *PhysicsP2) SetFrameRateA(member int) {\n self.Object.Set(\"frameRate\", member)\n}", "func (a *AdditionalGUTI) SetAMFPointer(aMFPointer uint8) {}", "func BindFramebuffer(target Enum, fb Framebuffer) {\n\tgl.BindFramebuffer(uint32(target), fb.Value)\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 NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tsyscall.Syscall(gpNamedFramebufferReadBuffer, 2, uintptr(framebuffer), uintptr(src), 0)\n}", "func (pix *Pixel) Set(keyName string, val int) Pixel {\n\tswitch keyName {\n\tcase \"R\":\n\t\tpix.R = val\n\tcase \"G\":\n\t\tpix.G = val\n\tcase \"B\":\n\t\tpix.B = val\n\tcase \"A\":\n\t\tpix.A = val\n\t}\n\treturn *pix\n}", "func (self *Graphics) SetFixedToCameraA(member bool) {\n self.Object.Set(\"fixedToCamera\", member)\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tsyscall.Syscall(gpBindFramebuffer, 2, uintptr(target), uintptr(framebuffer), 0)\n}", "func TexParameteri(target, pname Enum, param int) {\n\tgl.TexParameteri(uint32(target), uint32(pname), int32(param))\n}", "func (gl *WebGL) TexParameterf(target GLEnum, param GLEnum, value float64) {\n\tgl.context.Call(\"texParameterf\", target, param, value)\n}", "func (self *Graphics) SetXA(member int) {\n self.Object.Set(\"x\", member)\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\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 (self *Graphics) SetZA(member int) {\n self.Object.Set(\"z\", member)\n}", "func (frame *AvFrame) SetInfo(width int, height int, pixFmt int) (err error) {\n\tframe.width = C.int(width)\n\tframe.height = C.int(height)\n\tframe.format = C.int(pixFmt)\n\tif ret := C.av_frame_get_buffer((*C.struct_AVFrame)(unsafe.Pointer(frame)), 32 /*alignment*/); ret < 0 {\n\t\terr = fmt.Errorf(\"Error allocating avframe buffer. Err: %v\", ret)\n\t\treturn\n\t}\n\treturn\n}", "func setIntensity(intensity, device int, name string) {\n\trequest := RpcRequest{(fmt.Sprintf(\"{\\\"command\\\":\\\"gpuintensity\\\",\\\"parameter\\\":\\\"%v,%v\\\"}\", device, intensity)), make(chan []byte), name}\n\trequest.Send()\n}", "func TexParameterfv(target, pname Enum, params []float32) {\n\tgl.TexParameterfv(uint32(target), uint32(pname), &params[0])\n}", "func (self *Rectangle) SetYA(member int) {\n self.Object.Set(\"y\", member)\n}", "func (self *Graphics) SetInputA(member interface{}) {\n self.Object.Set(\"input\", member)\n}", "func (self *TileSprite) SetNameA(member string) {\n self.Object.Set(\"name\", member)\n}", "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func (self *Graphics) SetDebugA(member bool) {\n self.Object.Set(\"debug\", member)\n}", "func (input *BeegoInput) SetParam(key, val string) {\n\t// check if already exists\n\tfor i, v := range input.pnames {\n\t\tif v == key && i <= len(input.pvalues) {\n\t\t\tinput.pvalues[i] = val\n\t\t\treturn\n\t\t}\n\t}\n\tinput.pvalues = append(input.pvalues, val)\n\tinput.pnames = append(input.pnames, key)\n}", "func BindAttribLocation(program uint32, index uint32, name *int8) {\n C.glowBindAttribLocation(gpBindAttribLocation, (C.GLuint)(program), (C.GLuint)(index), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\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 TexParameteri(target, pname GLEnum, param int32) {\n\tgl.TexParameteri(uint32(target), uint32(pname), param)\n}", "func (self *Graphics) SetDataA(member interface{}) {\n self.Object.Set(\"data\", member)\n}", "func setGPUMemory(clock, device int, name string) {\n\trequest := RpcRequest{(fmt.Sprintf(\"{\\\"command\\\":\\\"gpumem\\\",\\\"parameter\\\":\\\"%v,%v\\\"}\", device, clock)), make(chan []byte), name}\n\trequest.Send()\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func Set(name, value string) bool {\n\tf, ok := flags.formal[name];\n\tif !ok {\n\t\treturn false\n\t}\n\tok = f.Value.set(value);\n\tif !ok {\n\t\treturn false\n\t}\n\tflags.actual[name] = f;\n\treturn true;\n}", "func BindFramebuffer(target Enum, framebuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcframebuffer, _ := (C.GLuint)(framebuffer), cgoAllocsUnknown\n\tC.glBindFramebuffer(ctarget, cframebuffer)\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 BindBuffer(target Enum, b Buffer) {\n\tgl.BindBuffer(uint32(target), b.Value)\n}", "func (m *Win32LobAppRegistryDetection) SetValueName(value *string)() {\n err := m.GetBackingStore().Set(\"valueName\", value)\n if err != nil {\n panic(err)\n }\n}", "func (debugging *debuggingOpenGL) BindFramebuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindFramebuffer\", target, buffer)\n\tdebugging.gl.BindFramebuffer(target, buffer)\n\tdebugging.recordExit(\"BindFramebuffer\")\n}", "func (self *Graphics) SetBlendModeA(member int) {\n self.Object.Set(\"blendMode\", member)\n}", "func (skeleton *Skeleton) SetSmoothingFactor(value float32) {\n\n\tC.setObjParamFloat((C.gpointer)(skeleton.skeleton), C.CString(\"smoothing-factor\"), C.float(value))\n}", "func (self *Graphics) SetTypeA(member int) {\n self.Object.Set(\"type\", member)\n}", "func (native *OpenGL) TexParameteri(target uint32, pname uint32, param int32) {\n\tgl.TexParameteri(target, pname, param)\n}", "func SetPixelFormat(hdc unsafe.Pointer, ipfd unsafe.Pointer, ppfd unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpSetPixelFormat, 3, uintptr(hdc), uintptr(ipfd), uintptr(ppfd))\n\treturn (unsafe.Pointer)(ret)\n}", "func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tsyscall.Syscall6(gpNamedFramebufferTextureLayer, 5, uintptr(framebuffer), uintptr(attachment), uintptr(texture), uintptr(level), uintptr(layer), 0)\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 NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (d *ModeDiff) setArg(mode rune, arg string) {\n\td.pos.setArg(mode, arg)\n\td.neg.unsetArg(mode, arg)\n}", "func (self *Graphics) SetKeyA(member interface{}) {\n self.Object.Set(\"key\", member)\n}", "func GetNamedFramebufferParameteriv(framebuffer uint32, pname uint32, param *int32) {\n\tsyscall.Syscall(gpGetNamedFramebufferParameteriv, 3, uintptr(framebuffer), uintptr(pname), uintptr(unsafe.Pointer(param)))\n}", "func SetParam(params ParamT, pname string, value string) int32 {\n\tcpname := C.CString(pname)\n\tdefer C.free(unsafe.Pointer(cpname))\n\tcvalue := C.CString(value)\n\tdefer C.free(unsafe.Pointer(cvalue))\n\treturn int32(C.yices_set_param(yparam(params), cpname, cvalue))\n}", "func InvalidateNamedFramebufferData(framebuffer uint32, numAttachments int32, attachments *uint32) {\n\tsyscall.Syscall(gpInvalidateNamedFramebufferData, 3, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)))\n}", "func (self *TileSprite) SetTextureDebugA(member bool) {\n self.Object.Set(\"textureDebug\", member)\n}", "func (m *ChatMessageAttachment) SetName(value *string)() {\n err := m.GetBackingStore().Set(\"name\", value)\n if err != nil {\n panic(err)\n }\n}", "func (self *Graphics) SetFreshA(member bool) {\n self.Object.Set(\"fresh\", member)\n}", "func (self *Graphics) SetGameA(member *Game) {\n self.Object.Set(\"game\", member)\n}", "func InvalidateNamedFramebufferSubData(framebuffer uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpInvalidateNamedFramebufferSubData, 7, uintptr(framebuffer), uintptr(numAttachments), uintptr(unsafe.Pointer(attachments)), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0, 0)\n}", "func (native *OpenGL) BindFramebuffer(target, buffer uint32) {\n\tgl.BindFramebuffer(target, buffer)\n}", "func (f v4l2Format) setPixFormat(newPix PixFormat) {\n\t*(*PixFormat)(unsafe.Pointer(&f.fmt[0])) = newPix\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 BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (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 (self *Graphics) SetHeightA(member int) {\n self.Object.Set(\"height\", member)\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "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 (self *Graphics) SetWorldA(member *Point) {\n self.Object.Set(\"world\", member)\n}" ]
[ "0.6607994", "0.6322477", "0.62866694", "0.62609506", "0.61261916", "0.59485966", "0.5854527", "0.5854527", "0.5809548", "0.5750729", "0.572978", "0.572978", "0.5721515", "0.5720505", "0.5703115", "0.5621067", "0.56060416", "0.5551461", "0.5527168", "0.5496869", "0.5496869", "0.54811317", "0.547598", "0.546166", "0.54603404", "0.54412824", "0.5418363", "0.5391593", "0.53708446", "0.5342425", "0.5333473", "0.53135544", "0.5311344", "0.5297348", "0.5295057", "0.5291401", "0.52738607", "0.52705973", "0.5257424", "0.52375525", "0.5234736", "0.5232614", "0.5214384", "0.5205178", "0.5198552", "0.5186266", "0.51813686", "0.51521504", "0.5152146", "0.51508725", "0.5150243", "0.51493067", "0.5146511", "0.5146204", "0.51419365", "0.5122745", "0.512253", "0.512253", "0.51206976", "0.51206976", "0.5118593", "0.51156694", "0.5106945", "0.51049304", "0.50984865", "0.50951785", "0.50926363", "0.50808597", "0.5061589", "0.5059382", "0.5051542", "0.5038162", "0.5035023", "0.50329655", "0.5030838", "0.5022363", "0.50206465", "0.50167793", "0.50167793", "0.5014382", "0.50126505", "0.50122565", "0.49971685", "0.4991168", "0.49885914", "0.49881136", "0.4985098", "0.498243", "0.49788126", "0.49738222", "0.49679643", "0.4965953", "0.4956131", "0.49530244", "0.49467474", "0.49388036", "0.49388036", "0.49371445", "0.49369758" ]
0.6318116
3
select a color buffer source for pixels
func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) { C.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func SelectBuffer(size int32, buffer *uint32) {\n C.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func SelectBuffer(size int32, buffer *uint32) {\n\tC.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func ReadBuffer(src uint32) {\n\tC.glowReadBuffer(gpReadBuffer, (C.GLenum)(src))\n}", "func ReadBuffer(src uint32) {\n\tC.glowReadBuffer(gpReadBuffer, (C.GLenum)(src))\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 (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 (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 (fb FrameBuffer) ColorAt(x int, y int) color.Color {\n\tc := fb.img.At(x, y)\n\treturn c\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 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 (s *Surface) Blit(source *Surface, x, y float64) {\n\ts.Ctx.Call(\"drawImage\", source.Canvas, math.Floor(x), math.Floor(y))\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 (self *TileSprite) CanvasBuffer() *PIXICanvasBuffer{\n return &PIXICanvasBuffer{self.Object.Get(\"canvasBuffer\")}\n}", "func SelectBuffer(size int32, buffer *uint32) {\n\tsyscall.Syscall(gpSelectBuffer, 2, uintptr(size), uintptr(unsafe.Pointer(buffer)), 0)\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 ReadBuffer(mode uint32) {\n C.glowReadBuffer(gpReadBuffer, (C.GLenum)(mode))\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(src uint32) {\n\tsyscall.Syscall(gpReadBuffer, 1, uintptr(src), 0, 0)\n}", "func BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\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 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 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 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 ReadPixels(x int32, y int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowReadPixels(gpReadPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\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 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 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 BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\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 qr_decoder_get_image_buffer(p _QrDecoderHandle) *_IplImage {\n\tv := C.qr_decoder_get_image_buffer(C.QrDecoderHandle(p))\n\treturn (*_IplImage)(v)\n}", "func ChoosePixelFormat(hDc unsafe.Pointer, pPfd unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpChoosePixelFormat, 2, uintptr(hDc), uintptr(pPfd), 0)\n\treturn (unsafe.Pointer)(ret)\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 (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\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 BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func (c ColorOrder) RawPixel(r, g, b byte) Pixel {\n\tswitch c {\n\tcase RGB:\n\t\treturn Pixel{[8]byte{\n\t\t\tzero &^ (r>>7&1 | r>>3&8 | r<<1&0x40),\n\t\t\tzero &^ (r>>4&1 | r>>0&8 | r<<4&0x40),\n\t\t\tzero &^ (r>>1&1 | r<<3&8 | g>>1&0x40),\n\t\t\tzero &^ (g>>6&1 | g>>2&8 | g<<2&0x40),\n\t\t\tzero &^ (g>>3&1 | g<<1&8 | g<<5&0x40),\n\t\t\tzero &^ (g>>0&1 | b>>4&8 | b>>0&0x40),\n\t\t\tzero &^ (b>>5&1 | b>>1&8 | b<<3&0x40),\n\t\t\tzero &^ (b>>2&1 | b<<2&8 | b<<6&0x40),\n\t\t}}\n\tcase GRB:\n\t\treturn Pixel{[8]byte{\n\t\t\tzero &^ (g>>7&1 | g>>3&8 | g<<1&0x40),\n\t\t\tzero &^ (g>>4&1 | g>>0&8 | g<<4&0x40),\n\t\t\tzero &^ (g>>1&1 | g<<3&8 | r>>1&0x40),\n\t\t\tzero &^ (r>>6&1 | r>>2&8 | r<<2&0x40),\n\t\t\tzero &^ (r>>3&1 | r<<1&8 | r<<5&0x40),\n\t\t\tzero &^ (r>>0&1 | b>>4&8 | b>>0&0x40),\n\t\t\tzero &^ (b>>5&1 | b>>1&8 | b<<3&0x40),\n\t\t\tzero &^ (b>>2&1 | b<<2&8 | b<<6&0x40),\n\t\t}}\n\t}\n\treturn Pixel{}\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tsyscall.Syscall(gpNamedFramebufferReadBuffer, 2, uintptr(framebuffer), uintptr(src), 0)\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 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 GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n C.glowGetBufferSubData(gpGetBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\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 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 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 (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 pickColor(pixel byte) (byte, byte, byte, byte) {\n\tif pixel == 1 {\n\t\tr, g, b, a = 200, 190, 133, 255\n\t} else if pixel == 2 {\n\t\tr, g, b, a = 6, 67, 200, 255\n\t} else if pixel == 3 {\n\t\tr, g, b, a = 2, 46, 46, 255\n\t} else if pixel == 4 {\n\t\tr, g, b, a = 80, 80, 80, 255\n\t} else {\n\t\ta = 0\n\t}\n\treturn r, g, b, a\n}", "func PngGetColorAt(filename string, x int, y int) color.RGBA {\n\n\tfile, err := os.Open(filename)\n\n\tif err != nil {\n\t\tfmt.Println(\"Error: File could not be opened.\")\n\t\tos.Exit(1)\n\t}\n\tdefer file.Close()\n\n\timg, _, err := image.Decode(file)\n\n\tr, g, b, a := img.At(x, y).RGBA()\n\ttopleftColor := Pixel{uint8(r / 257), uint8(g / 257), uint8(b / 257), uint8(a / 257)}\n\n\treturn color.RGBA{topleftColor.R, topleftColor.G, topleftColor.B, topleftColor.A}\n\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 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 (shader Shader) Source(source string) {\n\tcstrs, free := gl.Strs(source + \"\\x00\")\n\tgl.ShaderSource(uint32(shader), 1, cstrs, nil)\n\tfree()\n}", "func (native *OpenGL) GLShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tgl.ShaderSource(shader, count, xstring, length)\n}", "func ReadPixels(x int32, y int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowReadPixels(gpReadPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func ReadPixels(x int32, y int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowReadPixels(gpReadPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureBufferRange(texture uint32, internalformat uint32, buffer uint32, offset int, size int) {\n\tsyscall.Syscall6(gpTextureBufferRange, 5, uintptr(texture), uintptr(internalformat), uintptr(buffer), uintptr(offset), uintptr(size), 0)\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 GetShaderSource(shader uint32, bufSize int32, length *int32, source *uint8) {\n\tC.glowGetShaderSource(gpGetShaderSource, (C.GLuint)(shader), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(source)))\n}", "func GetShaderSource(shader uint32, bufSize int32, length *int32, source *uint8) {\n\tC.glowGetShaderSource(gpGetShaderSource, (C.GLuint)(shader), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(source)))\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 ReadPixels(x Int, y Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\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\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glReadPixels(cx, cy, cwidth, cheight, cformat, ckind, cpixels)\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 TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n C.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func BindBufferRange(target uint32, index uint32, buffer uint32, offset int, size int) {\n\tC.glowBindBufferRange(gpBindBufferRange, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func BindBufferRange(target uint32, index uint32, buffer uint32, offset int, size int) {\n\tC.glowBindBufferRange(gpBindBufferRange, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\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 BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\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 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 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 GetShaderSource(shader uint32, bufSize int32, length *int32, source *uint8) {\n\tsyscall.Syscall6(gpGetShaderSource, 4, uintptr(shader), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(source)), 0, 0)\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 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 Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(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 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 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 ReadPixels(x int32, y int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpReadPixels, 7, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func ReadPixels(x int, y int, width int, height int, format, typ GLenum, pixels interface{}) {\n\tC.glReadPixels(C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height),\n\t\tC.GLenum(format), C.GLenum(typ), ptr(pixels))\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 BindBuffer(target Enum, buffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\tC.glBindBuffer(ctarget, cbuffer)\n}", "func (debugging *debuggingOpenGL) ReadPixels(x int32, y int32, width int32, height int32, format uint32, pixelType uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"ReadPixels\", x, y, width, height, format, pixelType, pixels)\n\tdebugging.gl.ReadPixels(x, y, width, height, format, pixelType, pixels)\n\tdebugging.recordExit(\"ReadPixels\")\n}", "func (src *Source) SetNewBuffer() {\n\tsrc.buf = make([]byte, 64)\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\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 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 (this *osmSourceStruct) Get(zoom uint8, x uint32, y uint32, colorScale float64) (Tile, error) {\n\n\t/*\n\t * Check if zoom level is in range.\n\t */\n\tif zoom > MAX_ZOOM_LEVEL {\n\t\terr := fmt.Errorf(\"Zoom level %d not allowed. (Maximum: %d)\", zoom, MAX_ZOOM_LEVEL)\n\t\treturn nil, err\n\t} else {\n\t\ttilesPerAxis := uint32(1) << zoom\n\t\tmaxTileId := tilesPerAxis - 1\n\n\t\t/*\n\t\t * Check if tile IDs are in range.\n\t\t */\n\t\tif (x > maxTileId) || (y > maxTileId) {\n\t\t\tmsg := \"Cannot fetch tile (%d, %d). Maximum tile ID is (%d, %d) at zoom level %d.\"\n\t\t\terr := fmt.Errorf(msg, x, y, maxTileId, maxTileId, zoom)\n\t\t\treturn nil, err\n\t\t} else {\n\n\t\t\t/*\n\t\t\t * Make sure that color scale is in range.\n\t\t\t */\n\t\t\tif colorScale < 0.0 {\n\t\t\t\tcolorScale = 0.0\n\t\t\t} else if colorScale > 1.0 {\n\t\t\t\tcolorScale = 1.0\n\t\t\t}\n\n\t\t\t/*\n\t\t\t * Create OSM tile id.\n\t\t\t */\n\t\t\ttileId := osmTileIdStruct{\n\t\t\t\tzoom: zoom,\n\t\t\t\tx: x,\n\t\t\t\ty: y,\n\t\t\t}\n\n\t\t\ttileSource := this.getTile(tileId)\n\t\t\timgSource := tileSource.imageData\n\t\t\trect := imgSource.Bounds()\n\t\t\timgTarget := image.NewNRGBA(rect)\n\t\t\trectMin := rect.Min\n\t\t\tminX := rectMin.X\n\t\t\tminY := rectMin.Y\n\t\t\trectMax := rect.Max\n\t\t\tmaxX := rectMax.X\n\t\t\tmaxY := rectMax.Y\n\n\t\t\t/*\n\t\t\t * Read image line by line.\n\t\t\t */\n\t\t\tfor y := minY; y < maxY; y++ {\n\n\t\t\t\t/*\n\t\t\t\t * Read line pixel by pixel.\n\t\t\t\t */\n\t\t\t\tfor x := minX; x < maxX; x++ {\n\t\t\t\t\tsourceColor := imgSource.NRGBAAt(x, y)\n\t\t\t\t\ttargetColor := this.transformColor(sourceColor, colorScale)\n\t\t\t\t\timgTarget.Set(x, y, targetColor)\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\t/*\n\t\t\t * Create OSM tile.\n\t\t\t */\n\t\t\ttileTarget := osmTileStruct{\n\t\t\t\timageData: imgTarget,\n\t\t\t\ttileId: tileId,\n\t\t\t}\n\n\t\t\treturn &tileTarget, nil\n\t\t}\n\n\t}\n\n}", "func NewBuffer(ssrc uint32, vp, ap *sync.Pool) *Buffer {\n\tb := &Buffer{\n\t\tmediaSSRC: ssrc,\n\t\tvideoPool: vp,\n\t\taudioPool: ap,\n\t\tpacketChan: make(chan rtp.Packet, 100),\n\t}\n\treturn b\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\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 BindBuffer(target Enum, b Buffer) {\n\tgl.BindBuffer(uint32(target), b.Value)\n}", "func (native *OpenGL) ReadPixels(x int32, y int32, width int32, height int32, format uint32, pixelType uint32, pixels interface{}) {\n\tgl.ReadPixels(x, y, width, height, format, pixelType, gl.Ptr(pixels))\n}", "func TextureBufferRange(texture uint32, internalformat uint32, buffer uint32, offset int, size int) {\n\tC.glowTextureBufferRange(gpTextureBufferRange, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}" ]
[ "0.6068057", "0.5763617", "0.57270753", "0.57270753", "0.5656174", "0.54879344", "0.5338901", "0.5296984", "0.52896583", "0.52872366", "0.5283478", "0.52303445", "0.52246875", "0.52222335", "0.5191319", "0.51414114", "0.5134801", "0.5116785", "0.5074263", "0.5053044", "0.49916804", "0.49902368", "0.49791902", "0.49783012", "0.49714872", "0.49659348", "0.49425328", "0.49251553", "0.49143577", "0.4874199", "0.482434", "0.48234937", "0.48167092", "0.47946596", "0.47842413", "0.478047", "0.478047", "0.4768782", "0.4768782", "0.47640654", "0.4752222", "0.47407967", "0.4726506", "0.47253284", "0.47248763", "0.47202206", "0.4709919", "0.47044408", "0.47032258", "0.47025335", "0.46965027", "0.4688267", "0.4688267", "0.46862593", "0.46851352", "0.46836537", "0.46836537", "0.4683171", "0.46670276", "0.46665615", "0.46665615", "0.46652573", "0.46607718", "0.46603796", "0.4657774", "0.4657765", "0.4657765", "0.46511886", "0.46511886", "0.46381307", "0.46369687", "0.46355128", "0.46269202", "0.46144152", "0.4611874", "0.4611874", "0.4593489", "0.45929745", "0.4586033", "0.45848656", "0.4580164", "0.4577715", "0.4553614", "0.45523906", "0.45456892", "0.45396423", "0.4535403", "0.4535333", "0.4535333", "0.45330465", "0.45330465", "0.45267245", "0.4523179", "0.45115706", "0.45093516", "0.45026052", "0.4498568", "0.44971344", "0.4493509" ]
0.4893914
30
attach a renderbuffer as a logical buffer of a framebuffer object
func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) { C.glowNamedFramebufferRenderbuffer(gpNamedFramebufferRenderbuffer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\n\t)\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (native *OpenGL) FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tgl.FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer)\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (debugging *debuggingOpenGL) FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tdebugging.recordEntry(\"FramebufferRenderbuffer\", target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.gl.FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.recordExit(\"FramebufferRenderbuffer\")\n}", "func FramebufferRenderbuffer(target, attachment, rbTarget Enum, rb Renderbuffer) {\n\tgl.FramebufferRenderbuffer(uint32(target), uint32(attachment), uint32(rbTarget), rb.Value)\n}", "func (native *OpenGL) BindFramebuffer(target, buffer uint32) {\n\tgl.BindFramebuffer(target, buffer)\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func FramebufferRenderbuffer(target Enum, attachment Enum, renderbuffertarget Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tcrenderbuffertarget, _ := (C.GLenum)(renderbuffertarget), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glFramebufferRenderbuffer(ctarget, cattachment, crenderbuffertarget, crenderbuffer)\n}", "func (debugging *debuggingOpenGL) BindFramebuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindFramebuffer\", target, buffer)\n\tdebugging.gl.BindFramebuffer(target, buffer)\n\tdebugging.recordExit(\"BindFramebuffer\")\n}", "func FrameBuffer(m rv.RenderModel) {\n\tframebuffer(m)\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 (w *windowImpl) bindBackBuffer() {\n\t// w.mu.Lock()\n\t// size := w.Sz\n\t// w.mu.Unlock()\n\t//\n\tw.backBufferBound = true\n\t// gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t// gl.Viewport(0, 0, int32(size.X), int32(size.Y))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func initFramebuffer(width, height int) {\n\tlog.Printf(\"[Video]: Initializing HW render (%v x %v).\\n\", width, height)\n\n\tgl.GenFramebuffers(1, &fboID)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, fboID)\n\n\t//gl.GenTextures(1, &video.texID)\n\tgl.BindTexture(gl.TEXTURE_2D, texID)\n\tgl.TexStorage2D(gl.TEXTURE_2D, 1, gl.RGBA8, int32(width), int32(height))\n\n\tgl.FramebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texID, 0)\n\n\thw := state.Global.Core.HWRenderCallback\n\n\tgl.BindRenderbuffer(gl.RENDERBUFFER, 0)\n\n\tif gl.CheckFramebufferStatus(gl.FRAMEBUFFER) != gl.FRAMEBUFFER_COMPLETE {\n\t\tlog.Fatalln(\"[Video] Framebuffer is not complete.\")\n\t}\n\n\tgl.ClearColor(0, 0, 0, 1)\n\tif hw.Depth && hw.Stencil {\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT)\n\t} else if hw.Depth {\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t} else {\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT)\n\t}\n\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n C.glowBindRenderbuffer(gpBindRenderbuffer, (C.GLenum)(target), (C.GLuint)(renderbuffer))\n}", "func NewAttachedBuffer(buffer *Buffer) *Buffer {\n result := NewEmptyBuffer()\n result.AttachBuffer(buffer)\n return result\n}", "func (debugging *debuggingOpenGL) BindBuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindBuffer\", target, buffer)\n\tdebugging.gl.BindBuffer(target, buffer)\n\tdebugging.recordExit(\"BindBuffer\")\n}", "func (native *OpenGL) BindBuffer(target uint32, buffer uint32) {\n\tgl.BindBuffer(target, buffer)\n}", "func BindBuffer(target Enum, b Buffer) {\n\tgl.BindBuffer(uint32(target), b.Value)\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tsyscall.Syscall(gpBindRenderbuffer, 2, uintptr(target), uintptr(renderbuffer), 0)\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n C.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func (gl *WebGL) BindBuffer(target GLEnum, buffer WebGLBuffer) {\n\tgl.context.Call(\"bindBuffer\", target, buffer)\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func (debugging *debuggingOpenGL) BindRenderbuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindRenderbuffer\", target, buffer)\n\tdebugging.gl.BindRenderbuffer(target, buffer)\n\tdebugging.recordExit(\"BindRenderbuffer\")\n}", "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 BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func (native *OpenGL) BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tgl.BindRenderbuffer(target, renderbuffer)\n}", "func BindRenderbuffer(target GLEnum, renderbuffer Renderbuffer) {\n\tgl.BindRenderbuffer(uint32(target), uint32(renderbuffer))\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tsyscall.Syscall(gpBindFramebuffer, 2, uintptr(target), uintptr(framebuffer), 0)\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(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 BindFramebuffer(target Enum, framebuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcframebuffer, _ := (C.GLuint)(framebuffer), cgoAllocsUnknown\n\tC.glBindFramebuffer(ctarget, cframebuffer)\n}", "func (debugging *debuggingOpenGL) FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n\tdebugging.recordEntry(\"FramebufferTexture\", target, attachment, texture, level)\n\tdebugging.gl.FramebufferTexture(target, attachment, texture, level)\n\tdebugging.recordExit(\"FramebufferTexture\")\n}", "func BindFramebuffer(target Enum, fb Framebuffer) {\n\tgl.BindFramebuffer(uint32(target), fb.Value)\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func BindRenderbuffer(target Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glBindRenderbuffer(ctarget, crenderbuffer)\n}", "func BindRenderbuffer(target Enum, rb Renderbuffer) {\n\tgl.BindRenderbuffer(uint32(target), rb.Value)\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBuffer, 2, uintptr(target), uintptr(buffer), 0)\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tC.glowBindRenderbuffer(gpBindRenderbuffer, (C.GLenum)(target), (C.GLuint)(renderbuffer))\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tC.glowBindRenderbuffer(gpBindRenderbuffer, (C.GLenum)(target), (C.GLuint)(renderbuffer))\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 (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 DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tC.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tC.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\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 DrawBuffer(buf uint32) {\n\tsyscall.Syscall(gpDrawBuffer, 1, uintptr(buf), 0, 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 NewAttached(buffer []byte) *Buffer {\n result := NewEmptyBuffer()\n result.Attach(buffer)\n return result\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func (du *DescriptorSet) AddBuffer(dstBinding int, dtype vk.DescriptorType, b *Buffer, offset int) {\n\tvar descriptorBufferInfo = vk.DescriptorBufferInfo{}\n\tdescriptorBufferInfo.Buffer = b.VKBuffer\n\tdescriptorBufferInfo.Offset = vk.DeviceSize(offset)\n\tdescriptorBufferInfo.Range = vk.DeviceSize(b.Size)\n\n\tvar writeDescriptorSet = vk.WriteDescriptorSet{}\n\twriteDescriptorSet.SType = vk.StructureTypeWriteDescriptorSet\n\twriteDescriptorSet.DstBinding = uint32(dstBinding) // write to the first, and only binding.\n\twriteDescriptorSet.DescriptorCount = 1 // update a single descriptor.\n\twriteDescriptorSet.DescriptorType = dtype\n\twriteDescriptorSet.PBufferInfo = []vk.DescriptorBufferInfo{descriptorBufferInfo}\n\n\tif du.VKWriteDiscriptorSet == nil {\n\t\tdu.VKWriteDiscriptorSet = make([]vk.WriteDescriptorSet, 0)\n\t}\n\tdu.VKWriteDiscriptorSet = append(du.VKWriteDiscriptorSet, writeDescriptorSet)\n}", "func NamedFramebufferRenderbuffer(framebuffer uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpNamedFramebufferRenderbuffer, 4, uintptr(framebuffer), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (dev *Device) SetVideobuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_video_buffer(dev.ptr(), buf))\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tsyscall.Syscall(gpTextureBuffer, 3, uintptr(texture), uintptr(internalformat), uintptr(buffer))\n}", "func (buffer Buffer) Bind(target gl.Enum) {\n\tgl.BindBuffer(gl.Enum(target), gl.Uint(buffer))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tsyscall.Syscall(gpNamedFramebufferReadBuffer, 2, uintptr(framebuffer), uintptr(src), 0)\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffers, 3, uintptr(framebuffer), uintptr(n), uintptr(unsafe.Pointer(bufs)))\n}", "func (buffer Buffer) BindBufferBase(target gl.Enum, index uint) {\n\tgl.BindBufferBase(gl.Enum(target), gl.Uint(index), gl.Uint(buffer))\n}", "func Framebuffer() *framebuffer.Device {\n\treturn fb\n}", "func newScreenFramebuffer(context *context, width, height int) *framebuffer {\n\treturn &framebuffer{\n\t\tnative: context.getScreenFramebuffer(),\n\t\twidth: width,\n\t\theight: height,\n\t}\n}", "func BindBuffer(target Enum, buffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcbuffer, _ := (C.GLuint)(buffer), cgoAllocsUnknown\n\tC.glBindBuffer(ctarget, cbuffer)\n}", "func NewFramebuffer(w, h int) *Framebuffer {\n\treturn &Framebuffer{\n\t\tfb: image.NewRGBA(image.Rectangle{image.Point{0, 0}, image.Point{w, h}}),\n\t}\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 (native *OpenGL) FramebufferTexture2D(target uint32, attachment uint32, textarget uint32, texture uint32, level int32) {\n\tgl.FramebufferTexture2D(target, attachment, textarget, texture, level)\n}", "func newFramebufferFromTexture(context *context, texture textureNative, width, height int) (*framebuffer, error) {\n\tnative, err := context.newFramebuffer(texture)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &framebuffer{\n\t\tnative: native,\n\t\twidth: width,\n\t\theight: height,\n\t}, nil\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 (g *GBufferPipeline) Render(graph SceneNode) {\n\tgl.Enable(gl.DEPTH_TEST)\n\tgl.DepthMask(true)\n\n\tgl.Enable(gl.CULL_FACE)\n\tgl.CullFace(gl.BACK)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, g.buffer.fbo)\n\tvar attachments = [2]uint32{gl.COLOR_ATTACHMENT0, gl.COLOR_ATTACHMENT1}\n\tgl.DrawBuffers(int32(len(attachments)), &attachments[0])\n\tgl.Clear(gl.DEPTH_BUFFER_BIT | gl.COLOR_BUFFER_BIT)\n\tgraph.Render(g.tShader, g.mShader)\n\n\tgl.UseProgram(0)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n\tC.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n\tC.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func BlitContextFramebufferAMD(dstCtx unsafe.Pointer, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall12(gpBlitContextFramebufferAMD, 11, uintptr(dstCtx), uintptr(srcX0), uintptr(srcY0), uintptr(srcX1), uintptr(srcY1), uintptr(dstX0), uintptr(dstY0), uintptr(dstX1), uintptr(dstY1), uintptr(mask), uintptr(filter), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tsyscall.Syscall12(gpBlitNamedFramebuffer, 12, uintptr(readFramebuffer), uintptr(drawFramebuffer), uintptr(srcX0), uintptr(srcY0), uintptr(srcX1), uintptr(srcY1), uintptr(dstX0), uintptr(dstY0), uintptr(dstX1), uintptr(dstY1), uintptr(mask), uintptr(filter))\n}", "func createFB(tex wasm.WebGLTexture) wasm.WebGLFramebuffer {\n\tfb := gl.CreateFramebuffer()\n\tgl.BindFramebuffer(wasm.FRAMEBUFFER, fb)\n\tgl.FramebufferTexture2D(wasm.FRAMEBUFFER, wasm.COLOR_ATTACHMENT0, wasm.TEXTURE_2D, tex, 0)\n\treturn fb\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 FramebufferTextureLayer(target uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tsyscall.Syscall6(gpFramebufferTextureLayer, 5, uintptr(target), uintptr(attachment), uintptr(texture), uintptr(level), uintptr(layer), 0)\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 BindVertexBuffer(bindingindex uint32, buffer uint32, offset int, stride int32) {\n C.glowBindVertexBuffer(gpBindVertexBuffer, (C.GLuint)(bindingindex), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizei)(stride))\n}", "func (n *BufferView) AddBuffer() *Buffer {\n\tn.UnfocusBuffers()\n\n\tconf := n.conf\n\tc := NewBuffer(conf, BufferConfig{\n\t\tconf.Theme.Background,\n\t\tconf.Theme.Foreground,\n\t\tconf.Theme.Cursor,\n\t\tconf.Theme.CursorInvert,\n\t\tconf.Theme.HighlightLineBackground,\n\t\tconf.Theme.GutterBackground,\n\t\tconf.Theme.GutterForeground,\n\t\tgui.GetDefaultFont(),\n\t}, n, len(n.buffers))\n\n\tc.SetFocus(true)\n\n\tw, h := n.GetSize()\n\n\tn.focusedBuff = c.index\n\tn.buffers = append(n.buffers, NewBufferPane(c))\n\tn.Resize(w, h)\n\n\treturn c\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tsyscall.Syscall(gpBindBufferBase, 3, uintptr(target), uintptr(index), uintptr(buffer))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func NamedFramebufferReadBuffer(framebuffer uint32, src uint32) {\n\tC.glowNamedFramebufferReadBuffer(gpNamedFramebufferReadBuffer, (C.GLuint)(framebuffer), (C.GLenum)(src))\n}", "func FramebufferTexture2D(target, attachment, texTarget Enum, t Texture, level int) {\n\tgl.FramebufferTexture2D(uint32(target), uint32(attachment), uint32(texTarget), t.Value, int32(level))\n}", "func (emu *emuState) Framebuffer() []byte {\n\treturn emu.framebuffer()\n}", "func BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitNamedFramebuffer(gpBlitNamedFramebuffer, (C.GLuint)(readFramebuffer), (C.GLuint)(drawFramebuffer), (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 BlitNamedFramebuffer(readFramebuffer uint32, drawFramebuffer uint32, srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitNamedFramebuffer(gpBlitNamedFramebuffer, (C.GLuint)(readFramebuffer), (C.GLuint)(drawFramebuffer), (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 CreateFramebuffer() Framebuffer {\n\tvar b Framebuffer\n\tgl.GenFramebuffers(1, &b.Value)\n\treturn b\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 DrawBuffer(buf uint32) {\n\tC.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf))\n}", "func DrawBuffer(buf uint32) {\n\tC.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf))\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpRenderbufferStorage, 4, uintptr(target), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\n}", "func CreateBuffer() Buffer {\n\tvar b Buffer\n\tgl.GenBuffers(1, &b.Value)\n\treturn b\n}" ]
[ "0.77140707", "0.727492", "0.7183856", "0.7163278", "0.70613325", "0.7029213", "0.69460857", "0.69198567", "0.69198567", "0.6916873", "0.68896997", "0.6797278", "0.6751622", "0.6735318", "0.6734214", "0.6733123", "0.6629343", "0.6621128", "0.66165966", "0.66085124", "0.65327", "0.65182394", "0.65044194", "0.6484164", "0.64684075", "0.64684075", "0.64355177", "0.6423317", "0.6347452", "0.6339661", "0.6316486", "0.6311535", "0.6291794", "0.6246031", "0.62383676", "0.615794", "0.6121588", "0.6117472", "0.6111064", "0.6099627", "0.60892785", "0.6086297", "0.6086297", "0.60681397", "0.60681397", "0.6066447", "0.60538155", "0.60532856", "0.60532856", "0.60518575", "0.60518575", "0.6022738", "0.6000089", "0.5990294", "0.5967483", "0.5965905", "0.59522325", "0.5951045", "0.5926498", "0.5923117", "0.5905659", "0.5903862", "0.58944064", "0.58936834", "0.5877427", "0.5853189", "0.58515096", "0.58400697", "0.583633", "0.58301336", "0.58301336", "0.5826917", "0.58095914", "0.5801105", "0.57918835", "0.5756872", "0.5756872", "0.575657", "0.5753997", "0.5739763", "0.5733747", "0.5717602", "0.5716577", "0.5716577", "0.5695226", "0.56672674", "0.56614166", "0.5656356", "0.5656356", "0.5632551", "0.5632361", "0.5631613", "0.5631613", "0.5620025", "0.5613544", "0.56104773", "0.56104773", "0.55903655", "0.5587763" ]
0.56367624
90
attach a single layer of a texture object as a logical buffer of a framebuffer object
func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) { C.glowNamedFramebufferTextureLayer(gpNamedFramebufferTextureLayer, (C.GLuint)(framebuffer), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(layer)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func FramebufferTextureLayer(target uint32, attachment uint32, texture uint32, level int32, layer int32) {\n C.glowFramebufferTextureLayer(gpFramebufferTextureLayer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(layer))\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 (debugging *debuggingOpenGL) FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n\tdebugging.recordEntry(\"FramebufferTexture\", target, attachment, texture, level)\n\tdebugging.gl.FramebufferTexture(target, attachment, texture, level)\n\tdebugging.recordExit(\"FramebufferTexture\")\n}", "func FramebufferTextureLayer(target uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tsyscall.Syscall6(gpFramebufferTextureLayer, 5, uintptr(target), uintptr(attachment), uintptr(texture), uintptr(level), uintptr(layer), 0)\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n C.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\n\t)\n}", "func FramebufferTextureLayer(target uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tC.glowFramebufferTextureLayer(gpFramebufferTextureLayer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(layer))\n}", "func FramebufferTextureLayer(target uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tC.glowFramebufferTextureLayer(gpFramebufferTextureLayer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(layer))\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n\tC.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n\tC.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tsyscall.Syscall(gpTextureBuffer, 3, uintptr(texture), uintptr(internalformat), uintptr(buffer))\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n C.glowBindRenderbuffer(gpBindRenderbuffer, (C.GLenum)(target), (C.GLuint)(renderbuffer))\n}", "func (c *Context) AddTextureObject(cfg *TextureConfig) (*TextureObject, error) {\n\n\t// var pbo uint32\n\t// gl.GenBuffers(1, &pbo)\n\t// gl.BindBuffer(gl.PIXEL_UNPACK_BUFFER, pbo)\n\t// // Write PBO with nil to initialize the space\n\t// gl.BufferData(gl.PIXEL_UNPACK_BUFFER, len(cfg.Image.Pix), nil, gl.STREAM_DRAW)\n\n\tmode := int32(gl.LINEAR)\n\tif cfg.Mode != 0 {\n\t\tmode = cfg.Mode\n\t}\n\n\tvar texID uint32\n\tgl.GenTextures(1, &texID)\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, texID)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, mode)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mode)\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\n\t// write texture with nil pointer to initialize the space\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA,\n\t\tint32(cfg.Image.Rect.Size().X), int32(cfg.Image.Rect.Size().Y),\n\t\t0, gl.RGBA, gl.UNSIGNED_BYTE, gl.Ptr(cfg.Image.Pix))\n\n\ttexLoc := c.GetUniformLocation(cfg.UniformName)\n\tgl.Uniform1i(texLoc, 0)\n\n\ttex := &TextureObject{\n\t\ttexID: texID,\n\t\ttexLoc: texLoc,\n\t\t//pbo: pbo,\n\t\timage: cfg.Image,\n\t}\n\tc.textures = append(c.textures, tex)\n\treturn tex, nil\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n C.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tC.glowTextureBuffer(gpTextureBuffer, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tC.glowTextureBuffer(gpTextureBuffer, (C.GLuint)(texture), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func initFramebuffer(width, height int) {\n\tlog.Printf(\"[Video]: Initializing HW render (%v x %v).\\n\", width, height)\n\n\tgl.GenFramebuffers(1, &fboID)\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, fboID)\n\n\t//gl.GenTextures(1, &video.texID)\n\tgl.BindTexture(gl.TEXTURE_2D, texID)\n\tgl.TexStorage2D(gl.TEXTURE_2D, 1, gl.RGBA8, int32(width), int32(height))\n\n\tgl.FramebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texID, 0)\n\n\thw := state.Global.Core.HWRenderCallback\n\n\tgl.BindRenderbuffer(gl.RENDERBUFFER, 0)\n\n\tif gl.CheckFramebufferStatus(gl.FRAMEBUFFER) != gl.FRAMEBUFFER_COMPLETE {\n\t\tlog.Fatalln(\"[Video] Framebuffer is not complete.\")\n\t}\n\n\tgl.ClearColor(0, 0, 0, 1)\n\tif hw.Depth && hw.Stencil {\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT)\n\t} else if hw.Depth {\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t} else {\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT)\n\t}\n\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n}", "func (debugging *debuggingOpenGL) BindFramebuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindFramebuffer\", target, buffer)\n\tdebugging.gl.BindFramebuffer(target, buffer)\n\tdebugging.recordExit(\"BindFramebuffer\")\n}", "func BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func (native *OpenGL) FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tgl.FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer)\n}", "func (native *OpenGL) FramebufferTexture2D(target uint32, attachment uint32, textarget uint32, texture uint32, level int32) {\n\tgl.FramebufferTexture2D(target, attachment, textarget, texture, level)\n}", "func (native *OpenGL) BindFramebuffer(target, buffer uint32) {\n\tgl.BindFramebuffer(target, buffer)\n}", "func TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n C.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tC.glowFramebufferRenderbuffer(gpFramebufferRenderbuffer, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(renderbuffertarget), (C.GLuint)(renderbuffer))\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 (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 FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (debugging *debuggingOpenGL) FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tdebugging.recordEntry(\"FramebufferRenderbuffer\", target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.gl.FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer)\n\tdebugging.recordExit(\"FramebufferRenderbuffer\")\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\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}", "func (w *windowImpl) bindBackBuffer() {\n\t// w.mu.Lock()\n\t// size := w.Sz\n\t// w.mu.Unlock()\n\t//\n\tw.backBufferBound = true\n\t// gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t// gl.Viewport(0, 0, int32(size.X), int32(size.Y))\n}", "func FramebufferTexture2D(target, attachment, texTarget Enum, t Texture, level int) {\n\tgl.FramebufferTexture2D(uint32(target), uint32(attachment), uint32(texTarget), t.Value, int32(level))\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 updateTextureVbo(data []float32, vbo uint32) {\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferSubData(gl.ARRAY_BUFFER, 0, len(data)*4, gl.Ptr(data))\n\tgl.BindBuffer(gl.ARRAY_BUFFER, 0)\n}", "func (debugging *debuggingOpenGL) BindBuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindBuffer\", target, buffer)\n\tdebugging.gl.BindBuffer(target, buffer)\n\tdebugging.recordExit(\"BindBuffer\")\n}", "func FramebufferRenderbuffer(target, attachment, rbTarget Enum, rb Renderbuffer) {\n\tgl.FramebufferRenderbuffer(uint32(target), uint32(attachment), uint32(rbTarget), rb.Value)\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\n}", "func newFramebufferFromTexture(context *context, texture textureNative, width, height int) (*framebuffer, error) {\n\tnative, err := context.newFramebuffer(texture)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &framebuffer{\n\t\tnative: native,\n\t\twidth: width,\n\t\theight: height,\n\t}, nil\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func BindBuffer(target Enum, b Buffer) {\n\tgl.BindBuffer(uint32(target), b.Value)\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 TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n\tC.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n\tC.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func FramebufferTexture2D(target uint32, attachment uint32, textarget uint32, texture uint32, level int32) {\n\tC.glowFramebufferTexture2D(gpFramebufferTexture2D, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(textarget), (C.GLuint)(texture), (C.GLint)(level))\n}", "func FramebufferTexture2D(target uint32, attachment uint32, textarget uint32, texture uint32, level int32) {\n\tC.glowFramebufferTexture2D(gpFramebufferTexture2D, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLenum)(textarget), (C.GLuint)(texture), (C.GLint)(level))\n}", "func (native *OpenGL) BindBuffer(target uint32, buffer uint32) {\n\tgl.BindBuffer(target, buffer)\n}", "func (gl *WebGL) BindBuffer(target GLEnum, buffer WebGLBuffer) {\n\tgl.context.Call(\"bindBuffer\", target, buffer)\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 (debugging *debuggingOpenGL) BindRenderbuffer(target uint32, buffer uint32) {\n\tdebugging.recordEntry(\"BindRenderbuffer\", target, buffer)\n\tdebugging.gl.BindRenderbuffer(target, buffer)\n\tdebugging.recordExit(\"BindRenderbuffer\")\n}", "func FramebufferRenderbuffer(target Enum, attachment Enum, renderbuffertarget Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tcrenderbuffertarget, _ := (C.GLenum)(renderbuffertarget), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glFramebufferRenderbuffer(ctarget, cattachment, crenderbuffertarget, crenderbuffer)\n}", "func NamedFramebufferTextureLayer(framebuffer uint32, attachment uint32, texture uint32, level int32, layer int32) {\n\tsyscall.Syscall6(gpNamedFramebufferTextureLayer, 5, uintptr(framebuffer), uintptr(attachment), uintptr(texture), uintptr(level), uintptr(layer), 0)\n}", "func (debugging *debuggingOpenGL) BindTexture(target uint32, texture uint32) {\n\tdebugging.recordEntry(\"BindTexture\", target, texture)\n\tdebugging.gl.BindTexture(target, texture)\n\tdebugging.recordExit(\"BindTexture\")\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tC.glowBindRenderbuffer(gpBindRenderbuffer, (C.GLenum)(target), (C.GLuint)(renderbuffer))\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tC.glowBindRenderbuffer(gpBindRenderbuffer, (C.GLenum)(target), (C.GLuint)(renderbuffer))\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func BindBuffer(target uint32, buffer uint32) {\n\tC.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func NewAttachedBuffer(buffer *Buffer) *Buffer {\n result := NewEmptyBuffer()\n result.AttachBuffer(buffer)\n return result\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tC.glowNamedFramebufferDrawBuffer(gpNamedFramebufferDrawBuffer, (C.GLuint)(framebuffer), (C.GLenum)(buf))\n}", "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 BindTexture(target uint32, texture uint32) {\n C.glowBindTexture(gpBindTexture, (C.GLenum)(target), (C.GLuint)(texture))\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tC.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tC.glowBindFramebuffer(gpBindFramebuffer, (C.GLenum)(target), (C.GLuint)(framebuffer))\n}", "func BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tsyscall.Syscall(gpBindRenderbuffer, 2, uintptr(target), uintptr(renderbuffer), 0)\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\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 FramebufferTexture2D(target Enum, attachment Enum, textarget Enum, texture Uint, level Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tctextarget, _ := (C.GLenum)(textarget), cgoAllocsUnknown\n\tctexture, _ := (C.GLuint)(texture), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tC.glFramebufferTexture2D(ctarget, cattachment, ctextarget, ctexture, clevel)\n}", "func BindRenderbuffer(target GLEnum, renderbuffer Renderbuffer) {\n\tgl.BindRenderbuffer(uint32(target), uint32(renderbuffer))\n}", "func FrameBuffer(m rv.RenderModel) {\n\tframebuffer(m)\n}", "func createFB(tex wasm.WebGLTexture) wasm.WebGLFramebuffer {\n\tfb := gl.CreateFramebuffer()\n\tgl.BindFramebuffer(wasm.FRAMEBUFFER, fb)\n\tgl.FramebufferTexture2D(wasm.FRAMEBUFFER, wasm.COLOR_ATTACHMENT0, wasm.TEXTURE_2D, tex, 0)\n\treturn fb\n}", "func NamedFramebufferDrawBuffer(framebuffer uint32, buf uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffer, 2, uintptr(framebuffer), uintptr(buf), 0)\n}", "func (native *OpenGL) BindRenderbuffer(target uint32, renderbuffer uint32) {\n\tgl.BindRenderbuffer(target, renderbuffer)\n}", "func BindFramebuffer(target uint32, framebuffer uint32) {\n\tsyscall.Syscall(gpBindFramebuffer, 2, uintptr(target), uintptr(framebuffer), 0)\n}", "func (gl *WebGL) BindTexture(target GLEnum, texture WebGLTexture) {\n\tgl.context.Call(\"bindTexture\", target, texture)\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\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 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 (t *Texture2D) Bind() {\n\tgl.BindTexture(gl.TEXTURE_2D, t.ID)\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 BindFramebuffer(target Enum, fb Framebuffer) {\n\tgl.BindFramebuffer(uint32(target), fb.Value)\n}", "func (buffer Buffer) Bind(target gl.Enum) {\n\tgl.BindBuffer(gl.Enum(target), gl.Uint(buffer))\n}", "func BindTexture(target uint32, texture uint32) {\n\tsyscall.Syscall(gpBindTexture, 2, uintptr(target), uintptr(texture), 0)\n}", "func BindFramebuffer(target Enum, framebuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcframebuffer, _ := (C.GLuint)(framebuffer), cgoAllocsUnknown\n\tC.glBindFramebuffer(ctarget, cframebuffer)\n}", "func (native *OpenGL) BindTexture(target uint32, texture uint32) {\n\tgl.BindTexture(target, texture)\n}", "func (t Texture3D) Bind() {\n\tgl.BindTexture(gl.TEXTURE_3D, t.id)\n}", "func TextureBufferRange(texture uint32, internalformat uint32, buffer uint32, offset int, size int) {\n\tsyscall.Syscall6(gpTextureBufferRange, 5, uintptr(texture), uintptr(internalformat), uintptr(buffer), uintptr(offset), uintptr(size), 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 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 BindTexture(target Enum, t Texture) {\n\tgl.BindTexture(uint32(target), t.Value)\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 BindRenderbuffer(target Enum, rb Renderbuffer) {\n\tgl.BindRenderbuffer(uint32(target), rb.Value)\n}", "func (self *TileSprite) CanvasBuffer() *PIXICanvasBuffer{\n return &PIXICanvasBuffer{self.Object.Get(\"canvasBuffer\")}\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 (c *Context) BindTexture(texture *Texture) {\n\tif texture == nil {\n\t\treturn\n\t}\n\tif c.currentTexture == nil || texture.id != c.currentTexture.id {\n\t\tgl.BindTexture(gl.TEXTURE_2D, texture.id)\n\t\tc.currentTexture = texture\n\t}\n}", "func InvalidateSubFramebuffer(target uint32, numAttachments int32, attachments *uint32, x int32, y int32, width int32, height int32) {\n C.glowInvalidateSubFramebuffer(gpInvalidateSubFramebuffer, (C.GLenum)(target), (C.GLsizei)(numAttachments), (*C.GLenum)(unsafe.Pointer(attachments)), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func NewAttached(buffer []byte) *Buffer {\n result := NewEmptyBuffer()\n result.Attach(buffer)\n return result\n}" ]
[ "0.6999422", "0.69956523", "0.6836164", "0.67319816", "0.672857", "0.66928315", "0.6643474", "0.6643474", "0.66231644", "0.66231644", "0.65470356", "0.64222467", "0.63398826", "0.6331119", "0.63202375", "0.63202375", "0.6300761", "0.6292015", "0.62779385", "0.6229411", "0.62155825", "0.62018794", "0.6200421", "0.6195661", "0.6195661", "0.6136177", "0.61348253", "0.6133163", "0.61295", "0.6062783", "0.60611814", "0.6013428", "0.60019934", "0.5995808", "0.59697187", "0.5952906", "0.5948822", "0.5937816", "0.5929175", "0.5922639", "0.59209716", "0.59175587", "0.59087235", "0.59087235", "0.58901155", "0.58901155", "0.58875585", "0.58829653", "0.5871772", "0.58262926", "0.5824787", "0.58080596", "0.5804741", "0.57962114", "0.57962114", "0.57923746", "0.57923746", "0.5785434", "0.5758138", "0.5758138", "0.5752276", "0.5746633", "0.57390434", "0.57390434", "0.57332075", "0.5716515", "0.57134706", "0.57134706", "0.5712827", "0.57084", "0.57052106", "0.5704372", "0.5704048", "0.56421214", "0.56263083", "0.5606586", "0.56055224", "0.5579867", "0.5578951", "0.5578951", "0.5552747", "0.5546309", "0.55338234", "0.55201226", "0.5510604", "0.5504955", "0.549304", "0.5492266", "0.54918814", "0.54845333", "0.54803646", "0.5472297", "0.5464139", "0.54622066", "0.5462189", "0.5456751", "0.5441153", "0.54373735", "0.54322964" ]
0.5804017
54
establish data storage, format and dimensions of a renderbuffer object's image
func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) { C.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpRenderbufferStorage, 4, uintptr(target), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\n}", "func RenderbufferStorage(target, internalFormat Enum, width, height int) {\n\tgl.RenderbufferStorage(uint32(target), uint32(internalFormat), int32(width), int32(height))\n}", "func RenderbufferStorage(target Enum, internalformat Enum, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glRenderbufferStorage(ctarget, cinternalformat, cwidth, cheight)\n}", "func (native *OpenGL) RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tgl.RenderbufferStorage(target, internalformat, width, height)\n}", "func (self *GameObjectCreator) BitmapData4O(width int, height int, key string, addToCache bool) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height, key, addToCache)}\n}", "func RenderbufferStorage(target, internalFormat GLEnum, width, height int32) {\n\tgl.RenderbufferStorage(uint32(target), uint32(internalFormat), width, height)\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tC.glowRenderbufferStorage(gpRenderbufferStorage, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tC.glowRenderbufferStorage(gpRenderbufferStorage, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (self *GameObjectCreator) BitmapData1O(width int) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width)}\n}", "func (debugging *debuggingOpenGL) RenderbufferStorage(target uint32, internalFormat uint32, width int32, height int32) {\n\tdebugging.recordEntry(\"RenderbufferStorage\", target, internalFormat, width, height)\n\tdebugging.gl.RenderbufferStorage(target, internalFormat, width, height)\n\tdebugging.recordExit(\"RenderbufferStorage\")\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 (self *GameObjectCreator) BitmapData3O(width int, height int, key string) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height, key)}\n}", "func (self *TileSprite) CanvasBuffer() *PIXICanvasBuffer{\n return &PIXICanvasBuffer{self.Object.Get(\"canvasBuffer\")}\n}", "func (self *GameObjectCreator) BitmapData2O(width int, height int) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height)}\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 (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\n\t)\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 (is ImageSurface) Format() Format {\n\treturn is.format\n}", "func (self *GameObjectCreator) BitmapData() *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\")}\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 (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 NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpNamedRenderbufferStorage, 4, uintptr(renderbuffer), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\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 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 Image(img []byte) string {\n\treturn ImageWidthHeight(img, 0, 0, true)\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 (self *GameObjectCreator) BitmapDataI(args ...interface{}) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", args)}\n}", "func (i *ImageBuf) Spec() *ImageSpec {\n\tret := &ImageSpec{C.ImageBuf_spec(i.ptr)}\n\truntime.KeepAlive(i)\n\treturn ret\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\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 (ob *Object) Render() {\n\tob.image.Draw(ob.x, ob.y, allegro.FLIP_NONE)\n}", "func (r renderer) Image(out *bytes.Buffer, link []byte, title []byte, alt []byte) {}", "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 ImageInfo(d Ploop) (ImageInfoData, error) {\n\tvar cinfo C.struct_ploop_spec\n\tvar info ImageInfoData\n\n\tret := C.ploop_get_spec(d.d, &cinfo)\n\tif ret == 0 {\n\t\tinfo.blocks = uint64(cinfo.size)\n\t\tinfo.blocksize = uint32(cinfo.blocksize)\n\t\tinfo.version = int(cinfo.fmt_version)\n\t}\n\n\treturn info, mkerr(ret)\n}", "func (*Image) Descriptor() ([]byte, []int) {\n\treturn file_api_proto_rawDescGZIP(), []int{1}\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 (*Image) Descriptor() ([]byte, []int) {\n\treturn file_kit_kit_proto_rawDescGZIP(), []int{1}\n}", "func Image(img image.Image) Data {\n\tdata, err := image0(img)\n\tif err != nil {\n\t\treturn Data{\n\t\t\tData: BundledMIMEData{\n\t\t\t\t\"ename\": \"ERROR\",\n\t\t\t\t\"evalue\": err.Error(),\n\t\t\t\t\"traceback\": nil,\n\t\t\t\t\"status\": \"error\",\n\t\t\t},\n\t\t}\n\t}\n\treturn data\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 qr_decoder_get_image_buffer(p _QrDecoderHandle) *_IplImage {\n\tv := C.qr_decoder_get_image_buffer(C.QrDecoderHandle(p))\n\treturn (*_IplImage)(v)\n}", "func (self *GameObjectCreator) Image(x int, y int, key interface{}) *Image{\n return &Image{self.Object.Call(\"image\", x, y, key)}\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 (API) GetFramebufferAttachmentInfo(state *api.State, thread uint64, attachment api.FramebufferAttachment) (width, height, index uint32, format *image.Format, err error) {\n\treturn 0, 0, 0, nil, fmt.Errorf(\"GVR does not support framebuffers\")\n}", "func (this *osmTileStruct) Image() *image.NRGBA {\n\timg := this.imageData\n\treturn img\n}", "func (self *Graphics) Data() interface{}{\n return self.Object.Get(\"data\")\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 (self *Surface) Data() []byte {\n\tself.Flush()\n\tdataPtr := C.cairo_image_surface_get_data(self.surface)\n\tif dataPtr == nil {\n\t\tpanic(\"cairo.Surface.Data(): can't access surface pixel data\")\n\t}\n\tstride := C.cairo_image_surface_get_stride(self.surface)\n\theight := C.cairo_image_surface_get_height(self.surface)\n\treturn C.GoBytes(unsafe.Pointer(dataPtr), stride*height)\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 *Surface) SetImage(img image.Image) {\n\twidth := self.Width()\n\theight := self.Height()\n\tstride := self.Stride()\n\n\tswitch self.Format() {\n\tcase FORMAT_ARGB32:\n\t\tif i, ok := img.(*extimage.BGRA); ok {\n\t\t\tif i.Rect.Dx() == width && i.Rect.Dy() == height && i.Stride == stride {\n\t\t\t\tself.SetData(i.Pix)\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t\tsurfImg := self.Image().(*extimage.BGRA)\n\t\tdraw.Draw(surfImg, surfImg.Bounds(), img, img.Bounds().Min, draw.Src)\n\t\tself.SetData(surfImg.Pix)\n\n\tcase FORMAT_RGB24:\n\t\tif i, ok := img.(*extimage.BGRN); ok {\n\t\t\tif i.Rect.Dx() == width && i.Rect.Dy() == height && i.Stride == stride {\n\t\t\t\tself.SetData(i.Pix)\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t\tsurfImg := self.Image().(*extimage.BGRN)\n\t\tdraw.Draw(surfImg, surfImg.Bounds(), img, img.Bounds().Min, draw.Src)\n\t\tself.SetData(surfImg.Pix)\n\n\tcase FORMAT_A8:\n\t\tif i, ok := img.(*image.Alpha); ok {\n\t\t\tif i.Rect.Dx() == width && i.Rect.Dy() == height && i.Stride == stride {\n\t\t\t\tself.SetData(i.Pix)\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t\tsurfImg := self.Image().(*image.Alpha)\n\t\tdraw.Draw(surfImg, surfImg.Bounds(), img, img.Bounds().Min, draw.Src)\n\t\tself.SetData(surfImg.Pix)\n\n\tcase FORMAT_A1:\n\t\tpanic(\"Unsuppored surface format cairo.FORMAT_A1\")\n\n\tcase FORMAT_RGB16_565:\n\t\tpanic(\"Unsuppored surface format cairo.FORMAT_RGB16_565\")\n\n\tcase FORMAT_RGB30:\n\t\tpanic(\"Unsuppored surface format cairo.FORMAT_RGB30\")\n\n\tcase FORMAT_INVALID:\n\t\tpanic(\"Invalid surface format\")\n\t}\n\tpanic(\"Unknown surface format\")\n}", "func (*ImageInfo) Descriptor() ([]byte, []int) {\n\treturn file_proto_laptopService_proto_rawDescGZIP(), []int{6}\n}", "func (*ImageInput) Descriptor() ([]byte, []int) {\n\treturn file_proto_meme_proto_rawDescGZIP(), []int{3}\n}", "func (*Image) Descriptor() ([]byte, []int) {\n\treturn file_google_cloud_retail_v2_common_proto_rawDescGZIP(), []int{4}\n}", "func (*ImageInfo) Descriptor() ([]byte, []int) {\n\treturn file_laptop_service_proto_rawDescGZIP(), []int{5}\n}", "func (renderbuffer Renderbuffer) IsRenderbuffer() bool {\n\treturn gl.IsRenderbuffer(uint32(renderbuffer))\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func (r *ImageRef) Format() ImageType {\n\treturn r.format\n}", "func (*ProductImage) Descriptor() ([]byte, []int) {\n\treturn file_product_proto_rawDescGZIP(), []int{1}\n}", "func FramebufferRenderbuffer(target, attachment, rbTarget Enum, rb Renderbuffer) {\n\tgl.FramebufferRenderbuffer(uint32(target), uint32(attachment), uint32(rbTarget), rb.Value)\n}", "func FramebufferRenderbuffer(target Enum, attachment Enum, renderbuffertarget Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tcrenderbuffertarget, _ := (C.GLenum)(renderbuffertarget), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glFramebufferRenderbuffer(ctarget, cattachment, crenderbuffertarget, crenderbuffer)\n}", "func (ite *ifdTagEnumerator) ReadBuffer(n int) (buf []byte, err error) {\n\tif n > len(ite.exifReader.rawBuffer) {\n\t\treturn nil, ErrDataLength\n\t}\n\t// Read from underlying exifReader io.ReaderAt interface\n\tn, err = ite.exifReader.ReadAt(ite.exifReader.rawBuffer[:n], int64(ite.offset+ite.ifdOffset))\n\n\tite.offset += uint32(n) // Update reader offset\n\n\treturn ite.exifReader.rawBuffer[:n], err\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (self *GameObjectCreator) RenderTexture2O(width int, height int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height)}\n}", "func (*ProductImage) Descriptor() ([]byte, []int) {\n\treturn file_proto_product_product_proto_rawDescGZIP(), []int{1}\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tsyscall.Syscall(gpTextureBuffer, 3, uintptr(texture), uintptr(internalformat), uintptr(buffer))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (emu *emuState) Framebuffer() []byte {\n\treturn emu.framebuffer()\n}", "func newImageResource(name string, width, height int, bitperComponent int, data []byte) *ImageResource {\n\treturn &ImageResource{\n\t\tname: name,\n\t\twidth: width,\n\t\theight: height,\n\t\tcolorSpace: colorSpaceDeviceGray,\n\t\tbitsPerComponent: bitperComponent,\n\t\tdata: data,\n\t}\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 (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 (*ReqImageInfo) Descriptor() ([]byte, []int) {\n\treturn file_docker_api_proto_rawDescGZIP(), []int{1}\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 (*Image) Descriptor() ([]byte, []int) {\n\treturn file_internal_services_profile_proto_profile_proto_rawDescGZIP(), []int{4}\n}", "func (x *FzPixmap) Deref() {\n\tif x.ref7c1a1ba1 == nil {\n\t\treturn\n\t}\n\tx.Storable = *(*FzStorable)(unsafe.Pointer(&x.ref7c1a1ba1.storable))\n\tx.X = (int32)(x.ref7c1a1ba1.x)\n\tx.Y = (int32)(x.ref7c1a1ba1.y)\n\tx.W = (int32)(x.ref7c1a1ba1.w)\n\tx.H = (int32)(x.ref7c1a1ba1.h)\n\tx.N = (byte)(x.ref7c1a1ba1.n)\n\tx.S = (byte)(x.ref7c1a1ba1.s)\n\tx.Alpha = (byte)(x.ref7c1a1ba1.alpha)\n\tx.Flags = (byte)(x.ref7c1a1ba1.flags)\n\tx.Stride = (int32)(x.ref7c1a1ba1.stride)\n\tx.Seps = (*FzSeparations)(unsafe.Pointer(x.ref7c1a1ba1.seps))\n\tx.Xres = (int32)(x.ref7c1a1ba1.xres)\n\tx.Yres = (int32)(x.ref7c1a1ba1.yres)\n\tx.Colorspace = (*FzColorspace)(unsafe.Pointer(x.ref7c1a1ba1.colorspace))\n\thxff73280 := (*sliceHeader)(unsafe.Pointer(&x.Samples))\n\thxff73280.Data = uintptr(unsafe.Pointer(x.ref7c1a1ba1.samples))\n\thxff73280.Cap = 0x7fffffff\n\t// hxff73280.Len = ?\n\n}", "func (g GenericBackend) ReadFramebufferCount(ctx context.Context, width, height int) (framebuffers int, e error) {\n\tf, err := os.Open(fmt.Sprintf(genericFramebufferFilePattern, g.index))\n\tif err != nil {\n\t\treturn framebuffers, errors.Wrap(err, \"failed to open dri file\")\n\t}\n\n\ttext, err := ioutil.ReadAll(f)\n\tif err != nil {\n\t\treturn framebuffers, errors.Wrap(err, \"failed to read dri file\")\n\t}\n\tlines := strings.Split(string(text), \"\\n\")\n\tfor _, line := range lines {\n\t\t// The line we're looking for looks like \"...size=1920x1080\"\n\t\tvar fbWidth, fbHeight int\n\t\tif _, err := fmt.Sscanf(line, \" size=%dx%d\", &fbWidth, &fbHeight); err != nil {\n\t\t\tcontinue\n\t\t}\n\t\tif fbWidth == width && fbHeight == height {\n\t\t\tframebuffers++\n\t\t}\n\t}\n\treturn\n}", "func FramebufferRenderbuffer(target uint32, attachment uint32, renderbuffertarget uint32, renderbuffer uint32) {\n\tsyscall.Syscall6(gpFramebufferRenderbuffer, 4, uintptr(target), uintptr(attachment), uintptr(renderbuffertarget), uintptr(renderbuffer), 0, 0)\n}", "func (s *ImageSpec) Format() TypeDesc {\n\tret := (TypeDesc)(C.ImageSpec_format(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func FrameBuffer(m rv.RenderModel) {\n\tframebuffer(m)\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 NewRenderer(i *image.RGBA, w int, h int) *Renderer {\n\tbuffer := make([]float64, w*h)\n\n\tfor num := range buffer {\n\t\tbuffer[num] = -2\n\t}\n\n\tr := Renderer{\n\t\timg: i,\n\t\twidth: w,\n\t\theight: h,\n\t\tzBuffer: buffer,\n\t}\n\n\treturn &r\n}", "func (o ArgoCDExportSpecOutput) Image() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v ArgoCDExportSpec) *string { return v.Image }).(pulumi.StringPtrOutput)\n}", "func CreateImageBufferI3D(hDC unsafe.Pointer, dwSize unsafe.Pointer, uFlags unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpCreateImageBufferI3D, 3, uintptr(hDC), uintptr(dwSize), uintptr(uFlags))\n\treturn (unsafe.Pointer)(ret)\n}", "func (s *AssetsStorage) Init(renderer *Renderer, config *config.Config) error {\n\tgrid := CreateGrid(renderer, config)\n\ts.Grid = grid\n\n\ts.Dots = make([]Renderable, len(Colors))\n\ts.VertLines = make([]Renderable, len(Colors))\n\ts.HorizLines = make([]Renderable, len(Colors))\n\tfor i, c := range Colors {\n\t\ts.Dots[i] = createDot(c, renderer, config)\n\t\ts.VertLines[i] = createVLine(c, renderer, config)\n\t\ts.HorizLines[i] = createHLine(c, renderer, config)\n\t}\n\n\treturn nil\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func pixelBufferLength(bytesPerPixel int, r Rectangle, imageTypeName string) int {\n\ttotalLength := mul3NonNeg(bytesPerPixel, r.Dx(), r.Dy())\n\tif totalLength < 0 {\n\t\tpanic(\"image: New\" + imageTypeName + \" Rectangle has huge or negative dimensions\")\n\t}\n\treturn totalLength\n}", "func (self *GameObjectCreator) RenderTexture3O(width int, height int, key string) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height, key)}\n}", "func Render(mem *memory.Bank) *image.RGBA {\n\t// Top border\n\tfor pixel := 0; pixel < 4*width*BorderTop; pixel += 4 {\n\t\tborder := findBorderColour(pixelT[pixel/4])\n\t\timg.Pix[pixel] = border[0]\n\t\timg.Pix[pixel+1] = border[1]\n\t\timg.Pix[pixel+2] = border[2]\n\t}\n\n\t// Main screen and left/right border\n\tfor line, addr := range lines {\n\t\tpx := 4 * (width*(line+BorderTop) + BorderLeft)\n\n\t\t// Left border\n\t\tfor left := px - 4*BorderLeft; left < px; left += 4 {\n\t\t\tborder := findBorderColour(pixelT[left/4])\n\t\t\timg.Pix[left] = border[0]\n\t\t\timg.Pix[left+1] = border[1]\n\t\t\timg.Pix[left+2] = border[2]\n\t\t}\n\t\t// Right border\n\t\tfor right := px + 4*256; right < px+4*256+4*BorderRight; right += 4 {\n\t\t\tborder := findBorderColour(pixelT[right/4])\n\t\t\timg.Pix[right] = border[0]\n\t\t\timg.Pix[right+1] = border[1]\n\t\t\timg.Pix[right+2] = border[2]\n\t\t}\n\n\t\t// Centre\n\t\tfor col := 0; col < 32; col++ {\n\t\t\tattr := mem[0x5800+32*(line/8)+col-0x4000]\n\t\t\tcell := mem[addr+col-0x4000]\n\t\t\tfor _, bit := range []byte{0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01} {\n\t\t\t\tvar colour []byte\n\t\t\t\tflash := attr&0x80 != 0 && frame >= 32\n\t\t\t\ton := cell&bit != 0\n\t\t\t\tif on != flash {\n\t\t\t\t\tcolour = inkPalette[attr&0b01000111]\n\t\t\t\t} else {\n\t\t\t\t\tcolour = paperPalette[attr&0b01111000]\n\t\t\t\t}\n\t\t\t\timg.Pix[px] = colour[0]\n\t\t\t\timg.Pix[px+1] = colour[1]\n\t\t\t\timg.Pix[px+2] = colour[2]\n\t\t\t\tpx += 4\n\t\t\t}\n\t\t}\n\t}\n\n\t// Bottom border\n\tfor px := 4 * width * (BorderTop + 192); px < 4*width*(height); px += 4 {\n\t\tborder := findBorderColour(pixelT[px/4])\n\t\timg.Pix[px] = border[0]\n\t\timg.Pix[px+1] = border[1]\n\t\timg.Pix[px+2] = border[2]\n\t}\n\n\t// Can safely drop recorded states\n\tresetBorderStates()\n\n\t// Keep frame count for the \"flash\" attribute\n\tframe += 1\n\tif frame > 50 {\n\t\tframe = 1\n\t}\n\n\treturn img\n}", "func IsRenderbuffer(renderbuffer Uint) Boolean {\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\t__ret := C.glIsRenderbuffer(crenderbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func (frame *AvFrame) SetInfo(width int, height int, pixFmt int) (err error) {\n\tframe.width = C.int(width)\n\tframe.height = C.int(height)\n\tframe.format = C.int(pixFmt)\n\tif ret := C.av_frame_get_buffer((*C.struct_AVFrame)(unsafe.Pointer(frame)), 32 /*alignment*/); ret < 0 {\n\t\terr = fmt.Errorf(\"Error allocating avframe buffer. Err: %v\", ret)\n\t\treturn\n\t}\n\treturn\n}", "func (*Asset) Descriptor() ([]byte, []int) {\n\treturn file_bastion_proto_rawDescGZIP(), []int{17}\n}", "func (frame *AvFrame) GetInfo() (width int, height int, linesize [8]int32, data [8]*uint8) {\n\twidth = int(frame.linesize[0])\n\theight = int(frame.height)\n\tfor i := range linesize {\n\t\tlinesize[i] = int32(frame.linesize[i])\n\t}\n\tfor i := range data {\n\t\tdata[i] = (*uint8)(frame.data[i])\n\t}\n\t// log.Println(\"Linesize is \", frame.linesize, \"Data is\", data)\n\treturn\n}", "func (r *RGBARotator) Image() image.Image {\n\treturn r.Img\n}", "func GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n C.glowGetBufferSubData(gpGetBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func (s *ShmPool) CreateBuffer(id *Buffer, offset int32, width int32, height int32, stride int32, format uint32) {\n sendrequest(s, \"wl_shm_pool_create_buffer\", id, offset, width, height, stride, format)\n}", "func (*DataShape) Descriptor() ([]byte, []int) {\n\treturn file_marketstore_proto_rawDescGZIP(), []int{0}\n}" ]
[ "0.5998305", "0.58400124", "0.5705627", "0.5702508", "0.5666278", "0.56230754", "0.56207895", "0.5602298", "0.5602298", "0.5592833", "0.55329335", "0.5517138", "0.551079", "0.549668", "0.5485291", "0.54749393", "0.5390986", "0.53616107", "0.53538954", "0.5349218", "0.5310649", "0.5305363", "0.5294529", "0.52583355", "0.5237834", "0.5220827", "0.51926565", "0.51597625", "0.51551783", "0.51461613", "0.51371914", "0.51208884", "0.5117754", "0.5105487", "0.5101095", "0.50756127", "0.5074031", "0.50693303", "0.5061891", "0.5060471", "0.50552917", "0.50537497", "0.5052644", "0.50436395", "0.50353324", "0.502344", "0.5023433", "0.5015386", "0.49866277", "0.49829352", "0.4963962", "0.49427593", "0.4935603", "0.49304858", "0.49171412", "0.4915753", "0.49091968", "0.48959675", "0.4895078", "0.4895042", "0.48896697", "0.48790303", "0.48790303", "0.48776576", "0.48581305", "0.48519558", "0.4839033", "0.4839033", "0.48216295", "0.48170313", "0.48107672", "0.48107672", "0.48097673", "0.4794968", "0.47887394", "0.4783381", "0.47819602", "0.4776854", "0.4768933", "0.476029", "0.47575283", "0.47527823", "0.47527823", "0.47474825", "0.47474492", "0.47434613", "0.47329715", "0.4729675", "0.47216845", "0.47210756", "0.47193795", "0.4709914", "0.47029677", "0.4702015", "0.4701244", "0.46936628", "0.46911648", "0.46895012", "0.46837953" ]
0.5047612
44
establish data storage, format, dimensions and sample count of a renderbuffer object's image
func NamedRenderbufferStorageMultisample(renderbuffer uint32, samples int32, internalformat uint32, width int32, height int32) { C.glowNamedRenderbufferStorageMultisample(gpNamedRenderbufferStorageMultisample, (C.GLuint)(renderbuffer), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 RenderbufferStorage(target Enum, internalformat Enum, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glRenderbufferStorage(ctarget, cinternalformat, cwidth, cheight)\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpRenderbufferStorage, 4, uintptr(target), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\n}", "func RenderbufferStorage(target, internalFormat Enum, width, height int) {\n\tgl.RenderbufferStorage(uint32(target), uint32(internalFormat), int32(width), int32(height))\n}", "func (native *OpenGL) RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tgl.RenderbufferStorage(target, internalformat, width, height)\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tC.glowRenderbufferStorage(gpRenderbufferStorage, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tC.glowRenderbufferStorage(gpRenderbufferStorage, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func RenderbufferStorage(target, internalFormat GLEnum, width, height int32) {\n\tgl.RenderbufferStorage(uint32(target), uint32(internalFormat), width, height)\n}", "func (debugging *debuggingOpenGL) RenderbufferStorage(target uint32, internalFormat uint32, width int32, height int32) {\n\tdebugging.recordEntry(\"RenderbufferStorage\", target, internalFormat, width, height)\n\tdebugging.gl.RenderbufferStorage(target, internalFormat, width, height)\n\tdebugging.recordExit(\"RenderbufferStorage\")\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func (self *GameObjectCreator) BitmapData1O(width int) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width)}\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 (i *ImageBuf) Spec() *ImageSpec {\n\tret := &ImageSpec{C.ImageBuf_spec(i.ptr)}\n\truntime.KeepAlive(i)\n\treturn ret\n}", "func (g GenericBackend) ReadFramebufferCount(ctx context.Context, width, height int) (framebuffers int, e error) {\n\tf, err := os.Open(fmt.Sprintf(genericFramebufferFilePattern, g.index))\n\tif err != nil {\n\t\treturn framebuffers, errors.Wrap(err, \"failed to open dri file\")\n\t}\n\n\ttext, err := ioutil.ReadAll(f)\n\tif err != nil {\n\t\treturn framebuffers, errors.Wrap(err, \"failed to read dri file\")\n\t}\n\tlines := strings.Split(string(text), \"\\n\")\n\tfor _, line := range lines {\n\t\t// The line we're looking for looks like \"...size=1920x1080\"\n\t\tvar fbWidth, fbHeight int\n\t\tif _, err := fmt.Sscanf(line, \" size=%dx%d\", &fbWidth, &fbHeight); err != nil {\n\t\t\tcontinue\n\t\t}\n\t\tif fbWidth == width && fbHeight == height {\n\t\t\tframebuffers++\n\t\t}\n\t}\n\treturn\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpNamedRenderbufferStorage, 4, uintptr(renderbuffer), uintptr(internalformat), uintptr(width), uintptr(height), 0, 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 (self *GameObjectCreator) BitmapData4O(width int, height int, key string, addToCache bool) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height, key, addToCache)}\n}", "func (f *Framebuffer) Renderbuffer(attachment gfx.FramebufferAttachment, buf gfx.Renderbuffer) {\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.RENDERBUFFER,\n\t\tbuf.Object().(*js.Object),\n\t\t0,\n\t)\n}", "func (self *GameObjectCreator) BitmapData3O(width int, height int, key string) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height, key)}\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 NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tC.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func NamedRenderbufferStorage(renderbuffer uint32, internalformat uint32, width int32, height int32) {\n\tC.glowNamedRenderbufferStorage(gpNamedRenderbufferStorage, (C.GLuint)(renderbuffer), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func ImageInfo(d Ploop) (ImageInfoData, error) {\n\tvar cinfo C.struct_ploop_spec\n\tvar info ImageInfoData\n\n\tret := C.ploop_get_spec(d.d, &cinfo)\n\tif ret == 0 {\n\t\tinfo.blocks = uint64(cinfo.size)\n\t\tinfo.blocksize = uint32(cinfo.blocksize)\n\t\tinfo.version = int(cinfo.fmt_version)\n\t}\n\n\treturn info, mkerr(ret)\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 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 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 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 (is ImageSurface) Format() Format {\n\treturn is.format\n}", "func (self *GameObjectCreator) BitmapData2O(width int, height int) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height)}\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 (g I915Backend) ReadFramebufferCount(ctx context.Context, width, height int) (framebuffers int, e error) {\n\tf, err := os.Open(i915FramebufferFile)\n\tif err != nil {\n\t\treturn framebuffers, errors.Wrap(err, \"failed to open dri file\")\n\t}\n\ttext, err := ioutil.ReadAll(f)\n\tif err != nil {\n\t\treturn framebuffers, errors.Wrap(err, \"failed to read dri file\")\n\t}\n\tlines := strings.Split(string(text), \"\\n\")\n\tfor _, line := range lines {\n\t\t// The line we're looking for looks like \"user size: 1920 x 1080,...\"\n\t\tvar fbWidth, fbHeight int\n\t\tif _, err := fmt.Sscanf(line, \"user size: %d x %d\", &fbWidth, &fbHeight); err != nil {\n\t\t\tcontinue\n\t\t}\n\t\tif fbWidth == width && fbHeight == height {\n\t\t\tframebuffers++\n\t\t}\n\t}\n\treturn\n}", "func RenderbufferStorageMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32) {\n C.glowRenderbufferStorageMultisample(gpRenderbufferStorageMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (self *TileSprite) CanvasBuffer() *PIXICanvasBuffer{\n return &PIXICanvasBuffer{self.Object.Get(\"canvasBuffer\")}\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 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 pixelBufferLength(bytesPerPixel int, r Rectangle, imageTypeName string) int {\n\ttotalLength := mul3NonNeg(bytesPerPixel, r.Dx(), r.Dy())\n\tif totalLength < 0 {\n\t\tpanic(\"image: New\" + imageTypeName + \" Rectangle has huge or negative dimensions\")\n\t}\n\treturn totalLength\n}", "func (self *GameObjectCreator) BitmapData() *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\")}\n}", "func (m *metricMysqlBufferPoolUsage) init() {\n\tm.data.SetName(\"mysql.buffer_pool.usage\")\n\tm.data.SetDescription(\"The number of bytes in the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"By\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func (ite *ifdTagEnumerator) ReadBuffer(n int) (buf []byte, err error) {\n\tif n > len(ite.exifReader.rawBuffer) {\n\t\treturn nil, ErrDataLength\n\t}\n\t// Read from underlying exifReader io.ReaderAt interface\n\tn, err = ite.exifReader.ReadAt(ite.exifReader.rawBuffer[:n], int64(ite.offset+ite.ifdOffset))\n\n\tite.offset += uint32(n) // Update reader offset\n\n\treturn ite.exifReader.rawBuffer[:n], err\n}", "func RenderbufferStorageMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpRenderbufferStorageMultisample, 5, uintptr(target), uintptr(samples), uintptr(internalformat), uintptr(width), uintptr(height), 0)\n}", "func (b *BatchBuffer) Init() {}", "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 (i *ImageBuf) NumChannels() int {\n\tret := int(C.ImageBuf_nchannels(i.ptr))\n\truntime.KeepAlive(i)\n\treturn ret\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowNamedBufferData(gpNamedBufferData, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (API) GetFramebufferAttachmentInfo(state *api.State, thread uint64, attachment api.FramebufferAttachment) (width, height, index uint32, format *image.Format, err error) {\n\treturn 0, 0, 0, nil, fmt.Errorf(\"GVR does not support framebuffers\")\n}", "func (renderbuffer Renderbuffer) IsRenderbuffer() bool {\n\treturn gl.IsRenderbuffer(uint32(renderbuffer))\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 (self *GameObjectCreator) BitmapDataI(args ...interface{}) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", args)}\n}", "func (*Image) Descriptor() ([]byte, []int) {\n\treturn file_kit_kit_proto_rawDescGZIP(), []int{1}\n}", "func Image(img []byte) string {\n\treturn ImageWidthHeight(img, 0, 0, true)\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 qr_decoder_get_image_buffer(p _QrDecoderHandle) *_IplImage {\n\tv := C.qr_decoder_get_image_buffer(C.QrDecoderHandle(p))\n\treturn (*_IplImage)(v)\n}", "func (s *ImageSpec) Format() TypeDesc {\n\tret := (TypeDesc)(C.ImageSpec_format(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\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 FramebufferRenderbuffer(target Enum, attachment Enum, renderbuffertarget Enum, renderbuffer Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcattachment, _ := (C.GLenum)(attachment), cgoAllocsUnknown\n\tcrenderbuffertarget, _ := (C.GLenum)(renderbuffertarget), cgoAllocsUnknown\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\tC.glFramebufferRenderbuffer(ctarget, cattachment, crenderbuffertarget, crenderbuffer)\n}", "func FrameBuffer(m rv.RenderModel) {\n\tframebuffer(m)\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tC.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func RenderbufferStorageMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32) {\n\tC.glowRenderbufferStorageMultisample(gpRenderbufferStorageMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func RenderbufferStorageMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32) {\n\tC.glowRenderbufferStorageMultisample(gpRenderbufferStorageMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func ReadBuffer(mode uint32) {\n C.glowReadBuffer(gpReadBuffer, (C.GLenum)(mode))\n}", "func (*Image) Descriptor() ([]byte, []int) {\n\treturn file_api_proto_rawDescGZIP(), []int{1}\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 FramebufferRenderbuffer(target, attachment, rbTarget Enum, rb Renderbuffer) {\n\tgl.FramebufferRenderbuffer(uint32(target), uint32(attachment), uint32(rbTarget), rb.Value)\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 (*ImageInput) Descriptor() ([]byte, []int) {\n\treturn file_proto_meme_proto_rawDescGZIP(), []int{3}\n}", "func (n *nativeObject) SampleCount() int {\n\treturn n.sampleCount\n}", "func NamedRenderbufferStorageMultisample(renderbuffer uint32, samples int32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpNamedRenderbufferStorageMultisample, 5, uintptr(renderbuffer), uintptr(samples), uintptr(internalformat), uintptr(width), uintptr(height), 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 (spriteBatch *SpriteBatch) GetBufferSize() int {\n\treturn spriteBatch.size\n}", "func TextureBuffer(texture uint32, internalformat uint32, buffer uint32) {\n\tsyscall.Syscall(gpTextureBuffer, 3, uintptr(texture), uintptr(internalformat), uintptr(buffer))\n}", "func (frame *AvFrame) GetInfo() (width int, height int, linesize [8]int32, data [8]*uint8) {\n\twidth = int(frame.linesize[0])\n\theight = int(frame.height)\n\tfor i := range linesize {\n\t\tlinesize[i] = int32(frame.linesize[i])\n\t}\n\tfor i := range data {\n\t\tdata[i] = (*uint8)(frame.data[i])\n\t}\n\t// log.Println(\"Linesize is \", frame.linesize, \"Data is\", data)\n\treturn\n}", "func (r *ImageRef) Format() ImageType {\n\treturn r.format\n}", "func (ob *Object) Render() {\n\tob.image.Draw(ob.x, ob.y, allegro.FLIP_NONE)\n}", "func DataTypeSize(t GLenum) int {\n\tswitch t {\n\tcase GLenum_GL_BYTE,\n\t\tGLenum_GL_UNSIGNED_BYTE:\n\t\treturn 1\n\tcase GLenum_GL_SHORT,\n\t\tGLenum_GL_UNSIGNED_SHORT,\n\t\tGLenum_GL_HALF_FLOAT_ARB,\n\t\tGLenum_GL_HALF_FLOAT_OES:\n\t\treturn 2\n\tcase GLenum_GL_FIXED,\n\t\tGLenum_GL_FLOAT,\n\t\tGLenum_GL_INT,\n\t\tGLenum_GL_UNSIGNED_INT,\n\t\tGLenum_GL_UNSIGNED_INT_2_10_10_10_REV:\n\t\treturn 4\n\tdefault:\n\t\tpanic(fmt.Errorf(\"Unknown data type %v\", t))\n\t}\n}", "func (m *metricMysqlBufferPoolDataPages) init() {\n\tm.data.SetName(\"mysql.buffer_pool.data_pages\")\n\tm.data.SetDescription(\"The number of data pages in the InnoDB buffer pool.\")\n\tm.data.SetUnit(\"1\")\n\tm.data.SetEmptySum()\n\tm.data.Sum().SetIsMonotonic(false)\n\tm.data.Sum().SetAggregationTemporality(pmetric.MetricAggregationTemporalityCumulative)\n\tm.data.Sum().DataPoints().EnsureCapacity(m.capacity)\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func (s *AssetsStorage) Init(renderer *Renderer, config *config.Config) error {\n\tgrid := CreateGrid(renderer, config)\n\ts.Grid = grid\n\n\ts.Dots = make([]Renderable, len(Colors))\n\ts.VertLines = make([]Renderable, len(Colors))\n\ts.HorizLines = make([]Renderable, len(Colors))\n\tfor i, c := range Colors {\n\t\ts.Dots[i] = createDot(c, renderer, config)\n\t\ts.VertLines[i] = createVLine(c, renderer, config)\n\t\ts.HorizLines[i] = createHLine(c, renderer, config)\n\t}\n\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 (*ImageInfo) Descriptor() ([]byte, []int) {\n\treturn file_proto_laptopService_proto_rawDescGZIP(), []int{6}\n}", "func (frame *AvFrame) SetInfo(width int, height int, pixFmt int) (err error) {\n\tframe.width = C.int(width)\n\tframe.height = C.int(height)\n\tframe.format = C.int(pixFmt)\n\tif ret := C.av_frame_get_buffer((*C.struct_AVFrame)(unsafe.Pointer(frame)), 32 /*alignment*/); ret < 0 {\n\t\terr = fmt.Errorf(\"Error allocating avframe buffer. Err: %v\", ret)\n\t\treturn\n\t}\n\treturn\n}", "func (s *Stream) FrameImageDataSize() int64 {\n\treturn int64(s.LumaPlaneSize() + 2*s.ChromaPlaneSize() + s.AlphaPlaneSize())\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 (*ImageInfo) Descriptor() ([]byte, []int) {\n\treturn file_laptop_service_proto_rawDescGZIP(), []int{5}\n}", "func GetBufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n C.glowGetBufferSubData(gpGetBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func IsRenderbuffer(renderbuffer Uint) Boolean {\n\tcrenderbuffer, _ := (C.GLuint)(renderbuffer), cgoAllocsUnknown\n\t__ret := C.glIsRenderbuffer(crenderbuffer)\n\t__v := (Boolean)(__ret)\n\treturn __v\n}", "func (r renderer) Image(out *bytes.Buffer, link []byte, title []byte, alt []byte) {}", "func ReadBuffer(src uint32) {\n\tC.glowReadBuffer(gpReadBuffer, (C.GLenum)(src))\n}", "func ReadBuffer(src uint32) {\n\tC.glowReadBuffer(gpReadBuffer, (C.GLenum)(src))\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 IsRenderbuffer(renderbuffer uint32) bool {\n ret := C.glowIsRenderbuffer(gpIsRenderbuffer, (C.GLuint)(renderbuffer))\n return ret == TRUE\n}", "func (s *ImageSpec) NumChannels() int {\n\tret := int(C.ImageSpec_nchannels(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func (*ProductImage) Descriptor() ([]byte, []int) {\n\treturn file_product_proto_rawDescGZIP(), []int{1}\n}", "func init() {\n\timage.RegisterFormat(\"pbm\", \"P4\", decodePBM, decodeConfigPBM)\n\timage.RegisterFormat(\"pbm\", \"P1\", decodePBMPlain, decodeConfigPBM)\n}", "func IsRenderbuffer(rb Renderbuffer) bool {\n\treturn gl.IsRenderbuffer(rb.Value)\n}", "func (self *Graphics) Data() interface{}{\n return self.Object.Get(\"data\")\n}", "func (*Images) Descriptor() ([]byte, []int) {\n\treturn file_kit_kit_proto_rawDescGZIP(), []int{0}\n}" ]
[ "0.6029619", "0.5719552", "0.5705418", "0.56924033", "0.56395096", "0.5618975", "0.5618975", "0.55995035", "0.5489016", "0.53760284", "0.53604287", "0.5332098", "0.5273535", "0.5263664", "0.5249539", "0.5241155", "0.51979065", "0.5148246", "0.5137379", "0.5113538", "0.510561", "0.510561", "0.51047415", "0.5072804", "0.5072792", "0.50644946", "0.5046332", "0.5042196", "0.5036478", "0.5025968", "0.50176936", "0.5011708", "0.5010739", "0.49938315", "0.49861085", "0.4925964", "0.4918479", "0.4903479", "0.48890018", "0.4870156", "0.4867893", "0.48509192", "0.48505467", "0.48364785", "0.48364785", "0.48210898", "0.48170698", "0.48123464", "0.48123464", "0.4807546", "0.48065007", "0.48008627", "0.47905302", "0.47905302", "0.47901198", "0.47789416", "0.47774813", "0.47710973", "0.47708878", "0.47610626", "0.47610626", "0.4743563", "0.4743563", "0.4736847", "0.47331023", "0.47282705", "0.4725537", "0.47214392", "0.47210214", "0.47162098", "0.4714935", "0.4695632", "0.46841955", "0.46809304", "0.4676294", "0.46761346", "0.46731195", "0.46669868", "0.46602735", "0.46516702", "0.46504104", "0.4649652", "0.46480575", "0.46465948", "0.46457604", "0.46454072", "0.46430022", "0.46350974", "0.46350098", "0.46317968", "0.4629637", "0.4629637", "0.4625062", "0.46197355", "0.46191442", "0.46169722", "0.46091676", "0.46051717", "0.45988956", "0.45983055", "0.45980194" ]
0.0
-1
create or replace a display list
func NewList(list uint32, mode uint32) { C.glowNewList(gpNewList, (C.GLuint)(list), (C.GLenum)(mode)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 (m *List) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (l *FileList) Display(\n\taccessKey *ui.Entry,\n\tsecretKey *ui.Entry,\n\tbucket *ui.Entry) (err error) {\n\n\tlist, err := comm.Refresh(\n\t\taccessKey.Text(), secretKey.Text(), bucket.Text())\n\n\tif err != nil {\n\t\treturn\n\t}\n\tlog.Println(\"Displaying the list.\")\n\n\tl.name.Clear()\n\tl.mType.Clear()\n\tl.size.Clear()\n\tl.checkbox.Clear()\n\tlog.Println(\"Boxes cleared.\")\n\n\tl.NameList = []string{}\n\tl.CheckboxList = []*ui.Checkbox{}\n\tlog.Println(\"Lists cleared.\")\n\n\t// Fix the number of the list.\n\t// TODO: clear this limit.\n\tif len(list) > 30 {\n\t\tlist = list[:30]\n\t}\n\n\tfor _, item := range list {\n\t\tl.name.Append(ui.NewLabel(item.Key), true)\n\t\tl.NameList = append(l.NameList, item.Key)\n\n\t\tl.mType.Append(ui.NewLabel(item.MimeType), true)\n\t\tl.size.Append(\n\t\t\tui.NewLabel(tool.FormatSize(item.Fsize)), true)\n\n\t\ttempCheckbox := ui.NewCheckbox(\"\")\n\t\tl.checkbox.Append(tempCheckbox, true)\n\t\tl.CheckboxList = append(l.CheckboxList, tempCheckbox)\n\t}\n\tlog.Println(\"Displayed the list.\")\n\n\treturn\n}", "func ShowUserList(ul *[]define.User) {\n\t//ul := &define.UserList\n\tt := tablewriter.NewWriter(os.Stdout)\n\tt.SetAutoFormatHeaders(false)\n\tt.SetAutoWrapText(false)\n\tt.SetReflowDuringAutoWrap(false)\n\tt.SetHeader([]string{\"ID\", \"Name\", \"Cell\", \"Address\", \"Born\", \"Passwd\"})\n\tfor _, user := range *ul {\n\t\tid := strconv.FormatUint(uint64(user.ID), 10)\n\t\tt.Append([]string{id, user.Name, user.Cell, user.Address,\n\t\t\tuser.Born.Format(\"2006.01.02\"), user.Passwd})\n\t}\n\tt.Render()\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 (d *Inbrs) DisplayTable(w io.Writer) {\n\tvar data [][]string\n\tfor _, s := range d.list {\n\t\tdata = append(data, []string{s.hostname, s.intName, s.area,\n\t\t\ts.remoteID, s.fwAddress.String()})\n\t}\n\ttable := tablewriter.NewWriter(w)\n\ttable.SetHeader([]string{\"hostname\", \"interface\", \"area\", \"remote id\", \"FW address\"})\n\tfor _, v := range data {\n\t\ttable.Append(v)\n\t}\n\ttable.Render() // Send output\n}", "func (L *List) Display() {\n\tnode := L.Head\n\tfor node != nil {\n\t\tfmt.Printf(\"%+v -> \", node.Key)\n\t\tnode = node.next\n\t}\n\tfmt.Println(\"---\")\n}", "func (controller *List) Display() {\n\tcontroller.Data[\"searches\"] = controller.Account.GetSearches().GetAll()\n\tcontroller.SetCustomTitle(\"Account - Activity\")\n\tcontroller.LoadTemplate(\"home\")\n}", "func (r *LocalRegistry) List(artHome string, extended bool) {\n\t// get a table writer for the stdout\n\tw := tabwriter.NewWriter(os.Stdout, 0, 0, 1, ' ', tabwriter.Debug)\n\t// print the header row\n\tvar err error\n\tif extended {\n\t\t_, err = fmt.Fprintln(w, i18n.String(artHome, i18n.LBL_LS_HEADER_PLUS))\n\t} else {\n\t\t_, err = fmt.Fprintln(w, i18n.String(artHome, i18n.LBL_LS_HEADER))\n\t}\n\tcore.CheckErr(err, \"failed to write table header\")\n\tvar (\n\t\ts *data.Seal\n\t\tauthor string\n\t)\n\t// repository, tag, package id, created, size\n\tfor _, repo := range r.Repositories {\n\t\tfor _, a := range repo.Packages {\n\t\t\ts, err = r.GetSeal(a)\n\t\t\tif err != nil {\n\t\t\t\tauthor = \"unknown\"\n\t\t\t} else {\n\t\t\t\tauthor = s.Manifest.Author\n\t\t\t}\n\t\t\t// if the package is dangling (no tags)\n\t\t\tif len(a.Tags) == 0 {\n\t\t\t\tif extended {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\t\"<none>\",\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size,\n\t\t\t\t\t\tauthor),\n\t\t\t\t\t)\n\t\t\t\t} else {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\t\"<none>\",\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size),\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t\tcore.CheckErr(err, \"failed to write output\")\n\t\t\t}\n\t\t\tfor _, tag := range a.Tags {\n\t\t\t\tif extended {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\ttag,\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size,\n\t\t\t\t\t\tauthor),\n\t\t\t\t\t)\n\t\t\t\t} else {\n\t\t\t\t\t_, err = fmt.Fprintln(w, fmt.Sprintf(\"%s\\t %s\\t %s\\t %s\\t %s\\t %s\\t\",\n\t\t\t\t\t\trepo.Repository,\n\t\t\t\t\t\ttag,\n\t\t\t\t\t\ta.Id[0:12],\n\t\t\t\t\t\ta.Type,\n\t\t\t\t\t\ttoElapsedLabel(a.Created),\n\t\t\t\t\t\ta.Size),\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t\tcore.CheckErr(err, \"failed to write output\")\n\t\t\t}\n\t\t}\n\t}\n\terr = w.Flush()\n\tcore.CheckErr(err, \"failed to flush output\")\n}", "func updateDisplays(elevatorFloor int, e *Elevator) {\n\tfor _, display := range e.floorDisplaysList {\n\t\tdisplay.floor = elevatorFloor\n\t}\n}", "func (l *List) Display() {\n\tlst := l.head\n\tfor lst != nil {\n\t\tif lst.next != nil {\n\t\t\tfmt.Printf(\"%+v -> \", lst.val)\n\t\t} else {\n\t\t\tfmt.Printf(\"%+v\", lst.val)\n\t\t}\n\t\tlst = lst.next\n\t}\n\tfmt.Println()\n}", "func (r *Ri) Display(name, typeof, mode RtToken, parameterlist ...Rter) error {\n\n\tvar out = []Rter{name, typeof, mode, PARAMETERLIST}\n\tout = append(out, parameterlist...)\n\n\treturn r.writef(\"Display\", out...)\n}", "func newListWin(filters []string) *listWin {\n\tsort.Strings(filters)\n\n\ttitle := fmt.Sprintf(\"%s/%s\", path, strings.Join(filters, \"\"))\n\twin, err := acme.New(title)\n\tif err != nil {\n\t\tdie(1, \"Failed to create a new window %s: %s\", title, err)\n\t}\n\tif err := win.Fprintf(\"tag\", \"Sort \"); err != nil {\n\t\tdie(1, \"Failed to write the tag of %s: %s\", title, err)\n\t}\n\tlw := &listWin{\n\t\tWin: win,\n\t\ttitle: title,\n\t\tfilters: filters,\n\t\tless: lessFuncs[\"prio\"],\n\t}\n\twg.Add(1)\n\tgo lw.events()\n\tlw.refresh()\n\treturn lw\n}", "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 (l *ToDoList) showList() []string {\n\treturn l.list\n}", "func (card Card) display(view View, show_sensitive bool, include_deleted bool) {\n if view == SingleLineView {\n user, _ := card.getUser()\n url, _ := card.firstFieldByType(\"url\")\n password := \"\"\n if show_sensitive {\n password, _ = card.firstFieldByType(\"password\")\n }\n fmt.Printf(\"%s: %s %s %s\\n\", card.Name, user, url, password)\n return\n }\n\n const noteLabel = \"Note\"\n const indent = 4\n\n fmt.Println(card.Name)\n\n width := 0\n type_width := 0\n for pass := 0; pass <= 1 ; pass++ {\n for _, f := range(card.Fields) {\n value := f.Value\n if f.Sensitive != 0 && !show_sensitive && value != \"\" {\n value = \"*****\"\n }\n\n if (value != \"\" || view > CardView) &&\n (f.Isdeleted == 0 || include_deleted) {\n if pass == 0 {\n width = max(width, len(f.label()))\n type_width = max(type_width, len(f.Type))\n } else {\n fmt.Printf(\"%*s: %s\\n\", width+indent, f.label(), value)\n }\n }\n }\n\n if view > CardView || card.Note != \"\" {\n if pass == 0 {\n width = max(width, len(noteLabel))\n } else {\n fmt.Printf(\"%*s: %s\\n\", width+indent, noteLabel, card.Note)\n }\n }\n }\n}", "func ShowList(manuals []*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\n\t}\n\n\t// show manuals\n\thead, rows := createList(manuals)\n\tfmt.Println(ansi.ColorCode(\"cyan\") + head + ansi.Reset)\n\tfmt.Println(strings.Join(rows, \"\\n\"))\n}", "func (ll *linkedList) display() {\n\tfor tip := ll.head; tip != nil; tip = tip.Next {\n\t\tfmt.Printf(\"NODE: %+v %p \\n\", tip, tip)\n\t}\n\tfmt.Println()\n}", "func newNodeWithDisplay(p string, display DisplayFn) *Node {\n\tn := newNode(p)\n\tn.display = display\n\treturn n\n}", "func NewNotificationDisplayInfo_List(s *capnp.Segment, sz int32) (NotificationDisplayInfo_List, error) {\n\tl, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}, sz)\n\treturn NotificationDisplayInfo_List{l}, err\n}", "func createView(controls *ControlList, conf *cf.Config) {\n\tcontrols.mainWindow = ui.AddWindow(0, 0, 12, 7, \"TermFB2\")\n\tcontrols.mainWindow.SetPack(ui.Vertical)\n\n\tcontrols.mainWindow.OnKeyDown(func(ev ui.Event, data interface {}) bool {\n\t\tif ev.Key == term.KeyF2 && conf.UseDb {\n\t\t\tcreateBookListDialog(controls, conf)\n\t\t\treturn true\n\t\t}\n\t\treturn false\n\t}, nil)\n\tcontrols.reader = ui.CreateTextReader(controls.mainWindow, minWidth, minHeight, 1)\n\tcontrols.reader.SetTextColor(conf.TextColor)\n\tcontrols.reader.SetBackColor(conf.BackColor)\n\tui.ActivateControl(controls.mainWindow, controls.reader)\n\tcontrols.mainWindow.SetMaximized(true)\n\tcontrols.mainWindow.SetModal(true)\n}", "func (l List) ShowList() {\n\tfmt.Println(\"ID\\tArrival\\tBurst\\tPriority\")\n\n\tfor i := 0; i < len(l); i++ {\n\t\tfmt.Printf(\"%d\\t%d\\t%d\\t%d\\n\",\n\t\t\tl[i].ID, l[i].Arrival, l[i].Burst, l[i].Priority)\n\t}\n\tfmt.Printf(\"Number of jobs: %d\\n\\n\", len(l))\n}", "func ShowCurrentUserList() {\n\tul := &define.UserList\n\tShowUserList(ul)\n}", "func ShowInteractiveList(manuals []*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\n\t}\n\n\t_, rows := createList(manuals)\n\tprompt := &survey.Select{\n\t\tMessage: \"Select a manual to show\",\n\t\tOptions: rows,\n\t}\n\tvar row string\n\tif err := survey.AskOne(prompt, &row, nil); err != nil {\n\t\tText(err)\n\t\treturn\n\t}\n\n\tfor i, r := range rows {\n\t\tif row == r {\n\t\t\tShowManual(manuals[i], false)\n\t\t\tbreak\n\t\t}\n\t}\n}", "func Display(possible ...Cmd) {\n\thint := randHint(possible)\n\tif hint != \"\" {\n\t\tui.Hint(hint, false)\n\t}\n}", "func (c *UsageController) setList(list []models.Usage) {\n\tc.Usage = list\n\tc.parseNewID()\n}", "func Display(lst *Node) {\n\tfor lst != nil {\n\t\tif lst.next != nil {\n\t\t\tfmt.Printf(\"%v -> \", lst.val)\n\t\t} else {\n\t\t\tfmt.Printf(\"%v\", lst.val)\n\t\t}\n\t\tlst = lst.next\n\t}\n\tfmt.Println()\n}", "func (m *Model) View() string {\n\tcontents := make([]string, len(m.valueLists))\n\tfor i, l := range m.valueLists {\n\t\tcontents[i] = l.View()\n\t}\n\tresult := lipgloss.JoinHorizontal(lipgloss.Top, contents...)\n\tcurSelected := m.valueLists[m.selectedList].SelectedItem()\n\tvar desc string\n\tif curSelected == nil {\n\t\tdesc = m.Styles.PlaceholderDescription.Render(\"(no entry seleted)\")\n\t} else {\n\t\titem := curSelected.(candidateItem)\n\t\tdesc = item.Description()\n\t\tif desc != \"\" {\n\t\t\tdesc = m.Styles.Description.Render(truncate.String(item.Title()+\": \"+desc, uint(m.width)))\n\t\t} else {\n\t\t\tdesc = m.Styles.PlaceholderDescription.Render(fmt.Sprintf(\"(entry %q has no description)\", item.Title()))\n\t\t}\n\t}\n\treturn result + \"\\n\" + desc\n}", "func (h *HandlersApp01sqVendor) ListShow(w http.ResponseWriter, offset int, msg string) {\n\tvar err error\n\tvar rcds []App01sqVendor.App01sqVendor\n\tvar name = \"App01sq.Vendor.list.gohtml\"\n\tvar str strings.Builder\n\n\tlog.Printf(\"hndlrVendor.ListShow(%d)\\n\", offset)\n\tlog.Printf(\"\\tname: %s\\n\", name)\n\tw2 := io.MultiWriter(w, &str)\n\n\t// Get the records to display\n\trcds, err = h.db.RowPage(offset, h.rowsPerPage)\n\tif err != nil {\n\n\t\tlog.Printf(\"...end hndlrVendor.ListShow(Error:400) - No Key\\n\")\n\n\t\thttp.Error(w, http.StatusText(400), http.StatusBadRequest)\n\t\treturn\n\t}\n\n\tdata := struct {\n\t\tRcds []App01sqVendor.App01sqVendor\n\t\tOffset int\n\t\tMsg string\n\t}{rcds, offset, msg}\n\n\tlog.Printf(\"\\tData: %+v\\n\", data)\n\n\tlog.Printf(\"\\tExecuting template: %s\\n\", name)\n\terr = h.Tmpls.Tmpls.ExecuteTemplate(w2, name, data)\n\tif err != nil {\n\t\tfmt.Fprintf(w, err.Error())\n\t}\n\n\tlog.Printf(\"\\t output: %s\\n\", str.String())\n\tlog.Printf(\"...end hndlrVendor.ListShow(%s)\\n\", util.ErrorString(err))\n}", "func FormatList(list []string, indent int) string {\n\tout := \"\\n\"\n\tfor _, item := range list {\n\t\tout = out + \"- \" + strings.ReplaceAll(strings.TrimLeft(item, \"\\n\"), \"\\n\", \"\\n \")\n\t}\n\treturn ApplyIdent(out, indent)\n}", "func (l *linkedliststock) Display() {\n\tcurrent := l.front\n\tfor current != nil {\n\t\t//taking values of corresponding struct\n\t\tvalue1 := current.stockname\n\t\tvalue2 := current.stockshares\n\t\tvalue3 := current.stockprice\n\t\tfmt.Println(\"--------------------------------------\")\n\t\tfmt.Printf(\"Stock Name : %s\\n\", value1)\n\t\tfmt.Printf(\"Stock Shares : %d\\n\", value2)\n\t\tfmt.Printf(\"Stock Price : %d\\n\", value3)\n\t\tfmt.Println(\"--------------------------------------\")\n\t\t//moving to next struct\n\t\tcurrent = current.next\n\t}\n\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 (x *FzDisplayList) Ref() *C.fz_display_list {\n\tif x == nil {\n\t\treturn nil\n\t}\n\treturn (*C.fz_display_list)(unsafe.Pointer(x))\n}", "func (s *Service) Display(c context.Context, mid int64, plat int8, build int, buvid, channel, ip, ak, network, mobiApp,\n\tdevice, language, adExtra string, isTmp bool, now time.Time) (res []*show.Show) {\n\tres = s.showDisplay(c, mid, plat, build, buvid, channel, ip, ak, network, mobiApp, device, language, adExtra, isTmp, false, false, now)\n\treturn\n}", "func formatCmdDisplay(results client.StorageFormatResults, summary bool) (string, error) {\n\tout := &bytes.Buffer{}\n\n\tgroups, mixedGroups, err := groupFormatResults(results, summary)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\n\tif len(groups) > 0 {\n\t\tfmt.Fprintf(out, \"\\n%s\\n\", groups)\n\t}\n\n\treturn formatHostGroups(out, mixedGroups), nil\n}", "func (h *History) List() {\n\tload := reverse(h.Load())\n\tprompt := promptui.Select{\n\t\tLabel: \"Target hisotry\",\n\t\tItems: load,\n\t\tSize: 10,\n\t}\n\n\ti, _, err := prompt.Run()\n\n\tif err != nil {\n\t\tlog.Fatalln(\"Prompt failed: \\n\", err)\n\t}\n\n\titem := load[i]\n\th.Write(item)\n\tExecuteItem(h.binary, item)\n}", "func DisplayName(value string) *SimpleElement { return newSEString(\"displayName\", value) }", "func createList(w io.Writer, r *http.Request) error {\n\tc := appengine.NewContext(r)\n\n\t// Check that the user is logged in.\n\t// - user.Current : http://golang.org/s/users#Current\n\n\t// Decode a list from the request body.\n\tlist := List{}\n\terr := json.NewDecoder(r.Body).Decode(&list)\n\tif err != nil {\n\t\treturn appErrorf(http.StatusBadRequest, \"decode list: %v\", err)\n\t}\n\n\tif list.Name == \"\" {\n\t\treturn appErrorf(http.StatusBadRequest, \"missing list name\")\n\t}\n\n\t// Set the Creator field of list as the email of the current user.\n\n\t// Put the List in the datastore.\n\tkey := datastore.NewIncompleteKey(c, listKind, nil)\n\tkey, err = datastore.Put(c, key, &list)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"create list: %v\", err)\n\t}\n\n\t// Update the encoded key and encode the list.\n\tlist.ID = key.Encode()\n\treturn json.NewEncoder(w).Encode(list)\n}", "func main() {\n\tfmt.Println(\"Lista enlazada simple\")\n\n\tl := &List{}\n\tnode1 := Node{value: 1}\n\tnode2 := Node{value: 2}\n\tnode3 := Node{value: 4}\n\tnode4 := Node{value: 6}\n\tnode5 := Node{value: 8}\n\tl.Append(&node1)\n\tl.Append(&node2)\n\tl.Append(&node3)\n\tl.Append(&node4)\n\tl.Append(&node5)\n\n\tPrintList(l)\n}", "func NewList(list uint32, mode uint32) {\n\tsyscall.Syscall(gpNewList, 2, uintptr(list), uintptr(mode), 0)\n}", "func (m *BrowserSiteList) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func saveLists() {\n\ttmpArticleList = articleList\n}", "func listRun(cmd *cobra.Command, args []string) {\n\t\n\t// Items are read in using ReadItems; an example of stepwise refinement and procedural abstraction.\n\titems, err := todo.ReadItems(dataFile)\n\n\tvar data [][]string\n\n\t// Selection statement run to check if the To-Do list is empty\n\tif len(items) == 0 {\n\t\tlog.Println(\"No To-Do's in Your List - use the create command to get started!\")\n\t\treturn\n\t}\n\n\t// Selection statement run to check if there was an error from reading the data\n\tif err != nil {\n\t\tlog.Printf(\"%v\", err)\n\t} \n\n\t// Calls Sort method created in todo.go; an example of stepwise refinement\n\ttodo.Sort(items)\n\n\t// Iterative statement that appends all of the To-Dos in the list to a String array\n\t// Sequential statements are run within the FOR-EACH loop\n\tfor _, i := range items {\n\t\tvar temp []string\n\t\ttemp = append(temp, i.Label())\n\t\ttemp = append(temp, i.PrettyDone())\n\t\ttemp = append(temp, i.PrettyPrint())\n\t\ttemp = append(temp, i.Text)\n\t\tdata = append(data, temp)\n\t}\n\n\t\n\t/*\n\tSets the parameters for the To-Do list displayed as a table to the user. \n\tControls the appearence of the GUI.\n\t*/\n\ttable := tablewriter.NewWriter(os.Stdout)\n\ttable.SetHeader([]string {\"Position\", \"Done?\", \"Priority\", \"Task\"})\n\n\ttable.SetHeaderColor(tablewriter.Colors{tablewriter.Bold, tablewriter.BgHiBlueColor},\n\t\ttablewriter.Colors{tablewriter.FgWhiteColor, tablewriter.Bold, tablewriter.BgHiBlueColor},\n\t\ttablewriter.Colors{tablewriter.BgHiBlueColor, tablewriter.FgWhiteColor},\n\t\ttablewriter.Colors{tablewriter.BgHiBlueColor, tablewriter.FgWhiteColor})\n\n\ttable.SetColumnColor(tablewriter.Colors{tablewriter.Bold, tablewriter.FgHiCyanColor},\n\t\ttablewriter.Colors{tablewriter.Bold, tablewriter.FgHiRedColor},\n\t\ttablewriter.Colors{tablewriter.Bold, tablewriter.FgHiMagentaColor},\n\t\ttablewriter.Colors{tablewriter.Bold, tablewriter.FgBlackColor})\n\n\tw := tabwriter.NewWriter(os.Stdout, 3, 0, 1, ' ', 0)\n\n\t// Iterative statement that appends all To-Do items marked done based on the condition of if either the --all or --done flag is active.\n\tfor p, i := range data {\n\t\tif allFlag || items[p].Done == doneFlag {\n\t\t\ttable.Append(i)\n\t\t}\n\t}\n\n\t// Renders the table\n\ttable.Render()\n\n\t// Flushes the writer\n\tw.Flush()\n\n}", "func List() {\n\terr := ListCmd.Parse(os.Args[2:])\n\tif err != nil || internal.Help {\n\t\tListCmd.Usage()\n\t\tos.Exit(0)\n\t}\n\n\tconfigurator, err := config.NewConfigurator()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tlist, err := configurator.GetCollaborators()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tsort.Slice(list, func(i, j int) bool {\n\t\treturn config.Less(list[i], list[j])\n\t})\n\n\ttw := tabwriter.NewWriter(os.Stdout, 0, 0, 2, ' ', 0x0)\n\tfor _, collab := range list {\n\t\tline := fmt.Sprintf(\"\\t%s\\t<%s>\", collab.Name, collab.Email)\n\t\tif (collab.Alias != collab.Name) {\n\t\t\tline = fmt.Sprintf(\"%s:%s\", collab.Alias, line)\n\t\t}\n\t\tfmt.Fprintln(tw, line)\n\t}\n\ttw.Flush()\n}", "func allocFzDisplayListMemory(n int) unsafe.Pointer {\n\tmem, err := C.calloc(C.size_t(n), (C.size_t)(sizeOfFzDisplayListValue))\n\tif err != nil {\n\t\tpanic(\"memory alloc error: \" + err.Error())\n\t}\n\treturn mem\n}", "func listExtended(cmd *cobra.Command, features []FeatureInfo) error {\n\tvar t component.OutputWriterSpinner\n\tt, err := component.NewOutputWriterWithSpinner(cmd.OutOrStdout(), outputFormat,\n\t\t\"Retrieving Features...\", true, \"NAME\", \"ACTIVATION STATE\", \"STABILITY\", \"DESCRIPTION\", \"IMMUTABLE\", \"FEATUREGATE\")\n\tif err != nil {\n\t\treturn fmt.Errorf(\"could not get OutputWriterSpinner: %w\", err)\n\t}\n\n\tfor _, info := range features {\n\t\tt.AddRow(info.Name, info.Activated, info.Stability, info.Description, info.Immutable, info.FeatureGate)\n\t}\n\tt.RenderWithSpinner()\n\n\treturn nil\n}", "func restoreLists() {\n\tarticleList = tmpArticleList\n}", "func newList(data interface{}) *List {\n\tnewL := new(List)\n\tnewL.Insert(data)\n\treturn newL\n}", "func (ll *Doubly[T]) Display() {\n\tfor cur := ll.Head.Next; cur != ll.Head; cur = cur.Next {\n\t\tfmt.Print(cur.Val, \" \")\n\t}\n\n\tfmt.Print(\"\\n\")\n}", "func List(pdf *gofpdf.Fpdf, list model.ListContent) {\n\tlevel := 1\n\tpdf.SetLeftMargin(margins[level])\n\tpdf.SetRightMargin(21)\n\n\tdrawList(pdf, list, level)\n\n\tpdf.SetLeftMargin(20)\n\tpdf.SetRightMargin(20)\n\tpdf.SetFont(\"helvetica\", \"\", 12)\n\tpdf.Ln(1)\n}", "func registerCommandList(progname string) {\n\tlog.Printf(\"Entering repo::registerCommandList(%s)\", progname)\n\tdefer log.Println(\"Exiting repo::registerCommandList\")\n\n\tcmdOptions.listCmd = flag.NewFlagSet(progname+\" list\", flag.PanicOnError)\n\n\tcmdOptions.listCmd.StringVar(\n\t\t&cmdOptions.productVersion,\n\t\t\"product-version\",\n\t\t\"\",\n\t\t\"Version that a software should be compatibile with.\"+\n\t\t\t\" (I.e., product-version)\",\n\t)\n\tcmdOptions.listCmd.StringVar(\n\t\t&cmdOptions.softwareName,\n\t\t\"filename\",\n\t\t\"\",\n\t\t\"File name of the software.\",\n\t)\n\tcmdOptions.listCmd.StringVar(\n\t\t&cmdOptions.softwareRepo,\n\t\t\"repo\",\n\t\tSoftwareRepoPath,\n\t\t\"Path of the software repository.\",\n\t)\n\tcmdOptions.listCmd.StringVar(\n\t\t&cmdOptions.softwareType,\n\t\t\"type\",\n\t\t\"\",\n\t\t\"Type of the software.\",\n\t)\n\toutput.RegisterCommandOptions(cmdOptions.listCmd,\n\t\tmap[string]string{\"output-format\": \"yaml\"})\n}", "func newListView(title string, x1, y1, x2, y2 int, listData []string) *ListView {\n\tlistWidget := newListWidget(title, x1, y1, x2, y2)\n\tlistView := &ListView{listWidget}\n\n\tlistView.SetData(listData)\n\n\treturn listView\n}", "func (l *LinkedList) Display() {\n\tif l.count == 0 {\n\t\tfmt.Println(\"No items in the stock\")\n\t} else {\n\t\tfmt.Println(\"..........The stock report is......\")\n\t\tcurrentPost := l.head\n\t\tfor currentPost != nil {\n\t\t\tfmt.Println(\"\\n-----------------------------------------\\n\")\n\t\t\tfmt.Printf(\"\\nName : %s\", currentPost.Name)\n\t\t\tfmt.Printf(\"\\nShare_Price : %d\", currentPost.Share_price)\n\t\t\tfmt.Printf(\"\\nShares : %d\", currentPost.Number_of_shares)\n\t\t\tfmt.Println(\"\\n----------------------------------------\\n\")\n\t\t\tcurrentPost = currentPost.next\n\t\t}\n\t}\n}", "func (s *Service) showDisplay(c context.Context, mid int64, plat int8, build int, buvid, channel, ip, ak, network, mobiApp,\n\tdevice, language, adExtra string, isTmp, isRegion, isIndex bool, now time.Time) (res []*show.Show) {\n\tvar (\n\t\tbnr string\n\t\tbanners map[int][]*resource.Banner\n\t\tshowRec []*show.Item\n\t\tshowLive []*show.Item\n\t\tisBangumi = false\n\t\tisRegionBanner = false\n\t\tss []*show.Show\n\t\tresIDStr = _bannersPlat[plat]\n\t)\n\tif language == \"\" {\n\t\tlanguage = _initlanguage\n\t}\n\tkey := fmt.Sprintf(_initShowKey, plat, language)\n\tif (plat == model.PlatIPhone && build > 6050) || (plat == model.PlatAndroid && build > 512007) {\n\t\tss = s.cacheBgEp[key]\n\t} else if ((mobiApp == \"iphone\" && build > 5600) || (mobiApp == \"android\" && build > 507000)) && isIndex {\n\t\tss = s.cacheBg[key]\n\t} else {\n\t\tss = s.cache[key]\n\t}\n\tif isTmp {\n\t\tss = s.tempCache[key]\n\t}\n\tif len(ss) == 0 {\n\t\tres = _emptyShow\n\t\treturn\n\t}\n\tres = make([]*show.Show, 0, len(ss))\n\tif (mobiApp == \"iphone\" && build > 4310) || (mobiApp == \"android\" && build > 502000) || isIndex {\n\t\tisBangumi = true\n\t}\n\tif (mobiApp == \"iphone\" && build > 4350) || (mobiApp == \"android\" && build > 503000) {\n\t\tisRegionBanner = true\n\t}\n\tg, ctx := errgroup.WithContext(c)\n\tg.Go(func() error {\n\t\tbanners = s.resBanners(ctx, plat, build, mid, resIDStr, channel, ip, buvid, network, mobiApp, device, adExtra)\n\t\treturn nil\n\t})\n\tif !isRegion {\n\t\tg.Go(func() error {\n\t\t\tshowRec = s.getRecommend(ctx, mid, build, plat, buvid, network, mobiApp, device, ip)\n\t\t\treturn nil\n\t\t})\n\t\tg.Go(func() error {\n\t\t\tshowLive = s.getLive(ctx, mid, ak, ip, 0, now)\n\t\t\treturn nil\n\t\t})\n\t}\n\tif err := g.Wait(); err != nil {\n\t\tlog.Error(\"showDisplay errgroup.WithContext error(%v)\", err)\n\t}\n\tfor i, sw := range ss {\n\t\tif mobiApp == \"white\" && 101220 >= build && sw.Param == \"165\" { // 165 ad region\n\t\t\tcontinue\n\t\t} else if sw.Param != \"165\" || ((mobiApp != \"iphone\" || device != \"pad\") || build <= 3590) {\n\t\t\tif model.InvalidBuild(build, sw.Build, sw.Condition) {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\tif sw.Type == \"recommend\" {\n\t\t\tif isRegion {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tsw = s.dealRecommend(c, sw, plat, mid, build, buvid, network, mobiApp, device, ip, showRec)\n\t\t\tbnr = \"0\"\n\t\t} else if sw.Type == \"live\" {\n\t\t\tif isRegion {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tsw = s.dealLive(c, sw, showLive)\n\t\t\tbnr = \"65537\"\n\t\t} else if sw.Type == \"bangumi\" {\n\t\t\tif ok := s.auditRegion(mobiApp, plat, build, \"13\"); ok {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif isRegion && isBangumi && !isRegionBanner {\n\t\t\t\tbnr = \"-1\"\n\t\t\t} else if isRegion && !isBangumi && !isRegionBanner {\n\t\t\t\tcontinue\n\t\t\t} else {\n\t\t\t\tbnr = \"13\"\n\t\t\t}\n\t\t} else {\n\t\t\tbnr = sw.Param\n\t\t\tif isRegion {\n\t\t\t\tif ok := s.auditRegion(mobiApp, plat, build, sw.Param); ok {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tif !isRegionBanner {\n\t\t\t\t\tif sw.Param == \"1\" && !isBangumi {\n\t\t\t\t\t\tbnr = \"-1\"\n\t\t\t\t\t}\n\t\t\t\t\tif sw.Type == \"topic\" && i > 0 && (ss[i-1].Type == \"bangumi\" || ss[i-1].Type == \"1\") {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tsw.Banner = s.getBanners(c, plat, build, bnr, channel, ip, banners, isIndex)\n\t\tres = append(res, sw)\n\t}\n\treturn\n}", "func (g *Game) listUsables() {\n\tletter := 'a'\n\tlistText, _ := sf.NewText(Font)\n\tlistText.SetCharacterSize(12)\n\tlistText.SetPosition(sf.Vector2f{12, 12})\n\tusables := make(map[rune]*Item)\n\tnames := make(map[*Item]string)\n\tfor k, i := range g.player.inventory {\n\t\tif i.effect != nil {\n\t\t\tappendString(listText, strconv.QuoteRune(letter)+\" - \"+k+\" x\"+strconv.Itoa(i.stack))\n\t\t\tusables[letter] = i\n\t\t\tnames[i] = k\n\t\t\tletter++\n\t\t}\n\t}\n\nlistLoop:\n\tfor g.window.IsOpen() {\n\t\tfor event := g.window.PollEvent(); event != nil; event = g.window.PollEvent() {\n\t\t\tswitch et := event.(type) {\n\t\t\tcase sf.EventTextEntered:\n\t\t\t\tdone, used := g.inventoryInput(et.Char, usables, names)\n\t\t\t\tif used != \"\" {\n\t\t\t\t\tusedI := g.player.inventory[used]\n\t\t\t\t\tif usedI.stack > 1 {\n\t\t\t\t\t\tusedI.stack--\n\t\t\t\t\t\tbreak listLoop\n\t\t\t\t\t}\n\t\t\t\t\tdelete(g.player.inventory, used)\n\t\t\t\t\tbreak listLoop\n\t\t\t\t}\n\t\t\t\tif done {\n\t\t\t\t\tbreak listLoop\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tg.window.Clear(sf.ColorBlack())\n\n\t\tg.window.SetView(g.logView)\n\t\tg.drawLog()\n\t\tg.window.SetView(g.gameView)\n\t\tlistText.Draw(g.window, sf.DefaultRenderStates())\n\t\tg.window.Display()\n\t}\n\n\tg.state = PLAY\n}", "func (m *Group) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func MembersAddDisplay(w http.ResponseWriter, r *http.Request) {\n\tauth := service.GetSessionMember(r)\n\t// get all team, company and department to select\n\tallTeams := model.GetAllTeam()\n\tcompanies := model.GetAllCompany()\n\tdepartments := model.GetAllDepartment()\n\tmember := model.Member{}\n\n\ttemplateData := map[string]interface{}{\n\t\t\"allTeams\": allTeams.List,\n\t\t\"companies\": companies,\n\t\t\"departments\": departments,\n\t\t\"member\": member,\n\t\t\"defaultGender\": setting.MaleGenderType,\n\t\t\"title\": \"Add Member\",\n\t\t\"auth\": auth,\n\t\t\"tab\": setting.MembersTab,\n\t}\n\n\ttmpl := template.Must(template.ParseFiles(\"template/admin_members/member_add.tmpl\", setting.AdminTemplate))\n\tif err := tmpl.ExecuteTemplate(w, \"base\", templateData); err != nil {\n\t\tLogger.Error(err.Error())\n\t}\n}", "func (l LinkedList) Display() string {\n\ts := make([]string, l.Size)\n\tcurrentNode := l.Head\n\n\tfor i := 0; i < l.Size; i++ {\n\t\ts[i] = fmt.Sprintf(\"%v\", currentNode.Data)\n\t\tcurrentNode = currentNode.Next\n\t}\n\n\treturn strings.Join(s, \", \")\n}", "func AddToMountedList(nbd, img string) {\n\tMountedList[nbd] = img\n\tfor key, value := range AvailableList {\n\t\tif value == nbd {\n\t\t\tAvailableList[key] = \"\"\n\t\t\tbreak\n\t\t}\n\t}\n}", "func (c *Dg) ShowList() ([]string, error) {\n c.con.LogQuery(\"(show) list of device groups\")\n path := c.xpath(nil)\n return c.con.EntryListUsing(c.con.Show, path[:len(path) - 1])\n}", "func (u *User) display() {\n\tif err := u.GqlClient.Query(u.Context, &user, nil); err != nil {\n\t\t_, _ = fmt.Fprint(u, \"[::b]an error occurred while retrieving user data\")\n\t\treturn\n\t}\n\n\tbio := user.Viewer.Bio\n\tr := regexp.MustCompile(`([@A-Z])\\b\\w+`)\n\tbio = r.ReplaceAllStringFunc(bio, func(s string) string {\n\t\treturn \"[::b]\" + s + \"[::-]\"\n\t})\n\n\t_, _ = fmt.Fprintf(u, formatText(\"\", user.Viewer.Name, \"[::b]\", \"\\n\"))\n\t_, _ = fmt.Fprintf(u, formatText(\"\", user.Viewer.Login, \"[gray::d]\", \"\\n\\n\"))\n\t_, _ = fmt.Fprintf(u, formatText(\"\", bio, \"\", \"\\n\\n\"))\n\t_, _ = fmt.Fprintf(u, formatText(\"\\U0001F465\", user.Viewer.Company, \"[::b]\", \"\\n\\n\"))\n\t_, _ = fmt.Fprintf(u, formatText(\"\\U0001F4CD\", user.Viewer.Location, \"\", \"\\n\\n\"))\n\t_, _ = fmt.Fprintf(u, formatText(\"\\u2709\", user.Viewer.Email, \"\", \"\\n\\n\"))\n\t_, _ = fmt.Fprintf(u, formatText(\"\\U0001F517\", user.Viewer.WebsiteUrl, \"\", \"\\n\\n\"))\n\tif user.Viewer.IsDeveloperProgramMember {\n\t\t_, _ = fmt.Fprintln(u, \"[::b]Developer Program Member\")\n\t}\n}", "func addList() {\n\tcmd := &cobra.Command{\n\t\tUse: \"list\",\n\t\tShort: \"Retrieves a list of all available Set names.\",\n\t\tLong: listLong,\n\t\tRunE: runList,\n\t}\n\tqueryCmd.AddCommand(cmd)\n}", "func NewList(list uint32, mode uint32) {\n C.glowNewList(gpNewList, (C.GLuint)(list), (C.GLenum)(mode))\n}", "func assignToLists(desktopID, categories string) {\n\tcats := strings.Split(categories, \";\")\n\tassigned := false\n\tfor _, cat := range cats {\n\t\tif cat == \"Utility\" && !isIn(listUtility, desktopID) {\n\t\t\tlistUtility = append(listUtility, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif cat == \"Development\" && !isIn(listDevelopment, desktopID) {\n\t\t\tlistDevelopment = append(listDevelopment, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif cat == \"Game\" && !isIn(listGame, desktopID) {\n\t\t\tlistGame = append(listGame, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif cat == \"Graphics\" && !isIn(listGraphics, desktopID) {\n\t\t\tlistGraphics = append(listGraphics, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif cat == \"Network\" && !isIn(listInternetAndNetwork, desktopID) {\n\t\t\tlistInternetAndNetwork = append(listInternetAndNetwork, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif isIn([]string{\"Office\", \"Science\", \"Education\"}, cat) && !isIn(listOffice, desktopID) {\n\t\t\tlistOffice = append(listOffice, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif isIn([]string{\"AudioVideo\", \"Audio\", \"Video\"}, cat) && !isIn(listAudioVideo, desktopID) {\n\t\t\tlistAudioVideo = append(listAudioVideo, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t\tif isIn([]string{\"Settings\", \"System\", \"DesktopSettings\", \"PackageManager\"}, cat) && !isIn(listSystemTools, desktopID) {\n\t\t\tlistSystemTools = append(listSystemTools, desktopID)\n\t\t\tassigned = true\n\t\t\tcontinue\n\t\t}\n\t}\n\tif categories != \"\" && !assigned && !isIn(listOther, desktopID) {\n\t\tlistOther = append(listOther, desktopID)\n\t}\n}", "func mergeDisplayTasks(current DisplayTask, toMerge DisplayTask) DisplayTask {\n\tfor _, et := range toMerge.ExecTasks {\n\t\tif !utility.StringSliceContains(current.ExecTasks, et) {\n\t\t\tcurrent.ExecTasks = append(current.ExecTasks, et)\n\t\t}\n\t}\n\treturn current\n}", "func createList(arg string) []string {\n\tvar retObject = []string{arg}\n\treturn retObject\n}", "func addList() {\n\tcmd := &cobra.Command{\n\t\tUse: \"list\",\n\t\tShort: \"Retrieves a list of all available Set names.\",\n\t\tLong: listLong,\n\t\tRun: runList,\n\t}\n\tqueryCmd.AddCommand(cmd)\n}", "func (c *CreateListCommand) Execute(w io.Writer, s Storage) {\n\n\tlist := make(map[string][]map[string]string, 1)\n\n\tlist[c.List] = make([]map[string]string, 0)\n\n\ts.Lists = append(s.Lists, list)\n\n\t//Persist our data back.\n\ts.Save()\n\n\t//Notify the user.\n\tfmt.Fprintf(w, \"List '%v' successfully Created!\\n\", c.List)\n\n}", "func (l *SList) Buffer() ui.Buffer {\n\tlselect := len(l.SelectableItems)\n\n\tif l.Selected >= lselect {\n\t\tl.Selected = lselect - 1\n\t}\n\tif l.Selected < 0 {\n\t\tl.Selected = 0\n\t}\n\n\tl.List.Items = make([]string, lselect)\n\tfor i, item := range l.SelectableItems {\n\t\tif i == l.Selected {\n\t\t\tl.Items[i] = \"[\" + item + \"](fg-white,bg-green)\"\n\t\t} else {\n\t\t\tl.Items[i] = item\n\t\t}\n\t}\n\treturn l.List.Buffer()\n}", "func newList(rowType reflect.Type) []*Info {\n\tvar list columnList\n\tvar state = stateT{}\n\tlist.addFields(rowType, state)\n\treturn list\n}", "func DisplayProviders(verbose bool) string {\n\tnames := ProviderNames(verbose)\n\n\treturn fmt.Sprintf(\"%s\\n\", strings.Join(names, \"\\n\"))\n}", "func newList(vert bool, width, height float32) *List {\n\n\tli := new(List)\n\tli.initialize(vert, width, height)\n\treturn li\n}", "func (u Universe) Show() {\n\tfor _, row := range u {\n\t\tfor _, column := range row {\n\t\t\tif column {\n\t\t\t\tfmt.Print(\"*\")\n\t\t\t} else {\n\t\t\t\tfmt.Print(\" \")\n\t\t\t}\n\t\t}\n\t\tfmt.Println()\n\t}\n}", "func (m *RemoteAssistancePartner) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func displayNotes(notes jot.Notes) {\n\tfor i := 0; i < len(notes.Notes); i++ {\n\t\tdisplayNote(notes.Notes[i])\n\t}\n}", "func NewFzDisplayList() *FzDisplayList {\n\treturn (*FzDisplayList)(allocFzDisplayListMemory(1))\n}", "func createGenreList(m *Manga, c2 *colly.Collector) {\n\n\tc2.OnHTML(\"tr:nth-child(4) .table-value a.a-h\", func(h *colly.HTMLElement) {\n\t\tg := Genre{}\n\n\t\tg.getID(h.Attr(\"href\"))\n\t\tg.GenreName = h.Text\n\n\t\tm.Genres = append(m.Genres, g)\n\t})\n}", "func (l *LargeSizeChar) Display() {\n\t// ˅\n\tfmt.Println(l.displayData)\n\t// ˄\n}", "func (o SparseRenderTemplatesList) List() elemental.IdentifiablesList {\n\n\tout := make(elemental.IdentifiablesList, len(o))\n\tfor i := 0; i < len(o); i++ {\n\t\tout[i] = o[i]\n\t}\n\n\treturn out\n}", "func (m *WorkforceIntegration) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func AdminList(w http.ResponseWriter, data interface{}) {\n\trender(tpAdminList, w, data)\n}", "func (e *DefaultExecutor) makeFiltersList() string {\n\tbuf := new(bytes.Buffer)\n\tw := tabwriter.NewWriter(buf, 5, 0, 1, ' ', 0)\n\n\tfmt.Fprintln(w, \"FILTER\\tENABLED\\tDESCRIPTION\")\n\tfor _, filter := range e.filterEngine.RegisteredFilters() {\n\t\tfmt.Fprintf(w, \"%s\\t%v\\t%s\\n\", filter.Name(), filter.Enabled, filter.Describe())\n\t}\n\n\tw.Flush()\n\treturn buf.String()\n}", "func (m *List) SetList(value ListInfoable)() {\n m.list = value\n}", "func (m *List) GetDisplayName()(*string) {\n return m.displayName\n}", "func displayDesc(avl *avlTreeNode) []int {\n\treturn appendValues2([]int{}, avl)\n}", "func (g *Game) Display() string {\n\tdisplay := \"\"\n\tfor i, pos := range boardPositions {\n\t\tif i%3 == 0 {\n\t\t\tdisplay = fmt.Sprintf(\"%s\\n%s\", display, g.Board[pos])\n\t\t} else {\n\t\t\tdisplay = fmt.Sprintf(\"%s | %s\", display, g.Board[pos])\n\t\t}\n\t}\n\treturn display\n}", "func (m *AccessPackageCatalog) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func (m *PrintConnector) SetDisplayName(value *string)() {\n err := m.GetBackingStore().Set(\"displayName\", value)\n if err != nil {\n panic(err)\n }\n}", "func NewDisplay(chip gpio.Chip, rs, e, db4, db5, db6, db7 int) (*Display, error) {\n\tlineRS := gpio.NewHandleRequest([]int{rs}, gpio.HandleRequestOutput).WithConsumer(\"weh001602a-rs\").WithDefaults([]int{0})\n\tif err := chip.RequestLines(lineRS); err != nil {\n\t\treturn nil, err\n\t}\n\n\tlineE := gpio.NewHandleRequest([]int{e}, gpio.HandleRequestOutput).WithConsumer(\"weh001602a-e\").WithDefaults([]int{0})\n\tif err := chip.RequestLines(lineE); err != nil {\n\t\treturn nil, err\n\t}\n\n\tlinesDB := gpio.NewHandleRequest([]int{db4, db5, db6, db7}, gpio.HandleRequestOutput).WithConsumer(\"weh001602a-db4567\").WithDefaults([]int{0, 0, 0, 0})\n\tif err := chip.RequestLines(linesDB); err != nil {\n\t\treturn nil, err\n\t}\n\n\td := Display{rs: lineRS, e: lineE, db4567: linesDB}\n\terr := d.initialize()\n\treturn &d, err\n}", "func newCheckDisplay() *checkDisplay {\n\tp := &checkDisplay{}\n\treturn p\n}", "func mkEmptylist() *udoc {\n\tlinks := udata{\n\t\tID: \"links\",\n\t\tData: []udata{\n\t\t\tudata{ID: \"alps\",\n\t\t\t\tRel: []string{\"profile\"},\n\t\t\t\tURL: \"/tasks-alps.xml\",\n\t\t\t\tAction: \"read\",\n\t\t\t\tData: []udata{}},\n\t\t\tudata{ID: \"list\",\n\t\t\t\tName: \"links\",\n\t\t\t\tRel: []string{\"collection\"},\n\t\t\t\tURL: \"/tasks/\",\n\t\t\t\tAction: \"read\",\n\t\t\t\tData: []udata{}},\n\t\t\tudata{ID: \"search\",\n\t\t\t\tName: \"links\",\n\t\t\t\tRel: []string{\"search\"},\n\t\t\t\tURL: \"/tasks/search\",\n\t\t\t\tAction: \"read\",\n\t\t\t\tModel: \"?text={text}\",\n\t\t\t\tData: []udata{}},\n\t\t\tudata{ID: \"add\",\n\t\t\t\tName: \"links\",\n\t\t\t\tRel: []string{\"add\"},\n\t\t\t\tURL: \"/tasks/\",\n\t\t\t\tAction: \"append\",\n\t\t\t\tModel: \"text={text}\",\n\t\t\t\tData: []udata{}}}}\n\n\treturn &udoc{ubody{Version: \"1.0\", Data: []udata{links, udata{ID: \"tasks\", Data: []udata{}}}, Error: []udata{}}}\n}", "func Display(tally hangman.Tally) {\n\tfmt.Printf(\"\\n%10s: %s\\n\", \"Letters\", tally.Letters)\n\tfmt.Printf(\"%10s: %s [%d]\\n\", \"Status\", statusToH(tally.Status), tally.TurnsLeft)\n}", "func New(name string, options []string) *List {\n\tlist := &List{}\n\n\tlist.name = name\n\tlist.options = options\n\tlist.Index = 0\n\n\tlist.Cursor = &curse.Cursor{}\n\n\tlist.SetColors(DefaultColors)\n\tlist.SetPrint(fmt.Print)\n\tlist.SetChooser(\" ❯ \")\n\tlist.SetIndent(3)\n\n\treturn list\n}", "func (e *Election) AddDisplay(global *Display) *Display {\n\te.Display = NewDisplay(e, global)\n\treturn e.Display\n}", "func (d *Driver) Display() error {\n\tbuff := make([]byte, d.Drivers*2)\n\n\tfor r := 0; r < 8; r++ {\n\t\trowNo := r + 1\n\t\tfor i := 0; i < d.Drivers; i++ {\n\t\t\tbuffIdx := d.Drivers*i + r\n\t\t\toutIdx := (d.Drivers - i - 1) * 2\n\t\t\tbuff[outIdx] = byte(rowNo)\n\t\t\tbuff[outIdx+1] = d.buff[buffIdx]\n\t\t}\n\n\t\tif err := d.dev.Tx(buff, nil); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (c *Variable) ShowList(tmpl, ts string) ([]string, error) {\n c.con.LogQuery(\"(show) list of template variables\")\n path := c.xpath(tmpl, ts, nil)\n return c.con.EntryListUsing(c.con.Show, path[:len(path) - 1])\n}", "func sprintDisplay(chip *CHIP8) string {\n\n\tvar b strings.Builder\n\n\tfor i := range chip.Display {\n\t\tif (i*8)%chip.Cfg.ResolutionX == 0 {\n\t\t\tfmt.Fprintf(&b, \"\\n\")\n\t\t}\n\t\tfmt.Fprintf(&b, \"%08b \", chip.Display[i])\n\t}\n\tfmt.Fprintf(&b, \"\\n\")\n\n\treturn b.String()\n}", "func (m *EducationAssignment) SetDisplayName(value *string)() {\n m.displayName = value\n}", "func List(g *types.Cmd) {\n\tg.AddOptions(\"list\")\n}", "func AdminList(w http.ResponseWriter, data *AdminListData) {\n\trender(tpAdminList, w, data)\n}", "func ShowList(selfMember *MemberID, memberList *[]MemberID) {\n\tfmt.Println(\"You are:\")\n\tfmt.Println(*selfMember)\n\n\tfmt.Println(\"And this is your membership list:\")\n\tfor _, Member := range *memberList {\n\t\tfmt.Println(Member)\n\t}\n\tfmt.Println()\n}" ]
[ "0.63825405", "0.6013778", "0.5855815", "0.5609792", "0.54711187", "0.541456", "0.5395596", "0.53566885", "0.527666", "0.5263921", "0.52556235", "0.5244852", "0.51780784", "0.5148643", "0.5061043", "0.50426114", "0.5038283", "0.5013533", "0.5011656", "0.49866888", "0.49732983", "0.49639916", "0.49597794", "0.4950122", "0.49486834", "0.49316958", "0.49178934", "0.4891293", "0.48893005", "0.4880107", "0.48636806", "0.48628396", "0.48534617", "0.48516718", "0.48496154", "0.48439464", "0.48320255", "0.4831989", "0.4819943", "0.48155484", "0.4811063", "0.4806674", "0.48030415", "0.47955826", "0.479475", "0.47884455", "0.4781422", "0.47726968", "0.475707", "0.475096", "0.4744761", "0.4740782", "0.47394413", "0.47373343", "0.4731941", "0.47291595", "0.47273794", "0.47197762", "0.46941757", "0.46852538", "0.46675515", "0.46607172", "0.4659787", "0.4659", "0.4657656", "0.4657655", "0.4651025", "0.46491504", "0.46467468", "0.4640655", "0.46385252", "0.46379375", "0.4637262", "0.46331266", "0.4632155", "0.4628862", "0.46196172", "0.46007475", "0.4600311", "0.45961377", "0.4594289", "0.45880488", "0.45880082", "0.45803514", "0.45791933", "0.45788166", "0.4566898", "0.45590588", "0.4551289", "0.4548432", "0.45406306", "0.4534776", "0.45332435", "0.4533046", "0.45284632", "0.45267522", "0.45261055", "0.4523054", "0.45228192", "0.45207295", "0.4518137" ]
0.0
-1
define an array of normals
func NormalPointer(xtype uint32, stride int32, pointer unsafe.Pointer) { C.glowNormalPointer(gpNormalPointer, (C.GLenum)(xtype), (C.GLsizei)(stride), pointer) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func Normal(a [100][100]float64, b [100]float64, m int32) {\n\tvar i, j int32\n\tvar big float64\n\n\tfor i = 0; i < m; i++ {\n\t\tbig = 0.0\n\n\t\tfor j = 0; j < m; j++ {\n\t\t\tif big < math.Abs(a[i][j]) {\n\t\t\t\tbig = math.Abs(a[i][j])\n\t\t\t}\n\t\t}\n\n\t\tfor j = 0; j < m; j++ {\n\t\t\ta[i][j] = a[i][j] / big\n\t\t}\n\n\t\tb[i] = b[i] / big\n\t}\n}", "func (m *Mesh) VertexNormals() *CoordMap[Coord3D] {\n\tsums := NewCoordMap[Coord3D]()\n\tm.Iterate(func(t *Triangle) {\n\t\tedges := [3]Coord3D{\n\t\t\tt[0].Sub(t[1]).Normalize(),\n\t\t\tt[1].Sub(t[2]).Normalize(),\n\t\t\tt[2].Sub(t[0]).Normalize(),\n\t\t}\n\t\tnormal := t.Normal()\n\t\tfor i, c := range t {\n\t\t\te1 := edges[(i+2)%3]\n\t\t\te2 := edges[i]\n\t\t\ttheta := math.Acos(math.Max(-1.0, math.Min(1.0, -e1.Dot(e2))))\n\t\t\tcur, _ := sums.Load(c)\n\t\t\tsums.Store(c, cur.Add(normal.Scale(theta)))\n\t\t}\n\t})\n\tnormalized := NewCoordMap[Coord3D]()\n\tsums.Range(func(k, v Coord3D) bool {\n\t\tnormalized.Store(k, v.Normalize())\n\t\treturn true\n\t})\n\treturn normalized\n}", "func (m *Mesh) RepairNormals(epsilon float64) (*Mesh, int) {\n\tcollider := MeshToCollider(m)\n\tsolid := NewColliderSolid(collider)\n\tnumFlipped := 0\n\tnewMesh := NewMesh()\n\n\tm.Iterate(func(t *Triangle) {\n\t\tt1 := *t\n\t\tnormal := t.Normal()\n\t\tcenter := t[0].Add(t[1]).Add(t[2]).Scale(1.0 / 3)\n\t\tmovedOut := center.Add(normal.Scale(epsilon))\n\t\tif solid.Contains(movedOut) {\n\t\t\tnumFlipped++\n\t\t\tt1[0], t1[1] = t1[1], t1[0]\n\t\t}\n\t\tnewMesh.Add(&t1)\n\t})\n\treturn newMesh, numFlipped\n}", "func (u Vec) Normal() Vec {\n\treturn Vec{-u.Y, u.X}\n}", "func NormalExtrude(p V3) V2 {\n\treturn V2{p.X, p.Y}\n}", "func (cp *CCollisionPoly) NormalAxes() []pixel.Vec {\n\tvar normals []pixel.Vec\n\tfor _, ed := range cp.UniqueEdges {\n\t\tangle := ed.pointA.Sub(*ed.pointB).Angle() + math.Pi/2\n\t\tnormal := pixel.Unit(angle)\n\t\tnormals = append(normals, normal)\n\t}\n\treturn normals\n}", "func (s Sphere) Normal(p vector.Vec4) vector.Vec4 {\n\treturn vector.Subtract(&s.origin, &p)\n}", "func (rng RandomGenerator) MakeNormalVector(size int, mean, stdDev float64) []float64 {\n\tret := make([]float64, size)\n\tfor i := 0; i < len(ret); i++ {\n\t\tret[i] = rng.NormFloat64()*stdDev + mean\n\t}\n\treturn ret\n}", "func NewNormal(lb int64, ub int64) *Normal {\n\treturn &Normal{\n\t\tImpl: distuv.Normal{\n\t\t\tMu: float64(lb + ub/2), // Mean of the normal distribution\n\t\t\tSigma: NormalSigma, // Standard deviation of the normal distribution\n\t\t},\n\t}\n}", "func NewNormalizer() *Normalizer { return &Normalizer{Norm: \"l2\", Axis: 1} }", "func (tri *Triangle) RecalculateNormal() {\n\ttri.Normal = calculateNormal(tri.Vertices[0].Position, tri.Vertices[1].Position, tri.Vertices[2].Position)\n}", "func (controller *Controller) parseNormalsFromMap(objectData map[string]interface{}) ([]*vector.Vector, error) {\n\terrorMessage := \"unable to parse normals\"\n\n\tnormalsInterface, found := objectData[\"normals\"]\n\tif !found {\n\t\treturn nil, errors.New(errorMessage)\n\t}\n\tnormalsInterfaceList, parsed := normalsInterface.([]interface{})\n\tif !parsed {\n\t\treturn nil, errors.New(errorMessage)\n\t}\n\n\tnormals := make([]*vector.Vector, len(normalsInterfaceList))\n\tfor normalIndex := 0; normalIndex < len(normalsInterfaceList); normalIndex++ {\n\t\tnormalMap, parsed := normalsInterfaceList[normalIndex].(map[string]interface{})\n\t\tif !parsed {\n\t\t\treturn nil, errors.New(errorMessage)\n\t\t}\n\t\tcurrentNormal, err := controller.parseVectorFromMap(normalMap)\n\t\tif err != nil {\n\t\t\treturn nil, errors.New(errorMessage)\n\t\t}\n\t\tnormals[normalIndex] = currentNormal\n\t}\n\n\treturn normals, nil\n}", "func (a *Vector3) Normalise() {\n\tl := a.Length()\n\t*a = Vector3{a.X / l, a.Y / l, a.Z / l}\n}", "func parseNormal(line string) Vector3 {\n\tvar x, y, z float64\n\t_, err := fmt.Sscanf(line, \"vn %f %f %f\", &x, &y, &z)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\treturn Vector3{x, y, z}\n}", "func DirtoArr(direction string) []float64 {\n\tswitch direction {\n\tcase \"north\":\n\t\treturn []float64{1, 0}\n\tcase \"east\":\n\t\treturn []float64{0, 1}\n\tcase \"west\":\n\t\treturn []float64{-1, 0}\n\tcase \"south\":\n\t\treturn []float64{-1, 0}\n\tdefault:\n\t\treturn []float64{1, 0}\n\t}\n}", "func RandNormalVector(r *rand.Rand, mean, std []float64) []float64 {\n\n\tif len(mean) != len(std) {\n\t\tpanic(fmt.Errorf(\"Cannot generate random vectors because length of mean [%d] and std [%d] don't match.\",\n\t\t\tlen(mean), len(std)))\n\t}\n\tvector := make([]float64, len(mean))\n\tfor i, _ := range mean {\n\t\tv := r.NormFloat64()*std[i] + mean[i]\n\t\tvector[i] = v\n\t}\n\n\treturn vector\n}", "func (gdt *Vector3) Normalized() Vector3 {\n\targ0 := gdt.getBase()\n\n\tret := C.go_godot_vector3_normalized(GDNative.api, arg0)\n\n\treturn Vector3{base: &ret}\n\n}", "func (n *NormalProposer) Probs(values ...float64) []float64 {\n\tres := make([]float64, len(values))\n\tfor i, v := range values {\n\t\tres[i] = n.Pdf(v)\n\t}\n\treturn res\n}", "func NewNormalizer() *Normalizer {\n\treturn &Normalizer{\n\t\ttrans: transform.Chain(norm.NFD, runes.Remove(mn), norm.NFC),\n\t}\n}", "func (n Notes) Normalized() Notes {\n\tnotes := make(Notes, 0)\n\tfor _, v := range n {\n\t\tnotes = append(notes, v.Normalize())\n\t}\n\n\treturn notes\n}", "func normalize(f *dump.Frame) {\n\ta := f.Vectors()\n\tfor i := range a[0] {\n\n\t\tfor j := range a[0][i] {\n\n\t\t\tfor k := range a[0][i][j] {\n\t\t\t\tx, y, z := a[0][i][j][k], a[1][i][j][k], a[2][i][j][k]\n\t\t\t\tnorm := math.Sqrt(float64(x*x + y*y + z*z))\n\t\t\t\tinvnorm := float32(1)\n\t\t\t\tif norm != 0 {\n\t\t\t\t\tinvnorm = float32(1 / norm)\n\t\t\t\t}\n\t\t\t\ta[0][i][j][k] *= invnorm\n\t\t\t\ta[1][i][j][k] *= invnorm\n\t\t\t\ta[2][i][j][k] *= invnorm\n\n\t\t\t}\n\t\t}\n\t}\n}", "func NewNormal(mu []float64, sigma mat64.Symmetric, src *rand.Rand) (*Normal, bool) {\n\tif len(mu) == 0 {\n\t\tpanic(badZeroDimension)\n\t}\n\tdim := sigma.Symmetric()\n\tif dim != len(mu) {\n\t\tpanic(badSizeMismatch)\n\t}\n\tn := &Normal{\n\t\tsrc: src,\n\t\tdim: dim,\n\t\tmu: make([]float64, dim),\n\t\tsigma: mat64.NewSymDense(dim, nil),\n\t\tchol: mat64.NewTriDense(dim, true, nil),\n\t}\n\tcopy(n.mu, mu)\n\tn.sigma.CopySym(sigma)\n\t// TODO(btracey): Change this to the input Sigma, in case it is diagonal or\n\t// banded.\n\tok := n.chol.Cholesky(n.sigma, true)\n\tif !ok {\n\t\treturn nil, false\n\t}\n\tfor i := 0; i < dim; i++ {\n\t\tn.logSqrtDet += math.Log(n.chol.At(i, i))\n\t}\n\treturn n, true\n}", "func (n *LogNormalProposer) Probs(values ...float64) []float64 {\n\tres := make([]float64, len(values))\n\tfor i, v := range values {\n\t\tres[i] = n.Pdf(v)\n\t}\n\treturn res\n}", "func (o *Grid) UnitNormal(N la.Vector, tag, I int) {\n\tfor i := 0; i < o.ndim; i++ {\n\t\tN[i] = 0.0\n\t}\n\tm, n, p := o.IndexItoMNP(I)\n\tvar sum float64\n\tif o.ndim == 2 { // set N set as the relevant contravariant vector pointing outwards\n\t\tswitch tag {\n\t\tcase 10:\n\t\t\tfor i := 0; i < 2; i++ {\n\t\t\t\tN[i] = -o.mtr[p][n][m].CntG0[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 11:\n\t\t\tfor i := 0; i < 2; i++ {\n\t\t\t\tN[i] = o.mtr[p][n][m].CntG0[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 20:\n\t\t\tfor i := 0; i < 2; i++ {\n\t\t\t\tN[i] = -o.mtr[p][n][m].CntG1[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 21:\n\t\t\tfor i := 0; i < 2; i++ {\n\t\t\t\tN[i] = o.mtr[p][n][m].CntG1[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\t}\n\t} else {\n\t\tswitch tag { // set N as the relevant contravariant vector pointing outwards\n\t\tcase 100:\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\tN[i] = -o.mtr[p][n][m].CntG0[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 101:\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\tN[i] = o.mtr[p][n][m].CntG0[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 200:\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\tN[i] = -o.mtr[p][n][m].CntG1[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 201:\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\tN[i] = o.mtr[p][n][m].CntG1[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 300:\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\tN[i] = -o.mtr[p][n][m].CntG2[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\tcase 301:\n\t\t\tfor i := 0; i < 3; i++ {\n\t\t\t\tN[i] = o.mtr[p][n][m].CntG2[i]\n\t\t\t\tsum += N[i] * N[i]\n\t\t\t}\n\t\t}\n\t}\n\tif sum > 0 { // normalize\n\t\tfor i := 0; i < o.ndim; i++ {\n\t\t\tN[i] /= math.Sqrt(sum)\n\t\t}\n\t}\n}", "func (v Vec3) Normalized() Vec3 {\n\tf := 1.0 / v.Norm()\n\treturn Vec3{f * v[0], f * v[1], f * v[2]}\n}", "func (rng RandomGenerator) MakeNormalMatrix(row, col int, mean, stdDev float64) [][]float64 {\n\tret := make([][]float64, row)\n\tfor i := range ret {\n\t\tret[i] = rng.MakeNormalVector(col, mean, stdDev)\n\t}\n\treturn ret\n}", "func (etf *Etf) normalize(x, y, z float32) gocv.Vecf {\n\tnv := float32(math.Sqrt(float64(x*x) + float64(y*y) + float64(z*z)))\n\n\tif nv > 0.0 {\n\t\treturn gocv.Vecf{x * 1.0 / nv, y * 1.0 / nv, z * 1.0 / nv}\n\t}\n\treturn gocv.Vecf{0.0, 0.0, 0.0}\n}", "func (s *Sphere) NormalAt(p Vector) Vector {\n\treturn p.Minus(s.Center).Normalize()\n}", "func (a Vec4) Normalized() Vec4 {\n\tlength := math.Sqrt(a.X*a.X + a.Y*a.Y + a.Z*a.Z + a.W*a.W)\n\treturn Vec4{a.X / length, a.Y / length, a.Z / length, a.W / length}\n}", "func Mat3NormalFromMat4(out, a []float64) []float64 {\n\ta00 := a[0]\n\ta01 := a[1]\n\ta02 := a[2]\n\ta03 := a[3]\n\ta10 := a[4]\n\ta11 := a[5]\n\ta12 := a[6]\n\ta13 := a[7]\n\ta20 := a[8]\n\ta21 := a[9]\n\ta22 := a[10]\n\ta23 := a[11]\n\ta30 := a[12]\n\ta31 := a[13]\n\ta32 := a[14]\n\ta33 := a[15]\n\n\tb00 := a00*a11 - a01*a10\n\tb01 := a00*a12 - a02*a10\n\tb02 := a00*a13 - a03*a10\n\tb03 := a01*a12 - a02*a11\n\tb04 := a01*a13 - a03*a11\n\tb05 := a02*a13 - a03*a12\n\tb06 := a20*a31 - a21*a30\n\tb07 := a20*a32 - a22*a30\n\tb08 := a20*a33 - a23*a30\n\tb09 := a21*a32 - a22*a31\n\tb10 := a21*a33 - a23*a31\n\tb11 := a22*a33 - a23*a32\n\n\t// Calculate the determinant\n\tdet := b00*b11 - b01*b10 + b02*b09 + b03*b08 - b04*b07 + b05*b06\n\n\tif det == 0. {\n\t\treturn nil\n\t}\n\tdet = 1.0 / det\n\n\tout[0] = (a11*b11 - a12*b10 + a13*b09) * det\n\tout[1] = (a12*b08 - a10*b11 - a13*b07) * det\n\tout[2] = (a10*b10 - a11*b08 + a13*b06) * det\n\n\tout[3] = (a02*b10 - a01*b11 - a03*b09) * det\n\tout[4] = (a00*b11 - a02*b08 + a03*b07) * det\n\tout[5] = (a01*b08 - a00*b10 - a03*b06) * det\n\n\tout[6] = (a31*b05 - a32*b04 + a33*b03) * det\n\tout[7] = (a32*b02 - a30*b05 - a33*b01) * det\n\tout[8] = (a30*b04 - a31*b02 + a33*b00) * det\n\n\treturn out\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 Norm(r *rand.Rand, mean, sd float32, shape ...int) *NArray {\n\n\tna := New(shape...)\n\tfor i := range na.Data {\n\t\tna.Data[i] = float32(r.NormFloat64())*sd + mean\n\t}\n\treturn na\n}", "func Magnitude(r [3]float64) float64 {\n return math.Abs(math.Sqrt(r[1]*r[1] + r[2]*r[2] + r[0]*r[0]))\n}", "func (t *Triangle) NormalSDF(c Coord) (Coord, float64) {\n\tvar n Coord\n\tres := t.genericSDF(c, &n, nil, nil)\n\treturn n, res\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 normalizeAnchors(a [1][][4]float32, imageBounds image.Rectangle) {\n\tfor i := range a[0] {\n\t\ta[0][i][0] = a[0][i][0] / float32(imageBounds.Dy())\n\t\ta[0][i][1] = a[0][i][1] / float32(imageBounds.Dx())\n\t\ta[0][i][2] = (a[0][i][2] - 1) / float32(imageBounds.Dy())\n\t\ta[0][i][3] = (a[0][i][3] - 1) / float32(imageBounds.Dx())\n\t}\n}", "func DenormalizeRGB(v [3]uint8) [3]float32 {\n\treturn [3]float32{\n\t\tlinearize(float32(v[0]) / 255),\n\t\tlinearize(float32(v[1]) / 255),\n\t\tlinearize(float32(v[2]) / 255),\n\t}\n}", "func Normal(mean, sd float64) float64 {\n\treturn rand.NormFloat64()*sd + mean\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n C.glowGenVertexArrays(gpGenVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func Invert(m []gl.Float) ([]gl.Float, error) {\n\n\t//double inv[16], det;\n\t//int i;\n\tinv := make([]gl.Float, 16)\n\tinvOut := make([]gl.Float, 16)\n\tif len(m) != 16 {\n\t\treturn nil, errors.New(\"Not a 4x4 matrix, needs 16 elements\")\n\t}\n\n\tinv[0] = m[5]*m[10]*m[15] -\n\t\tm[5]*m[11]*m[14] -\n\t\tm[9]*m[6]*m[15] +\n\t\tm[9]*m[7]*m[14] +\n\t\tm[13]*m[6]*m[11] -\n\t\tm[13]*m[7]*m[10]\n\n\tinv[4] = -m[4]*m[10]*m[15] +\n\t\tm[4]*m[11]*m[14] +\n\t\tm[8]*m[6]*m[15] -\n\t\tm[8]*m[7]*m[14] -\n\t\tm[12]*m[6]*m[11] +\n\t\tm[12]*m[7]*m[10]\n\n\tinv[8] = m[4]*m[9]*m[15] -\n\t\tm[4]*m[11]*m[13] -\n\t\tm[8]*m[5]*m[15] +\n\t\tm[8]*m[7]*m[13] +\n\t\tm[12]*m[5]*m[11] -\n\t\tm[12]*m[7]*m[9]\n\n\tinv[12] = -m[4]*m[9]*m[14] +\n\t\tm[4]*m[10]*m[13] +\n\t\tm[8]*m[5]*m[14] -\n\t\tm[8]*m[6]*m[13] -\n\t\tm[12]*m[5]*m[10] +\n\t\tm[12]*m[6]*m[9]\n\n\tinv[1] = -m[1]*m[10]*m[15] +\n\t\tm[1]*m[11]*m[14] +\n\t\tm[9]*m[2]*m[15] -\n\t\tm[9]*m[3]*m[14] -\n\t\tm[13]*m[2]*m[11] +\n\t\tm[13]*m[3]*m[10]\n\n\tinv[5] = m[0]*m[10]*m[15] -\n\t\tm[0]*m[11]*m[14] -\n\t\tm[8]*m[2]*m[15] +\n\t\tm[8]*m[3]*m[14] +\n\t\tm[12]*m[2]*m[11] -\n\t\tm[12]*m[3]*m[10]\n\n\tinv[9] = -m[0]*m[9]*m[15] +\n\t\tm[0]*m[11]*m[13] +\n\t\tm[8]*m[1]*m[15] -\n\t\tm[8]*m[3]*m[13] -\n\t\tm[12]*m[1]*m[11] +\n\t\tm[12]*m[3]*m[9]\n\n\tinv[13] = m[0]*m[9]*m[14] -\n\t\tm[0]*m[10]*m[13] -\n\t\tm[8]*m[1]*m[14] +\n\t\tm[8]*m[2]*m[13] +\n\t\tm[12]*m[1]*m[10] -\n\t\tm[12]*m[2]*m[9]\n\n\tinv[2] = m[1]*m[6]*m[15] -\n\t\tm[1]*m[7]*m[14] -\n\t\tm[5]*m[2]*m[15] +\n\t\tm[5]*m[3]*m[14] +\n\t\tm[13]*m[2]*m[7] -\n\t\tm[13]*m[3]*m[6]\n\n\tinv[6] = -m[0]*m[6]*m[15] +\n\t\tm[0]*m[7]*m[14] +\n\t\tm[4]*m[2]*m[15] -\n\t\tm[4]*m[3]*m[14] -\n\t\tm[12]*m[2]*m[7] +\n\t\tm[12]*m[3]*m[6]\n\n\tinv[10] = m[0]*m[5]*m[15] -\n\t\tm[0]*m[7]*m[13] -\n\t\tm[4]*m[1]*m[15] +\n\t\tm[4]*m[3]*m[13] +\n\t\tm[12]*m[1]*m[7] -\n\t\tm[12]*m[3]*m[5]\n\n\tinv[14] = -m[0]*m[5]*m[14] +\n\t\tm[0]*m[6]*m[13] +\n\t\tm[4]*m[1]*m[14] -\n\t\tm[4]*m[2]*m[13] -\n\t\tm[12]*m[1]*m[6] +\n\t\tm[12]*m[2]*m[5]\n\n\tinv[3] = -m[1]*m[6]*m[11] +\n\t\tm[1]*m[7]*m[10] +\n\t\tm[5]*m[2]*m[11] -\n\t\tm[5]*m[3]*m[10] -\n\t\tm[9]*m[2]*m[7] +\n\t\tm[9]*m[3]*m[6]\n\n\tinv[7] = m[0]*m[6]*m[11] -\n\t\tm[0]*m[7]*m[10] -\n\t\tm[4]*m[2]*m[11] +\n\t\tm[4]*m[3]*m[10] +\n\t\tm[8]*m[2]*m[7] -\n\t\tm[8]*m[3]*m[6]\n\n\tinv[11] = -m[0]*m[5]*m[11] +\n\t\tm[0]*m[7]*m[9] +\n\t\tm[4]*m[1]*m[11] -\n\t\tm[4]*m[3]*m[9] -\n\t\tm[8]*m[1]*m[7] +\n\t\tm[8]*m[3]*m[5]\n\n\tinv[15] = m[0]*m[5]*m[10] -\n\t\tm[0]*m[6]*m[9] -\n\t\tm[4]*m[1]*m[10] +\n\t\tm[4]*m[2]*m[9] +\n\t\tm[8]*m[1]*m[6] -\n\t\tm[8]*m[2]*m[5]\n\n\tdet := m[0]*inv[0] + m[1]*inv[4] + m[2]*inv[8] + m[3]*inv[12]\n\n\tif det == 0 {\n\t\treturn nil, errors.New(\"No inverse for this matrix!\")\n\t}\n\n\tdet = 1.0 / det\n\n\tfor i := 0; i < 16; i++ {\n\t\tinvOut[i] = inv[i] * det\n\t}\n\n\treturn invOut, nil\n}", "func Ones(m, n int) *Matrix {\n\tA := Zeros(m, n)\n\tfor i := range(A.data) {\n\t\tA.data[i] = 1.0\n\t}\n\treturn A\n}", "func NewMesh(name string, verts ...*Vertex) *Mesh {\n\n\tmesh := &Mesh{\n\t\tName: name,\n\t\tVertices: []*Vertex{},\n\t\tsortedVertices: []*Vertex{},\n\t\tTriangles: []*Triangle{},\n\t\tFilterMode: ebiten.FilterNearest,\n\t\tDimensions: Dimensions{{0, 0, 0}, {0, 0, 0}},\n\t}\n\n\tif len(verts) == 0 || len(verts)%3 != 0 {\n\t\tpanic(\"Error: NewMesh() has not been given a correct number of vertices to constitute triangles (it needs to be greater than 0 and divisible by 3).\")\n\t}\n\n\tmesh.AddTriangles(verts...)\n\tmesh.UpdateBounds()\n\treturn mesh\n\n}", "func (v Vec) Normalized() Vec {\n\treturn v.Copy().Normalize()\n}", "func normalize(vals []float64) {\n\tvar mean float64\n\tallEqual := true\n\tfor _, x := range vals {\n\t\tif x != vals[0] {\n\t\t\tallEqual = false\n\t\t}\n\t\tmean += x\n\t}\n\n\tif allEqual {\n\t\tfor i := range vals {\n\t\t\tvals[i] = 0\n\t\t}\n\t\treturn\n\t}\n\n\tmean /= float64(len(vals))\n\n\tvar variance float64\n\tfor _, x := range vals {\n\t\tdiff := x - mean\n\t\tvariance += diff * diff\n\t}\n\tvariance /= float64(len(vals))\n\n\tscale := 1 / math.Sqrt(variance)\n\tfor i, x := range vals {\n\t\tvals[i] = (x - mean) * scale\n\t}\n}", "func (m mathUtil) Normalize(values ...float64) []float64 {\n\tvar total float64\n\tfor _, v := range values {\n\t\ttotal += v\n\t}\n\toutput := make([]float64, len(values))\n\tfor x, v := range values {\n\t\toutput[x] = m.RoundDown(v/total, 0.0001)\n\t}\n\treturn output\n}", "func (pl *Plane) NormalAt(point *Tuple) Tuple {\n\tobNormal := Vector(0, 1, 0)\n\twNormal := pl.NormalToWorld(obNormal)\n\treturn *wNormal\n}", "func NewNormal(mean, variance float64) gostats.Distribution {\n\treturn &Normal{\n\t\tmean: mean,\n\t\tvariance: variance,\n\t\tstddev: math.Sqrt(variance),\n\t}\n}", "func NatrArr(h, l, c []float64, n int64) []float64 {\n\tout := make([]float64, len(c))\n\n\ta := NewNatr(n)\n\tfor i := 0; i < len(c); i++ {\n\t\tout[i] = a.Update(h[i], l[i], c[i])\n\t}\n\n\treturn out\n}", "func (gdt *Array) Invert() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_invert(GDNative.api, arg0)\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 Vec(s ...float64) Vector {\n\tv := make([]float64, len(s))\n\tfor i := range s {\n\t\tv[i] = s[i]\n\t}\n\treturn v\n}", "func (vn VecN) Raw() []float64 {\n\treturn vn.vec\n}", "func (model *Way) normalProbability(cor Coordinate) float64 {\n\tvar NormalMean float64\n\tvar NormalDeviation float64 = 20 //Amount of expected GPS error\n\tprojection := model.FindProjection(cor)\n\tdistanceMeter := projection.Distance * float64(distanceMeterFactor)\n\t//Normal distribution formula\n\tprobability := 1 / (math.Sqrt(2*math.Pi) * NormalDeviation) * math.Exp(-(math.Pow(distanceMeter-NormalMean, 2) / (2 * math.Pow(NormalDeviation, 2))))\n\treturn probability\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 GenVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpGenVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func initVector(n int, value float64) []float64 {\n\tx := make([]float64, n)\n\tfor i := 0; i < n; i++ {\n\t\tx[i] = value\n\t}\n\treturn x\n}", "func GetNormal(l *Line, p, out *point.Point) *point.Point {\n\tif out == nil {\n\t\tout = point.New(0, 0)\n\t}\n\n\ta := Angle(l) - phomath.TAU\n\n\tout.X = math.Cos(a)\n\tout.Y = math.Sin(a)\n\n\treturn out\n}", "func norm(t, a, b float64) float64 {\n\treturn (t - a) * (1 / (b - a))\n}", "func NewNormal(mu float64, sigma float64) (Normal, error) {\n\tif sigma <= 0 {\n\t\treturn Normal{}, errors.New(\"stats: invalid Normal parameters. Check Sigma > 0\")\n\t}\n\treturn Normal{Mu: mu, Sigma: sigma}, nil\n}", "func GenerateHemisphereDirection(normal vector.Vector3) vector.Vector3 {\n r1 := 2 * math.Pi * rand.Float64()\n r2 := rand.Float64()\n r2s := math.Sqrt(1-r2)\n\n // Compute a direction in the unit hemisphere\n x := float32(math.Cos(r1) * r2s)\n y := float32(math.Sin(r1) * r2s)\n z := float32(math.Sqrt(r2))\n\n // Compute a coordinate frame around the normal and then linearly combine\n // the basis vectors using the direction components as weights to transform\n // from unit hemisphere coordinate system to the normal's coordinate system.\n u, v, w := coordinateFrame(normal)\n t := vector.Add(vector.Scale(u, x), vector.Scale(v, y))\n return vector.Add(t, vector.Scale(w, z))\n}", "func NormalPDF(z float64) float64 {\n\treturn math.Exp(-math.Pow(z, 2)/2) / math.Sqrt(2*math.Pi)\n}", "func CreateVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpCreateVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func (n *NormalProposer) Moments(names ...string) []float64 {\n\tvar moments []float64\n\tfor _, name := range names {\n\t\tswitch name {\n\t\tcase \"Mean\":\n\t\t\tmoments = append(moments, n.Mean())\n\t\tcase \"Variance\":\n\t\t\tmoments = append(moments, n.Variance())\n\t\tcase \"Skewness\":\n\t\t\tmoments = append(moments, n.Skewness())\n\t\tcase \"Kurtosis\":\n\t\t\tmoments = append(moments, n.Kurtosis())\n\t\tcase \"StdDev\":\n\t\t\tmoments = append(moments, n.StdDev())\n\t\tcase \"RelStdDev\":\n\t\t\tmoments = append(moments, n.RelStdDev())\n\t\t}\n\t}\n\treturn moments\n}", "func (tile *Tile) normaliseEdges() {\n\tidx := 0\n\tfor i, v := range tile.sides {\n\t\tif v == 0 {\n\t\t\tidx = i\n\t\t\tbreak\n\t\t}\n\t}\n\tvar tmpSides [4]side\n\tfor i2 := range tile.sides {\n\t\ttmpSides[i2] = tile.sides[(i2+idx)%4]\n\t}\n\ttile.sides = tmpSides\n}", "func (a Ant) GetVertexesRNValue() []float64 {\n numVertex := len((*(*a.graph).vertexes))\n rnvalues := make([]float64, numVertex)\n //fmt.Printf(\"Num vertexes %d\\n\", numVertex)\n count := 0;\n for count < numVertex {\n indexVertex := (*(*a.graph).vertexes)[count].index\n pheromoneVertex := (*(*a.graph).vertexes)[count].pheromone\n weightVertex := (*a.graph).FullWeightOfVertex(indexVertex)\n rnvalues[indexVertex] = pheromoneVertex*weightVertex\n //fmt.Printf(\"Index: %d Pheromone: %f Weight: %f RN: %f\\n\", indexVertex,pheromoneVertex,weightVertex, rnvalues[indexVertex])\n count = count+1\n }\n return rnvalues\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 (b *BasicShape) NormalAt(geometry.Vector) geometry.Vector {\n\tpanic(\"NormalAt is not implemented for basic shape\")\n}", "func (m *Mesh) RepairNormalsMajority() (*Mesh, int) {\n\torientations := m.FaceOrientations()\n\tflipFlags := map[*Triangle]bool{}\n\tfor _, group := range orientations {\n\t\tnumTrue := 0\n\t\tfor _, value := range group {\n\t\t\tif value {\n\t\t\t\tnumTrue++\n\t\t\t}\n\t\t}\n\t\tinvert := numTrue > len(group)/2\n\t\tfor k, v := range group {\n\t\t\tflipFlags[k] = v == !invert\n\t\t}\n\t}\n\tres := NewMesh()\n\tvar count int\n\tm.Iterate(func(t *Triangle) {\n\t\tt1 := *t\n\t\tif flipFlags[t] {\n\t\t\tcount++\n\t\t\tt1[0], t1[1] = t1[1], t1[0]\n\t\t}\n\t\tres.Add(&t1)\n\t})\n\treturn res, count\n}", "func invert(m [][]float64) [][]float64 {\n\ta := xcopy(m)\n\tn := len(a)\n\tipvt := make([]int, n)\n\tif !lufactor(a, ipvt) {\n\t\treturn nil\n\t}\n\n\tb := make([]float64, n)\n\tinva := zeroes(n)\n\tfor i := 0; i != n; i++ {\n\t\tfor j := 0; j != n; j++ {\n\t\t\tb[j] = 0\n\t\t}\n\t\tb[i] = 1\n\t\tlusolve(a, ipvt, b)\n\t\tfor j := 0; j != n; j++ {\n\t\t\tinva[j][i] = b[j]\n\t\t}\n\t}\n\treturn inva\n}", "func (n *LogNormalProposer) LogProbs(values ...float64) []float64 {\n\tres := make([]float64, len(values))\n\tfor i, v := range values {\n\t\tres[i] = math.Log(n.Pdf(v))\n\t}\n\treturn res\n}", "func (t *Tuple) Normalize() *Tuple {\n\tmag := t.Magnitude()\n\tif mag == 0.0 {\n\t\treturn t\n\t}\n\treturn Vector(t.x/mag, t.y/mag, t.z/mag)\n\n}", "func (vn *VecN) Normalize(dst *VecN) *VecN {\n\tif vn == nil {\n\t\treturn nil\n\t}\n\n\treturn vn.Mul(dst, 1/vn.Len())\n}", "func (self *Sax) normalize(measureList []float64) []float64 {\n var err error\n if len(measureList) < 1 {\n return measureList\n }\n\n s2 := float64(1)\n m2 := float64(0)\n m1 := mean(measureList)\n if err != nil {\n panic(err)\n }\n s1 := stdDev(measureList, m1)\n if err != nil {\n panic(err)\n }\n\n stdMultiplier := (s2 / s1)\n\n for i, m := range measureList {\n measureList[i] = float64(m2 + (m - m1)) * stdMultiplier\n }\n return measureList\n}", "func PlayerNormal(userDiffs map[string][]float64) map[string][]float64 {\n\tperUser := make(map[string][]float64)\n\tfor user, diffs := range userDiffs {\n\t\tmu, sigma := stat.MeanStdDev(diffs, nil)\n\t\tperUser[user] = []float64{mu, sigma}\n\t}\n\treturn perUser\n}", "func Normalize(t Tuplelike) Tuplelike {\n\treturn Divide(t, Magnitude(t))\n}", "func LPNorm(vector []float64, p float64) (float64, error) {\n\tdistance := 0.\n\tfor _, jj := range vector {\n\t\tdistance += math.Pow(math.Abs(jj), p)\n\t}\n\treturn math.Pow(distance, 1/p), nil\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 NewStdNorm() (x *Norm){\n x = NewNorm(0.,1.)\n return\n}", "func CreateVertexArrays(n int32, arrays *uint32) {\n\tC.glowCreateVertexArrays(gpCreateVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func CreateVertexArrays(n int32, arrays *uint32) {\n\tC.glowCreateVertexArrays(gpCreateVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func initWeights(length int) []float64 {\n\n\tweights := make([]float64, length)\n\t//Inits the slice with random numbers between [-1, 1]\n\tfor index := range weights {\n\t\tw := 2*rand.Float64() - 1\n\t\tweights[index] = w\n\t}\n\treturn weights\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 (n *NormalProposer) LogProbs(values ...float64) []float64 {\n\tres := make([]float64, len(values))\n\tfor i, v := range values {\n\t\tres[i] = math.Log(n.Pdf(v))\n\t}\n\treturn res\n}", "func (o BoundingPolyOutput) Vertices() VertexArrayOutput {\n\treturn o.ApplyT(func(v BoundingPoly) []Vertex { return v.Vertices }).(VertexArrayOutput)\n}", "func NewNormalProposer(mu, sigma float64) *NormalProposer {\n\tp, _ := prob.NewNormal(mu, sigma)\n\treturn &NormalProposer{p}\n}", "func DenormalizeRGBA(v [4]uint8) [4]float32 {\n\treturn [4]float32{\n\t\tlinearize(float32(v[0]) / 255),\n\t\tlinearize(float32(v[1]) / 255),\n\t\tlinearize(float32(v[2]) / 255),\n\t\tfloat32(v[3]) / 255,\n\t}\n}", "func (v *Vector) Normalize() *Vector {\n\tl := v.Length()\n\treturn &Vector{X: v.X / l, Y: v.Y / l, Z: v.Z / l}\n}", "func (n *LogNormalProposer) Moments(names ...string) []float64 {\n\tvar moments []float64\n\tfor _, name := range names {\n\t\tswitch name {\n\t\tcase \"Mean\":\n\t\t\tmoments = append(moments, n.Mean())\n\t\tcase \"Variance\":\n\t\t\tmoments = append(moments, n.Variance())\n\t\tcase \"Skewness\":\n\t\t\tmoments = append(moments, n.Skewness())\n\t\tcase \"Kurtosis\":\n\t\t\tmoments = append(moments, n.Kurtosis())\n\t\tcase \"StdDev\":\n\t\t\tmoments = append(moments, n.StdDev())\n\t\tcase \"RelStdDev\":\n\t\t\tmoments = append(moments, n.RelStdDev())\n\t\t}\n\t}\n\treturn moments\n}", "func (r *Repo) NormalizedVersions() ([]newtutil.RepoVersion, error) {\n\tverMap := map[newtutil.RepoVersion]struct{}{}\n\n\tfor ver, _ := range r.vers {\n\t\tnver, err := r.NormalizeVersion(ver)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tverMap[nver] = struct{}{}\n\t}\n\n\tvers := make([]newtutil.RepoVersion, 0, len(verMap))\n\tfor ver, _ := range verMap {\n\t\tvers = append(vers, ver)\n\t}\n\n\treturn vers, nil\n}", "func NormalEquation(X Matrix, y Matrix)Matrix{\n\t//note: when the normal equation meets the problem of non-invertible matrix\n\t//\t\tregularized normal equation can fix it ;-)\n\t//\t\tjust put a really small number like o.ooo1 into lambda\n\n\tif y.Row != X.Row || y.Column != 1{\n\t\tpanic(\"value format error\")\n\t}\n\tXT := TransposeMatrix(X)\n\treturn MatrixMultiplication(MatrixMultiplication(InverseMatrix(MatrixMultiplication(XT, X)), XT), y)\n\n\n}", "func Uniform3FloatArray(location UniformLocation, value []float32) {\n\tgl.Uniform3fv(int32(location), 1, &value[0])\n}", "func vwap(positions ...[2]float32) float32 {\n\tvar sum, total float32\n\tfor _, x := range positions {\n\t\tsum += x[0] * x[1]\n\t\ttotal += x[0]\n\t}\n\tif total == 0 {\n\t\treturn 0\n\t}\n\treturn sum / total\n}", "func normalize(input []float64) []float64 {\n\t// gracefully handle empty inputs.\n\tif len(input) == 0 {\n\t\treturn input\n\t}\n\tmin, max := input[0], input[0]\n\tfor _, v := range input {\n\t\tif v > max {\n\t\t\tmax = v\n\t\t}\n\t\tif v < min {\n\t\t\tmin = v\n\t\t}\n\t}\n\tfor i, v := range input {\n\t\tinput[i] = (v - min) / (max - min)\n\t}\n\treturn input\n}", "func DenormalizeRGB64(v [3]uint16) [3]float32 {\n\treturn [3]float32{\n\t\tlinearize(float32(v[0]) / 65535),\n\t\tlinearize(float32(v[1]) / 65535),\n\t\tlinearize(float32(v[2]) / 65535),\n\t}\n}", "func NormalizedLinearCoefficients(m, b, stdev, avg float64) LinearCoefficientSet {\n\treturn LinearCoefficientSet{\n\t\tM: m,\n\t\tB: b,\n\t\tStdDev: stdev,\n\t\tAvg: avg,\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 NormalCDF(z float64) float64 {\n\treturn (1 + math.Erf(z/(math.Sqrt2))) / 2\n}", "func DeleteVertexArrays(n int32, arrays *uint32) {\n C.glowDeleteVertexArrays(gpDeleteVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\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 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}" ]
[ "0.60351044", "0.589565", "0.58394325", "0.5808904", "0.5757458", "0.56112206", "0.5609545", "0.5499453", "0.5355278", "0.526311", "0.5236602", "0.5229515", "0.5133886", "0.4951735", "0.48658308", "0.485038", "0.48271272", "0.48121497", "0.4797551", "0.4779746", "0.47541413", "0.47140798", "0.470801", "0.46903196", "0.46712258", "0.46506447", "0.46387163", "0.46219698", "0.460989", "0.45969838", "0.45767137", "0.45463783", "0.4545269", "0.4506958", "0.44915792", "0.4453425", "0.4450891", "0.44405267", "0.4439603", "0.44378063", "0.44357306", "0.44323486", "0.44169715", "0.4413469", "0.44116154", "0.44108683", "0.44026417", "0.43984914", "0.43928424", "0.4389609", "0.43875664", "0.43863642", "0.43680966", "0.435341", "0.43520585", "0.43514758", "0.43477932", "0.4345616", "0.4336241", "0.4329293", "0.43248028", "0.43246987", "0.4323442", "0.43133724", "0.43102232", "0.4305667", "0.43022367", "0.4290094", "0.42879376", "0.4284442", "0.42764434", "0.427611", "0.42667228", "0.4263284", "0.42627665", "0.425202", "0.42513552", "0.42366588", "0.42261556", "0.42261556", "0.422067", "0.42192283", "0.42121595", "0.4207488", "0.4201497", "0.41993043", "0.41955233", "0.41901615", "0.41811663", "0.41786945", "0.41786864", "0.41731784", "0.41631398", "0.41569474", "0.41483045", "0.41445655", "0.41439578", "0.41434076", "0.41425306", "0.41382766", "0.41382766" ]
0.0
-1
label a named object identified within a namespace
func ObjectLabel(identifier uint32, name uint32, length int32, label *uint8) { C.glowObjectLabel(gpObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ObjectLabel(identifier uint32, name uint32, length int32, label *uint8) {\n\tsyscall.Syscall6(gpObjectLabel, 4, uintptr(identifier), uintptr(name), uintptr(length), uintptr(unsafe.Pointer(label)), 0, 0)\n}", "func (api *objectAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Object\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleObjectEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func ObjectLabel(identifier uint32, name uint32, length int32, label *int8) {\n C.glowObjectLabel(gpObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func label(r interface{}) string {\n\treturn strings.ToLower(migref.ToKind(r))\n}", "func (api *nodeAPI) Label(obj *api.Label) 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().Node().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Node\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleNodeEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *bucketAPI) Label(obj *api.Label) 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().Bucket().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Bucket\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleBucketEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *snapshotrestoreAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.SnapshotRestore\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleSnapshotRestoreEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (obj *label) Name() string {\n\treturn obj.name\n}", "func (obj *labelDeclaration) Name() string {\n\treturn obj.name\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *uint8) {\n\tsyscall.Syscall6(gpGetObjectLabel, 5, uintptr(identifier), uintptr(name), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(label)), 0)\n}", "func (api *clusterAPI) Label(obj *api.Label) 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().Cluster().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Cluster\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleClusterEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func labelNamespace(ns string, labels map[string]string) {\n\tfor k, v := range labels {\n\t\tcmd := command{\n\t\t\tCmd: \"bash\",\n\t\t\tArgs: []string{\"-c\", \"kubectl label --overwrite namespace/\" + ns + \" \" + k + \"=\" + v},\n\t\t\tDescription: \"labeling namespace \" + ns,\n\t\t}\n\n\t\tif exitCode, _ := cmd.exec(debug, verbose); exitCode != 0 {\n\t\t\tlog.Println(\"WARN: I could not label namespace [ \" + ns + \" with \" + k + \"=\" + v +\n\t\t\t\t\" ]. It already exists. I am skipping this.\")\n\t\t}\n\t}\n}", "func (api *hostAPI) Label(obj *api.Label) 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().Host().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Host\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleHostEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func namespaceNameFromObjectRef(or *v1.ObjectReference) types.NamespacedName {\n\treturn types.NamespacedName{\n\t\tNamespace: or.Namespace,\n\t\tName: or.Name,\n\t}\n}", "func (api *versionAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Version\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleVersionEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *licenseAPI) Label(obj *api.Label) 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().License().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.License\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleLicenseEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *uint8) {\n\tsyscall.Syscall(gpObjectPtrLabel, 3, uintptr(ptr), uintptr(length), uintptr(unsafe.Pointer(label)))\n}", "func (obj *languageLabelDeclaration) Name() string {\n\treturn obj.name\n}", "func (api *dscprofileAPI) Label(obj *api.Label) 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().DSCProfile().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.DSCProfile\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleDSCProfileEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *distributedservicecardAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.DistributedServiceCard\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleDistributedServiceCardEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func EvalLabelName(a Attrib) (labelName, error) {\n\tidentifier := string(a.(*token.Token).Lit)\n\tstart := &codegen.TargetEntry{\n\t\tTarget: fmt.Sprintf(\"_label_%s\", identifier),\n\t}\n\t// Associating identifier with some entry\n\terr := codegen.SymbolTable.InsertSymbol(identifier, start)\n\tend := &codegen.TargetEntry{\n\t\tTarget: fmt.Sprintf(\"_labelend_%s\", identifier),\n\t}\n\treturn labelName{start, end}, err\n}", "func (a *Agent) LabelFind(name string, label *Label) (err error) {\n\tspec := (&api.LabelSearchSpec{}).Init(name, 0)\n\tif err = a.pc.ExecuteApi(spec); err != nil {\n\t\treturn\n\t}\n\n\tif spec.Result.Total == 0 || spec.Result.List[0].Name != name {\n\t\terr = errors.ErrNotExist\n\t} else {\n\t\tli := spec.Result.List[0]\n\t\tlabel.Id = li.Id\n\t\tlabel.Name = li.Name\n\t\tlabel.Color = labelColorRevMap[li.Color]\n\t}\n\treturn\n}", "func (api *tenantAPI) Label(obj *api.Label) 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().Tenant().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Tenant\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleTenantEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (uem *UyuniEventMapper) Label() string {\n\tvalueOf := reflect.ValueOf(uem)\n\tif valueOf.Type().Kind() == reflect.Ptr {\n\t\treturn reflect.Indirect(valueOf).Type().Name()\n\t} else {\n\t\treturn valueOf.Type().Name()\n\t}\n}", "func (cc *ClusterContext) LabelNamespace(label string, value string) (err error) {\n\n\tpayload := fmt.Sprintf(`{\"metadata\": {\"labels\": {\"%v\": \"%v\"}}}`, label, value)\n\n\t_, err = cc.VanClient.KubeClient.CoreV1().Namespaces().Patch(context.TODO(), cc.Namespace, types.MergePatchType, []byte(payload), metav1.PatchOptions{})\n\n\treturn\n}", "func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *int8) {\n C.glowObjectPtrLabel(gpObjectPtrLabel, ptr, (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func AssertLabel(t *testing.T, label string, expected string, objectMeta metav1.ObjectMeta, kindMessage string) {\n\tmessage := ObjectNameMessage(objectMeta, kindMessage)\n\tlabels := objectMeta.Labels\n\trequire.NotNil(t, labels, \"no labels for %s\", message)\n\tvalue := labels[label]\n\tassert.Equal(t, expected, value, \"label %s for %s\", label, message)\n\tt.Logf(\"%s has label %s=%s\", message, label, value)\n}", "func (client *Client) LabelNamespace(labels map[string]string) error {\n\tnamespace := client.Namespace\n\tnsSpec, err := client.Kube.Kube.CoreV1().Namespaces().Get(namespace, metav1.GetOptions{})\n\tif err != nil {\n\t\treturn err\n\t}\n\tif nsSpec.Labels == nil {\n\t\tnsSpec.Labels = map[string]string{}\n\t}\n\tfor k, v := range labels {\n\t\tnsSpec.Labels[k] = v\n\t}\n\t_, err = client.Kube.Kube.CoreV1().Namespaces().Update(nsSpec)\n\treturn err\n}", "func (nv *NetView) LabelByName(lab string) *gi3d.Text2D {\n\tvs := nv.Scene()\n\tlgp, err := vs.ChildByNameTry(\"Labels\", 1)\n\tif err != nil {\n\t\treturn nil\n\t}\n\ttxt, err := lgp.ChildByNameTry(lab, 0)\n\tif err != nil {\n\t\treturn nil\n\t}\n\treturn txt.(*gi3d.Text2D)\n}", "func (ls *Layers) ElemLabel(idx int) string {\n\treturn (*ls)[idx].Name()\n}", "func (n Name) Label() *Label {\n\tif len(n) > 0 {\n\t\treturn n[0]\n\t}\n\treturn nil\n}", "func (p libvirtPlugin) Label(instance instance.ID, labels map[string]string) error {\n\t//l := log.WithField(\"instance\", instance)\n\n\tconn, err := libvirt.NewConnect(p.URI)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Connecting to libvirt\")\n\t}\n\tdefer conn.Close()\n\n\td, err := p.lookupInstanceByID(conn, instance)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Looking up domain\")\n\t}\n\n\tmeta := infrakitMetadata{}\n\tm, err := d.GetMetadata(libvirt.DOMAIN_METADATA_ELEMENT,\n\t\t\"https://github.com/docker/infrakit\",\n\t\tlibvirt.DOMAIN_AFFECT_LIVE)\n\tif err == nil {\n\t\tif err := meta.Unmarshal(m); err != nil {\n\t\t\treturn errors.Wrap(err, \"Unmarshalling domain metadata XML\")\n\t\t}\n\t} else {\n\t\tmeta.LogicalID = string(instance)\n\t}\n\n\tmetaSetTags(&meta, labels)\n\n\txmlbytes, err := xml.MarshalIndent(meta, \"\", \" \")\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Marshalling infrakitMetadata\")\n\t}\n\tm = string(xmlbytes)\n\n\terr = d.SetMetadata(libvirt.DOMAIN_METADATA_ELEMENT,\n\t\tm,\n\t\t\"infrakit\",\n\t\t\"https//github.com/docker/infrakit\",\n\t\tlibvirt.DOMAIN_AFFECT_LIVE)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Setting domain metadata\")\n\t}\n\n\treturn nil\n}", "func (fxt *TestFixture) LabelByName(name string, spaceID ...uuid.UUID) *label.Label {\n\tfor _, l := range fxt.Labels {\n\t\tif l.Name == name && len(spaceID) > 0 && l.SpaceID == spaceID[0] {\n\t\t\treturn l\n\t\t} else if l.Name == name && len(spaceID) == 0 {\n\t\t\treturn l\n\t\t}\n\t}\n\treturn nil\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *uint8) {\n\tsyscall.Syscall6(gpGetObjectPtrLabel, 4, uintptr(ptr), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(label)), 0, 0)\n}", "func Label(name string) string {\n\treturn fmt.Sprintf(\"%s/%s\", LabelPrefix, name)\n}", "func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *uint8) {\n\tC.glowObjectPtrLabel(gpObjectPtrLabel, ptr, (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *uint8) {\n\tC.glowObjectPtrLabel(gpObjectPtrLabel, ptr, (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (o ResourceAnnotationOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v ResourceAnnotation) *string { return v.Label }).(pulumi.StringPtrOutput)\n}", "func isLabelUnique(ctx context.Context, ss do.ServerlessService, label string) (bool, error) {\n\tresp, err := ss.ListNamespaces(ctx)\n\tif err != nil {\n\t\treturn false, err\n\t}\n\tfor _, ns := range resp.Namespaces {\n\t\tif label == ns.Label {\n\t\t\treturn false, nil\n\t\t}\n\t}\n\treturn true, nil\n}", "func (s *sound) label() string { return s.name }", "func objectName(u *unstructured.Unstructured) string {\n\treturn strings.ToLower(fmt.Sprintf(\"%s-%s\", u.GetKind(), strings.Replace(u.GetName(), \":\", \"-\", -1)))\n}", "func ServiceLabelFromNamespaceLabels(namespaceLabels map[string]string) voyager.Label {\n\treturn voyager.Label(namespaceLabels[voyager.ServiceLabelLabel])\n}", "func NamespacedNameOf(r *corev1.ObjectReference) types.NamespacedName {\n\treturn types.NamespacedName{Namespace: r.Namespace, Name: r.Name}\n}", "func (api *configurationsnapshotAPI) Label(obj *api.Label) 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().ConfigurationSnapshot().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.ConfigurationSnapshot\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleConfigurationSnapshotEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *credentialsAPI) Label(obj *api.Label) 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().Credentials().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Credentials\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleCredentialsEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (g *grpc) objectNamed(name string) generator.Object {\n\tg.gen.RecordTypeUse(name)\n\treturn g.gen.ObjectNamed(name)\n}", "func GenerateLabels(object CommonInterface) map[string]string {\n\tkind := object.GroupVersionKind().Kind\n\tgroup := object.GroupVersionKind().Group\n\tname := object.GetName()\n\tkey := strings.ToLower(kind) + \".\" + group + \"/name\"\n\tlabels := make(map[string]string)\n\tlabels[key] = name\n\treturn labels\n}", "func GenerateLabels(object CommonInterface) map[string]string {\n\tkind := object.GroupVersionKind().Kind\n\tgroup := object.GroupVersionKind().Group\n\tname := object.GetName()\n\tkey := strings.ToLower(kind) + \".\" + group + \"/name\"\n\tlabels := make(map[string]string)\n\tlabels[key] = name\n\treturn labels\n}", "func (c *ContainerContext) Label(name string) string {\n\tif c.c.Labels == nil {\n\t\treturn \"\"\n\t}\n\treturn c.c.Labels[name]\n}", "func (o NodeBalancerOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *NodeBalancer) pulumi.StringPtrOutput { return v.Label }).(pulumi.StringPtrOutput)\n}", "func labelLonghornNode(nodeID string, obj runtime.Object) error {\n\tmetadata, err := meta.Accessor(obj)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tlabels := metadata.GetLabels()\n\tif labels == nil {\n\t\tlabels = map[string]string{}\n\t}\n\tlabels[types.GetLonghornLabelKey(types.LonghornLabelNode)] = nodeID\n\tmetadata.SetLabels(labels)\n\treturn nil\n}", "func (object Object) Name(value string, language string) Object {\n\treturn object.Map(as.PropertyName, value, language)\n}", "func (*Object) Name() string { return \"object\" }", "func (n Node) Label(label string) Node {\n\treturn n.Attr(\"label\", label)\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectPtrLabel(gpGetObjectPtrLabel, ptr, (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func autolabel(prefix string) *types.Sym {\n\tif prefix[0] != '.' {\n\t\tFatalf(\"autolabel prefix must start with '.', have %q\", prefix)\n\t}\n\tfn := Curfn\n\tif Curfn == nil {\n\t\tFatalf(\"autolabel outside function\")\n\t}\n\tn := fn.Func.Label\n\tfn.Func.Label++\n\treturn lookupN(prefix, int(n))\n}", "func (r *Release) label(storageBackend string, labels ...string) {\n\tif len(labels) == 0 {\n\t\treturn\n\t}\n\tif r.Enabled.Value {\n\n\t\targs := []string{\"label\", \"--overwrite\", storageBackend, \"-n\", r.Namespace, \"-l\", \"owner=helm,name=\" + r.Name}\n\t\targs = append(args, labels...)\n\t\tcmd := kubectl(args, \"Applying Helmsman labels to [ \"+r.Name+\" ] release\")\n\n\t\tif _, err := cmd.Exec(); err != nil {\n\t\t\tlog.Fatal(err.Error())\n\t\t}\n\t}\n}", "func (c *Configuration) LabelFor(org, repo string) *TiCommunityLabel {\n\tfullName := fmt.Sprintf(\"%s/%s\", org, repo)\n\tfor _, label := range c.TiCommunityLabel {\n\t\tif !sets.NewString(label.Repos...).Has(fullName) {\n\t\t\tcontinue\n\t\t}\n\t\treturn &label\n\t}\n\t// If you don't find anything, loop again looking for an org config\n\tfor _, label := range c.TiCommunityLabel {\n\t\tif !sets.NewString(label.Repos...).Has(org) {\n\t\t\tcontinue\n\t\t}\n\t\treturn &label\n\t}\n\treturn &TiCommunityLabel{}\n}", "func (o ResourceAnnotationPtrOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *ResourceAnnotation) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn v.Label\n\t}).(pulumi.StringPtrOutput)\n}", "func (k *kubectlContext) Label(args ...string) (string, error) {\n\tout, err := k.do(append([]string{\"label\"}, args...)...)\n\treturn string(out), err\n}", "func (pi *PackageInfo) ObjectVName(obj types.Object) *spb.VName {\n\tif pkg, ok := obj.(*types.PkgName); ok {\n\t\treturn pi.PackageVName[pkg.Imported()]\n\t}\n\tsig := pi.Signature(obj)\n\tpkg := obj.Pkg()\n\tvar vname *spb.VName\n\tif base := pi.PackageVName[pkg]; base != nil {\n\t\tvname = proto.Clone(base).(*spb.VName)\n\t} else if pkg == nil {\n\t\treturn govname.Builtin(obj.Name())\n\t} else {\n\t\t// This is an indirect import, that is, a name imported but not\n\t\t// mentioned explicitly by the package being indexed.\n\t\t// TODO(#2383): This is a workaround, and may not be correct in all\n\t\t// cases; work out a more comprehensive solution (possibly during\n\t\t// extraction).\n\t\tvname = proto.Clone(pi.VName).(*spb.VName)\n\t\tvname.Path = strings.TrimPrefix(pkg.Path(), vname.Corpus+\"/\")\n\t}\n\n\tvname.Signature = sig\n\treturn vname\n}", "func (up *Upstream) Label() string {\n\treturn fmt.Sprintf(\"%s_%s_%s_%d\", up.Protocol, up.Name, up.Namespace, up.Port)\n}", "func (e *clfEncoder) OpenNamespace(key string) {}", "func (e *EDNS) Name() string { return name }", "func (p *plugin) Label(instance instance.ID, labels map[string]string) error {\n\treturn fmt.Errorf(\"VMware vSphere VM label updates are not implemented yet\")\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectPtrLabel(gpGetObjectPtrLabel, ptr, (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectPtrLabel(gpGetObjectPtrLabel, ptr, (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (c *Collection) Label() {\n\tfor _, resource := range c.Items {\n\t\tresource.Label(c.ResourceLabel)\n\t}\n}", "func (o ResourceAnnotationResponsePtrOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *ResourceAnnotationResponse) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn &v.Label\n\t}).(pulumi.StringPtrOutput)\n}", "func TranslatedObjectLabels() map[string]string {\n\treturn map[string]string{OwnershipLabelKey: defaults.GetPodNamespace()}\n}", "func (reg *registrar) NameFor(item interface{}) (string, error) {\n\treg.lock.Lock()\n\tdefer reg.lock.Unlock()\n\treturn reg.Registry.NameFor(item)\n}", "func (i *Instance) Label() string {\n\treturn i.Domain\n}", "func ObjName(iface interface{}) string {\n\treturn filepath.Base(reflect.TypeOf(iface).PkgPath()) +\n\t\t\".\" + reflect.TypeOf(iface).Name()\n}", "func (t *Type) Nname() *Node", "func AppendNamespaceLabel(namespace string, labels map[string]string) map[string]string {\n\tfinal := labels\n\n\tif final == nil {\n\t\tfinal = make(map[string]string)\n\t}\n\n\tif final[NamespaceLabelKey] == \"\" {\n\t\tfinal[NamespaceLabelKey] = namespace\n\t}\n\n\treturn final\n}", "func (pl *NodeLabel) Name() string {\n\treturn Name\n}", "func NamespacedName(obj metav1.Object) types.NamespacedName {\n\treturn types.NamespacedName{\n\t\tNamespace: obj.GetNamespace(),\n\t\tName: obj.GetName(),\n\t}\n}", "func Label(key string, value interface{}, args ...context.Context) {\n\tcurrentTracer := ExtractTracer(args)\n\tif currentTracer != nil {\n\t\tcurrentTracer.AddLabel(key, value)\n\t}\n}", "func onAdd(obj interface{}) {\n\t// Cast the obj as node\n\tpod := obj.(*corev1.Pod)\n\tlabel, ok := pod.GetLabels()[SOME_LABEL]\n\tif ok {\n\t\tfmt.Printf(\"onAdd\\n\")\n\t\tfmt.Printf(\"It has the label: %s\\n\", label)\n\t}\n}", "func (r *ImageRef) Label(labelParams *LabelParams) error {\n\tout, err := labelImage(r.image, labelParams)\n\tif err != nil {\n\t\treturn err\n\t}\n\tr.setImage(out)\n\treturn nil\n}", "func (c *C) NameSpace(prefix string, beforeControllers ...action) *NS {\n\tns := &NS{\n\t\tc: c,\n\t\tprefix: prefix,\n\t\tbCtrl: beforeControllers,\n\t}\n\n\treturn ns\n}", "func (p *Parser) Label(label string) *Parser {\n\tp.nextLabel = label\n\treturn p\n}", "func getLabelToMatchForKind(kind string) []string {\n\tswitch kind {\n\tcase \"apiservice\": // API Services are not namespaced\n\t\treturn []string{\"apiservice\"}\n\tcase \"customresourcedefinition\": // CRD are not namespaced\n\t\treturn []string{\"customresourcedefinition\"}\n\tcase \"job\": // job metrics use specific label\n\t\treturn []string{\"job_name\", \"namespace\"}\n\tcase \"node\": // persistent nodes are not namespaced\n\t\treturn []string{\"node\"}\n\tcase \"persistentvolume\": // persistent volumes are not namespaced\n\t\treturn []string{\"persistentvolume\"}\n\tdefault:\n\t\treturn []string{kind, \"namespace\"}\n\t}\n}", "func (p *Program) FindLabel(xp uint64) *Label {\n\ti := sort.Search(len(p.Labels), func(i int) bool {\n\t\treturn p.Labels[i].Offset >= xp\n\t})\n\tif i < len(p.Labels) && p.Labels[i].Offset == xp {\n\t\treturn p.Labels[i]\n\t}\n\treturn &Label{\n\t\tOffset: xp,\n\t\tPublic: false,\n\t\tName: fmt.Sprintf(\".ANON@%x\", xp),\n\t}\n}", "func getResourceLabelsForModel(namespace, name string) map[string]string {\n\tprojectId, _ := gce.ProjectID()\n\tlocation, _ := gce.InstanceAttributeValue(\"cluster-location\")\n\tlocation = strings.TrimSpace(location)\n\tclusterName, _ := gce.InstanceAttributeValue(\"cluster-name\")\n\tclusterName = strings.TrimSpace(clusterName)\n\treturn map[string]string{\n\t\t\"project_id\": projectId,\n\t\t\"location\": location,\n\t\t\"cluster_name\": clusterName,\n\t\t\"namespace_name\": namespace,\n\t\t\"pod_name\": name,\n\t}\n}", "func (p *iexporter) exportName(obj types.Object) (res string) {\n\tif name := p.tparamNames[obj]; name != \"\" {\n\t\treturn name\n\t}\n\treturn obj.Name()\n}", "func (l Label) Label() string { return string(l) }", "func k8sObjectName(doc *yaml.Node) (string, error) {\n\t// iterate over content\n\tit := yit.FromNode(doc.Content[0]).\n\t\t// Access nested 'metadata' attribute\n\t\tValuesForMap(\n\t\t\tyit.WithStringValue(\"metadata\"),\n\t\t\tyit.WithKind(yaml.MappingNode),\n\t\t).\n\t\t// Access nested 'name' attribute\n\t\tValuesForMap(\n\t\t\tyit.WithStringValue(\"name\"),\n\t\t\tyit.StringValue,\n\t\t)\n\n\t// no need to iterate in a loop here, the StringValue predicate\n\t// guarantees we get a single node\n\tnode, ok := it()\n\tif !ok || node.Value == \"\" {\n\t\treturn \"\", errors.New(\"missing metadata.name attribute\")\n\t}\n\n\treturn node.Value, nil\n}", "func retrieveInventoryLabel(obj *unstructured.Unstructured) (string, error) {\n\tinventoryLabel, exists := obj.GetLabels()[common.InventoryLabel]\n\tif !exists {\n\t\treturn \"\", fmt.Errorf(\"inventory label does not exist for inventory object: %s\", common.InventoryLabel)\n\t}\n\treturn inventoryLabel, nil\n}", "func (m *Media) SetLabel(value *string)() {\n m.label = value\n}", "func (o BoundingPolyOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v BoundingPoly) *string { return v.Label }).(pulumi.StringPtrOutput)\n}", "func (p *Parser) label() {\n\tlabel := p.previous.Literal\n\tif offset, ok := p.labels[label]; ok {\n\t\tp.emitByte(byte(offset))\n\t} else {\n\t\tdata := Label{offset: p.chunk.count, token: p.previous}\n\t\tp.backpatch[label] = append(p.backpatch[label], data)\n\t\tp.emitByte(0)\n\t}\n}", "func internLabelString(s string) string {\n\treturn intern.GetByString(s).Get().(string)\n}", "func (gen *Generator) NamedLookup(name string) ast.Node {\n\treturn NodeByName(gen.Nodes.Definition, name)\n}", "func ObjectKey(name, namespace string) types.NamespacedName {\n\treturn types.NamespacedName{\n\t\tNamespace: namespace,\n\t\tName: name,\n\t}\n}", "func PidLabel(pid int) (string, error) {\n\treturn pidLabel(pid)\n}" ]
[ "0.67744076", "0.6563606", "0.6442182", "0.63694155", "0.63467276", "0.6293929", "0.6173011", "0.617141", "0.611636", "0.6076318", "0.603768", "0.60299015", "0.5996577", "0.595825", "0.59285295", "0.5907533", "0.58909935", "0.5884448", "0.58744997", "0.5868947", "0.5868347", "0.58541703", "0.58541703", "0.5835411", "0.5792357", "0.5772528", "0.57550746", "0.5754546", "0.5735555", "0.5720754", "0.5714753", "0.5708221", "0.56616503", "0.5644542", "0.56057614", "0.5605689", "0.5605302", "0.5597087", "0.5570839", "0.5570839", "0.5563152", "0.5552391", "0.55409294", "0.5501551", "0.54906774", "0.54667294", "0.54552656", "0.54472935", "0.5447233", "0.5440009", "0.5440009", "0.54372907", "0.5434019", "0.54188555", "0.5405787", "0.53789234", "0.5370581", "0.53702974", "0.5360962", "0.5359847", "0.5349726", "0.53411424", "0.5340023", "0.5337433", "0.53331465", "0.53233486", "0.5320541", "0.5310292", "0.5293552", "0.5293552", "0.52919006", "0.5287755", "0.5276424", "0.52652156", "0.52421725", "0.5229376", "0.52198476", "0.5219608", "0.5214275", "0.5211113", "0.5205569", "0.5166687", "0.51587665", "0.51581377", "0.5152372", "0.51519686", "0.514675", "0.51404774", "0.5135955", "0.5129541", "0.51289064", "0.5124739", "0.5122371", "0.5120349", "0.5119564", "0.51074815", "0.5099835", "0.5098699", "0.508958" ]
0.6274733
7
label a sync object identified by a pointer
func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *uint8) { C.glowObjectPtrLabel(gpObjectPtrLabel, ptr, (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *uint8) {\n\tsyscall.Syscall(gpObjectPtrLabel, 3, uintptr(ptr), uintptr(length), uintptr(unsafe.Pointer(label)))\n}", "func ObjectPtrLabel(ptr unsafe.Pointer, length int32, label *int8) {\n C.glowObjectPtrLabel(gpObjectPtrLabel, ptr, (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func ObjectLabel(identifier uint32, name uint32, length int32, label *uint8) {\n\tsyscall.Syscall6(gpObjectLabel, 4, uintptr(identifier), uintptr(name), uintptr(length), uintptr(unsafe.Pointer(label)), 0, 0)\n}", "func (api *objectAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Object\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleObjectEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectPtrLabel(gpGetObjectPtrLabel, ptr, (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *uint8) {\n\tsyscall.Syscall6(gpGetObjectPtrLabel, 4, uintptr(ptr), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(label)), 0, 0)\n}", "func ObjectLabel(identifier uint32, name uint32, length int32, label *int8) {\n C.glowObjectLabel(gpObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func ObjectLabel(identifier uint32, name uint32, length int32, label *uint8) {\n\tC.glowObjectLabel(gpObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func ObjectLabel(identifier uint32, name uint32, length int32, label *uint8) {\n\tC.glowObjectLabel(gpObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectPtrLabel(gpGetObjectPtrLabel, ptr, (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetObjectPtrLabel(ptr unsafe.Pointer, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectPtrLabel(gpGetObjectPtrLabel, ptr, (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (api *bucketAPI) Label(obj *api.Label) 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().Bucket().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Bucket\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleBucketEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *nodeAPI) Label(obj *api.Label) 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().Node().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Node\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleNodeEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *distributedservicecardAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.DistributedServiceCard\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleDistributedServiceCardEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *hostAPI) Label(obj *api.Label) 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().Host().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Host\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleHostEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *clusterAPI) Label(obj *api.Label) 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().Cluster().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Cluster\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleClusterEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *int8) {\n C.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (api *versionAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Version\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleVersionEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *snapshotrestoreAPI) Label(obj *api.Label) 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().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.SnapshotRestore\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleSnapshotRestoreEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func newLabelFromNative(obj unsafe.Pointer) interface{} {\n\tl := &Label{}\n\tl.object = C.to_GtkLabel(obj)\n\n\tif gobject.IsObjectFloating(l) {\n\t\tgobject.RefSink(l)\n\t} else {\n\t\tgobject.Ref(l)\n\t}\n\tl.Widget = NewWidget(unsafe.Pointer(l.object))\n\tlabelFinalizer(l)\n\n\treturn l\n}", "func labelLonghornNode(nodeID string, obj runtime.Object) error {\n\tmetadata, err := meta.Accessor(obj)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tlabels := metadata.GetLabels()\n\tif labels == nil {\n\t\tlabels = map[string]string{}\n\t}\n\tlabels[types.GetLonghornLabelKey(types.LonghornLabelNode)] = nodeID\n\tmetadata.SetLabels(labels)\n\treturn nil\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *uint8) {\n\tsyscall.Syscall6(gpGetObjectLabel, 5, uintptr(identifier), uintptr(name), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(label)), 0)\n}", "func (api *configurationsnapshotAPI) Label(obj *api.Label) 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().ConfigurationSnapshot().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.ConfigurationSnapshot\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleConfigurationSnapshotEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func label(r interface{}) string {\n\treturn strings.ToLower(migref.ToKind(r))\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func GetObjectLabel(identifier uint32, name uint32, bufSize int32, length *int32, label *uint8) {\n\tC.glowGetObjectLabel(gpGetObjectLabel, (C.GLenum)(identifier), (C.GLuint)(name), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(label)))\n}", "func (api *licenseAPI) Label(obj *api.Label) 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().License().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.License\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleLicenseEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (self Label) ToNative() unsafe.Pointer {\n\treturn unsafe.Pointer(self.object)\n}", "func labelLonghornDiskUUID(diskUUID string, obj runtime.Object) error {\n\tmetadata, err := meta.Accessor(obj)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tlabels := metadata.GetLabels()\n\tif labels == nil {\n\t\tlabels = map[string]string{}\n\t}\n\tlabels[types.GetLonghornLabelKey(types.LonghornLabelDiskUUID)] = diskUUID\n\tmetadata.SetLabels(labels)\n\treturn nil\n}", "func (p *plugin) Label(instance instance.ID, labels map[string]string) error {\n\treturn fmt.Errorf(\"VMware vSphere VM label updates are not implemented yet\")\n}", "func (api *tenantAPI) Label(obj *api.Label) 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().Tenant().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Tenant\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleTenantEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (api *dscprofileAPI) Label(obj *api.Label) 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().DSCProfile().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.DSCProfile\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleDSCProfileEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (m *Media) SetLabel(value *string)() {\n m.label = value\n}", "func (api *credentialsAPI) Label(obj *api.Label) 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().Credentials().Label(context.Background(), obj)\n\t\treturn err\n\t}\n\n\tctkitObj, err := api.Find(obj.GetObjectMeta())\n\tif err != nil {\n\t\treturn err\n\t}\n\twriteObj := ctkitObj.Credentials\n\twriteObj.Labels = obj.Labels\n\n\tapi.ct.handleCredentialsEvent(&kvstore.WatchEvent{Object: &writeObj, Type: kvstore.Updated})\n\treturn nil\n}", "func (uem *UyuniEventMapper) Label() string {\n\tvalueOf := reflect.ValueOf(uem)\n\tif valueOf.Type().Kind() == reflect.Ptr {\n\t\treturn reflect.Indirect(valueOf).Type().Name()\n\t} else {\n\t\treturn valueOf.Type().Name()\n\t}\n}", "func (c *GlInsertEventMarkerEXT) Label(ctx context.Context, s *api.GlobalState) string {\n\treturn readString(ctx, c, s, c.Marker(), c.Length())\n}", "func syncLabelsWithPrefix(src metav1.Object, dest metav1.Object, prefix string) (changed bool) {\n\tlabels := dest.GetLabels()\n\n\tfor srcKey, srcValue := range src.GetLabels() {\n\t\tif strings.HasPrefix(srcKey, prefix) {\n\t\t\tdestValue, ok := labels[srcKey]\n\t\t\tif !ok || destValue != srcValue {\n\t\t\t\tchanged = true\n\t\t\t\tlabels[srcKey] = srcValue\n\t\t\t}\n\t\t}\n\t}\n\n\tdest.SetLabels(labels)\n\treturn\n}", "func (*NetworkInstance_Mpls_SignalingProtocols_SegmentRouting_Interface_SidCounter_MplsLabel_Union_E_OpenconfigSegmentRouting_SidCounter_MplsLabel) Is_NetworkInstance_Mpls_SignalingProtocols_SegmentRouting_Interface_SidCounter_MplsLabel_Union() {\n}", "func (recv *Object) ConnectNotify(callback ObjectSignalNotifyCallback) int {\n\tsignalObjectNotifyLock.Lock()\n\tdefer signalObjectNotifyLock.Unlock()\n\n\tsignalObjectNotifyId++\n\tinstance := C.gpointer(recv.native)\n\thandlerID := C.Object_signal_connect_notify(instance, C.gpointer(uintptr(signalObjectNotifyId)))\n\n\tdetail := signalObjectNotifyDetail{callback, handlerID}\n\tsignalObjectNotifyMap[signalObjectNotifyId] = detail\n\n\treturn signalObjectNotifyId\n}", "func (c *GlPushGroupMarkerEXT) Label(ctx context.Context, s *api.GlobalState) string {\n\treturn readString(ctx, c, s, c.Marker(), c.Length())\n}", "func (up *Upstream) Label() string {\n\treturn fmt.Sprintf(\"%s_%s_%s_%d\", up.Protocol, up.Name, up.Namespace, up.Port)\n}", "func (p libvirtPlugin) Label(instance instance.ID, labels map[string]string) error {\n\t//l := log.WithField(\"instance\", instance)\n\n\tconn, err := libvirt.NewConnect(p.URI)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Connecting to libvirt\")\n\t}\n\tdefer conn.Close()\n\n\td, err := p.lookupInstanceByID(conn, instance)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Looking up domain\")\n\t}\n\n\tmeta := infrakitMetadata{}\n\tm, err := d.GetMetadata(libvirt.DOMAIN_METADATA_ELEMENT,\n\t\t\"https://github.com/docker/infrakit\",\n\t\tlibvirt.DOMAIN_AFFECT_LIVE)\n\tif err == nil {\n\t\tif err := meta.Unmarshal(m); err != nil {\n\t\t\treturn errors.Wrap(err, \"Unmarshalling domain metadata XML\")\n\t\t}\n\t} else {\n\t\tmeta.LogicalID = string(instance)\n\t}\n\n\tmetaSetTags(&meta, labels)\n\n\txmlbytes, err := xml.MarshalIndent(meta, \"\", \" \")\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Marshalling infrakitMetadata\")\n\t}\n\tm = string(xmlbytes)\n\n\terr = d.SetMetadata(libvirt.DOMAIN_METADATA_ELEMENT,\n\t\tm,\n\t\t\"infrakit\",\n\t\t\"https//github.com/docker/infrakit\",\n\t\tlibvirt.DOMAIN_AFFECT_LIVE)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Setting domain metadata\")\n\t}\n\n\treturn nil\n}", "func (obj *instruction) Label() label_instruction.Instruction {\n\treturn obj.label\n}", "func (o BoundingPolyOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v BoundingPoly) *string { return v.Label }).(pulumi.StringPtrOutput)\n}", "func (obj *label) Name() string {\n\treturn obj.name\n}", "func (detach *LibcomposeDetachProperty) Label() string {\n\treturn \"Detach\"\n}", "func (o ResourceAnnotationPtrOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *ResourceAnnotation) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn v.Label\n\t}).(pulumi.StringPtrOutput)\n}", "func (c *GlPushDebugGroupKHR) Label(ctx context.Context, s *api.GlobalState) string {\n\t// This is incorrect, fudging for a bug in Unity which has been fixed but not\n\t// rolled out.\n\t// See https://github.com/google/gapid/issues/459 for reference.\n\t//\n\t// c.Length() should only be treated as null-terminated if c.Length() is < 0.\n\t//\n\t// TODO: Consider removing once the fixed version is mainstream.\n\treturn readString(ctx, c, s, c.Message(), c.Length())\n}", "func (p *Parser) label() {\n\tlabel := p.previous.Literal\n\tif offset, ok := p.labels[label]; ok {\n\t\tp.emitByte(byte(offset))\n\t} else {\n\t\tdata := Label{offset: p.chunk.count, token: p.previous}\n\t\tp.backpatch[label] = append(p.backpatch[label], data)\n\t\tp.emitByte(0)\n\t}\n}", "func (m *Media) GetLabel()(*string) {\n return m.label\n}", "func setLabel(object metav1.Object, key string, value string) {\n\tlabels := object.GetLabels()\n\tif labels == nil {\n\t\tlabels = map[string]string{}\n\t}\n\tif value != \"\" {\n\t\tlabels[key] = value\n\t} else {\n\t\tdelete(labels, key)\n\t}\n\tobject.SetLabels(labels)\n}", "func PeerLabel(fd uintptr) (string, error) {\n\treturn peerLabel(fd)\n}", "func (o ResourceAnnotationOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v ResourceAnnotation) *string { return v.Label }).(pulumi.StringPtrOutput)\n}", "func onAdd(obj interface{}) {\n\t// Cast the obj as node\n\tpod := obj.(*corev1.Pod)\n\tlabel, ok := pod.GetLabels()[SOME_LABEL]\n\tif ok {\n\t\tfmt.Printf(\"onAdd\\n\")\n\t\tfmt.Printf(\"It has the label: %s\\n\", label)\n\t}\n}", "func (o NodeBalancerOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *NodeBalancer) pulumi.StringPtrOutput { return v.Label }).(pulumi.StringPtrOutput)\n}", "func (m *Manager) SetLabel(k, v string) {\n\tm.b.SetLabel(k, v)\n}", "func (*NetworkInstance_Mpls_SignalingProtocols_SegmentRouting_AggregateSidCounter_MplsLabel_Union_E_OpenconfigSegmentRouting_AggregateSidCounter_MplsLabel) Is_NetworkInstance_Mpls_SignalingProtocols_SegmentRouting_AggregateSidCounter_MplsLabel_Union() {\n}", "func (h *descriptorHandler) keyLabel(key string) string {\n\tif h.descriptor == nil || h.descriptor.KeyLabel == nil {\n\t\treturn key\n\t}\n\tdefer trackDescMethod(h.descriptor.Name, \"KeyLabel\")()\n\treturn h.descriptor.KeyLabel(key)\n}", "func (zc *Zcounter) Label(l string) {\n\tzc.label = l\n}", "func (r *Release) label(storageBackend string, labels ...string) {\n\tif len(labels) == 0 {\n\t\treturn\n\t}\n\tif r.Enabled.Value {\n\n\t\targs := []string{\"label\", \"--overwrite\", storageBackend, \"-n\", r.Namespace, \"-l\", \"owner=helm,name=\" + r.Name}\n\t\targs = append(args, labels...)\n\t\tcmd := kubectl(args, \"Applying Helmsman labels to [ \"+r.Name+\" ] release\")\n\n\t\tif _, err := cmd.Exec(); err != nil {\n\t\t\tlog.Fatal(err.Error())\n\t\t}\n\t}\n}", "func (l Label) Label() string { return string(l) }", "func NewSingleObjectLabeler(json string) (GenericLabeler, error) {\n\tlabeler, err := newGabsObjectLabeler(json)\n\treturn labeler, err\n}", "func (s *BaselimboListener) EnterLabel(ctx *LabelContext) {}", "func (o ResourceAnnotationResponsePtrOutput) Label() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *ResourceAnnotationResponse) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn &v.Label\n\t}).(pulumi.StringPtrOutput)\n}", "func (r *ImageRef) Label(labelParams *LabelParams) error {\n\tout, err := labelImage(r.image, labelParams)\n\tif err != nil {\n\t\treturn err\n\t}\n\tr.setImage(out)\n\treturn nil\n}", "func (s *sound) label() string { return s.name }", "func (o *AddOn) Label() string {\n\tif o != nil && o.bitmap_&1024 != 0 {\n\t\treturn o.label\n\t}\n\treturn \"\"\n}", "func (norecreate *LibcomposeNoRecreateProperty) Label() string {\n\treturn \"Create\"\n}", "func (z *zpoolctl) LabelClear(ctx context.Context, device string, force bool) *execute {\n\targs := []string{\"labelclear\"}\n\tif force {\n\t\targs = append(args, \"-f\", device)\n\t}\n\treturn &execute{ctx: ctx, name: z.cmd, args: args}\n}", "func (*Label) Kind() *base.Kind {\n\treturn &labelKind\n}", "func AssertLabel(t *testing.T, label string, expected string, objectMeta metav1.ObjectMeta, kindMessage string) {\n\tmessage := ObjectNameMessage(objectMeta, kindMessage)\n\tlabels := objectMeta.Labels\n\trequire.NotNil(t, labels, \"no labels for %s\", message)\n\tvalue := labels[label]\n\tassert.Equal(t, expected, value, \"label %s for %s\", label, message)\n\tt.Logf(\"%s has label %s=%s\", message, label, value)\n}", "func (tracker *tracker) Mark(node *Node) {\n\ttracker.mutex.Lock()\n\ttracker.nodes[node.Name]++\n\ttracker.mutex.Unlock()\n}", "func (a *Agent) LabelFind(name string, label *Label) (err error) {\n\tspec := (&api.LabelSearchSpec{}).Init(name, 0)\n\tif err = a.pc.ExecuteApi(spec); err != nil {\n\t\treturn\n\t}\n\n\tif spec.Result.Total == 0 || spec.Result.List[0].Name != name {\n\t\terr = errors.ErrNotExist\n\t} else {\n\t\tli := spec.Result.List[0]\n\t\tlabel.Id = li.Id\n\t\tlabel.Name = li.Name\n\t\tlabel.Color = labelColorRevMap[li.Color]\n\t}\n\treturn\n}", "func Label(title string) iup.Ihandle {\n\tc_title := C.CString(title)\n\tdefer C.free(unsafe.Pointer(c_title))\n\n\t//Ihandle* IupGLLabel(const char* title);\n\treturn mkih(C.IupGLLabel(c_title))\n}", "func (g *Graph) Node(gvk schema.GroupVersionKind, obj metav1.Object) *Node {\n\tapiVersion, kind := gvk.ToAPIVersionAndKind()\n\tnode := &Node{\n\t\tTypeMeta: metav1.TypeMeta{\n\t\t\tAPIVersion: apiVersion,\n\t\t\tKind: kind,\n\t\t},\n\t\tObjectMeta: metav1.ObjectMeta{\n\t\t\tUID: obj.GetUID(),\n\t\t\tNamespace: obj.GetNamespace(),\n\t\t\tName: obj.GetName(),\n\t\t\tAnnotations: FilterByValue(obj.GetAnnotations(), func(v string) bool {\n\t\t\t\treturn !strings.HasPrefix(v, \"{\") && !strings.HasPrefix(v, \"[\")\n\t\t\t}),\n\t\t\tLabels: obj.GetLabels(),\n\t\t},\n\t}\n\n\tif n, ok := g.Nodes[obj.GetUID()]; ok {\n\t\tif len(n.GetAnnotations()) != 0 {\n\t\t\tnode.SetAnnotations(n.GetAnnotations())\n\t\t}\n\t\tif len(n.GetLabels()) != 0 {\n\t\t\tnode.SetLabels(n.GetLabels())\n\t\t}\n\t}\n\n\tg.Nodes[obj.GetUID()] = node\n\n\tfor _, ownerRef := range obj.GetOwnerReferences() {\n\t\towner := g.Node(\n\t\t\tschema.FromAPIVersionAndKind(ownerRef.APIVersion, ownerRef.Kind),\n\t\t\t&metav1.ObjectMeta{\n\t\t\t\tUID: ownerRef.UID,\n\t\t\t\tName: ownerRef.Name,\n\t\t\t\tNamespace: obj.GetNamespace(),\n\t\t\t},\n\t\t)\n\t\tg.Relationship(owner, kind, node)\n\t}\n\n\treturn node\n}", "func Label(name string) string {\n\treturn fmt.Sprintf(\"%s/%s\", LabelPrefix, name)\n}", "func (i *Instance) Label() string {\n\treturn i.Domain\n}", "func (s *BasevhdlListener) EnterLabel_colon(ctx *Label_colonContext) {}", "func (dm *DummySyncManager) ActiveLightSync(pid peer.ID) error { return nil }", "func printSyncWith(sender string) {\n\tfmt.Println(\"IN SYNC WITH \" + sender)\n}", "func (c *GlPushDebugGroup) Label(ctx context.Context, s *api.GlobalState) string {\n\t// This is incorrect, fudging for a bug in Unity which has been fixed but not\n\t// rolled out.\n\t// See https://github.com/google/gapid/issues/459 for reference.\n\t//\n\t// c.Length() should only be treated as null-terminated if c.Length() is < 0.\n\t//\n\t// TODO: Consider removing once the fixed version is mainstream.\n\treturn readString(ctx, c, s, c.Message(), c.Length())\n}", "func (c *Catalog) LabeledPod(name string, labels map[string]string) corev1.Pod {\n\treturn corev1.Pod{\n\t\tObjectMeta: metav1.ObjectMeta{\n\t\t\tName: name,\n\t\t\tLabels: labels,\n\t\t},\n\t\tSpec: c.Sleep1hPodSpec(),\n\t}\n}", "func (b *button) label(part *vu.Ent, keyCode int) {\n\tif keysym := vu.Symbol(keyCode); keysym > 0 {\n\t\tif b.banner == nil {\n\t\t\tb.banner = part.AddPart().SetAt(float64(b.x), float64(b.y), 0)\n\t\t\tb.banner.MakeLabel(\"labeled\", \"lucidiaSu22\")\n\t\t\tb.banner.SetColor(0, 0, 0)\n\t\t}\n\t\tif keyCode == 0 {\n\t\t\tkeyCode = vu.KSpace\n\t\t}\n\t\tb.banner.SetStr(string(keysym))\n\t}\n}", "func (p *Program) Label() base.Label { return p.label }", "func (*NetworkInstance_Mpls_SignalingProtocols_SegmentRouting_Interface_SidCounter_MplsLabel_Union_Uint32) Is_NetworkInstance_Mpls_SignalingProtocols_SegmentRouting_Interface_SidCounter_MplsLabel_Union() {\n}", "func ReconcileLabelledObject(\n\tctx context.Context,\n\tlogger logr.Logger,\n\tregistry k8s_registry.TypeRegistry,\n\tclient kube_client.Client,\n\towner kube_types.NamespacedName,\n\townerMesh string,\n\townedType k8s_registry.ResourceType,\n\townedNamespace string,\n\towned map[string]core_model.ResourceSpec,\n) error {\n\tlog := logger.WithValues(\"type\", ownedType, \"name\", owner.Name, \"namespace\", owner.Namespace)\n\t// First we list which existing objects are owned by this owner.\n\t// We expect either 0 or 1 and depending on whether routeSpec is nil\n\t// we either create an object or update or delete the existing one.\n\townerLabelValue := hashNamespacedName(owner)\n\tlabels := kube_client.MatchingLabels{\n\t\townerLabel: ownerLabelValue,\n\t}\n\n\texistingList, err := registry.NewList(ownedType)\n\tif err != nil {\n\t\treturn errors.Wrapf(err, \"could not create list of owned %T\", ownedType)\n\t}\n\n\tif err := client.List(ctx, existingList, labels); err != nil {\n\t\treturn err\n\t}\n\n\t// Delete unneeded objects\n\texistingObjs := map[string]k8s_model.KubernetesObject{}\n\tfor _, existing := range existingList.GetItems() {\n\t\tif _, ok := owned[existing.GetName()]; !ok {\n\t\t\terr := client.Delete(ctx, existing)\n\t\t\tswitch {\n\t\t\tcase kube_apierrs.IsNotFound(err):\n\t\t\t\tlog.V(1).Info(\"object not found. Nothing to delete\")\n\t\t\tcase err == nil:\n\t\t\t\tlog.Info(\"object deleted\")\n\t\t\tdefault:\n\t\t\t\treturn err\n\t\t\t}\n\t\t\t// We don't care about this anymore\n\t\t\tcontinue\n\t\t}\n\t\texistingObjs[existing.GetName()] = existing\n\t}\n\n\t// We need a mesh when creating objects\n\tif len(owned) > 0 && ownerMesh == \"\" {\n\t\treturn fmt.Errorf(\"could not reconcile object, owner mesh must not be empty\")\n\t}\n\n\tfor ownedName, ownedSpec := range owned {\n\t\t// Update existing\n\t\tif existing, ok := existingObjs[ownedName]; ok {\n\t\t\texistingSpec, err := existing.GetSpec()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif core_model.Equal(existingSpec, ownedSpec) {\n\t\t\t\tlog.V(1).Info(\"object is the same. Nothing to update\")\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\texisting.SetSpec(ownedSpec)\n\n\t\t\tif err := client.Update(ctx, existing); err != nil {\n\t\t\t\treturn errors.Wrapf(err, \"could not update owned %T\", ownedType)\n\t\t\t}\n\t\t\tlog.Info(\"object updated\")\n\n\t\t\tcontinue\n\t\t}\n\n\t\t// Or create new\n\t\towned, err := registry.NewObject(ownedType)\n\t\tif err != nil {\n\t\t\treturn errors.Wrapf(err, \"could not get new %T from registry\", ownedType)\n\t\t}\n\n\t\towned.SetMesh(ownerMesh)\n\n\t\towned.SetObjectMeta(\n\t\t\t&kube_meta.ObjectMeta{\n\t\t\t\tName: ownedName,\n\t\t\t\tNamespace: ownedNamespace,\n\t\t\t\tLabels: map[string]string{\n\t\t\t\t\townerLabel: ownerLabelValue,\n\t\t\t\t},\n\t\t\t},\n\t\t)\n\t\towned.SetSpec(ownedSpec)\n\n\t\tif err := client.Create(ctx, owned); err != nil {\n\t\t\treturn errors.Wrapf(err, \"could not create owned %T\", ownedType)\n\t\t}\n\t\tlogger.Info(\"object created\")\n\t}\n\n\treturn nil\n}", "func internLabelString(s string) string {\n\treturn intern.GetByString(s).Get().(string)\n}", "func (n *Node) labeledControl() *Node {\n\tif n.Op != OLABEL {\n\t\tFatalf(\"labeledControl %v\", n.Op)\n\t}\n\tctl := n.Name.Defn\n\tif ctl == nil {\n\t\treturn nil\n\t}\n\tswitch ctl.Op {\n\tcase OFOR, OFORUNTIL, OSWITCH, OSELECT:\n\t\treturn ctl\n\t}\n\treturn nil\n}", "func LabelOwnerCyclone() string {\n\treturn LabelOwner + \"=\" + OwnerCyclone\n}", "func (m *TransposableMatrix) SetLabel(x, y int, slt Slot) {\n\tbefore := m.Get(x, y)\n\tbefore.Label = slt.Label\n\tm.Set(x, y, before)\n}", "func (d *Decoder) SeekToLabel(p string) error {\n\treturn errTODO\n}", "func synchronize(kvsync kvs.Sync) {\n\tc := context.Background()\n\n\t// This is the object to be synchronized\n\tdb := Data{}\n\n\t// Creating a sync object from the provided lower-level kv sync.\n\ts := sync.Sync{\n\t\tSync: kvsync,\n\t}\n\n\t// Registering callback for given object with given format\n\ts.SyncObject(sync.SyncObject{\n\t\tCallback: SyncCallback,\n\t\tObject: &db,\n\t\tFormat: \"/db/stored/here/\",\n\t})\n\n\t// Time wheel to trigger callback notification for successive events\n\tfor {\n\t\te := s.Next(c)\n\t\tif e != nil {\n\t\t\tpanic(e)\n\t\t}\n\t\tif stopTimeWheel {\n\t\t\tbreak\n\t\t}\n\t}\n\n\tfmt.Printf(\"Final DB state %v\\n\\n\", &db)\n}", "func (r *ScaledObjectReconciler) ensureScaledObjectLabel(logger logr.Logger, scaledObject *kedav1alpha1.ScaledObject) error {\n\tconst labelScaledObjectName = \"scaledObjectName\"\n\n\tif scaledObject.Labels == nil {\n\t\tscaledObject.Labels = map[string]string{labelScaledObjectName: scaledObject.Name}\n\t} else {\n\t\tvalue, found := scaledObject.Labels[labelScaledObjectName]\n\t\tif found && value == scaledObject.Name {\n\t\t\treturn nil\n\t\t}\n\t\tscaledObject.Labels[labelScaledObjectName] = scaledObject.Name\n\t}\n\n\tlogger.V(1).Info(\"Adding scaledObjectName label on ScaledObject\", \"value\", scaledObject.Name)\n\treturn r.Client.Update(context.TODO(), scaledObject)\n}", "func (obj *labelDeclaration) Name() string {\n\treturn obj.name\n}", "func rcDefLabel(p *TCompiler, code *TCode) (*value.Value, error) {\n\tp.moveNext()\n\treturn nil, nil\n}", "func (b *buffer) Label(label string, indent int) {\n\tb.Write(fmt.Sprintf(\"%s:\\n\", strings.TrimSpace(label)), indent)\n}", "func (instance *Host) BindLabel(ctx context.Context, labelInstance resources.Label, value string) (ferr fail.Error) {\n\tdefer fail.OnPanic(&ferr)\n\n\tif instance == nil || valid.IsNil(instance) {\n\t\treturn fail.InvalidInstanceError()\n\t}\n\tif ctx == nil {\n\t\treturn fail.InvalidParameterCannotBeNilError(\"ctx\")\n\t}\n\tif labelInstance == nil {\n\t\treturn fail.InvalidParameterCannotBeNilError(\"label\")\n\t}\n\n\tlabelName := labelInstance.GetName()\n\n\tlabelID, err := labelInstance.GetID()\n\tif err != nil {\n\t\treturn fail.ConvertError(err)\n\t}\n\n\tinstanceID, err := instance.GetID()\n\tif err != nil {\n\t\treturn fail.ConvertError(err)\n\t}\n\n\t// Inform Label we want it bound to Host (updates its metadata)\n\txerr := labelInstance.BindToHost(ctx, instance, value)\n\txerr = debug.InjectPlannedFail(xerr)\n\tif xerr != nil {\n\t\treturn xerr\n\t}\n\tdefer func() {\n\t\tferr = debug.InjectPlannedFail(ferr)\n\t\tif ferr != nil {\n\t\t\tderr := labelInstance.UnbindFromHost(cleanupContextFrom(ctx), instance)\n\t\t\tif derr != nil {\n\t\t\t\t_ = ferr.AddConsequence(fail.Wrap(derr, \"cleaning up on failure\"))\n\t\t\t}\n\t\t}\n\t}()\n\n\tif value == \"\" {\n\t\tvalue, xerr = labelInstance.DefaultValue(ctx)\n\t\tif xerr != nil {\n\t\t\treturn xerr\n\t\t}\n\t}\n\n\txerr = instance.Alter(ctx, func(_ data.Clonable, props *serialize.JSONProperties) fail.Error {\n\t\treturn props.Alter(hostproperty.LabelsV1, func(clonable data.Clonable) fail.Error {\n\t\t\thostLabelsV1, ok := clonable.(*propertiesv1.HostLabels)\n\t\t\tif !ok {\n\t\t\t\treturn fail.InconsistentError(\"'*propertiesv1.HostLabels' expected, '%s' provided\", reflect.TypeOf(clonable).String())\n\t\t\t}\n\n\t\t\t// If the host already has this tag, consider it a success\n\t\t\t_, ok = hostLabelsV1.ByID[labelID]\n\t\t\tif !ok {\n\t\t\t\thostLabelsV1.ByID[labelID] = value\n\t\t\t\thostLabelsV1.ByName[labelName] = value\n\t\t\t}\n\t\t\treturn nil\n\t\t})\n\t})\n\txerr = debug.InjectPlannedFail(xerr)\n\tif xerr != nil {\n\t\treturn xerr\n\t}\n\n\tlmap, err := labelToMap(labelInstance, value)\n\tif err != nil {\n\t\treturn fail.ConvertError(err)\n\t}\n\n\tsvc := instance.Service()\n\txerr = svc.UpdateTags(ctx, abstract.HostResource, instanceID, lmap)\n\tif xerr != nil {\n\t\treturn xerr\n\t}\n\n\treturn nil\n}", "func (c *client) LabelNode(name string, labels map[string]string) error {\n\tif err := c.WaitForNode(name); err != nil {\n\t\treturn fmt.Errorf(\"failed waiting for node: %w\", err)\n\t}\n\n\tpatches := []patchStringValue{}\n\n\tfor k, v := range labels {\n\t\tpatches = append(patches, patchStringValue{\n\t\t\tOp: \"replace\",\n\t\t\tPath: fmt.Sprintf(\"/metadata/labels/%s\", strings.ReplaceAll(strings.ReplaceAll(k, \"~\", \"~0\"), \"/\", \"~1\")),\n\t\t\tValue: v,\n\t\t})\n\t}\n\n\tpayloadBytes, err := json.Marshal(patches)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to encode update payload: %w\", err)\n\t}\n\n\tif _, err := c.CoreV1().Nodes().Patch(name, types.JSONPatchType, payloadBytes); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (r *Release) mark(storageBackend string) {\n\tr.label(storageBackend, \"MANAGED-BY=HELMSMAN\", \"NAMESPACE=\"+r.Namespace, \"HELMSMAN_CONTEXT=\"+curContext)\n}" ]
[ "0.6950776", "0.6672603", "0.6315552", "0.60750383", "0.6066214", "0.60471725", "0.6046042", "0.5971814", "0.5971814", "0.5892775", "0.5892775", "0.5747266", "0.5720918", "0.5696668", "0.5656469", "0.56403005", "0.5635596", "0.5559489", "0.55570877", "0.546876", "0.5414075", "0.54065394", "0.53908956", "0.5362025", "0.53459406", "0.53459406", "0.52585554", "0.5216712", "0.51938033", "0.51859605", "0.5182911", "0.51785374", "0.5143245", "0.5128985", "0.5055641", "0.50408524", "0.50359887", "0.5010248", "0.49964508", "0.49864766", "0.49672157", "0.4943328", "0.49425185", "0.4928862", "0.49199566", "0.48983878", "0.48965865", "0.48868114", "0.48841956", "0.4879989", "0.48730174", "0.4863117", "0.4859172", "0.48501366", "0.48386505", "0.48207358", "0.48196438", "0.47813904", "0.47696847", "0.47586155", "0.4752556", "0.47507033", "0.47409964", "0.47394827", "0.47101855", "0.47096324", "0.47018644", "0.46997097", "0.46905643", "0.46904454", "0.4688705", "0.46829057", "0.46742105", "0.4668895", "0.46430832", "0.46418086", "0.4631804", "0.46174824", "0.4615136", "0.461016", "0.46100137", "0.45983025", "0.4596821", "0.4593996", "0.45843467", "0.45755365", "0.4574568", "0.4571761", "0.4567672", "0.4566726", "0.45644563", "0.45601532", "0.4553101", "0.45530912", "0.45491174", "0.45436087", "0.45343557", "0.45309895", "0.4527713" ]
0.66300714
3
multiply the current matrix with an orthographic matrix
func Ortho(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) { C.glowOrtho(gpOrtho, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func MatrixOrtho(left, right, bottom, top, near, far float32) Matrix {\n\tvar result Matrix\n\n\trl := right - left\n\ttb := top - bottom\n\tfn := far - near\n\n\tresult.M0 = 2.0 / rl\n\tresult.M1 = 0.0\n\tresult.M2 = 0.0\n\tresult.M3 = 0.0\n\tresult.M4 = 0.0\n\tresult.M5 = 2.0 / tb\n\tresult.M6 = 0.0\n\tresult.M7 = 0.0\n\tresult.M8 = 0.0\n\tresult.M9 = 0.0\n\tresult.M10 = -2.0 / fn\n\tresult.M11 = 0.0\n\tresult.M12 = -(left + right) / rl\n\tresult.M13 = -(top + bottom) / tb\n\tresult.M14 = -(far + near) / fn\n\tresult.M15 = 1.0\n\n\treturn result\n}", "func (matrix Matrix4) Mult(other Matrix4) Matrix4 {\n\n\tnewMat := NewMatrix4()\n\n\tnewMat[0][0] = matrix[0][0]*other[0][0] + matrix[0][1]*other[1][0] + matrix[0][2]*other[2][0] + matrix[0][3]*other[3][0]\n\tnewMat[1][0] = matrix[1][0]*other[0][0] + matrix[1][1]*other[1][0] + matrix[1][2]*other[2][0] + matrix[1][3]*other[3][0]\n\tnewMat[2][0] = matrix[2][0]*other[0][0] + matrix[2][1]*other[1][0] + matrix[2][2]*other[2][0] + matrix[2][3]*other[3][0]\n\tnewMat[3][0] = matrix[3][0]*other[0][0] + matrix[3][1]*other[1][0] + matrix[3][2]*other[2][0] + matrix[3][3]*other[3][0]\n\n\tnewMat[0][1] = matrix[0][0]*other[0][1] + matrix[0][1]*other[1][1] + matrix[0][2]*other[2][1] + matrix[0][3]*other[3][1]\n\tnewMat[1][1] = matrix[1][0]*other[0][1] + matrix[1][1]*other[1][1] + matrix[1][2]*other[2][1] + matrix[1][3]*other[3][1]\n\tnewMat[2][1] = matrix[2][0]*other[0][1] + matrix[2][1]*other[1][1] + matrix[2][2]*other[2][1] + matrix[2][3]*other[3][1]\n\tnewMat[3][1] = matrix[3][0]*other[0][1] + matrix[3][1]*other[1][1] + matrix[3][2]*other[2][1] + matrix[3][3]*other[3][1]\n\n\tnewMat[0][2] = matrix[0][0]*other[0][2] + matrix[0][1]*other[1][2] + matrix[0][2]*other[2][2] + matrix[0][3]*other[3][2]\n\tnewMat[1][2] = matrix[1][0]*other[0][2] + matrix[1][1]*other[1][2] + matrix[1][2]*other[2][2] + matrix[1][3]*other[3][2]\n\tnewMat[2][2] = matrix[2][0]*other[0][2] + matrix[2][1]*other[1][2] + matrix[2][2]*other[2][2] + matrix[2][3]*other[3][2]\n\tnewMat[3][2] = matrix[3][0]*other[0][2] + matrix[3][1]*other[1][2] + matrix[3][2]*other[2][2] + matrix[3][3]*other[3][2]\n\n\tnewMat[0][3] = matrix[0][0]*other[0][3] + matrix[0][1]*other[1][3] + matrix[0][2]*other[2][3] + matrix[0][3]*other[3][3]\n\tnewMat[1][3] = matrix[1][0]*other[0][3] + matrix[1][1]*other[1][3] + matrix[1][2]*other[2][3] + matrix[1][3]*other[3][3]\n\tnewMat[2][3] = matrix[2][0]*other[0][3] + matrix[2][1]*other[1][3] + matrix[2][2]*other[2][3] + matrix[2][3]*other[3][3]\n\tnewMat[3][3] = matrix[3][0]*other[0][3] + matrix[3][1]*other[1][3] + matrix[3][2]*other[2][3] + matrix[3][3]*other[3][3]\n\n\treturn newMat\n\n}", "func (m Matrix) Multiply(right Matrix) Matrix {\n\treturn Matrix{\n\t\tM0: m.M0*right.M0 + m.M1*right.M4 + m.M2*right.M8 + m.M3*right.M12,\n\t\tM1: m.M0*right.M1 + m.M1*right.M5 + m.M2*right.M9 + m.M3*right.M13,\n\t\tM2: m.M0*right.M2 + m.M1*right.M6 + m.M2*right.M10 + m.M3*right.M14,\n\t\tM3: m.M0*right.M3 + m.M1*right.M7 + m.M2*right.M11 + m.M3*right.M15,\n\t\tM4: m.M4*right.M0 + m.M5*right.M4 + m.M6*right.M8 + m.M7*right.M12,\n\t\tM5: m.M4*right.M1 + m.M5*right.M5 + m.M6*right.M9 + m.M7*right.M13,\n\t\tM6: m.M4*right.M2 + m.M5*right.M6 + m.M6*right.M10 + m.M7*right.M14,\n\t\tM7: m.M4*right.M3 + m.M5*right.M7 + m.M6*right.M11 + m.M7*right.M15,\n\t\tM8: m.M8*right.M0 + m.M9*right.M4 + m.M10*right.M8 + m.M11*right.M12,\n\t\tM9: m.M8*right.M1 + m.M9*right.M5 + m.M10*right.M9 + m.M11*right.M13,\n\t\tM10: m.M8*right.M2 + m.M9*right.M6 + m.M10*right.M10 + m.M11*right.M14,\n\t\tM11: m.M8*right.M3 + m.M9*right.M7 + m.M10*right.M11 + m.M11*right.M15,\n\t\tM12: m.M12*right.M0 + m.M13*right.M4 + m.M14*right.M8 + m.M15*right.M12,\n\t\tM13: m.M12*right.M1 + m.M13*right.M5 + m.M14*right.M9 + m.M15*right.M13,\n\t\tM14: m.M12*right.M2 + m.M13*right.M6 + m.M14*right.M10 + m.M15*right.M14,\n\t\tM15: m.M12*right.M3 + m.M13*right.M7 + m.M14*right.M11 + m.M15*right.M15,\n\t}\n}", "func MatrixMultiply(left, right Matrix) Matrix {\n\tvar result Matrix\n\n\tresult.M0 = left.M0*right.M0 + left.M1*right.M4 + left.M2*right.M8 + left.M3*right.M12\n\tresult.M1 = left.M0*right.M1 + left.M1*right.M5 + left.M2*right.M9 + left.M3*right.M13\n\tresult.M2 = left.M0*right.M2 + left.M1*right.M6 + left.M2*right.M10 + left.M3*right.M14\n\tresult.M3 = left.M0*right.M3 + left.M1*right.M7 + left.M2*right.M11 + left.M3*right.M15\n\tresult.M4 = left.M4*right.M0 + left.M5*right.M4 + left.M6*right.M8 + left.M7*right.M12\n\tresult.M5 = left.M4*right.M1 + left.M5*right.M5 + left.M6*right.M9 + left.M7*right.M13\n\tresult.M6 = left.M4*right.M2 + left.M5*right.M6 + left.M6*right.M10 + left.M7*right.M14\n\tresult.M7 = left.M4*right.M3 + left.M5*right.M7 + left.M6*right.M11 + left.M7*right.M15\n\tresult.M8 = left.M8*right.M0 + left.M9*right.M4 + left.M10*right.M8 + left.M11*right.M12\n\tresult.M9 = left.M8*right.M1 + left.M9*right.M5 + left.M10*right.M9 + left.M11*right.M13\n\tresult.M10 = left.M8*right.M2 + left.M9*right.M6 + left.M10*right.M10 + left.M11*right.M14\n\tresult.M11 = left.M8*right.M3 + left.M9*right.M7 + left.M10*right.M11 + left.M11*right.M15\n\tresult.M12 = left.M12*right.M0 + left.M13*right.M4 + left.M14*right.M8 + left.M15*right.M12\n\tresult.M13 = left.M12*right.M1 + left.M13*right.M5 + left.M14*right.M9 + left.M15*right.M13\n\tresult.M14 = left.M12*right.M2 + left.M13*right.M6 + left.M14*right.M10 + left.M15*right.M14\n\tresult.M15 = left.M12*right.M3 + left.M13*right.M7 + left.M14*right.M11 + left.M15*right.M15\n\n\treturn result\n}", "func MakeProductOperator(op *Operator, operands map[string]string) {\n\tinvertRight := operands[\"invertright\"] == \"yes\"\n\tparent1 := op.Parents[0]\n\tparent2 := op.Parents[1]\n\tvar matrix1 map[[2]int]*MatrixData\n\tvar matrix2 map[[2]int]*MatrixData\n\n\top.InitFunc = func(frame *Frame) {\n\t\tdriver.DeleteMatrixAfter(op.Name, frame.Time)\n\t\tmatrix1 = driver.LoadMatrixBefore(parent1.Name, frame.Time)\n\t\tmatrix2 = driver.LoadMatrixBefore(parent2.Name, frame.Time)\n\t\top.updateChildRerunTime(frame.Time)\n\t}\n\n\top.Func = func(frame *Frame, pd ParentData) {\n\t\tnewCells := make(map[[2]int]bool)\n\t\tfor _, md := range pd.MatrixData[0] {\n\t\t\tcell := [2]int{md.I, md.J}\n\t\t\tmatrix1[cell] = md\n\t\t\tnewCells[cell] = true\n\t\t}\n\t\tfor _, md := range pd.MatrixData[1] {\n\t\t\tcell := [2]int{md.I, md.J}\n\t\t\tmatrix2[cell] = md\n\t\t\tnewCells[cell] = true\n\t\t}\n\t\tfor cell := range newCells {\n\t\t\tif matrix1[cell] == nil || matrix2[cell] == nil {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tleft := matrix1[cell].Val\n\t\t\tright := matrix2[cell].Val\n\t\t\tif invertRight {\n\t\t\t\tright = 1 - right\n\t\t\t}\n\t\t\tAddMatrixData(op.Name, cell[0], cell[1], left * right, \"\", frame.Time)\n\t\t}\n\t}\n\n\top.Loader = op.MatrixLoader\n}", "func NewMatrixOrtho(left, right, bottom, top, near, far float64) Matrix {\n\trl := (right - left)\n\ttb := (top - bottom)\n\tfn := (far - near)\n\treturn Matrix{\n\t\tM0: float32(2 / rl),\n\t\tM1: 0,\n\t\tM2: 0,\n\t\tM3: 0,\n\t\tM4: 0,\n\t\tM5: float32(2 / tb),\n\t\tM6: 0,\n\t\tM7: 0,\n\t\tM8: 0,\n\t\tM9: 0,\n\t\tM10: float32(-2 / fn),\n\t\tM11: 0,\n\t\tM12: float32(-(left + right) / rl),\n\t\tM13: float32(-(top + bottom) / tb),\n\t\tM14: float32(-(far + near) / fn),\n\t\tM15: 1,\n\t}\n}", "func MatrixOrthoSubProjection(projection Matrix4f, orthoScale Vector2f, orthoDistance, eyeViewAdjustX float32) Matrix4f {\n\treturn matrix4f(C.ovrMatrix4f_OrthoSubProjection(c_matrix4f(projection), c_vector2f(orthoScale), C.float(orthoDistance), C.float(eyeViewAdjustX)))\n}", "func (mat Mat) MultiplyMatrix(mat_2 Mat) (Mat,error) {\n if mat.Shape[1] != mat_2.Shape[0] {\n return mat,&MatrixError{(\"Miss-matched shape.\")}\n }\n Shape := []int{ mat.Shape[1], mat_2.Shape[0]}\n var temp [][]float32\n for i := 0 ; i < Shape[0]; i++ {\n temp_r := make([]float32, Shape[1])\n for j := 0 ; j < Shape[1]; j++ {\n var p_val float32 = 0\n for k := 0; k < Shape[0]; k++ {\n p_val += mat.Value[i][k] * mat_2.Value[k][j]\n }\n temp_r[j] = p_val\n }\n temp = append(temp, temp_r)\n }\n return Mat{temp, Shape},nil\n}", "func (m *Mat4) Ortho(left, right, bottom, top, nearVal, farVal float64) *Mat4{\n\t*m = *Ortho4(left, right, bottom, top, nearVal, farVal)\n\n\treturn m\n}", "func (a *Mtx) Inverse() *Mtx {\n\tif a.inv != nil {\n\t\treturn a.inv\n\t}\n\ti := Identity()\n\te := a.el\n\ti.el[0][0] = e[1][1]*e[2][2]*e[3][3] - e[1][1]*e[2][3]*e[3][2] - e[2][1]*e[1][2]*e[3][3] + e[2][1]*e[1][3]*e[3][2] + e[3][1]*e[1][2]*e[2][3] - e[3][1]*e[1][3]*e[2][2]\n\ti.el[1][0] = e[1][0]*e[2][3]*e[3][2] - e[1][0]*e[2][2]*e[3][3] + e[2][0]*e[1][2]*e[3][3] - e[2][0]*e[1][3]*e[3][2] - e[3][0]*e[1][2]*e[2][3] + e[3][0]*e[1][3]*e[2][2]\n\ti.el[2][0] = e[1][0]*e[2][1]*e[3][3] - e[1][0]*e[2][3]*e[3][1] - e[2][0]*e[1][1]*e[3][3] + e[2][0]*e[1][3]*e[3][1] + e[3][0]*e[1][1]*e[2][3] - e[3][0]*e[1][3]*e[2][1]\n\ti.el[3][0] = e[1][0]*e[2][2]*e[3][1] - e[1][0]*e[2][1]*e[3][2] + e[2][0]*e[1][1]*e[3][2] - e[2][0]*e[1][2]*e[3][1] - e[3][0]*e[1][1]*e[2][2] + e[3][0]*e[1][2]*e[2][1]\n\ti.el[0][1] = e[0][1]*e[2][3]*e[3][2] - e[0][1]*e[2][2]*e[3][3] + e[2][1]*e[0][2]*e[3][3] - e[2][1]*e[0][3]*e[3][2] - e[3][1]*e[0][2]*e[2][3] + e[3][1]*e[0][3]*e[2][2]\n\ti.el[1][1] = e[0][0]*e[2][2]*e[3][3] - e[0][0]*e[2][3]*e[3][2] - e[2][0]*e[0][2]*e[3][3] + e[2][0]*e[0][3]*e[3][2] + e[3][0]*e[0][2]*e[2][3] - e[3][0]*e[0][3]*e[2][2]\n\ti.el[2][1] = e[0][0]*e[2][3]*e[3][1] - e[0][0]*e[2][1]*e[3][3] + e[2][0]*e[0][1]*e[3][3] - e[2][0]*e[0][3]*e[3][1] - e[3][0]*e[0][1]*e[2][3] + e[3][0]*e[0][3]*e[2][1]\n\ti.el[3][1] = e[0][0]*e[2][1]*e[3][2] - e[0][0]*e[2][2]*e[3][1] - e[2][0]*e[0][1]*e[3][2] + e[2][0]*e[0][2]*e[3][1] + e[3][0]*e[0][1]*e[2][2] - e[3][0]*e[0][2]*e[2][1]\n\ti.el[0][2] = e[0][1]*e[1][2]*e[3][3] - e[0][1]*e[1][3]*e[3][2] - e[1][1]*e[0][2]*e[3][3] + e[1][1]*e[0][3]*e[3][2] + e[3][1]*e[0][2]*e[1][3] - e[3][1]*e[0][3]*e[1][2]\n\ti.el[1][2] = e[0][0]*e[1][3]*e[3][2] - e[0][0]*e[1][2]*e[3][3] + e[1][0]*e[0][2]*e[3][3] - e[1][0]*e[0][3]*e[3][2] - e[3][0]*e[0][2]*e[1][3] + e[3][0]*e[0][3]*e[1][2]\n\ti.el[2][2] = e[0][0]*e[1][1]*e[3][3] - e[0][0]*e[1][3]*e[3][1] - e[1][0]*e[0][1]*e[3][3] + e[1][0]*e[0][3]*e[3][1] + e[3][0]*e[0][1]*e[1][3] - e[3][0]*e[0][3]*e[1][1]\n\ti.el[3][2] = e[0][0]*e[1][2]*e[3][1] - e[0][0]*e[1][1]*e[3][2] + e[1][0]*e[0][1]*e[3][2] - e[1][0]*e[0][2]*e[3][1] - e[3][0]*e[0][1]*e[1][2] + e[3][0]*e[0][2]*e[1][1]\n\ti.el[0][3] = e[0][1]*e[1][3]*e[2][2] - e[0][1]*e[1][2]*e[2][3] + e[1][1]*e[0][2]*e[2][3] - e[1][1]*e[0][3]*e[2][2] - e[2][1]*e[0][2]*e[1][3] + e[2][1]*e[0][3]*e[1][2]\n\ti.el[1][3] = e[0][0]*e[1][2]*e[2][3] - e[0][0]*e[1][3]*e[2][2] - e[1][0]*e[0][2]*e[2][3] + e[1][0]*e[0][3]*e[2][2] + e[2][0]*e[0][2]*e[1][3] - e[2][0]*e[0][3]*e[1][2]\n\ti.el[2][3] = e[0][0]*e[1][3]*e[2][1] - e[0][0]*e[1][1]*e[2][3] + e[1][0]*e[0][1]*e[2][3] - e[1][0]*e[0][3]*e[2][1] - e[2][0]*e[0][1]*e[1][3] + e[2][0]*e[0][3]*e[1][1]\n\ti.el[3][3] = e[0][0]*e[1][1]*e[2][2] - e[0][0]*e[1][2]*e[2][1] - e[1][0]*e[0][1]*e[2][2] + e[1][0]*e[0][2]*e[2][1] + e[2][0]*e[0][1]*e[1][2] - e[2][0]*e[0][2]*e[1][1]\n\tdet := 1.0 / (e[0][0]*i.el[0][0] + e[0][1]*i.el[1][0] + e[0][2]*i.el[2][0] + e[0][3]*i.el[3][0])\n\tfor j := 0; j < 4; j++ {\n\t\tfor k := 0; k < 4; k++ {\n\t\t\ti.el[j][k] *= det\n\t\t}\n\t}\n\ta.inv, i.inv = i, a\n\treturn i\n}", "func Pow(A Matrix, p int) Matrix {\n\tm, n := A.Dimensions()\n\tswitch {\n\tcase m != n:\n\t\tpanic(\"matrix must be square\")\n\tcase p < -1:\n\t\tpanic(\"power must be non-negative, except for -1\")\n\tcase p == -1:\n\t\treturn A.Inverse()\n\t}\n\n\t// Yacca's method\n\tB := Identity(m, n)\n\tC := A.Copy()\n\tfor ; 0 < p; p >>= 1 {\n\t\tif p&1 == 1 {\n\t\t\tB = Multiply(B, C)\n\t\t}\n\n\t\tC = Multiply(C, C)\n\t}\n\n\treturn B\n}", "func (m Matrix3) LeftMultiply(q Matrix3) (result Matrix3) {\n\tconst size = 3\n\tfor r := 0; r < size; r++ {\n\t\tfor c := 0; c < size; c++ {\n\t\t\tresult[r*size+c] = q.GetRow(r).Dot(m.GetCol(c))\n\t\t}\n\t}\n\treturn\n}", "func (a *Mtx) Mult(b *Mtx) *Mtx {\n\tm := Mtx{}\n\tfor i := 0; i < 4; i++ {\n\t\tfor j := 0; j < 4; j++ {\n\t\t\tfor k := 0; k < 4; k++ {\n\t\t\t\tm.el[j][i] += a.el[k][i] * b.el[j][k]\n\t\t\t}\n\t\t}\n\t}\n\treturn &m\n}", "func Multiply(matrix [][]float64, vector Vector) (product Vector) {\n\tproduct.X = matrix[0][0]*vector.X + matrix[0][1]*vector.Y + matrix[0][2]*vector.Z\n\tproduct.Y = matrix[1][0]*vector.X + matrix[1][1]*vector.Y + matrix[1][2]*vector.Z\n\tproduct.Z = matrix[2][0]*vector.X + matrix[2][1]*vector.Y + matrix[2][2]*vector.Z\n\treturn\n}", "func (mPointer *GF8Matrix) Inv() (*GF8Matrix, error) {\n\tm := NewMatrix(mPointer.numRow, mPointer.numCol)\n\tcopy(m.Matrix, mPointer.Matrix)\n\tif m.numCol != m.numRow {\n\t\tlog.Fatal(ErrNotSquareMatrix)\n\t}\n\t// extend identity matrix to right half\n\tfor r := 0; r < m.numRow; r++ {\n\t\tprepandArray := make([]byte, m.numCol)\n\t\tprepandArray[r] = 1\n\t\tm.Matrix[r] = append(m.Matrix[r], prepandArray...)\n\t}\n\toriginalNumCol := m.numCol\n\tm.numCol += originalNumCol\n\t// make left half identity\n\tfor r := 0; r < m.numRow; r++ {\n\t\t// find head\n\t\tsingularFlag := true\n\t\tfor iFindHead := r; iFindHead < m.numRow; iFindHead++ {\n\t\t\tif m.Matrix[iFindHead][r] != 0 {\n\t\t\t\tif iFindHead != r {\n\t\t\t\t\tm.swapRow(iFindHead, r)\n\t\t\t\t}\n\t\t\t\tsingularFlag = false\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif singularFlag {\n\t\t\treturn nil, ErrSingularMatrix\n\t\t}\n\t\t// make this diagnal unit\n\t\thead := m.Matrix[r][r]\n\t\tm.multRow(r, inverseTbl[head])\n\t\t// erase other rows\n\t\tfor rFollow := 0; rFollow < m.numRow; rFollow++ {\n\t\t\tif rFollow == r || m.Matrix[rFollow][r] == 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tm.mulAddToRow(r, m.Matrix[rFollow][r], rFollow)\n\t\t}\n\t}\n\t//remove left half\n\tfor r := 0; r < m.numRow; r++ {\n\t\tm.Matrix[r] = m.Matrix[r][originalNumCol:]\n\t}\n\tm.numCol = originalNumCol\n\n\tif SanityCheck {\n\t\tshouldBeIdentity := m.Mul(mPointer)\n\t\tshouldBeIdentity.ShowMatrix(SanityCheck)\n\t\tfor r := 0; r < m.numRow; r++ {\n\t\t\tfor c := 0; c < m.numCol; c++ {\n\t\t\t\tif r == c && shouldBeIdentity.Matrix[r][c] != 1 {\n\t\t\t\t\tlog.Fatalf(\"Fail the sanity check, %v != 1\", shouldBeIdentity.Matrix[r][c])\n\t\t\t\t} else if r != c && shouldBeIdentity.Matrix[r][c] != 0 {\n\t\t\t\t\tlog.Fatalf(\"Fail the sanity check, %v != 0\", shouldBeIdentity.Matrix[r][c])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn m, nil\n}", "func (eval *evaluator) MultiplyByDiagMatrix(ctIn *Ciphertext, matrix PtDiagMatrix, PoolDecompQP []rlwe.PolyQP, ctOut *Ciphertext) {\n\n\tringQ := eval.params.RingQ()\n\tringP := eval.params.RingP()\n\tringQP := rlwe.RingQP{RingQ: ringQ, RingP: ringP}\n\n\tlevelQ := utils.MinInt(ctOut.Level(), utils.MinInt(ctIn.Level(), matrix.Level))\n\tlevelP := len(ringP.Modulus) - 1\n\n\tQiOverF := eval.params.QiOverflowMargin(levelQ)\n\tPiOverF := eval.params.PiOverflowMargin(levelP)\n\n\tc0OutQP := rlwe.PolyQP{Q: ctOut.Value[0], P: eval.Pool[5].Q}\n\tc1OutQP := rlwe.PolyQP{Q: ctOut.Value[1], P: eval.Pool[5].P}\n\n\tct0TimesP := eval.Pool[0].Q // ct0 * P mod Q\n\ttmp0QP := eval.Pool[1]\n\ttmp1QP := eval.Pool[2]\n\tksRes0QP := eval.Pool[3]\n\tksRes1QP := eval.Pool[4]\n\n\tvar ctInTmp0, ctInTmp1 *ring.Poly\n\tif ctIn != ctOut {\n\t\tring.CopyValuesLvl(levelQ, ctIn.Value[0], eval.ctxpool.Value[0])\n\t\tring.CopyValuesLvl(levelQ, ctIn.Value[1], eval.ctxpool.Value[1])\n\t\tctInTmp0, ctInTmp1 = eval.ctxpool.Value[0], eval.ctxpool.Value[1]\n\t} else {\n\t\tctInTmp0, ctInTmp1 = ctIn.Value[0], ctIn.Value[1]\n\t}\n\n\tringQ.MulScalarBigintLvl(levelQ, ctInTmp0, ringP.ModulusBigint, ct0TimesP) // P*c0\n\n\tvar state bool\n\tvar cnt int\n\tfor k := range matrix.Vec {\n\n\t\tk &= int((ringQ.N >> 1) - 1)\n\n\t\tif k == 0 {\n\t\t\tstate = true\n\t\t} else {\n\n\t\t\tgalEl := eval.params.GaloisElementForColumnRotationBy(k)\n\n\t\t\trtk, generated := eval.rtks.Keys[galEl]\n\t\t\tif !generated {\n\t\t\t\tpanic(\"switching key not available\")\n\t\t\t}\n\n\t\t\tindex := eval.permuteNTTIndex[galEl]\n\n\t\t\teval.KeyswitchHoistedNoModDown(levelQ, PoolDecompQP, rtk, ksRes0QP.Q, ksRes1QP.Q, ksRes0QP.P, ksRes1QP.P)\n\t\t\tringQ.AddLvl(levelQ, ksRes0QP.Q, ct0TimesP, ksRes0QP.Q)\n\t\t\tringQP.PermuteNTTWithIndexLvl(levelQ, levelP, ksRes0QP, index, tmp0QP)\n\t\t\tringQP.PermuteNTTWithIndexLvl(levelQ, levelP, ksRes1QP, index, tmp1QP)\n\n\t\t\tif cnt == 0 {\n\t\t\t\t// keyswitch(c1_Q) = (d0_QP, d1_QP)\n\t\t\t\tringQP.MulCoeffsMontgomeryLvl(levelQ, levelP, matrix.Vec[k], tmp0QP, c0OutQP)\n\t\t\t\tringQP.MulCoeffsMontgomeryLvl(levelQ, levelP, matrix.Vec[k], tmp1QP, c1OutQP)\n\t\t\t} else {\n\t\t\t\t// keyswitch(c1_Q) = (d0_QP, d1_QP)\n\t\t\t\tringQP.MulCoeffsMontgomeryAndAddLvl(levelQ, levelP, matrix.Vec[k], tmp0QP, c0OutQP)\n\t\t\t\tringQP.MulCoeffsMontgomeryAndAddLvl(levelQ, levelP, matrix.Vec[k], tmp1QP, c1OutQP)\n\t\t\t}\n\n\t\t\tif cnt%QiOverF == QiOverF-1 {\n\t\t\t\tringQ.ReduceLvl(levelQ, c0OutQP.Q, c0OutQP.Q)\n\t\t\t\tringQ.ReduceLvl(levelQ, c1OutQP.Q, c1OutQP.Q)\n\t\t\t}\n\n\t\t\tif cnt%PiOverF == PiOverF-1 {\n\t\t\t\tringP.ReduceLvl(levelP, c0OutQP.P, c0OutQP.P)\n\t\t\t\tringP.ReduceLvl(levelP, c1OutQP.P, c1OutQP.P)\n\t\t\t}\n\n\t\t\tcnt++\n\t\t}\n\t}\n\n\tif cnt%QiOverF == 0 {\n\t\tringQ.ReduceLvl(levelQ, c0OutQP.Q, c0OutQP.Q)\n\t\tringQ.ReduceLvl(levelQ, c1OutQP.Q, c1OutQP.Q)\n\t}\n\n\tif cnt%PiOverF == 0 {\n\t\tringP.ReduceLvl(levelP, c0OutQP.P, c0OutQP.P)\n\t\tringP.ReduceLvl(levelP, c1OutQP.P, c1OutQP.P)\n\t}\n\n\teval.Baseconverter.ModDownQPtoQNTT(levelQ, levelP, c0OutQP.Q, c0OutQP.P, c0OutQP.Q) // sum(phi(c0 * P + d0_QP))/P\n\teval.Baseconverter.ModDownQPtoQNTT(levelQ, levelP, c1OutQP.Q, c1OutQP.P, c1OutQP.Q) // sum(phi(d1_QP))/P\n\n\tif state { // Rotation by zero\n\t\tringQ.MulCoeffsMontgomeryAndAddLvl(levelQ, matrix.Vec[0].Q, ctInTmp0, c0OutQP.Q) // ctOut += c0_Q * plaintext\n\t\tringQ.MulCoeffsMontgomeryAndAddLvl(levelQ, matrix.Vec[0].Q, ctInTmp1, c1OutQP.Q) // ctOut += c1_Q * plaintext\n\t}\n\n\tctOut.Scale = matrix.Scale * ctIn.Scale\n}", "func MatrixProjection(fov FovPort, znear, zfar float32, rightHanded bool) Matrix4f {\n\tif rightHanded {\n\t\treturn matrix4f(C.ovrMatrix4f_Projection(c_fovPort(fov), C.float(znear), C.float(zfar), 1))\n\t} else {\n\t\treturn matrix4f(C.ovrMatrix4f_Projection(c_fovPort(fov), C.float(znear), C.float(zfar), 0))\n\t}\n}", "func (pc *perspectiveCameraImp) MatrixWorldInverse() *threejs.Matrix4 {\n\treturn &threejs.Matrix4{Value: pc.JSValue().Get(\"matrixWorldInverse\")}\n}", "func (A Matrix) multiply(B Matrix) Matrix {\n\tma, na := A.Dimensions()\n\tmb, nb := B.Dimensions()\n\tif na != mb {\n\t\tpanic(\"A and B are of incompatible dimensions\")\n\t}\n\n\tf := func(i, j int) float64 {\n\t\tvar v float64\n\t\tfor k := 0; k < na; k++ {\n\t\t\tv += A[i][k] * B[k][j]\n\t\t}\n\n\t\treturn v\n\t}\n\n\treturn New(ma, nb, f)\n\n\t/*\n\t\t// Winograd's algorithm\n\t\t// Source: Analysis of Algorithms, 2nd Ed., by Jeffrey J.\n\t\t// McConnell, pg 139-140\n\t\tvar (\n\t\t\td = na >> 1\n\t\t\trfacts = make([]float64, 0, ma)\n\t\t\tcfacts = make([]float64, 0, nb)\n\t\t)\n\n\t\tfor i := 0; i < ma; i++ {\n\t\t\trfacts = append(rfacts, A[i][0]*A[i][1])\n\t\t\tfor j := 1; j < d; j++ {\n\t\t\t\trfacts[i] += A[i][j<<1] * A[i][j<<1+1]\n\t\t\t}\n\t\t}\n\n\t\tfor i := 0; i < nb; i++ {\n\t\t\tcfacts = append(cfacts, B[0][i]*B[1][i])\n\t\t\tfor j := 1; j < d; j++ {\n\t\t\t\tcfacts[i] += B[j<<1][i] * B[j<<1+1][i]\n\t\t\t}\n\t\t}\n\n\t\tC := Empty(ma, nb)\n\t\tfor i := 0; i < ma; i++ {\n\t\t\tfor j := 0; j < nb; j++ {\n\t\t\t\tC[i][j] = -rfacts[i] - cfacts[j]\n\t\t\t\tfor k := 0; k < d; k++ {\n\t\t\t\t\tC[i][j] += (A[i][k<<1] + B[k<<1+1][j]) * (A[i][k<<1+1] + B[2*k][j])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif na%1 == 1 {\n\t\t\tfor i := 0; i < ma; i++ {\n\t\t\t\tfor j := 0; j < nb; j++ {\n\t\t\t\t\tC[i][j] += A[i][na-1] * B[na-1][j]\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn C\n\t*/\n}", "func (m1 Matrix) Mul(m2 Matrix) Matrix {\n\treturn Matrix{\n\t\tm1[0]*m2[0] + m1[4]*m2[1] + m1[8]*m2[2] + m1[12]*m2[3],\n\t\tm1[1]*m2[0] + m1[5]*m2[1] + m1[9]*m2[2] + m1[13]*m2[3],\n\t\tm1[2]*m2[0] + m1[6]*m2[1] + m1[10]*m2[2] + m1[14]*m2[3],\n\t\tm1[3]*m2[0] + m1[7]*m2[1] + m1[11]*m2[2] + m1[15]*m2[3],\n\t\tm1[0]*m2[4] + m1[4]*m2[5] + m1[8]*m2[6] + m1[12]*m2[7],\n\t\tm1[1]*m2[4] + m1[5]*m2[5] + m1[9]*m2[6] + m1[13]*m2[7],\n\t\tm1[2]*m2[4] + m1[6]*m2[5] + m1[10]*m2[6] + m1[14]*m2[7],\n\t\tm1[3]*m2[4] + m1[7]*m2[5] + m1[11]*m2[6] + m1[15]*m2[7],\n\t\tm1[0]*m2[8] + m1[4]*m2[9] + m1[8]*m2[10] + m1[12]*m2[11],\n\t\tm1[1]*m2[8] + m1[5]*m2[9] + m1[9]*m2[10] + m1[13]*m2[11],\n\t\tm1[2]*m2[8] + m1[6]*m2[9] + m1[10]*m2[10] + m1[14]*m2[11],\n\t\tm1[3]*m2[8] + m1[7]*m2[9] + m1[11]*m2[10] + m1[15]*m2[11],\n\t\tm1[0]*m2[12] + m1[4]*m2[13] + m1[8]*m2[14] + m1[12]*m2[15],\n\t\tm1[1]*m2[12] + m1[5]*m2[13] + m1[9]*m2[14] + m1[13]*m2[15],\n\t\tm1[2]*m2[12] + m1[6]*m2[13] + m1[10]*m2[14] + m1[14]*m2[15],\n\t\tm1[3]*m2[12] + m1[7]*m2[13] + m1[11]*m2[14] + m1[15]*m2[15],\n\t}\n}", "func MatrixMode(mode uint32) {\n C.glowMatrixMode(gpMatrixMode, (C.GLenum)(mode))\n}", "func Ortho(left, right, bottom, top, nearVal, farVal gl.Float) *Mat4 {\n\tm := IdentMat4()\n\tm[0].X = 2.0 / (right - left)\n\tm[1].Y = 2.0 / (top - bottom)\n\tm[2].Z = -2.0 / (farVal - nearVal)\n\tm[3].X = -(right + left) / (right - left)\n\tm[3].Y = -(top + bottom) / (top - bottom)\n\tm[3].Z = -(farVal + nearVal) / (farVal - nearVal)\n\treturn m\n}", "func (r *Pow) Forward() mat.Matrix {\n\treturn r.x.Value().Pow(r.power)\n}", "func Mul(m1, m2 Matrix) Matrix {\n\tvar result Matrix\n\tm1 = m1.Transpose()\n\tfor i := 0; i < 4; i++ {\n\t\tfor j := 0; j < 4; j++ {\n\t\t\tresult[i][j] = vec32.Dot(m1[j], m2[i])\n\t\t}\n\t}\n\treturn result\n}", "func (m1 *Mat4) MulM(m2 *Mat4) *Mat4 {\n\tvar rm = Mat4{\n\t\t{\n\t\t\tm1[0].X*m2[0].X + m1[1].X*m2[0].Y + m1[2].X*m2[0].Z + m1[3].X*m2[0].W,\n\t\t\tm1[0].Y*m2[0].X + m1[1].Y*m2[0].Y + m1[2].Y*m2[0].Z + m1[3].Y*m2[0].W,\n\t\t\tm1[0].Z*m2[0].X + m1[1].Z*m2[0].Y + m1[2].Z*m2[0].Z + m1[3].Z*m2[0].W,\n\t\t\tm1[0].W*m2[0].X + m1[1].W*m2[0].Y + m1[2].W*m2[0].Z + m1[3].W*m2[0].W,\n\t\t},\n\t\t{\n\t\t\tm1[0].X*m2[1].X + m1[1].X*m2[1].Y + m1[2].X*m2[1].Z + m1[3].X*m2[1].W,\n\t\t\tm1[0].Y*m2[1].X + m1[1].Y*m2[1].Y + m1[2].Y*m2[1].Z + m1[3].Y*m2[1].W,\n\t\t\tm1[0].Z*m2[1].X + m1[1].Z*m2[1].Y + m1[2].Z*m2[1].Z + m1[3].Z*m2[1].W,\n\t\t\tm1[0].W*m2[1].X + m1[1].W*m2[1].Y + m1[2].W*m2[1].Z + m1[3].W*m2[1].W,\n\t\t},\n\t\t{\n\t\t\tm1[0].X*m2[2].X + m1[1].X*m2[2].Y + m1[2].X*m2[2].Z + m1[3].X*m2[2].W,\n\t\t\tm1[0].Y*m2[2].X + m1[1].Y*m2[2].Y + m1[2].Y*m2[2].Z + m1[3].Y*m2[2].W,\n\t\t\tm1[0].Z*m2[2].X + m1[1].Z*m2[2].Y + m1[2].Z*m2[2].Z + m1[3].Z*m2[2].W,\n\t\t\tm1[0].W*m2[2].X + m1[1].W*m2[2].Y + m1[2].W*m2[2].Z + m1[3].W*m2[2].W,\n\t\t},\n\t\t{\n\t\t\tm1[0].X*m2[3].X + m1[1].X*m2[3].Y + m1[2].X*m2[3].Z + m1[3].X*m2[3].W,\n\t\t\tm1[0].Y*m2[3].X + m1[1].Y*m2[3].Y + m1[2].Y*m2[3].Z + m1[3].Y*m2[3].W,\n\t\t\tm1[0].Z*m2[3].X + m1[1].Z*m2[3].Y + m1[2].Z*m2[3].Z + m1[3].Z*m2[3].W,\n\t\t\tm1[0].W*m2[3].X + m1[1].W*m2[3].Y + m1[2].W*m2[3].Z + m1[3].W*m2[3].W,\n\t\t},\n\t}\n\treturn &rm\n}", "func (obj *Device) MultiplyTransform(state TRANSFORMSTATETYPE, m MATRIX) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.MultiplyTransform,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(state),\n\t\tuintptr(unsafe.Pointer(&m[0])),\n\t)\n\treturn toErr(ret)\n}", "func MatrixMultiply(a [][]float64, b [][]float64) ([][]float64, error) {\n\n\tvar err error\n\n\tarows := len(a)\n\tacols := len(a[0])\n\tbrows := len(b)\n\tbcols := len(b[0])\n\n\terr = nil\n\tif acols != brows {\n\t\terr = fmt.Errorf(\"Number of Columns in the Matrix a must equal number rows in b\")\n\t\treturn nil, err\n\t}\n\n\t// creat a new target matrix\n\tnewarray := make([][]float64, arows)\n\tfrow := make([]float64, arows*(bcols))\n\tfor i := range newarray {\n\t\tnewarray[i], frow = frow[:bcols], frow[bcols:]\n\t}\n\n\tfor i := range newarray {\n\t\tfor j := range newarray[i] {\n\t\t\tfor k := 0; k < brows; k++ {\n\t\t\t\tnewarray[i][j] += a[i][k] * b[k][j]\n\t\t\t}\n\t\t}\n\t}\n\n\treturn newarray, err\n}", "func multiplyByOrder(s [][]int, i, j int, As ...Matrix) Matrix {\n\tif i < j {\n\t\treturn multiplyByOrder(s, i, s[i][j], As...).multiply(multiplyByOrder(s, s[i][j]+1, j, As...))\n\t}\n\n\treturn As[i]\n}", "func MOVAPS(mx, mx1 operand.Op) { ctx.MOVAPS(mx, mx1) }", "func Ortho2D(left, right, bottom, top float64) Mat4 {\n\treturn Ortho(left, right, bottom, top, -1, 1)\n}", "func Ortho(left, right, bottom, top, near, far float64) Mat4 {\n\trml, tmb, fmn := (right - left), (top - bottom), (far - near)\n\n\treturn Mat4{float64(2. / rml), 0, 0, 0, 0, float64(2. / tmb), 0, 0, 0, 0, float64(-2. / fmn), 0, float64(-(right + left) / rml), float64(-(top + bottom) / tmb), float64(-(far + near) / fmn), 1}\n}", "func (pc *perspectiveCameraImp) ProjectionMatrixInverse() *threejs.Matrix4 {\n\treturn &threejs.Matrix4{Value: pc.JSValue().Get(\"projectionMatrixInverse\")}\n}", "func multiplyStuff(finalMatrix *[][][]int64, matrix1 [][]int64, matrix2 [][]int64, i int) {\n\t(*finalMatrix)[i] = multiply(matrix1, matrix2)\n}", "func Matrix(index uint) uint {\n\tif index <= 1 {\n\t\treturn index\n\t}\n\n\tf := [2][2]uint{\n\t\t{1, 1},\n\t\t{1, 0},\n\t}\n\n\tf = matrixPower(f, index-1)\n\n\treturn f[0][0]\n}", "func orIdentity(a *bmatrix) {\n\tfor i := 0; i < n; i++ {\n\t\ta[i][i] = true\n\t}\n}", "func (a *Vec4) Multiply(s float32) {\n\ta.X *= s\n\ta.Y *= s\n\ta.Z *= s\n\ta.W *= s\n}", "func Ortho2D(left, right, bottom, top float32) Mat4 {\n\treturn Ortho(left, right, bottom, top, -1, 1)\n}", "func (r rsAVX2) matrixMul(start, end int, in, out Matrix) {\n\tfor i := 0; i < r.in; i++ {\n\t\ttmp := i * r.out\n\t\tfor oi := 0; oi < r.out; oi++ {\n\t\t\toffset := (tmp + oi) * 32\n\t\t\ttable := r.tables[offset : offset+32]\n\t\t\tif i == 0 {\n\t\t\t\tmulAVX2(table, in[i][start:end], out[oi][start:end])\n\t\t\t} else {\n\t\t\t\tmulXORAVX2(table, in[i][start:end], out[oi][start:end])\n\t\t\t}\n\t\t}\n\t}\n}", "func Ortho4(left, right, bottom, top, nearVal, farVal float64) (m *Mat4) {\n\ttx := -(right + left) / (right - left)\n\tty := -(top + bottom) / (top - bottom)\n\ttz := -(farVal + nearVal) / (farVal - nearVal)\n\n\tm = (*Mat4)(&[16]float64{2/(right-left), 0, 0, 0,\n 0, 2/(top-bottom), 0, 0,\n 0, 0, -2/(farVal-nearVal), 0,\n\t tx, ty, tz, 1})\n\n\treturn m;\n}", "func (A Matrix) Inverse() Matrix {\n\tm, n := A.Dimensions()\n\tif m != n {\n\t\tpanic(\"invalid dimensions\")\n\t}\n\n\tB := A.Join(Identity(m, m))\n\tfor i := 1; i < m; i++ {\n\t\tfor j := i; j < m; j++ {\n\t\t\tif B[j][j-1] != 0 {\n\t\t\t\tB[j].Divide(B[j][j-1])\n\t\t\t\tB[j].Multiply(B[j-1][j-1])\n\t\t\t\tB[j].Subtract(B[i-1])\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i := m - 2; 0 <= i; i-- {\n\t\tfor j := i; 0 <= j; j-- {\n\t\t\tif B[j][j+1] != 0 {\n\t\t\t\tB[j].Divide(B[j][j+1])\n\t\t\t\tB[j].Multiply(B[j+1][j+1])\n\t\t\t\tB[j].Subtract(B[i+1])\n\t\t\t}\n\t\t}\n\t}\n\n\tfor i, b := range B {\n\t\tif b[i] != 0 {\n\t\t\tb.Divide(b[i])\n\t\t}\n\t}\n\n\treturn New(m, m, func(i, j int) float64 { return B[i+m][j] })\n}", "func NewMatrix4Orthographic(left, right, top, bottom, near, far float32) *Matrix4 {\n\tma := NewDefaultMatrix4()\n\tma.MakeOrthographic(left, right, top, bottom, near, far)\n\treturn ma\n}", "func (p *Proc) Matrix(a, b, c, d, e, f float64) {\n\tp.stk.matrix(f32.NewAffine2D(\n\t\tfloat32(a), float32(b), float32(c),\n\t\tfloat32(d), float32(e), float32(f),\n\t))\n}", "func (o *Shape) InvMap(r, y []float64, x [][]float64) (err error) {\n\n\t// check\n\tif o.Gndim == 1 {\n\t\treturn chk.Err(\"Inverse mapping is not implemented in 1D\\n\")\n\t}\n\n\tvar δRnorm float64\n\te := make([]float64, o.Gndim) // residual\n\tδr := make([]float64, o.Gndim) // corrector\n\tr[0], r[1], r[2] = 0, 0, 0 // first trial\n\tit := 0\n\tderivs := true\n\tfor it = 0; it < INVMAP_NIT; it++ {\n\n\t\t// shape functions and derivatives\n\t\to.Func(o.S, o.DSdR, r, derivs, -1)\n\n\t\t// residual: e = y - x * S\n\t\tfor i := 0; i < o.Gndim; i++ {\n\t\t\te[i] = y[i]\n\t\t\tfor j := 0; j < o.Nverts; j++ {\n\t\t\t\te[i] -= x[i][j] * o.S[j]\n\t\t\t}\n\t\t}\n\n\t\t// Jmat == dxdR = x * dSdR;\n\t\tfor i := 0; i < len(x); i++ {\n\t\t\tfor j := 0; j < o.Gndim; j++ {\n\t\t\t\to.DxdR[i][j] = 0.0\n\t\t\t\tfor k := 0; k < o.Nverts; k++ {\n\t\t\t\t\to.DxdR[i][j] += x[i][k] * o.DSdR[k][j] // dxdR := x * dSdR\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Jimat == dRdx = Jmat.inverse();\n\t\to.J, err = la.MatInv(o.DRdx, o.DxdR, MINDET)\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\n\t\t// corrector: dR = Jimat * e\n\t\tfor i := 0; i < o.Gndim; i++ {\n\t\t\tδr[i] = 0.0\n\t\t\tfor j := 0; j < o.Gndim; j++ {\n\t\t\t\tδr[i] += o.DRdx[i][j] * e[j]\n\t\t\t}\n\t\t}\n\n\t\t// converged?\n\t\tδRnorm = 0.0\n\t\tfor i := 0; i < o.Gndim; i++ {\n\t\t\tr[i] += δr[i]\n\t\t\tδRnorm += δr[i] * δr[i]\n\t\t\t// fix r outside range\n\t\t\tif r[i] < -1.0 || r[i] > 1.0 {\n\t\t\t\tif math.Abs(r[i]-(-1.0)) < INVMAP_TOL {\n\t\t\t\t\tr[i] = -1.0\n\t\t\t\t}\n\t\t\t\tif math.Abs(r[i]-1.0) < INVMAP_TOL {\n\t\t\t\t\tr[i] = 1.0\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif math.Sqrt(δRnorm) < INVMAP_TOL {\n\t\t\tbreak\n\t\t}\n\t}\n\n\t// check\n\tif it == INVMAP_NIT {\n\t\treturn\n\t}\n\treturn\n}", "func transMatrix(pState []Pair) ([]float64) {\n var x float64 = 0.0\n tMat := make([]float64, len(pState))\n for i := range pState {\n x = float64(pState[i].cnt) + x\n }\n for i := range pState {\n tMat[i] = float64(pState[i].cnt) / x\n if i >= 1 {\n var y float64 = 0.0\n for j := i; j >= 0; j-- {\n y = float64(pState[j].cnt) + y\n }\n tMat[i] = y / x\n }\n }\n return tMat\n}", "func (mat Mat) InverseMatrix() (Mat,error) {\n if mat.Shape[0] != mat.Shape[1] {\n return mat,&MatrixError{\"Not a Square matrix.\"}\n }\n adj_mat,determinant := AdjointMatrix(mat)\n if determinant == 0 {\n return mat,&MatrixError{\"The determinant of the matrix is zero.\"}\n }\n adj_mat = adj_mat.MultiplyScalar(1/determinant)\n return adj_mat,nil\n}", "func MatrixTranspose(mat Matrix) Matrix {\n\tvar result Matrix\n\n\tresult.M0 = mat.M0\n\tresult.M1 = mat.M4\n\tresult.M2 = mat.M8\n\tresult.M3 = mat.M12\n\tresult.M4 = mat.M1\n\tresult.M5 = mat.M5\n\tresult.M6 = mat.M9\n\tresult.M7 = mat.M13\n\tresult.M8 = mat.M2\n\tresult.M9 = mat.M6\n\tresult.M10 = mat.M10\n\tresult.M11 = mat.M14\n\tresult.M12 = mat.M3\n\tresult.M13 = mat.M7\n\tresult.M14 = mat.M11\n\tresult.M15 = mat.M15\n\n\treturn result\n}", "func Inverse(m M) (M, error) {\n\tm = CopyMatrix(m)\n\n\tif m.Rows() != m.Cols() {\n\t\treturn m, errors.New(\"non-square matrices have no inverse\")\n\t}\n\n\tm, _ = Augment(m, Identity(m.r)) // ignore error because Identity will always match m row size\n\n\tm = Rref(m)\n\n\tfor c := 1; c <= m.Rows(); c++ { // must be square, so m.Rows() works here\n\t\tfound := false\n\t\tfor r := 1; r <= m.Rows(); r++ {\n\t\t\tif isLeadingEntry(m, r, c) && m.Get(r, c).Numerator() == 1 && m.Get(r, c).Denominator() == 1 { //Leading entry that is one\n\t\t\t\tfound = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t\tif !found { //no leading entry that is one... not the identity, not invertible :(\n\t\t\treturn m, errors.New(\"matrix has no inverse\")\n\t\t}\n\t}\n\n\trm := M{r: m.r, c: m.r, values: make([]Frac, m.r*m.r)}\n\n\tfor r := 1; r <= rm.Rows(); r++ {\n\t\tfor c := 1; c <= rm.Cols(); c++ {\n\t\t\trm.Set(r, c, m.Get(r, rm.Cols()+c))\n\t\t}\n\t}\n\n\treturn rm, nil\n}", "func MatrixLookAt(eye, target, up Vector3) Matrix {\n\tvar result Matrix\n\n\tz := Vector3Subtract(eye, target)\n\tz = Vector3Normalize(z)\n\tx := Vector3CrossProduct(up, z)\n\tx = Vector3Normalize(x)\n\ty := Vector3CrossProduct(z, x)\n\ty = Vector3Normalize(y)\n\n\tresult.M0 = x.X\n\tresult.M1 = x.Y\n\tresult.M2 = x.Z\n\tresult.M3 = -((x.X * eye.X) + (x.Y * eye.Y) + (x.Z * eye.Z))\n\tresult.M4 = y.X\n\tresult.M5 = y.Y\n\tresult.M6 = y.Z\n\tresult.M7 = -((y.X * eye.X) + (y.Y * eye.Y) + (y.Z * eye.Z))\n\tresult.M8 = z.X\n\tresult.M9 = z.Y\n\tresult.M10 = z.Z\n\tresult.M11 = -((z.X * eye.X) + (z.Y * eye.Y) + (z.Z * eye.Z))\n\tresult.M12 = 0.0\n\tresult.M13 = 0.0\n\tresult.M14 = 0.0\n\tresult.M15 = 1.0\n\n\treturn result\n}", "func (m *GF8Matrix) mulAddToRow(from int, coef byte, to int) {\n\tfor c := 0; c < m.numCol; c++ {\n\t\tm.Matrix[to][c] ^= mulTbl[m.Matrix[from][c]][coef]\n\t}\n\n}", "func (m Matrix) Transform(u vec32.Vector) (v vec32.Vector) {\n\tfor i := range v {\n\t\tfor j := range u {\n\t\t\tv[i] += m[i][j] * u[j]\n\t\t}\n\t}\n\treturn\n}", "func (c *Camera) Matrix() mgl32.Mat4 {\n\treturn mgl32.LookAtV(c.pos, c.pos.Add(c.front), c.up)\n}", "func MatrixInverse(scope *Scope, input tf.Output, optional ...MatrixInverseAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"MatrixInverse\",\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 transpose(minorMatrix [][]float64, dimension int, det float64) {\n\tvar i, j int\n\tinverseMatrix := make([][]float64, dimension)\n\tfor i = 0; i < dimension; i++ {\n\t\tinverseMatrix[i] = make([]float64, dimension)\n\t\tfor j = 0; j < dimension; j++ {\n\t\t\tinverseMatrix[i][j] = minorMatrix[j][i] / det\n\t\t}\n\t}\n\t/*\n\t\tprint the inverse matrix\n\t*/\n\tprintMatrix(inverseMatrix, dimension)\n}", "func MultiplyRow(A Matrix, i int, a float64) Matrix {\n\tm, n := A.Dimensions()\n\tf := func(j, k int) float64 {\n\t\tif i == j {\n\t\t\treturn a * A[j][k]\n\t\t}\n\t\treturn A[j][k]\n\t}\n\n\treturn New(m, n, f)\n}", "func (m IntMatrix2D) Times(other IntMatrix2D) *IntMatrix2D {\n\t// When multipling 2 matrices, [m1xn1] and [m2xn2], n1 shall equal m2.\n\tif m.ncols != other.nrows {\n\t\treturn nil\n\t}\n\n\tproduct, _ := New2D(m.nrows, other.ncols)\n\totherT := other.Transpose() // [m2xn2] Matrix -> [n2xm2] Matrix\n\trowLen := otherT.ncols // m2 == n1\n\t// Each location (i,j) in product corresponds to the dot product of row\n\t// row i in m and row j in otherT.\n\tfor i := 0; i < product.nrows; i++ {\n\t\tmRow := m.mat[i]\n\t\tfor j := 0; j < product.ncols; j++ {\n\t\t\totherTRow := otherT.mat[j]\n\t\t\tfor k := 0; k < rowLen; k++ {\n\t\t\t\tproduct.mat[i][j] += mRow[k] * otherTRow[k]\n\t\t\t}\n\t\t}\n\t}\n\treturn product\n}", "func MatrixMode(mode uint32) {\n\tC.glowMatrixMode(gpMatrixMode, (C.GLenum)(mode))\n}", "func (t *Transform) build() {\n\tvar parent *Transform\n\tif t.parent != nil {\n\t\tparent = t.parent.Transform()\n\t}\n\n\tnilParents := t.lastParent == nil && parent == nil\n\tnonNilParents := t.lastParent != nil && parent != nil\n\tif t.built != nil && (nilParents || (nonNilParents && t.lastParent.Equals(parent.Mat4()))) {\n\t\t// No update is required.\n\t\treturn\n\t}\n\tif parent != nil {\n\t\tparentMat := parent.Mat4()\n\t\tt.lastParent = &parentMat\n\t}\n\n\t// Apply rotation\n\tvar hpr lmath.Vec3\n\tif t.quat != nil {\n\t\t// Use quaternion rotation.\n\t\thpr = (*t.quat).Hpr(lmath.CoordSysZUpRight)\n\t} else {\n\t\t// Use euler rotation.\n\t\thpr = t.rot.XyzToHpr().Radians()\n\t}\n\n\t// Compose upper 3x3 matrics using scale, shear, and HPR components.\n\tscaleShearHpr := lmath.Mat3Compose(t.scale, t.shear, hpr, lmath.CoordSysZUpRight)\n\n\t// Build this space's transformation matrix.\n\tif t.built == nil {\n\t\tt.built = new(lmath.Mat4)\n\t}\n\t*t.built = lmath.Mat4Identity\n\t*t.built = t.built.SetUpperMat3(scaleShearHpr)\n\t*t.built = t.built.SetTranslation(t.pos)\n\n\t// Build the local-to-world transformation matrix.\n\tif t.localToWorld == nil {\n\t\tt.localToWorld = new(lmath.Mat4)\n\t}\n\t*t.localToWorld = *t.built\n\tif parent != nil {\n\t\t*t.localToWorld = t.localToWorld.Mul(parent.Convert(LocalToWorld))\n\t}\n\n\t// Build the world-to-local transformation matrix.\n\twtl, _ := t.built.Inverse()\n\tif parent != nil {\n\t\tparentToWorld := parent.Convert(WorldToLocal)\n\t\twtl = wtl.Mul(parentToWorld)\n\t}\n\tif t.worldToLocal == nil {\n\t\tt.worldToLocal = new(lmath.Mat4)\n\t}\n\t*t.worldToLocal = wtl\n}", "func Multiply(a, b M) (M, error) {\n\tif a.c != b.r {\n\t\treturn a, errors.New(\"multiplication can only be done on matrices A and B if the number of columns of A equals the number of rows of B\")\n\t}\n\n\trm := M{r: a.r, c: b.c, values: make([]Frac, a.r*b.c)}\n\n\tfor r := 1; r <= rm.Rows(); r++ {\n\t\tfor c := 1; c <= rm.Cols(); c++ {\n\t\t\tsum := NewScalarFrac(0)\n\t\t\tfor count := 1; count <= a.c; count++ {\n\t\t\t\tf1 := a.Get(r, count)\n\t\t\t\tf2 := b.Get(count, c)\n\t\t\t\tres := f1.Mul(f2)\n\t\t\t\tsum = sum.Add(res)\n\t\t\t}\n\t\t\trm.Set(r, c, sum)\n\t\t}\n\t}\n\n\treturn rm, nil\n}", "func Rref(m M) M {\n\tm = CopyMatrix(m)\n\n\tm = Ref(m)\n\n\tfor c := 1; c <= m.Cols(); c++ {\n\t\tfor r := 1; r <= m.Rows(); r++ {\n\t\t\tif isLeadingEntry(m, r, c) {\n\t\t\t\tm.MultiplyRow(r, m.Get(r, c).Reciprocal()) // make the leading entry 1\n\t\t\t\tfor rr := r - 1; rr > 0; rr-- { // for each row above the current row...\n\t\t\t\t\tif !m.Get(rr, c).IsZero() {\n\t\t\t\t\t\tm.MultiplyAndAddRow(r, m.Get(rr, c).Neg().Mul(m.Get(r, c).Reciprocal()), rr) // clear entry above leading entry\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn m\n}", "func (a *Mtx) MultPoint(v Vec) (result Vec) {\n\tresult.X = v.X*a.el[0][0] + v.Y*a.el[1][0] + v.Z*a.el[2][0] + a.el[3][0]\n\tresult.Y = v.X*a.el[0][1] + v.Y*a.el[1][1] + v.Z*a.el[2][1] + a.el[3][1]\n\tresult.Z = v.X*a.el[0][2] + v.Y*a.el[1][2] + v.Z*a.el[2][2] + a.el[3][2]\n\t// final row assumed to be [0,0,0,1]\n\treturn\n}", "func invertMatrix(matrix []byte, k int) error {\n\tpivot_searcher := newPivotSearcher(k)\n\tindxc := make([]int, k)\n\tindxr := make([]int, k)\n\tid_row := make([]byte, k)\n\n\tfor col := 0; col < k; col++ {\n\t\ticol, irow, err := pivot_searcher.search(col, matrix)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif irow != icol {\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tswap(&matrix[irow*k+i], &matrix[icol*k+i])\n\t\t\t}\n\t\t}\n\n\t\tindxr[col] = irow\n\t\tindxc[col] = icol\n\t\tpivot_row := matrix[icol*k:][:k]\n\t\tc := pivot_row[icol]\n\n\t\tif c == 0 {\n\t\t\treturn Error.New(\"singular matrix\")\n\t\t}\n\n\t\tif c != 1 {\n\t\t\tc = gf_inverse[c]\n\t\t\tpivot_row[icol] = 1\n\t\t\tmul_c := gf_mul_table[c][:]\n\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tpivot_row[i] = mul_c[pivot_row[i]]\n\t\t\t}\n\t\t}\n\n\t\tid_row[icol] = 1\n\t\tif !bytes.Equal(pivot_row, id_row) {\n\t\t\tp := matrix\n\t\t\tfor i := 0; i < k; i++ {\n\t\t\t\tif i != icol {\n\t\t\t\t\tc = p[icol]\n\t\t\t\t\tp[icol] = 0\n\t\t\t\t\taddmul(p[:k], pivot_row, c)\n\t\t\t\t}\n\t\t\t\tp = p[k:]\n\t\t\t}\n\t\t}\n\n\t\tid_row[icol] = 0\n\t}\n\n\tfor i := 0; i < k; i++ {\n\t\tif indxr[i] != indxc[i] {\n\t\t\tfor row := 0; row < k; row++ {\n\t\t\t\tswap(&matrix[row*k+indxr[i]], &matrix[row*k+indxc[i]])\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func (mesh *Mesh) ApplyMatrix(matrix Matrix4) {\n\n\tfor _, tri := range mesh.Triangles {\n\t\tfor _, vert := range tri.Vertices {\n\t\t\tvert.Position = matrix.MultVec(vert.Position)\n\t\t}\n\t\ttri.RecalculateCenter()\n\t}\n\n\tmesh.UpdateBounds()\n\n}", "func (vn *VecN) OuterProd(dst *MatMxN, v2 *VecN) *MatMxN {\n\tif vn == nil || v2 == nil {\n\t\treturn nil\n\t}\n\n\tdst = dst.Reshape(len(vn.vec), len(v2.vec))\n\n\tfor c, el1 := range v2.vec {\n\t\tfor r, el2 := range vn.vec {\n\t\t\tdst.Set(r, c, el1*el2)\n\t\t}\n\t}\n\n\treturn dst\n}", "func Plus(A, B *Matrix) *Matrix {\n\t return Zeros(A.height, A.width).Plus(A, B)\n}", "func MatrixMode(mode uint32) {\n\tsyscall.Syscall(gpMatrixMode, 1, uintptr(mode), 0, 0)\n}", "func matrixMult(a [][]int, b [][]int) (c [][]int) {\n\tc = make([][]int, len(a))\n\tfor i := range c {\n\t\tc[i] = make([]int, len(b[0]))\n\t}\n\tif len(a[0]) != len(b) {\n\t\tfmt.Println(\"can't multiply these two matrices\")\n\t\treturn c\n\t}\n\tfor i := 0; i < len(a); i++ {\n\t\tfor j := 0; j < len(b[0]); j++ {\n\t\t\tfor k := 0; k < len(b); k++ {\n\t\t\t\tc[i][j] = c[i][j] + a[i][k]*b[k][j]\n\t\t\t}\n\t\t}\n\t}\n\treturn c\n}", "func ORPS(mx, x operand.Op) { ctx.ORPS(mx, x) }", "func Ortho(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n C.glowOrtho(gpOrtho, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func MatrixRotation(matrix [][]int32, r int32) {\n\trows := len(matrix)\n\tcols := len(matrix[0])\n\n\tl := int(math.Round(math.Min(float64(rows), float64(cols))) / 2.0)\n\n\tfor i := 0; r > 0 && i < l; i++ {\n\t\tlayer := make([]int32, 2*(rows-2*i+cols-2*i-2))\n\t\trot := int(r) % len(layer)\n\t\tif rot == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\t// Walk the matrix clockwise starting from top left and collect the values\n\t\t// for each layer.\n\n\t\tc := 0\n\n\t\t// top left to top right\n\t\tfor j := i; j < cols-i-1; j++ {\n\t\t\tlayer[c] = matrix[i][j]\n\t\t\tc++\n\t\t}\n\t\t// top right to bottom right\n\t\tfor j := i; j < rows-i-1; j++ {\n\t\t\tlayer[c] = matrix[j][cols-i-1]\n\t\t\tc++\n\t\t}\n\t\t// bottom right to bottom left\n\t\tfor j := cols - i - 1; j > i; j-- {\n\t\t\tlayer[c] = matrix[rows-i-1][j]\n\t\t\tc++\n\t\t}\n\t\t// bottom left to top left\n\t\tfor j := rows - i - 1; j > i; j-- {\n\t\t\tlayer[c] = matrix[j][i]\n\t\t\tc++\n\t\t}\n\n\t\t// Left shift values.\n\t\tlayer = append(layer[rot:], layer[:rot]...)\n\n\t\t// Populate the matrix with the values from layer.\n\n\t\tc = 0\n\n\t\t// top left to top right\n\t\tfor j := i; j < cols-i-1; j++ {\n\t\t\tmatrix[i][j] = layer[c]\n\t\t\tc++\n\t\t}\n\t\t// top right to bottom right\n\t\tfor j := i; j < rows-i-1; j++ {\n\t\t\tmatrix[j][cols-i-1] = layer[c]\n\t\t\tc++\n\t\t}\n\t\t// bottom right to bottom left\n\t\tfor j := cols - i - 1; j > i; j-- {\n\t\t\tmatrix[rows-i-1][j] = layer[c]\n\t\t\tc++\n\t\t}\n\t\t// bottom left to top left\n\t\tfor j := rows - i - 1; j > i; j-- {\n\t\t\tmatrix[j][i] = layer[c]\n\t\t\tc++\n\t\t}\n\t}\n\n\t// Print the matrix.\n\tfor i := 0; i < rows; i++ {\n\t\tfor j := 0; j < cols; j++ {\n\t\t\tfmt.Print(matrix[i][j])\n\t\t\tif j < cols-1 {\n\t\t\t\tfmt.Print(\" \")\n\t\t\t}\n\t\t}\n\t\tfmt.Print(\"\\n\")\n\t}\n}", "func (ms *matrixStack) AssignMul(a *mat4.T) {\n\tproduct := mat4.Zero\n\tfor col := 0; col < a.Cols(); col++ {\n\t\tfor row := 0; row < a.Rows(); row++ {\n\t\t\tfor vecPos := 0; vecPos < a.Rows(); vecPos++ {\n\t\t\t\tproduct[col][row] += ms.T[vecPos][row] * a[col][vecPos]\n\t\t\t}\n\t\t}\n\t}\n\tms.T = product\n}", "func ORL(imr, emr operand.Op) { ctx.ORL(imr, emr) }", "func (m Matrix) Mul(n Matrix) Matrix {\n\treturn Matrix{\n\t\tm[0]*n[0] + m[1]*n[2],\n\t\tm[1]*n[3] + m[0]*n[1],\n\t\tm[2]*n[0] + m[3]*n[2],\n\t\tm[3]*n[3] + m[2]*n[1],\n\t\tm[4]*n[0] + m[5]*n[2] + n[4],\n\t\tm[5]*n[3] + m[4]*n[1] + n[5],\n\t}\n}", "func (mat *Matrix) MultiplyElements(other *Matrix) *Matrix {\n\t//Verify inputs\n\tm, n := mat.Dimensions()\n\to, p := other.Dimensions()\n\tif m != o || n != p {\n\t\tpanic(fmt.Sprintf(\"Cannot add matrices of different sizes. Matrixes are of sizes (%v, %v), and (%v, %v)\",\n\t\t\tm, n, o, p))\n\t}\n\n\tresult := Matrix{}.NewMatrix(m, n)\n\tfor i := 0; i < m; i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tresult.SetValue(i, j, mat.GetValue(i, j)*other.GetValue(i, j))\n\t\t}\n\t}\n\n\treturn result\n}", "func ORW(imr, amr operand.Op) { ctx.ORW(imr, amr) }", "func (t *TriDense) Copy(a Matrix) (r, c int) {\n\tr, c = a.Dims()\n\tr = min(r, t.mat.N)\n\tc = min(c, t.mat.N)\n\tif r == 0 || c == 0 {\n\t\treturn 0, 0\n\t}\n\n\tswitch a := a.(type) {\n\tcase RawMatrixer:\n\t\tamat := a.RawMatrix()\n\t\tif t.isUpper() {\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride+i:i*t.mat.Stride+c], amat.Data[i*amat.Stride+i:i*amat.Stride+c])\n\t\t\t}\n\t\t} else {\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride:i*t.mat.Stride+i+1], amat.Data[i*amat.Stride:i*amat.Stride+i+1])\n\t\t\t}\n\t\t}\n\tcase RawTriangular:\n\t\tamat := a.RawTriangular()\n\t\taIsUpper := isUpperUplo(amat.Uplo)\n\t\ttIsUpper := t.isUpper()\n\t\tswitch {\n\t\tcase tIsUpper && aIsUpper:\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride+i:i*t.mat.Stride+c], amat.Data[i*amat.Stride+i:i*amat.Stride+c])\n\t\t\t}\n\t\tcase !tIsUpper && !aIsUpper:\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tcopy(t.mat.Data[i*t.mat.Stride:i*t.mat.Stride+i+1], amat.Data[i*amat.Stride:i*amat.Stride+i+1])\n\t\t\t}\n\t\tdefault:\n\t\t\tfor i := 0; i < r; i++ {\n\t\t\t\tt.set(i, i, amat.Data[i*amat.Stride+i])\n\t\t\t}\n\t\t}\n\tdefault:\n\t\tisUpper := t.isUpper()\n\t\tfor i := 0; i < r; i++ {\n\t\t\tif isUpper {\n\t\t\t\tfor j := i; j < c; j++ {\n\t\t\t\t\tt.set(i, j, a.At(i, j))\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tfor j := 0; j <= i; j++ {\n\t\t\t\t\tt.set(i, j, a.At(i, j))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn r, c\n}", "func (m *M) MultiplyRow(r int, s Frac) {\n\tr = r - 1\n\tfor c := 0; c < m.c; c++ {\n\t\tm.values[r*m.c+c] = m.values[r*m.c+c].Mul(s).Reduce()\n\t}\n}", "func MatrixInvert(mat Matrix) Matrix {\n\tvar result Matrix\n\n\ta00 := mat.M0\n\ta01 := mat.M1\n\ta02 := mat.M2\n\ta03 := mat.M3\n\ta10 := mat.M4\n\ta11 := mat.M5\n\ta12 := mat.M6\n\ta13 := mat.M7\n\ta20 := mat.M8\n\ta21 := mat.M9\n\ta22 := mat.M10\n\ta23 := mat.M11\n\ta30 := mat.M12\n\ta31 := mat.M13\n\ta32 := mat.M14\n\ta33 := mat.M15\n\n\tb00 := a00*a11 - a01*a10\n\tb01 := a00*a12 - a02*a10\n\tb02 := a00*a13 - a03*a10\n\tb03 := a01*a12 - a02*a11\n\tb04 := a01*a13 - a03*a11\n\tb05 := a02*a13 - a03*a12\n\tb06 := a20*a31 - a21*a30\n\tb07 := a20*a32 - a22*a30\n\tb08 := a20*a33 - a23*a30\n\tb09 := a21*a32 - a22*a31\n\tb10 := a21*a33 - a23*a31\n\tb11 := a22*a33 - a23*a32\n\n\t// Calculate the invert determinant (inlined to avoid double-caching)\n\tinvDet := 1.0 / (b00*b11 - b01*b10 + b02*b09 + b03*b08 - b04*b07 + b05*b06)\n\n\tresult.M0 = (a11*b11 - a12*b10 + a13*b09) * invDet\n\tresult.M1 = (-a01*b11 + a02*b10 - a03*b09) * invDet\n\tresult.M2 = (a31*b05 - a32*b04 + a33*b03) * invDet\n\tresult.M3 = (-a21*b05 + a22*b04 - a23*b03) * invDet\n\tresult.M4 = (-a10*b11 + a12*b08 - a13*b07) * invDet\n\tresult.M5 = (a00*b11 - a02*b08 + a03*b07) * invDet\n\tresult.M6 = (-a30*b05 + a32*b02 - a33*b01) * invDet\n\tresult.M7 = (a20*b05 - a22*b02 + a23*b01) * invDet\n\tresult.M8 = (a10*b10 - a11*b08 + a13*b06) * invDet\n\tresult.M9 = (-a00*b10 + a01*b08 - a03*b06) * invDet\n\tresult.M10 = (a30*b04 - a31*b02 + a33*b00) * invDet\n\tresult.M11 = (-a20*b04 + a21*b02 - a23*b00) * invDet\n\tresult.M12 = (-a10*b09 + a11*b07 - a12*b06) * invDet\n\tresult.M13 = (a00*b09 - a01*b07 + a02*b06) * invDet\n\tresult.M14 = (-a30*b03 + a31*b01 - a32*b00) * invDet\n\tresult.M15 = (a20*b03 - a21*b01 + a22*b00) * invDet\n\n\treturn result\n}", "func MatInv(m u.Matrix) (u.Matrix, error) {\n\tvar (\n\t\terr = m.SetSize()\n\t\tresultMat u.Matrix\n\t\tmv = m.Value\n\t)\n\tif err != nil {\n\t\treturn u.Matrix{}, err\n\t}\n\n\tif m.ColsNum == 2 && m.RowsNum == 2 {\n\t\tnm := u.Matrix{\n\t\t\tRowsNum: 2,\n\t\t\tColsNum: 2,\n\t\t\tValue: u.MatVal{\n\t\t\t\t{mv[1][1], -mv[0][1]},\n\t\t\t\t{-mv[1][0], mv[0][0]},\n\t\t\t},\n\t\t}\n\n\t\tdetM := mv[0][0]*mv[1][1] - mv[0][1]*mv[1][0]\n\t\tif detM == 0 {\n\t\t\treturn u.Matrix{}, errors.New(\"matrix is singular, does not have an inverse\")\n\t\t}\n\n\t\treturn mult.ScalarMult(1/detM, nm), nil\n\t}\n\n\t// matrix of minors\n\tresultMat = u.PopulateNewMat(u.MatPopConfig{\n\t\tMainMat: m,\n\t\tNewRows: m.RowsNum,\n\t\tNewCols: m.ColsNum,\n\t\tAction: func(mv u.MatVal, r, c int, secMvs []u.MatVal) float64 {\n\t\t\tminor := u.GetMinor(m, r, c)\n\t\t\tdetMinor, _ := det.MatDet(minor) // add error handling in the future\n\n\t\t\treturn math.Pow(-1, float64(r+c)) * detMinor\n\t\t},\n\t})\n\n\tresultMat, err = trans.MatTrans(resultMat)\n\tif err != nil {\n\t\treturn u.Matrix{}, err\n\t}\n\n\tdetM, err := det.MatDet(m)\n\tif err != nil {\n\t\treturn u.Matrix{}, err\n\t} else if detM == 0 {\n\t\treturn u.Matrix{}, errors.New(\"matrix is singular, does not have an inverse\")\n\t}\n\n\tresultMat = mult.ScalarMult(1/detM, resultMat)\n\n\treturn resultMat, nil\n}", "func (this *BigInteger) MultiplyTo(a *BigInteger, r *BigInteger) {\n\tx := this.Abs()\n\ty := a.Abs()\n\ti := x.T\n\tr.T = i + y.T\n\tfor i--; i >= 0; i-- {\n\t\tr.V[i] = 0\n\t}\n\tfor i = 0; i < y.T; i++ {\n\t\tr.V[i+x.T] = x.AM(0, y.V[i], r, i, 0, x.T)\n\t}\n\tr.S = 0\n\tr.clamp()\n\tif this.S != a.S {\n\t\tZERO.SubTo(r, r)\n\t}\n}", "func NormalEquation(X Matrix, y Matrix)Matrix{\n\t//note: when the normal equation meets the problem of non-invertible matrix\n\t//\t\tregularized normal equation can fix it ;-)\n\t//\t\tjust put a really small number like o.ooo1 into lambda\n\n\tif y.Row != X.Row || y.Column != 1{\n\t\tpanic(\"value format error\")\n\t}\n\tXT := TransposeMatrix(X)\n\treturn MatrixMultiplication(MatrixMultiplication(InverseMatrix(MatrixMultiplication(XT, X)), XT), y)\n\n\n}", "func InverseMat4(m Mat4) Mat4 {\n\tminor11 := m.M22*m.M33*m.M44 + m.M23*m.M34*m.M42 + m.M24*m.M32*m.M43 - m.M24*m.M33*m.M42 - m.M23*m.M32*m.M44 - m.M22*m.M34*m.M43\n\tminor12 := m.M21*m.M33*m.M44 + m.M23*m.M34*m.M41 + m.M24*m.M31*m.M43 - m.M24*m.M33*m.M41 - m.M23*m.M31*m.M44 - m.M21*m.M34*m.M43\n\tminor13 := m.M21*m.M32*m.M44 + m.M22*m.M34*m.M41 + m.M24*m.M31*m.M42 - m.M24*m.M32*m.M41 - m.M22*m.M31*m.M44 - m.M21*m.M34*m.M42\n\tminor14 := m.M21*m.M32*m.M43 + m.M22*m.M33*m.M41 + m.M23*m.M31*m.M42 - m.M23*m.M32*m.M41 - m.M22*m.M31*m.M43 - m.M21*m.M33*m.M42\n\tminor21 := m.M12*m.M33*m.M44 + m.M13*m.M34*m.M42 + m.M14*m.M32*m.M43 - m.M14*m.M33*m.M42 - m.M13*m.M32*m.M44 - m.M12*m.M34*m.M43\n\tminor22 := m.M11*m.M33*m.M44 + m.M13*m.M34*m.M41 + m.M14*m.M31*m.M43 - m.M14*m.M33*m.M41 - m.M13*m.M31*m.M44 - m.M11*m.M34*m.M43\n\tminor23 := m.M11*m.M32*m.M44 + m.M12*m.M34*m.M41 + m.M14*m.M31*m.M42 - m.M14*m.M32*m.M41 - m.M12*m.M31*m.M44 - m.M11*m.M34*m.M42\n\tminor24 := m.M11*m.M32*m.M43 + m.M12*m.M33*m.M41 + m.M13*m.M31*m.M42 - m.M13*m.M32*m.M41 - m.M12*m.M31*m.M43 - m.M11*m.M33*m.M42\n\tminor31 := m.M12*m.M23*m.M44 + m.M13*m.M24*m.M42 + m.M14*m.M22*m.M43 - m.M14*m.M23*m.M42 - m.M13*m.M22*m.M44 - m.M12*m.M24*m.M43\n\tminor32 := m.M11*m.M23*m.M44 + m.M13*m.M24*m.M41 + m.M14*m.M21*m.M43 - m.M14*m.M23*m.M41 - m.M13*m.M21*m.M44 - m.M11*m.M24*m.M43\n\tminor33 := m.M11*m.M22*m.M44 + m.M12*m.M24*m.M41 + m.M14*m.M21*m.M42 - m.M14*m.M22*m.M41 - m.M12*m.M21*m.M44 - m.M11*m.M24*m.M42\n\tminor34 := m.M11*m.M22*m.M43 + m.M12*m.M23*m.M41 + m.M13*m.M21*m.M42 - m.M13*m.M22*m.M41 - m.M12*m.M21*m.M43 - m.M11*m.M23*m.M42\n\tminor41 := m.M12*m.M23*m.M34 + m.M13*m.M24*m.M32 + m.M14*m.M22*m.M33 - m.M14*m.M23*m.M32 - m.M13*m.M22*m.M34 - m.M12*m.M24*m.M33\n\tminor42 := m.M11*m.M23*m.M34 + m.M13*m.M24*m.M31 + m.M14*m.M21*m.M33 - m.M14*m.M23*m.M31 - m.M13*m.M21*m.M34 - m.M11*m.M24*m.M33\n\tminor43 := m.M11*m.M22*m.M34 + m.M12*m.M24*m.M31 + m.M14*m.M21*m.M32 - m.M14*m.M22*m.M31 - m.M12*m.M21*m.M34 - m.M11*m.M24*m.M32\n\tminor44 := m.M11*m.M22*m.M33 + m.M12*m.M23*m.M31 + m.M13*m.M21*m.M32 - m.M13*m.M22*m.M31 - m.M12*m.M21*m.M33 - m.M11*m.M23*m.M32\n\n\tdeterminant := m.M11*minor11 - m.M12*minor12 + m.M13*minor13 - m.M14*minor14\n\n\treturn NewMat4(\n\t\t+minor11/determinant, -minor21/determinant, +minor31/determinant, -minor41/determinant,\n\t\t-minor12/determinant, +minor22/determinant, -minor32/determinant, +minor42/determinant,\n\t\t+minor13/determinant, -minor23/determinant, +minor33/determinant, -minor43/determinant,\n\t\t-minor14/determinant, +minor24/determinant, -minor34/determinant, +minor44/determinant,\n\t)\n}", "func (C *Matrix) Plus(A, B *Matrix) *Matrix {\n\n\t// Normal matrices.\n\tif A.stride == A.width && B.stride == B.width && C.stride == C.width {\n\t\tfor i, ai := range A.data {\n\t\t\tC.data[i] = ai + B.data[i]\n\t\t}\n\t\treturn C\n\t}\n\n\t// SubMatrices.\n\tfor i := 0; i < A.height; i++ {\n\t\tAi := A.Row(i)\n\t\tCi := C.Row(i)\n\t\tfor j, bij := range B.Row(i) {\n\t\t\tCi[j] = Ai[j] + bij\n\t\t}\n\t}\n\n\treturn C\n}", "func rnd_m4_affine_inv(_mat [16]float64) ([16]float64, [9]float64) {\n\tupper := [9]float64{}\n\tcopy(upper[0:3], _mat[0:3])\n\tcopy(upper[3:6], _mat[4:7])\n\tcopy(upper[6:9], _mat[8:11])\n\tinv3 := mat.NewDense(3, 3, upper[:])\n\tif err:= inv3.Inverse(inv3); err!=nil {\n\t\tfmt.Println(\"Cannot inverse the matrix\")\n\t\tfmt.Println(err.Error())\n\t\tos.Exit(1)\n\t}\n\t_V := [3]float64{-_mat[3], -_mat[7], -_mat[11]}\n\tV := mat.NewVecDense(3, _V[:])\n\t//var U mat.VecDense\n\tactual := make([]float64,3)\n\tU:= mat.NewVecDense(3, actual)\n\tU.MulVec(inv3, V)\n\t_inv := [16]float64{\n\t\tupper[0], upper[1], upper[2], actual[0],\n\t\tupper[3], upper[4], upper[5], actual[1],\n\t\tupper[6], upper[7], upper[8], actual[2],\n\t\t0, 0, 0, 1,\n\t}\n\treturn _inv,upper\n}", "func (mat Mat) TransposeMatrix() Mat {\n r := mat.Shape[0]\n c := mat.Shape[1]\n var temp [][]float32\n for i := 0; i < c; i++ {\n temp_r := make([]float32, r)\n for j := 0 ; j < r; j++ {\n temp_r[j] = mat.Value[j][i]\n }\n temp = append(temp, temp_r)\n }\n return Mat{temp,[]int{mat.Shape[1], mat.Shape[0]}}\n}", "func Ref(m M) M {\n\tm = CopyMatrix(m)\n\n\tstartr := 1\n\tfor c := 1; c <= m.Cols(); c++ { // find a leading entry in this column\n\t\tfound := false\n\t\tfor r := startr; r <= m.Rows(); r++ {\n\t\t\tif isLeadingEntry(m, r, c) {\n\t\t\t\tfound = true\n\t\t\t\tm.SwitchRows(startr, r) // move it to the top, son!\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t\tif !found { // no leading entry, next column please\n\t\t\tcontinue\n\t\t}\n\n\t\tm.MultiplyRow(startr, m.Get(startr, c).Reciprocal()) // make first entry one\n\n\t\tfor r := startr + 1; r <= m.Rows(); r++ {\n\t\t\tif isLeadingEntry(m, r, c) {\n\t\t\t\tm.MultiplyAndAddRow(startr, m.Get(startr, c).Reciprocal().Mul(m.Get(r, c).Neg()), r) // zero first column entry\n\t\t\t}\n\t\t}\n\n\t\tstartr++ // row is now in ref\n\t}\n\n\treturn m\n}", "func multMatVect(substream []uint32, A [][]uint32, m1 uint32, B [][]uint32, m2 uint32) {\n\tvv := make([]uint32, 3)\n\tfor i := 0; i < 3; i++ {\n\t\tvv[i] = substream[i]\n\t}\n\tmatVecModM(A, vv, vv, m1)\n\tfor i := 0; i < 3; i++ {\n\t\tsubstream[i] = vv[i]\n\t}\n\n\tfor i := 0; i < 3; i++ {\n\t\tvv[i] = substream[i+3]\n\t}\n\tmatVecModM(B, vv, vv, m2)\n\tfor i := 0; i < 3; i++ {\n\t\tsubstream[i+3] = vv[i]\n\t}\n}", "func outerProduct(c Context, u Value, op string, v Value) Value {\n\tswitch u := u.(type) {\n\tcase Vector:\n\t\tv := v.(Vector)\n\t\tm := Matrix{\n\t\t\tshape: []int{len(u), len(v)},\n\t\t\tdata: NewVector(make(Vector, len(u)*len(v))),\n\t\t}\n\t\tindex := 0\n\t\tfor _, vu := range u {\n\t\t\tfor _, vv := range v {\n\t\t\t\tm.data[index] = c.EvalBinary(vu, op, vv)\n\t\t\t\tindex++\n\t\t\t}\n\t\t}\n\t\treturn &m // TODO: Shrink?\n\tcase *Matrix:\n\t\tv := v.(*Matrix)\n\t\tm := Matrix{\n\t\t\tshape: append(u.Shape(), v.Shape()...),\n\t\t\tdata: NewVector(make(Vector, len(u.Data())*len(v.Data()))),\n\t\t}\n\t\tindex := 0\n\t\tfor _, vu := range u.Data() {\n\t\t\tfor _, vv := range v.Data() {\n\t\t\t\tm.data[index] = c.EvalBinary(vu, op, vv)\n\t\t\t\tindex++\n\t\t\t}\n\t\t}\n\t\treturn &m // TODO: Shrink?\n\t}\n\tErrorf(\"can't do outer product on %s\", whichType(u))\n\tpanic(\"not reached\")\n}", "func Multiplicacao(a, b Matriz) Matriz {\n\n\tmatriz := Matriz{}\n\tmatriz.Iniciar(a.Linhas, b.Colunas)\n\n\tfor linha := 0; linha < a.Linhas; linha++ {\n\t\tfor coluna := 0; coluna < b.Colunas; coluna++ {\n\t\t\tfor i := 0; i < a.Colunas; i++ {\n\t\t\t\tmatriz.Dados[linha][coluna] = matriz.Dados[linha][coluna] + (a.Dados[linha][i] * b.Dados[i][coluna])\n\t\t\t}\n\t\t}\n\t}\n\n\treturn matriz\n}", "func (m Matrix) Inverse() Matrix {\n\td := m.Determinant()\n\treturn Matrix{\n\t\tm[3] / d, -m[1] / d,\n\t\t-m[2] / d, m[0] / d,\n\t\t(m[2]*m[5] - m[3]*m[4]) / d,\n\t\t(m[1]*m[4] - m[0]*m[5]) / d,\n\t}\n}", "func (m *Matrix) Copy() *Matrix {\n\tmat2 := make([][]qrvalue, m.width)\n\tfor w := 0; w < m.width; w++ {\n\t\tmat2[w] = make([]qrvalue, m.height)\n\t\tcopy(mat2[w], m.mat[w])\n\t}\n\n\tm2 := &Matrix{\n\t\twidth: m.width,\n\t\theight: m.height,\n\t\tmat: mat2,\n\t}\n\n\treturn m2\n}", "func MatrixRotateXYZ(ang Vector3) Matrix {\n\tresult := MatrixIdentity()\n\n\tcosz := float32(math.Cos(float64(-ang.Z)))\n\tsinz := float32(math.Sin(float64(-ang.Z)))\n\tcosy := float32(math.Cos(float64(-ang.Y)))\n\tsiny := float32(math.Sin(float64(-ang.Y)))\n\tcosx := float32(math.Cos(float64(-ang.X)))\n\tsinx := float32(math.Sin(float64(-ang.X)))\n\n\tresult.M0 = cosz * cosy\n\tresult.M4 = (cosz * siny * sinx) - (sinz * cosx)\n\tresult.M8 = (cosz * siny * cosx) + (sinz * sinx)\n\n\tresult.M1 = sinz * cosy\n\tresult.M5 = (sinz * siny * sinx) + (cosz * cosx)\n\tresult.M9 = (sinz * siny * cosx) - (cosz * sinx)\n\n\tresult.M2 = -siny\n\tresult.M6 = cosy * sinx\n\tresult.M10 = cosy * cosx\n\n\treturn result\n}", "func LookMatrix(o Vec, to Vec) *Mtx {\n\tf, _ := o.Minus(to).Unit() // forward\n\tr, _ := yAxis.Cross(f) // right\n\tu, _ := f.Cross(r) // up\n\torient := NewMat(\n\t\tr.X, u.X, f.X, 0,\n\t\tr.Y, u.Y, f.Y, 0,\n\t\tr.Z, u.Z, f.Z, 0,\n\t\t0, 0, 0, 1,\n\t)\n\treturn Shift(o).Mult(orient)\n}", "func (t1 *Tensor) Multiply(t2 *Tensor) (*Tensor, error) {\n\tif t1.Size.Z != t2.Size.Z || t1.Size.X != t2.Size.Y {\n\t\treturn nil, ErrDimensionsNotFit\n\t}\n\tret := NewTensor(t2.Size.X, t1.Size.Y, t1.Size.Z)\n\tfor z := 0; z < t1.Size.Z; z++ {\n\t\tfor y := 0; y < t1.Size.Y; y++ {\n\t\t\tfor x := 0; x < t2.Size.X; x++ {\n\t\t\t\tvar e float64\n\t\t\t\tfor i := 0; i < t1.Size.X; i++ {\n\t\t\t\t\te += t1.Get(i, y, z) * t2.Get(x, i, z)\n\t\t\t\t}\n\t\t\t\tret.Set(x, y, z, e)\n\t\t\t}\n\t\t}\n\t}\n\treturn ret, nil\n}", "func matmul(r [][]int, v []int) []int {\n\tif len(r[0]) != len(v) {\n\t\tpanic(fmt.Sprintf(\"incompatible matrix and vector sizes %d and %d\", len(r[0]), len(v)))\n\t}\n\toutput := make([]int, len(r))\n\tfor i, row := range r {\n\t\tfor j := range row {\n\t\t\toutput[i] += row[j] * v[j]\n\t\t}\n\t}\n\treturn output\n}", "func (mat Mat) MultiplyScalar(s float32) Mat {\n var temp [][]float32\n for i := 0 ; i < mat.Shape[0]; i++ {\n temp_r := make([]float32, mat.Shape[1])\n for j := 0 ; j < mat.Shape[1]; j++ {\n temp_r[j] = mat.Value[i][j] * s\n }\n temp = append(temp, temp_r)\n }\n return Mat{temp, mat.Shape}\n}", "func MULW(mr operand.Op) { ctx.MULW(mr) }", "func (leg *Leg) Matrix() math3d.Matrix44 {\n\treturn *math3d.MakeMatrix44(*leg.Origin, *math3d.MakeSingularEulerAngle(math3d.RotationHeading, leg.Angle))\n}", "func (A *Matrix64) Compose(B *Matrix64) *Matrix64 {\n\tif A.Ncols() != B.Nrows() {\n\t\treturn NewMatrix64(0, 0)\n\t}\n\treturn NewMatrix64(A.Nrows(), B.Ncols()).MatMul(A, B)\n}", "func ORPD(mx, x operand.Op) { ctx.ORPD(mx, x) }", "func Mat3Multiply(out, a, b []float64) []float64 {\n\ta00 := a[0]\n\ta01 := a[1]\n\ta02 := a[2]\n\ta10 := a[3]\n\ta11 := a[4]\n\ta12 := a[5]\n\ta20 := a[6]\n\ta21 := a[7]\n\ta22 := a[8]\n\n\tb00 := b[0]\n\tb01 := b[1]\n\tb02 := b[2]\n\tb10 := b[3]\n\tb11 := b[4]\n\tb12 := b[5]\n\tb20 := b[6]\n\tb21 := b[7]\n\tb22 := b[8]\n\n\tout[0] = b00*a00 + b01*a10 + b02*a20\n\tout[1] = b00*a01 + b01*a11 + b02*a21\n\tout[2] = b00*a02 + b01*a12 + b02*a22\n\n\tout[3] = b10*a00 + b11*a10 + b12*a20\n\tout[4] = b10*a01 + b11*a11 + b12*a21\n\tout[5] = b10*a02 + b11*a12 + b12*a22\n\n\tout[6] = b20*a00 + b21*a10 + b22*a20\n\tout[7] = b20*a01 + b21*a11 + b22*a21\n\tout[8] = b20*a02 + b21*a12 + b22*a22\n\treturn out\n}", "func MULL(mr operand.Op) { ctx.MULL(mr) }" ]
[ "0.61465484", "0.6131196", "0.5884769", "0.5633606", "0.5584747", "0.53963184", "0.525027", "0.52124923", "0.51904577", "0.50934064", "0.50872725", "0.5082984", "0.5078852", "0.50402695", "0.50176233", "0.50016457", "0.4943797", "0.49141926", "0.48892382", "0.4847114", "0.4820029", "0.4809792", "0.47727415", "0.47463718", "0.4738882", "0.47213387", "0.46628535", "0.4655907", "0.4642874", "0.46296933", "0.46280867", "0.46274197", "0.4610996", "0.460426", "0.46042117", "0.46028405", "0.45950067", "0.4593129", "0.45848495", "0.45836097", "0.4581479", "0.45707345", "0.4566327", "0.4546022", "0.45444447", "0.45143208", "0.4501188", "0.4500212", "0.4495073", "0.4493719", "0.44917762", "0.44913802", "0.44896892", "0.44547468", "0.44518575", "0.44446594", "0.4443103", "0.44338605", "0.44199908", "0.44135535", "0.44128445", "0.43982157", "0.4396561", "0.43823764", "0.4381672", "0.43586951", "0.43492255", "0.4332698", "0.432904", "0.43262535", "0.4322114", "0.43166104", "0.43157887", "0.43145588", "0.43084565", "0.43078497", "0.43050215", "0.430394", "0.43025962", "0.42903063", "0.42892158", "0.42857212", "0.42825252", "0.42711043", "0.42561615", "0.42556557", "0.4255583", "0.425534", "0.42528918", "0.4247164", "0.42449972", "0.42365688", "0.42355195", "0.423329", "0.42307347", "0.42272604", "0.42246872", "0.42148826", "0.42130068", "0.42073455", "0.42011294" ]
0.0
-1
place a marker in the feedback buffer
func PassThrough(token float32) { C.glowPassThrough(gpPassThrough, (C.GLfloat)(token)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (e *ObservableEditableBuffer) Mark(seq int) {\n\te.f.Mark()\n\te.seq = seq\n}", "func (timer *XTimer) Mark(tag string) {\n\tnow := time.Now().UnixNano()\n\tdelta := float64(now - timer.latestTime)\n\tpoint := &MarkPoint{\n\t\ttag: tag,\n\t\tdelta: delta,\n\t}\n\ttimer.latestTime = now\n\ttimer.points = append(timer.points, point)\n}", "func (store *MessageStore) Mark(uid uint32) {\n\tif store.visualMarkMode {\n\t\t// visual mode has override, bogus input from user\n\t\treturn\n\t}\n\tstore.marked[uid] = struct{}{}\n}", "func (opID OperationID) insertMarker(m Marker) error {\n\tif m.State == \"\" {\n\t\tm.State = \"pending\"\n\t}\n\n\t_, err := db.Exec(\"INSERT INTO marker (ID, opID, PortalID, type, gid, comment, state, oporder) VALUES (?, ?, ?, ?, ?, ?, ?, ?)\",\n\t\tm.ID, opID, m.PortalID, m.Type, MakeNullString(m.AssignedTo), MakeNullString(m.Comment), m.State, m.Order)\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\treturn nil\n}", "func (r *Renderer) RegisterMark(typ string, tags ...Tag) { r.marks[typ] = tags }", "func (e *ObservableEditableBuffer) Insert(p0 OffsetTuple, s []byte, nr int) {\n\tbefore := e.getTagStatus()\n\tdefer e.notifyTagObservers(before)\n\n\te.f.Insert(p0, s, nr, e.seq)\n\tif e.seq < 1 {\n\t\te.f.FlattenHistory()\n\t}\n\te.inserted(p0, s, nr)\n}", "func (is *InputStream) Mark() {\n\tis.markPush(is.offset)\n}", "func (b *Board) Mark(c Card) error {\n\tindex, ok := b.cardsMap[c]\n\tif !ok {\n\t\treturn ErrCardNotOnBoard\n\t}\n\n\tb.marked |= index\n\n\treturn nil\n}", "func (p *Player) Mark(c Card) error {\n\treturn p.board.Mark(c)\n}", "func (n *notifier) RecordReplace(x, y int, orig, repl interface{}) {\n\tn.add([]Update{Update{\n\t\tOld: &Point{x, y, orig},\n\t\tNew: &Point{x, y, repl},\n\t}})\n}", "func (o *Operation) AssignMarker(markerID MarkerID, gid GoogleID) error {\n\t_, err := db.Exec(\"UPDATE marker SET gid = ?, state = ? WHERE ID = ? AND opID = ?\", MakeNullString(gid), \"assigned\", markerID, o.ID)\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\n\tif gid.String() != \"\" {\n\t\to.ID.firebaseAssignMarker(gid, markerID)\n\n\t\tmarker := struct {\n\t\t\tOpID OperationID\n\t\t\tMarkerID MarkerID\n\t\t}{\n\t\t\tOpID: o.ID,\n\t\t\tMarkerID: markerID,\n\t\t}\n\n\t\tmsg, err := gid.ExecuteTemplate(\"assignMarker\", marker)\n\t\tif err != nil {\n\t\t\tLog.Error(err)\n\t\t\tmsg = fmt.Sprintf(\"assigned a marker for op %s\", o.ID)\n\t\t\t// do not report send errors up the chain, just log\n\t\t}\n\t\t_, err = gid.SendMessage(msg)\n\t\tif err != nil {\n\t\t\tLog.Errorf(\"%s %s %s\", gid, err, msg)\n\t\t\t// do not report send errors up the chain, just log\n\t\t}\n\t}\n\n\tif err = o.Touch(); err != nil {\n\t\tLog.Error(err)\n\t}\n\treturn nil\n}", "func (e *ObservableEditableBuffer) InsertAt(rp0 int, rs []rune) {\n\tp0 := e.f.RuneTuple(rp0)\n\ts, nr := RunesToBytes(rs)\n\n\te.Insert(p0, s, nr)\n}", "func annotateBuffer(text *string) []Annotation {\n\ttextLength := primitives.Cursor(len(*text))\n\treturn []Annotation{\n\t\t{\n\t\t\tTag: BUFFER,\n\t\t\tRegion: primitives.Region{\n\t\t\t\tLeft: primitives.Span{A: 0, B: 0},\n\t\t\t\tRight: primitives.Span{A: textLength, B: textLength},\n\t\t\t},\n\t\t},\n\t}\n}", "func (o *Operation) MarkerComment(markerID MarkerID, comment string) error {\n\t_, err := db.Exec(\"UPDATE marker SET comment = ? WHERE ID = ? AND opID = ?\", MakeNullString(comment), markerID, o.ID)\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\tif err = o.Touch(); err != nil {\n\t\tLog.Error(err)\n\t}\n\treturn nil\n}", "func (e *Extractor) Mark(s string) error {\n\tif e.state == stateBody {\n\t\te.state = stateDone\n\t} // TODO else :shrug:\n\treturn nil\n}", "func (c *ContextCollector) Mark(flowID string) {\n\t// when seeing an alert, just mark the flow ID as relevant\n\tc.MarkLock.Lock()\n\tc.Marked[flowID] = struct{}{}\n\tc.MarkLock.Unlock()\n}", "func (e *Exported) Mark(name string, r Range) {\n\tif e.markers == nil {\n\t\te.markers = make(map[string]Range)\n\t}\n\te.markers[name] = r\n}", "func (bf *boardFilter) addTiploc(tiploc string) {\n\tif tiploc != \"\" {\n\t\tbf.tiplocs[tiploc] = nil\n\t}\n}", "func (o *Operation) insertMarker(m *Marker) error {\n\t_, err := db.Exec(\"INSERT INTO marker (ID, opID, PortalID, type, comment) VALUES (?, ?, ?, ?, ?)\",\n\t\tm.ID, o.ID, m.PortalID, m.Type, m.Comment)\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\treturn nil\n}", "func (r *Ring) MarkPending(offset int) {\n\tif offset > r.highestMarked {\n\t\tr.highestMarked = offset\n\t}\n\tif r.lowestMarked >= 0 {\n\t\tif r.highestPending < offset {\n\t\t\tr.highestPending = offset\n\t\t}\n\t\tif r.lowestPending < 0 || r.lowestPending > offset {\n\t\t\tr.lowestPending = offset\n\t\t}\n\t\treturn\n\t}\n\tr.lowestMarked = offset\n\tr.lowestPending = offset\n}", "func (me TxsdPresentationAttributesGraphicsDisplay) IsMarker() bool { return me.String() == \"marker\" }", "func (dd *dictDecoder) writeMark(cnt int) {\n\tdd.wrPos += cnt\n}", "func (vbm VolumeBitMap) MarkUsed(block uint16) {\n\tvbm.mark(block, false)\n}", "func (f *field) Loc(y, x int) {\r\n\tborder := f.border\r\n\tf.Update(fmt.Sprintf(\"%*s\", f.len, \" \"))\r\n\tf.DrawBox(boxStyleClear)\r\n\tf.x = x\r\n\tf.y = y\r\n\tf.DrawBox(border)\r\n\tf.Update(f.text)\r\n}", "func Marker(value string) Option {\n\treturn addParam(\"marker\", value)\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 (jbobject *JavaIoInputStream) Mark(a int) {\n\t_, err := jbobject.CallMethod(javabind.GetEnv(), \"mark\", javabind.Void, a)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n}", "func (dw *DrawingWand) Annotation(x, y float64, text string) {\n\tcstext := (*C.uchar)((unsafe.Pointer)(C.CString(text)))\n\tdefer C.free(unsafe.Pointer(cstext))\n\tC.MagickDrawAnnotation(dw.dw, C.double(x), C.double(y), cstext)\n}", "func Mark(err error, m *Marker) error {\n\treturn MarkIf(err, m, RuleAlways)\n}", "func (e *ObservableEditableBuffer) inserted(q0 OffsetTuple, b []byte, nr int) {\n\te.treatasclean = false\n\tfor observer := range e.observers {\n\t\tobserver.Inserted(q0, b, nr)\n\t}\n}", "func Offset(dx, dy float32) {\n\tgContext.Cursor.X += dx\n\tgContext.Cursor.Y += dy\n}", "func getMarker(bloc,data []byte)Marker{\n\tmarker := hex.EncodeToString(bloc[0:2])\n\ttypeMarker := intReader.ReadInt16(bloc[2:4])\n\tlength := intReader.ReadInt32(bloc[4:8])\n\tvar formatData interface{}\n\tswitch typeMarker {\n\tcase 2 :\n\t\tif length > 4 {\n\t\t\t// Read data at offset\n\t\t\toffset := intReader.ReadInt32(bloc[8:])\n\t\t\tformatData = string(data[offset:offset+length])\n\t\t}else{\n\t\t\tformatData = string(bloc)\n\t\t}\n\tcase 3 : formatData = intReader.ReadInt16(bloc[8:])\n\tcase 4 : formatData = intReader.ReadInt32(bloc[8:])\n\t\tdefault:formatData = bloc[8:]\n\t}\n\n\treturn Marker{marker,typeMarker,length,formatData}\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 setCursorLoc(x, y int) {\n\tfmt.Printf(\"\\033[%v;%vH\", y, x)\n}", "func (o *Operation) MarkerOrder(order string, gid GoogleID) error {\n\tstmt, err := db.Prepare(\"UPDATE marker SET oporder = ? WHERE opID = ? AND ID = ?\")\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\n\tpos := 1\n\tmarkers := strings.Split(order, \",\")\n\tfor i := range markers {\n\t\tif markers[i] == \"000\" { // the header, could be anyplace in the order if the user was being silly\n\t\t\tcontinue\n\t\t}\n\t\tif _, err := stmt.Exec(pos, o.ID, markers[i]); err != nil {\n\t\t\tLog.Error(err)\n\t\t\tcontinue\n\t\t}\n\t\tpos++\n\t}\n\tif err = o.Touch(); err != nil {\n\t\tLog.Error(err)\n\t}\n\treturn nil\n}", "func writer(coord string) {\n\tbroadcast <- coord\n}", "func (mes *MarkerEncodingScheme) Annotation() Marker { return mes.annotation }", "func (_m *MarkerConsumer) Start() {\n\t_m.Called()\n}", "func (tv *TerminalView) SetCurrentBuffer(index int, mainText, secondaryText string, shortcut rune) {\n\t// special handlinge for the debug buffer with and without unread count.\n\tif mainText == \"[red]debug[white]\" || mainText == \"[pink]debug **[white]\" {\n\t\ttv.pages.SwitchToPage(\"page-debug\")\n\t\t// remove the unread aspect.\n\t\ttv.bufferList.List.SetItemText(index, \"[red]debug[white]\", \"\")\n\t\treturn\n\t}\n\t// Handle weechat buffers.\n\tbuf := tv.bufferList.getByFullName(mainText)\n\tif buf != nil {\n\t\t// For the buffer widget, set the right number of lines.\n\t\tif bufView, ok := tv.buffers[buf.FullName]; ok {\n\t\t\t//\t\t\ttv.app.QueueUpdate(func() {\n\t\t\tbufView.SetText(buf.TitleStr(true) + buf.GetLines(true))\n\t\t\ttv.bufferList.List.SetItemText(index, fmt.Sprintf(\"%v\", buf.FullName), \"\")\n\t\t\t// Then, switch to the page that is embedding the above buffer widget.\n\t\t\ttv.pages.SwitchToPage(fmt.Sprintf(\"page-%v\", buf.FullName))\n\t\t\t// Send command to load nicklist of the buffer if there\n\t\t\t// is no nicklist in it and it is a channel not person (# check)\n\t\t\tif buf.FullName != \"debug\" && buf.NickList.GetItemCount() == 0 && strings.Contains(buf.FullName, \"#\") {\n\t\t\t\ttv.sendchan <- fmt.Sprintf(\"(nicklist) nicklist %v\\n\", buf.FullName)\n\t\t\t}\n\t\t\t// })\n\t\t} else {\n\t\t\ttv.Debug(\n\t\t\t\tfmt.Sprintf(\n\t\t\t\t\t\"Failed to find the buffer in tv.buffers %v buffername %v\\n\",\n\t\t\t\t\tmainText, buf.FullName))\n\t\t}\n\n\t} else {\n\t\ttv.Debug(fmt.Sprintf(\"Failed to find the buffer %v\\n\", mainText))\n\t}\n}", "func (tv *TextView) InsertAtCursor(txt []byte) {\n\twupdt := tv.TopUpdateStart()\n\tdefer tv.TopUpdateEnd(wupdt)\n\tif tv.HasSelection() {\n\t\ttbe := tv.DeleteSelection()\n\t\ttv.CursorPos = tbe.AdjustPos(tv.CursorPos, AdjustPosDelStart) // move to start if in reg\n\t}\n\ttbe := tv.Buf.InsertText(tv.CursorPos, txt, true, true)\n\tif tbe == nil {\n\t\treturn\n\t}\n\tpos := tbe.Reg.End\n\tif len(txt) == 1 && txt[0] == '\\n' {\n\t\tpos.Ch = 0 // sometimes it doesn't go to the start..\n\t}\n\ttv.SetCursorShow(pos)\n\ttv.SetCursorCol(tv.CursorPos)\n}", "func (r Ruler) BufferPoint(p Point, buffer float64) Bbox {\n\tv := buffer / r.kx\n\th := buffer / r.ky\n\n\treturn Bbox{\n\t\tp[0] - h,\n\t\tp[1] - v,\n\t\tp[0] + h,\n\t\tp[1] + v,\n\t}\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 (bl *barLayout) setPointerPosition(position fyne.Position) {\n\tbl.mousePosition = position\n}", "func (ma *markAllocator) put(mark uint32) {\n\tma.lock.Lock()\n\tdefer ma.lock.Unlock()\n\tma.marks = append(ma.marks, mark)\n}", "func (b *button) position(cx, cy float64) {\n\tb.cx = cx\n\tb.cy = cy\n\tb.x = int(cx) - b.w/2\n\tb.y = int(cy) - b.h/2\n\tb.model.SetLocation(b.cx, b.cy, 0)\n\tif b.banner != nil {\n\t\tb.banner.SetLocation(float64(b.x), float64(b.y), 0)\n\t}\n}", "func (b *buffer) pin(loc Location, ptr unsafe.Pointer) {\n\tif !atomic.CompareAndSwapPointer(b.index(loc.index()), nil, ptr) {\n\t\tpanic(\"double pin\")\n\t}\n\t// atomic.StorePointer(b.index(loc.index()), ptr)\n\tatomic.AddUint32(&b.free, ^uint32(0))\n}", "func (Operators) Buffer(notifier Observable) OperatorFunc {\n\treturn func(source Observable) Observable {\n\t\top := bufferOperator{notifier}\n\t\treturn source.Lift(op.Call)\n\t}\n}", "func (b *button) position(cx, cy float64) {\n\tb.cx = cx\n\tb.cy = cy\n\tb.x = int(cx) - b.w/2\n\tb.y = int(cy) - b.h/2\n\tb.model.SetAt(b.cx, b.cy, 0)\n\tif b.banner != nil {\n\t\tb.banner.SetAt(float64(b.x), float64(b.y), 0)\n\t}\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 (f *Frame) SetMark(v int) {\n\tf.mark = v\n}", "func (p *Buffer) noteError(err error) {\n\tif p.err == nil {\n\t\tp.err = err\n\t}\n}", "func (image *JPGImage) nextMarker(buffer []byte) uint8 {\n\t// Find 0xFF byte; count and skip any non-FFs.\n\tch := buffer[image.index]\n\timage.index++\n\tif ch != 0xFF {\n\t\tlog.Fatal(\"0xFF byte expected.\")\n\t}\n\n\t// Get marker code byte, swallowing any duplicate FF bytes.\n\t// Extra FFs are legal as pad bytes, so don't count them in discardedBytes.\n\tfor {\n\t\tch = buffer[image.index]\n\t\timage.index++\n\t\tif ch != 0xFF {\n\t\t\tbreak\n\t\t}\n\t}\n\treturn ch\n}", "func (vbm VolumeBitMap) MarkUnused(block uint16) {\n\tvbm.mark(block, true)\n}", "func (ba *buddyAllocator) Mark(addr, order uint32) {\n\tindex, first := ba.getIndex(addr, order)\n\n\tif order >= MaxOrder {\n\t\t// we need to mark order / _maxOrder pages\n\t\tn := order / MaxOrder\n\t\t// Mark n pages from index as allocated\n\t\tfor i := uint32(0); i < n; i++ {\n\t\t\tba.buddies[MaxOrder].freeMap.Reset(index + i)\n\t\t}\n\t\treturn\n\t}\n\n\t// Mark index as allocated\n\tba.buddies[order].freeMap.Toggle(index)\n\t// If buddy is free add it to free list\n\tif ba.buddies[order].freeMap.IsSet(index) {\n\t\tbuddyAddress := ba.getBuddyAddress(index, order, first)\n\t\tba.buddies[order].freeList.Append(buddyAddress)\n\t}\n\treturn\n}", "func (f *Frame) Mark() int {\n\treturn f.mark\n}", "func PlotPoint(x, y gb.UINT8) {}", "func (p *scopeParser) mark() int {\n\tpos := p.position + 1\n\tp.position = pos\n\treturn pos\n}", "func (c *camera) point_at(v Vector) {\n c.front = v.Sub(c.pos).Normalize().Add(c.pos)\n}", "func (vm *VM) bufferVariable(variable Variable) {\n\tvm.bufferPush(variable.Value())\n}", "func (c *Consumer) CommitOffset(msg *sarama.ConsumerMessage) {\n\tc.consumer.MarkOffset(msg, \"\")\n}", "func (m MarkerID) Acknowledge(o *Operation, gid GoogleID) error {\n\tvar ns sql.NullString\n\terr := db.QueryRow(\"SELECT gid FROM marker WHERE ID = ? and opID = ?\", m, o.ID).Scan(&ns)\n\tif err != nil && err != sql.ErrNoRows {\n\t\tLog.Notice(err)\n\t\treturn err\n\t}\n\tif err != nil && err == sql.ErrNoRows {\n\t\terr = fmt.Errorf(\"no such marker\")\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\tif !ns.Valid {\n\t\terr = fmt.Errorf(\"marker not assigned\")\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\tmarkerGid := GoogleID(ns.String)\n\tif gid != markerGid {\n\t\terr = fmt.Errorf(\"marker assigned to someone else\")\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\t_, err = db.Exec(\"UPDATE marker SET state = ? WHERE ID = ? AND opID = ?\", \"acknowledged\", m, o.ID)\n\tif err != nil {\n\t\tLog.Error(err)\n\t\treturn err\n\t}\n\tif err = o.Touch(); err != nil {\n\t\tLog.Error(err)\n\t}\n\n\to.firebaseMarkerStatus(m, \"acknowledged\")\n\treturn nil\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 (p Point) Buffer() *Buffer {\n\treturn p.buffer\n}", "func CommentMarker(char rune) CommitOption {\n\treturn func(c *commitConfig) {\n\t\tc.commentMarker = char\n\t}\n}", "func (handle *NotifyFD) Mark(flags uint, mask uint64, dirFd int, path string) error {\n\tif err := unix.FanotifyMark(handle.fd, flags, mask, dirFd, path); err != nil {\n\t\treturn fmt.Errorf(\"fanotify: %w\", err)\n\t}\n\n\treturn nil\n}", "func BeatTracker() string {\n\tout := \"\"\n\tout += fmt.Sprint(cursorLeft(3))\n\tout += fmt.Sprint(\" *\")\n\n\treturn out\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 (c *otApplyContext) ligateInput(count int, matchPositions [maxContextLength]int,\n\tmatchLength int, ligGlyph fonts.GID, totalComponentCount uint8) {\n\tbuffer := c.buffer\n\n\tbuffer.mergeClusters(buffer.idx, buffer.idx+matchLength)\n\n\t/* - If a base and one or more marks ligate, consider that as a base, NOT\n\t* ligature, such that all following marks can still attach to it.\n\t* https://github.com/harfbuzz/harfbuzz/issues/1109\n\t*\n\t* - If all components of the ligature were marks, we call this a mark ligature.\n\t* If it *is* a mark ligature, we don't allocate a new ligature id, and leave\n\t* the ligature to keep its old ligature id. This will allow it to attach to\n\t* a base ligature in GPOS. Eg. if the sequence is: LAM,LAM,SHADDA,FATHA,HEH,\n\t* and LAM,LAM,HEH for a ligature, they will leave SHADDA and FATHA with a\n\t* ligature id and component value of 2. Then if SHADDA,FATHA form a ligature\n\t* later, we don't want them to lose their ligature id/component, otherwise\n\t* GPOS will fail to correctly position the mark ligature on top of the\n\t* LAM,LAM,HEH ligature. See:\n\t* https://bugzilla.gnome.org/show_bug.cgi?id=676343\n\t*\n\t* - If a ligature is formed of components that some of which are also ligatures\n\t* themselves, and those ligature components had marks attached to *their*\n\t* components, we have to attach the marks to the new ligature component\n\t* positions! Now *that*'s tricky! And these marks may be following the\n\t* last component of the whole sequence, so we should loop forward looking\n\t* for them and update them.\n\t*\n\t* Eg. the sequence is LAM,LAM,SHADDA,FATHA,HEH, and the font first forms a\n\t* 'calt' ligature of LAM,HEH, leaving the SHADDA and FATHA with a ligature\n\t* id and component == 1. Now, during 'liga', the LAM and the LAM-HEH ligature\n\t* form a LAM-LAM-HEH ligature. We need to reassign the SHADDA and FATHA to\n\t* the new ligature with a component value of 2.\n\t*\n\t* This in fact happened to a font... See:\n\t* https://bugzilla.gnome.org/show_bug.cgi?id=437633\n\t */\n\n\tisBaseLigature := buffer.Info[matchPositions[0]].isBaseGlyph()\n\tisMarkLigature := buffer.Info[matchPositions[0]].isMark()\n\tfor i := 1; i < count; i++ {\n\t\tif !buffer.Info[matchPositions[i]].isMark() {\n\t\t\tisBaseLigature = false\n\t\t\tisMarkLigature = false\n\t\t\tbreak\n\t\t}\n\t}\n\tisLigature := !isBaseLigature && !isMarkLigature\n\n\tklass, ligID := uint16(0), uint8(0)\n\tif isLigature {\n\t\tklass = tt.Ligature\n\t\tligID = buffer.allocateLigID()\n\t}\n\tlastLigID := buffer.cur(0).getLigID()\n\tlastNumComponents := buffer.cur(0).getLigNumComps()\n\tcomponentsSoFar := lastNumComponents\n\n\tif isLigature {\n\t\tbuffer.cur(0).setLigPropsForLigature(ligID, totalComponentCount)\n\t\tif buffer.cur(0).unicode.generalCategory() == nonSpacingMark {\n\t\t\tbuffer.cur(0).setGeneralCategory(otherLetter)\n\t\t}\n\t}\n\n\t// ReplaceGlyph_with_ligature\n\tc.setGlyphPropsExt(ligGlyph, klass, true, false)\n\tbuffer.replaceGlyphIndex(ligGlyph)\n\n\tfor i := 1; i < count; i++ {\n\t\tfor buffer.idx < matchPositions[i] {\n\t\t\tif isLigature {\n\t\t\t\tthisComp := buffer.cur(0).getLigComp()\n\t\t\t\tif thisComp == 0 {\n\t\t\t\t\tthisComp = lastNumComponents\n\t\t\t\t}\n\t\t\t\tnewLigComp := componentsSoFar - lastNumComponents +\n\t\t\t\t\tmin8(thisComp, lastNumComponents)\n\t\t\t\tbuffer.cur(0).setLigPropsForMark(ligID, newLigComp)\n\t\t\t}\n\t\t\tbuffer.nextGlyph()\n\t\t}\n\n\t\tlastLigID = buffer.cur(0).getLigID()\n\t\tlastNumComponents = buffer.cur(0).getLigNumComps()\n\t\tcomponentsSoFar += lastNumComponents\n\n\t\t/* Skip the base glyph */\n\t\tbuffer.skipGlyph()\n\t}\n\n\tif !isMarkLigature && lastLigID != 0 {\n\t\t/* Re-adjust components for any marks following. */\n\t\tfor i := buffer.idx; i < len(buffer.Info); i++ {\n\t\t\tif lastLigID != buffer.Info[i].getLigID() {\n\t\t\t\tbreak\n\t\t\t}\n\n\t\t\tthisComp := buffer.Info[i].getLigComp()\n\t\t\tif thisComp == 0 {\n\t\t\t\tbreak\n\t\t\t}\n\n\t\t\tnewLigComp := componentsSoFar - lastNumComponents +\n\t\t\t\tmin8(thisComp, lastNumComponents)\n\t\t\tbuffer.Info[i].setLigPropsForMark(ligID, newLigComp)\n\t\t}\n\t}\n}", "func aboveOpenInsert(gs *GlobalState) {\n\tif eb, ok := gs.curbuf.Value.(*EditBuffer); ok {\n\t\teb.insertEmptyLine(eb.lno)\n\t\teb.redraw = true\n\t\tgs.Mode = MODEINSERT\n\t\tinput(gs)\n\t}\n}", "func (m *MsgMemoryBuffer) Insert(value interface{}) {\n\tm.buff.Value = value\n\tm.buff = m.buff.Next()\n}", "func (i *Input) Insert(r rune) {\n\ti.Buffer.InsertRune(r, i.Pos)\n\ti.Pos++\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func (sw *instructionsWidget) Buffer() (*termui.Buffer, error) {\n\tbuffer := termui.NewBuffer(sw.list.GetRect())\n\tsw.list.Lock()\n\tsw.list.Draw(buffer)\n\tsw.list.Unlock()\n\treturn buffer, nil\n}", "func (c *minecraftConn) BufferPacket(packet proto.Packet) (err error) {\n\tif c.Closed() {\n\t\treturn ErrClosedConn\n\t}\n\tdefer func() { c.closeOnErr(err) }()\n\t_, err = c.encoder.WritePacket(packet)\n\treturn err\n}", "func (c *GlInsertEventMarkerEXT) Label(ctx context.Context, s *api.GlobalState) string {\n\treturn readString(ctx, c, s, c.Marker(), c.Length())\n}", "func OptBuffer(buffer int) func(*Beam) {\n\treturn func(b *Beam) { b.buffer = buffer }\n}", "func (s *DescribeTagsOutput) SetMarker(v string) *DescribeTagsOutput {\n\ts.Marker = &v\n\treturn s\n}", "func (ls *linestate) editInsert(r rune) {\n\tls.buf = append(ls.buf[:ls.pos], append([]rune{r}, ls.buf[ls.pos:]...)...)\n\tls.pos++\n\tls.refreshLine()\n}", "func (k Keeper) MarkStroke(ctx sdk.Context, acc sdk.AccAddress) error {\n\tp := k.GetParams(ctx)\n\n\treturn k.update(ctx, acc, func(d *types.Info) (save bool) {\n\t\tif d.Jailed {\n\t\t\treturn false\n\t\t}\n\n\t\td.Score = d.Score - d.OkBlocksInRow/100 - 1\n\t\td.Strokes++\n\t\td.OkBlocksInRow = 0\n\t\td.MissedBlocksInRow++\n\t\tif d.MissedBlocksInRow >= int64(p.JailAfter) {\n\t\t\td.Jailed = true\n\t\t\td.UnjailAt = ctx.BlockHeight() + int64(p.UnjailAfter)\n\t\t\td.JailCount++\n\t\t\td.MissedBlocksInRow = 0\n\t\t\tif d.LotteryNo != 0 {\n\t\t\t\tif err := k.lotteryExclude(ctx, d); err != nil {\n\t\t\t\t\t// Should never happen\n\t\t\t\t\tpanic(err)\n\t\t\t\t}\n\t\t\t}\n\t\t\tif err := ctx.EventManager().EmitTypedEvent(\n\t\t\t\t&types.EventValidatorJailed{\n\t\t\t\t\tAddress: acc.String(),\n\t\t\t\t},\n\t\t\t); err != nil { panic(err) }\n\t\t} else {\n\t\t\tif d.LotteryNo != 0 {\n\t\t\t\tif err := k.lotteryDownshift(ctx, acc, d); err != nil {\n\t\t\t\t\t// Should never happen\n\t\t\t\t\tpanic(err)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true\n\t})\n}", "func (pc *programCode) createJumpBackLabel(category string) {\n\tcode := \"\"\n\tstrlabelCounter := strconv.FormatInt(pc.labelCounter, 10)\n\tlabel := category + strlabelCounter\n\tpc.pushLastLabel(label)\n\tcode += \"\\t\" + label + \":\\t; return point\\n\"\n\tpc.appendCode(code)\n\n}", "func (g *GeneratedFile) Annotate(symbol string, loc Location) {\n\tg.annotations[symbol] = append(g.annotations[symbol], loc)\n}", "func (f *FlagSet) MarkDeprecated(name string, usageMessage string) error {\n\tflag := f.Lookup(name)\n\tif flag == nil {\n\t\treturn fmt.Errorf(\"flag %q does not exist\", name)\n\t}\n\tif usageMessage == \"\" {\n\t\treturn fmt.Errorf(\"deprecated message for flag %q must be set\", name)\n\t}\n\tflag.Deprecated = usageMessage\n\tflag.Hidden = true\n\treturn nil\n}", "func Mark(props *MarkProps, children ...Element) *MarkElem {\n\trProps := &_MarkProps{\n\t\tBasicHTMLElement: newBasicHTMLElement(),\n\t}\n\n\tif props != nil {\n\t\tprops.assign(rProps)\n\t}\n\n\treturn &MarkElem{\n\t\tElement: createElement(\"mark\", rProps, children...),\n\t}\n}", "func (tracker *tracker) Mark(node *Node) {\n\ttracker.mutex.Lock()\n\ttracker.nodes[node.Name]++\n\ttracker.mutex.Unlock()\n}", "func (ed *Editor) Notify(note string) {\n\ted.state.AddNote(note)\n\ted.Redraw(false)\n}", "func (e *Input) draw() {\n\te.Block.draw()\n\tp := e.GetPainter()\n\tif p == nil {\n\t\treturn\n\t}\n\ttext := e.visibleText()\n\tp.SetString(\n\t\ttext,\n\t\tNewStyle(ColorWhite),\n\t\te.GetInnerRealPos().Min,\n\t)\n\tif e.IsFocused() {\n\t\tvar off int\n\t\tif e.echoMode != EchoModeNoEcho {\n\t\t\toff = e.text.CursorPos().X - e.offset\n\t\t}\n\t\tinner := e.GetInnerRealPos()\n\t\ttb.SetCursor(inner.Min.X+off, inner.Min.Y)\n\t}\n}", "func (w *WaterMark) WaitForMark(ctx context.Context, index uint64) error {\n\tif w.DoneUntil() >= index {\n\t\treturn nil\n\t}\n\twaitCh := make(chan struct{})\n\tw.markCh <- mark{index: index, waiter: waitCh}\n\n\tselect {\n\tcase <-ctx.Done():\n\t\treturn ctx.Err()\n\tcase <-waitCh:\n\t\treturn nil\n\t}\n}", "func (s *DescribeTagsInput) SetMarker(v string) *DescribeTagsInput {\n\ts.Marker = &v\n\treturn s\n}", "func WriteSpecialMarker(os OStream, scheme *MarkerEncodingScheme, marker Marker) {\n\tos.WriteBits(scheme.Opcode(), scheme.NumOpcodeBits())\n\tos.WriteBits(uint64(marker), scheme.NumValueBits())\n}", "func (c *Compiler) trackPointer(value llvm.Value) {\n\tif value.Type() != c.i8ptrType {\n\t\tvalue = c.builder.CreateBitCast(value, c.i8ptrType, \"\")\n\t}\n\tc.createRuntimeCall(\"trackPointer\", []llvm.Value{value}, \"\")\n}", "func (t MatchTask) addSentenceWithOffset(contextMarker string, words []string, offset int) {\n\tvar sentence = Sentence{offset, words}\n\n\tt.sentenceByContextMarker[contextMarker] = sentence\n}", "func (mgmt *MonitoringManager) MarkSubmit(msgObj messagesocket.Message) {\n\tprintln(mgmt.LastMessageList)\n\t// Set last message list to nil and remove it from the map\n\tmgmt.LastMessageList[msgObj.Addr.String()] = nil\n\tdelete(mgmt.LastMessageList, msgObj.Addr.String())\n\tprintln(mgmt.LastMessageList)\n\tfmt.Printf(\"[MON] Marked %s as submitted\\n\", msgObj.Addr.String())\n}", "func (_m *MarkerConsumer) Stop() {\n\t_m.Called()\n}", "func (self Sound) SetPosition(v Vector3f) { \n C.sfSound_setPosition(self.Cref, v.Cref)\n}", "func (b *Buffer) PutChar(c byte) error {\n\tb.Cursor.Char = c\n\to := b.Cursor.Offset(b.Width)\n\tt := b.Expand(o).Tile(o)\n\tt.Update(&b.Cursor.Tile)\n\tb.Cursor.X++\n\tb.Cursor.NormalizeAndWrap(b.Width)\n\tb.maxWidth = calc.MaxInt(b.maxWidth, b.Cursor.X)\n\tb.maxHeight = calc.MaxInt(b.maxHeight, b.Cursor.Y)\n\treturn nil\n}", "func (b Buffer) Set(x, y int, c Cell) {\n\tb.CellMap[image.Pt(x, y)] = c\n}", "func NewTxMarker(height int64, memo string) TxMarker {\n\treturn TxMarker{\n\t\tHeight: height,\n\t\tMemo: memo,\n\t}\n}", "func (b *Base) SetPosition(x, y, z float64) {\n\tb.messageChan <- &proto.Update{\n\t\tPosition: &proto.Position{\n\t\t\tX: x,\n\t\t\tY: y,\n\t\t\tZ: z,\n\t\t},\n\t}\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 (dc *DCPClient) SnapshotMarker(snapshotMarker gocbcore.DcpSnapshotMarker) {\n\n\te := snapshotEvent{\n\t\tstreamEventCommon: streamEventCommon{\n\t\t\tvbID: snapshotMarker.VbID,\n\t\t\tstreamID: snapshotMarker.StreamID,\n\t\t},\n\t\tstartSeq: snapshotMarker.StartSeqNo,\n\t\tendSeq: snapshotMarker.EndSeqNo,\n\t\tsnapshotType: snapshotMarker.SnapshotType,\n\t}\n\tdc.workerForVbno(snapshotMarker.VbID).Send(e)\n}" ]
[ "0.66130394", "0.5892119", "0.54118264", "0.5340349", "0.5328326", "0.52502906", "0.5204639", "0.5170648", "0.5158217", "0.51402795", "0.5088688", "0.5080234", "0.50310963", "0.50295633", "0.5025763", "0.50248784", "0.50106835", "0.50103617", "0.50031745", "0.5001797", "0.5000459", "0.49599415", "0.49475634", "0.49377495", "0.4936635", "0.48923087", "0.48734394", "0.4871533", "0.48561335", "0.4841506", "0.48228768", "0.4819735", "0.48100108", "0.4775833", "0.47698933", "0.4757586", "0.4757407", "0.47371817", "0.47352275", "0.47182408", "0.4710311", "0.47077698", "0.47024006", "0.46863663", "0.4680863", "0.46808544", "0.46567324", "0.46537372", "0.46400493", "0.46400267", "0.46380648", "0.46253672", "0.46199757", "0.461814", "0.46143702", "0.45925236", "0.45907807", "0.45818362", "0.4579466", "0.45706353", "0.45645505", "0.45412517", "0.45410368", "0.4537926", "0.45313433", "0.45103726", "0.4499168", "0.4499168", "0.44983414", "0.44941837", "0.44912958", "0.4484128", "0.44796935", "0.44712135", "0.44671598", "0.4458076", "0.44533643", "0.44337943", "0.44279417", "0.4424782", "0.44231406", "0.44220024", "0.4408019", "0.44028193", "0.44002473", "0.43881217", "0.43868458", "0.4382912", "0.4381051", "0.4376377", "0.43743703", "0.43628818", "0.43627083", "0.43585214", "0.43513432", "0.43507016", "0.4341975", "0.43419158", "0.4341717", "0.43397248", "0.43383405" ]
0.0
-1
specifies the parameters for patch primitives
func PatchParameteri(pname uint32, value int32) { C.glowPatchParameteri(gpPatchParameteri, (C.GLenum)(pname), (C.GLint)(value)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (c *Client) patch(rawURL string, authenticate bool, expectedStatus int, in interface{}, out interface{}) error {\n\terr := c.do(rawURL, \"PATCH\", authenticate, expectedStatus, in, out)\n\treturn errio.Error(err)\n}", "func Patch() int {\n\treturn patch\n}", "func PatchParameteri(pname uint32, value int32) {\n\tsyscall.Syscall(gpPatchParameteri, 2, uintptr(pname), uintptr(value), 0)\n}", "func (k *kubectlContext) Patch(args ...string) error {\n\tout, err := k.do(append([]string{\"patch\"}, args...)...)\n\tk.t.Log(string(out))\n\treturn err\n}", "func patch(newObj runtime.Object, existingObj runtime.Object, c client.Client) error {\n\tnewObjJSON, _ := apijson.Marshal(newObj)\n\tkey, _ := client.ObjectKeyFromObject(newObj)\n\t_, isUnstructured := newObj.(runtime.Unstructured)\n\t_, isCRD := newObj.(*apiextv1beta1.CustomResourceDefinition)\n\n\tif isUnstructured || isCRD || isKudoType(newObj) {\n\t\t// strategic merge patch is not supported for these types, falling back to merge patch\n\t\terr := c.Patch(context.TODO(), newObj, client.ConstantPatch(types.MergePatchType, newObjJSON))\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"failed to apply merge patch to object %s/%s: %w\", key.Name, key.Name, err)\n\t\t}\n\t} else {\n\t\terr := c.Patch(context.TODO(), existingObj, client.ConstantPatch(types.StrategicMergePatchType, newObjJSON))\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"failed to apply StrategicMergePatch to object %s/%s: %w\", key.Namespace, key.Name, err)\n\t\t}\n\t}\n\treturn nil\n}", "func (APIResourceBase) Patch(session *Session, url string, queries url.Values, body io.Reader) (APIStatus, interface{}) {\n\treturn FailSimple(http.StatusMethodNotAllowed), nil\n}", "func (p localPatchList) patch(f *funcProto, soff int) {\n\tfor _, l := range p {\n\t\tf.localVars[l].sPC = int32(len(f.code) + soff)\n\t}\n}", "func (r *Request) Patch(path, contentType string, data ...interface{}) {\n\tr.Send(\"PATCH\", path, contentType, data...)\n}", "func (client MockStatusClient) Patch(context ctx.Context, object ctrlClient.Object, patch ctrlClient.Patch, options ...ctrlClient.PatchOption) error {\n\treturn fmt.Errorf(\"not implemented\")\n}", "func (ctl Controller) Patch(ctx *gin.Context) {\n\n\tMethodNotAllowedJSON(ctx)\n}", "func (sv SV) Patch() int { return sv.patch }", "func (f5 *f5LTM) patch(url string, payload interface{}, result interface{}) error {\n\treturn f5.restRequestPayload(\"PATCH\", url, payload, result)\n}", "func (native *OpenGL) PatchParameteri(pname uint32, value int32) {\n\tgl.PatchParameteri(pname, value)\n}", "func (m *MockPodInterface) Patch(arg0 string, arg1 types.PatchType, arg2 []byte, arg3 ...string) (*v1.Pod, error) {\n\tvarargs := []interface{}{arg0, arg1, arg2}\n\tfor _, a := range arg3 {\n\t\tvarargs = append(varargs, a)\n\t}\n\tret := m.ctrl.Call(m, \"Patch\", varargs...)\n\tret0, _ := ret[0].(*v1.Pod)\n\tret1, _ := ret[1].(error)\n\treturn ret0, ret1\n}", "func (w *Worker) Patch(c *http.Client, url string, data interface{}, bind interface{}) (int, error) {\n\tbs, err := json.Marshal(data)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\treq, err := http.NewRequest(\"PATCH\", url, bytes.NewReader(bs))\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\treq.Header.Set(\"Content-Type\", \"application/json\")\n\tres, err := c.Do(req)\n\tif err != nil {\n\t\tif res != nil {\n\t\t\tioutil.ReadAll(res.Body)\n\t\t\tres.Body.Close()\n\t\t}\n\t\treturn 0, err\n\t}\n\tdefer res.Body.Close()\n\terr = json.NewDecoder(res.Body).Decode(bind)\n\tif res.StatusCode == http.StatusNoContent || bind == nil {\n\t\treturn res.StatusCode, nil\n\t}\n\treturn res.StatusCode, err\n}", "func (akp *AKPatches) ForbidPatch(ctx context.Context, params interface{}) ([]byte, error) {\n\tpostData, err := json.Marshal(params)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\trequest, err := http.NewRequest(\"POST\", akp.client.Server+\"/api/v1.0/AKPatches.ForbidPatch\",\n\t\tbytes.NewBuffer(postData))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\traw, err := akp.client.Do(ctx, request, nil)\n\treturn raw, err\n}", "func marshalUpdateInterconnectPatchRequest(c *Client, m map[string]interface{}) ([]byte, error) {\n\n\treturn json.Marshal(m)\n}", "func (client *MockClient) Patch(context ctx.Context, object ctrlClient.Object, patch ctrlClient.Patch, options ...ctrlClient.PatchOption) error {\n\treturn fmt.Errorf(\"Not implemented\")\n}", "func (mr *MockInterfaceMockRecorder) Patch(ctx, name, pt, data, opts interface{}, subresources ...interface{}) *gomock.Call {\n\tmr.mock.ctrl.T.Helper()\n\tvarargs := append([]interface{}{ctx, name, pt, data, opts}, subresources...)\n\treturn mr.mock.ctrl.RecordCallWithMethodType(mr.mock, \"Patch\", reflect.TypeOf((*MockInterface)(nil).Patch), varargs...)\n}", "func (c *Client) Patch(url string, reqBody, resType interface{}) error {\n\treturn c.CallAPI(\"PATCH\", url, reqBody, resType, true)\n}", "func (r ApiPatchOAuth2ClientRequest) JsonPatch(jsonPatch []JsonPatch) ApiPatchOAuth2ClientRequest {\n\tr.jsonPatch = &jsonPatch\n\treturn r\n}", "func (avisess *AviSession) Patch(uri string, payload interface{}, patchOp string, response interface{}, options ...ApiOptionsParams) error {\n\tvar patchPayload = make(map[string]interface{})\n\tpatchPayload[patchOp] = payload\n\tglog.Infof(\" PATCH OP %v data %v\", patchOp, payload)\n\treturn avisess.restRequestInterfaceResponse(\"PATCH\", uri, patchPayload, response, options...)\n}", "func (o *Poke) Patch(sparse elemental.SparseIdentifiable) {\n}", "func (c *klusterlets) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.Klusterlet, err error) {\n\tresult = &v1.Klusterlet{}\n\terr = c.client.Patch(pt).\n\t\tResource(\"klusterlets\").\n\t\tName(name).\n\t\tSubResource(subresources...).\n\t\tVersionedParams(&opts, scheme.ParameterCodec).\n\t\tBody(data).\n\t\tDo(ctx).\n\t\tInto(result)\n\treturn\n}", "func Patch(pkgName, typeName, methodName string, patchFunc interface{}) {\n\t// find addr of the func\n\tsymbolName := getSymbolName(pkgName, typeName, methodName)\n\taddr := symbolTable[symbolName]\n\toriginalBytes := replaceFunction(addr, (uintptr)(getPtr(reflect.ValueOf(patchFunc))))\n\tpatchRecord[addr] = originalBytes\n}", "func PATCH(c *httputil.Client, data DataMultipartWriter, v interface{}, url string) error {\n\treturn Do(c, \"PATCH\", data, v, url)\n}", "func (e *Expect) PATCH(path string, pathargs ...interface{}) *Request {\n\treturn e.Request(http.MethodPatch, path, pathargs...)\n}", "func (c *previewFeatures) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PreviewFeature, err error) {\n\tresult = &v1alpha1.PreviewFeature{}\n\terr = c.client.Patch(pt).\n\t\tResource(\"previewfeatures\").\n\t\tName(name).\n\t\tSubResource(subresources...).\n\t\tVersionedParams(&opts, scheme.ParameterCodec).\n\t\tBody(data).\n\t\tDo(ctx).\n\t\tInto(result)\n\treturn\n}", "func PatchMethod(e *echo.Group, newFn newInstanceFn, pFn patchFn) {\n\te.PATCH(\"/:id\", func(c echo.Context) error {\n\t\tvar id int\n\n\t\tif err := Param(\"id\").InPath().Int(c, &id); err != nil {\n\t\t\treturn BadRequest(err)\n\t\t}\n\t\tresource := newFn()\n\t\tif err := c.Bind(resource); err != nil {\n\t\t\treturn BadRequest(err)\n\t\t}\n\n\t\tif err := pFn(resource); err != nil {\n\t\t\treturn InternalServerError(err)\n\t\t}\n\n\t\treturn c.NoContent(http.StatusNoContent)\n\t})\n\n}", "func PatchBytes(url string, data ...interface{}) []byte {\n\treturn RequestBytes(\"PATCH\", url, data...)\n}", "func (m *MockJobClient) Patch(arg0, arg1 string, arg2 types.PatchType, arg3 []byte, arg4 ...string) (*v1.Job, error) {\n\tm.ctrl.T.Helper()\n\tvarargs := []interface{}{arg0, arg1, arg2, arg3}\n\tfor _, a := range arg4 {\n\t\tvarargs = append(varargs, a)\n\t}\n\tret := m.ctrl.Call(m, \"Patch\", varargs...)\n\tret0, _ := ret[0].(*v1.Job)\n\tret1, _ := ret[1].(error)\n\treturn ret0, ret1\n}", "func Patch(t testing.TB, dest, value interface{}) {\n\tNew(t).Patch(dest, value)\n}", "func (conn Connection) Patch(cmd string, content, result interface{}) (effect *SideEffect, resp *http.Response, err error) {\n\treturn conn.Send(http.MethodPatch, cmd, content, result)\n}", "func patch(c client.Client, opCond *operators.OperatorCondition, newCond meta.Condition) error {\n\tnewCond.LastTransitionTime = meta.Now()\n\tpatchData, err := json.Marshal([]*patcher.JSONPatch{\n\t\tpatcher.NewJSONPatch(\"add\", \"/spec/conditions\", []meta.Condition{newCond})})\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to generate patch request body for Condition %v: %w\", newCond, err)\n\t}\n\tif err = c.Patch(context.TODO(), opCond, client.RawPatch(types.JSONPatchType, patchData)); err != nil {\n\t\treturn fmt.Errorf(\"unable to apply patch %s to OperatorCondition %s: %w\", patchData, opCond.GetName(), err)\n\t}\n\treturn nil\n}", "func (w *ClusterDynamicClient) Patch(name string, pt types.PatchType, data []byte, options metav1.PatchOptions, subresources ...string) (*unstructured.Unstructured, error) {\n\treturn w.dClient.Resource(w.resource).Namespace(w.namespace).Patch(w.ctx, name, pt, data, options, subresources...)\n}", "func (*PatchInputsRequest) Descriptor() ([]byte, []int) {\n\treturn file_proto_clarifai_api_service_proto_rawDescGZIP(), []int{59}\n}", "func (akp *AKPatches) ApprovePatch(ctx context.Context, params interface{}) ([]byte, error) {\n\tpostData, err := json.Marshal(params)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\trequest, err := http.NewRequest(\"POST\", akp.client.Server+\"/api/v1.0/AKPatches.ApprovePatch\",\n\t\tbytes.NewBuffer(postData))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\traw, err := akp.client.Do(ctx, request, nil)\n\treturn raw, err\n}", "func (c *kongs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.Kong, err error) {\n\tresult = &v1alpha1.Kong{}\n\terr = c.client.Patch(pt).\n\t\tNamespace(c.ns).\n\t\tResource(\"kongs\").\n\t\tSubResource(subresources...).\n\t\tName(name).\n\t\tBody(data).\n\t\tDo().\n\t\tInto(result)\n\treturn\n}", "func Patch(url string, requestBody []byte, requestHeaders map[string]string, authHeader string) (int, []byte, map[string][]string) {\n\tlogs.Alert(fmt.Sprintf(\"<------------------------- %s ------------------------->\\n\", \"start\"))\n\tlogs.Alert(fmt.Sprintf(\"[HTTP PATCH: %s]\", url))\n\n\tr, _ := http.NewRequest(\"PATCH\", url, bytes.NewBuffer(requestBody))\n\n\tif authHeader != \"\" {\n\t\tr.Header.Add(\"Authorization\", authHeader)\n\t}\n\n\tfor name, value := range requestHeaders {\n\t\tr.Header.Add(name, value)\n\t}\n\n\tclient := &http.Client{Transport: transport, Timeout: timeout}\n\tresp, err := client.Do(r)\n\n\tif err != nil {\n\t\tlogs.Alert(fmt.Sprintf(\"[Request Error --> %v]\", err))\n\t\treturn http.StatusInternalServerError, nil, nil\n\t}\n\n\tdefer resp.Body.Close()\n\tjsonBytes, _ := ioutil.ReadAll(resp.Body)\n\tlogs.Alert(fmt.Sprintf(\"[Status Code --> %d]\", resp.StatusCode))\n\tlogs.Alert(fmt.Sprintf(\"[Response Headers --> %v]\", resp.Header))\n\tlogs.Alert(fmt.Sprintf(\"[Response --> %s]\", string(jsonBytes)))\n\tlogs.Alert(fmt.Sprintf(\"<------------------------- %s ------------------------->\", \"end\"))\n\treturn resp.StatusCode, jsonBytes, resp.Header\n}", "func createPatch(key, basePath, patchOp, value string) JSONPatchOperation {\n\treturn JSONPatchOperation{\n\t\tOp: patchOp,\n\t\tPath: path.Join(basePath, escapeJSONPointerValue(key)),\n\t\tValue: value,\n\t}\n}", "func (c *Client) Patch(url string, headers, queryParams map[string][]string, data interface{}) (response *http.Response, err error) {\n\treturn c.makeRequest(url, http.MethodPatch, headers, queryParams, data)\n}", "func (conn Connection) Patch(cmd string, content, result interface{}) (resp *http.Response, err error) {\n\treturn conn.Send(http.MethodPatch, cmd, content, result)\n}", "func (p *Patch) Patch() error {\n\tif p == nil {\n\t\treturn errors.New(\"patch is nil\")\n\t}\n\tif err := isPatchable(p.target, p.redirection); err != nil {\n\t\treturn err\n\t}\n\tif err := applyPatch(p); err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (m *MultiValueLegacyExtendedPropertyItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.MultiValueLegacyExtendedPropertyable, requestConfiguration *MultiValueLegacyExtendedPropertyItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {\n requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()\n requestInfo.UrlTemplate = m.urlTemplate\n requestInfo.PathParameters = m.pathParameters\n requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH\n requestInfo.Headers[\"Accept\"] = \"application/json\"\n requestInfo.SetContentFromParsable(ctx, m.requestAdapter, \"application/json\", body)\n if requestConfiguration != nil {\n requestInfo.AddRequestHeaders(requestConfiguration.Headers)\n requestInfo.AddRequestOptions(requestConfiguration.Options)\n }\n return requestInfo, nil\n}", "func (r *FakeClient) Patch(\n\tctx context.Context, obj client.Object, patch client.Patch, opts ...client.PatchOption,\n) error {\n\t// TODO (covariance) implement me!\n\tpanic(\"not implemented\")\n}", "func (p *Permission) GetPatch() (map[string]interface{}, error) {\n\tpatch := make(map[string]interface{})\n\n\tif p.Owner != \"\" {\n\t\tpatch[\"owner\"] = p.Owner\n\t}\n\tif p.Username != \"\" {\n\t\treturn nil, errors.NewUnsupportedPatchError(\"permission\", \"username\")\n\t}\n\tif p.Password != \"\" {\n\t\treturn nil, errors.NewUnsupportedPatchError(\"permission\", \"password\")\n\t}\n\tif p.Creator != \"\" {\n\t\treturn nil, errors.NewUnsupportedPatchError(\"permission\", \"creator\")\n\t}\n\tif p.Categories != nil {\n\t\tpatch[\"categories\"] = p.Categories\n\t\tif p.ACLs != nil {\n\t\t\tif err := p.ValidateACLs(p.ACLs...); err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\t\t\tpatch[\"acls\"] = p.ACLs\n\t\t} else {\n\t\t\tpatch[\"acls\"] = category.ACLsFor(p.Categories...)\n\t\t}\n\t}\n\tif p.Ops != nil {\n\t\tpatch[\"ops\"] = p.Ops\n\t}\n\tif p.Indices != nil {\n\t\tpatch[\"indices\"] = p.Indices\n\t}\n\tif p.Sources != nil {\n\t\tif err := validateSources(p.Sources); err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tpatch[\"sources\"] = p.Sources\n\t}\n\tif p.Referers != nil {\n\t\tif err := validateReferers(p.Referers); err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tpatch[\"referers\"] = p.Referers\n\t}\n\tif p.CreatedAt != \"\" {\n\t\treturn nil, errors.NewUnsupportedPatchError(\"permission\", \"created_at\")\n\t}\n\tif p.TTL.String() != \"0s\" {\n\t\tpatch[\"ttl\"] = p.TTL\n\t}\n\t// Cannot patch individual limits to 0\n\tif p.Limits != nil {\n\t\tlimits := make(map[string]interface{})\n\t\tif p.Limits.IPLimit != 0 {\n\t\t\tlimits[\"ip_limit\"] = p.Limits.IPLimit\n\t\t}\n\t\tif p.Limits.DocsLimit != 0 {\n\t\t\tlimits[\"docs_limit\"] = p.Limits.DocsLimit\n\t\t}\n\t\tif p.Limits.SearchLimit != 0 {\n\t\t\tlimits[\"search_limit\"] = p.Limits.SearchLimit\n\t\t}\n\t\tif p.Limits.IndicesLimit != 0 {\n\t\t\tlimits[\"indices_limit\"] = p.Limits.IndicesLimit\n\t\t}\n\t\tif p.Limits.CatLimit != 0 {\n\t\t\tlimits[\"cat_limit\"] = p.Limits.CatLimit\n\t\t}\n\t\tif p.Limits.ClustersLimit != 0 {\n\t\t\tlimits[\"clusters_limit\"] = p.Limits.ClustersLimit\n\t\t}\n\t\tif p.Limits.MiscLimit != 0 {\n\t\t\tlimits[\"misc_limit\"] = p.Limits.MiscLimit\n\t\t}\n\t\tpatch[\"limits\"] = limits\n\t}\n\tif p.Description != \"\" {\n\t\tpatch[\"description\"] = p.Description\n\t}\n\n\treturn patch, nil\n}", "func (iface *Iface) patch(dev Patchable) {\n\tiface.patched = dev\n}", "func (l *Library) Patch(src *Library) {\n\tif src.Name != \"\" {\n\t\tl.Name = src.Name\n\t}\n\tif src.Description != \"\" {\n\t\tl.Description = src.Description\n\t}\n\tif src.Version != \"\" {\n\t\tl.Version = src.Version\n\t}\n}", "func (m *MockInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*v1.PersistentVolume, error) {\n\tm.ctrl.T.Helper()\n\tvarargs := []interface{}{ctx, name, pt, data, opts}\n\tfor _, a := range subresources {\n\t\tvarargs = append(varargs, a)\n\t}\n\tret := m.ctrl.Call(m, \"Patch\", varargs...)\n\tret0, _ := ret[0].(*v1.PersistentVolume)\n\tret1, _ := ret[1].(error)\n\treturn ret0, ret1\n}", "func TestPatch(t *testing.T) {\n\tconst case1Empty = \"/\"\n\tconst case2SetHeader = \"/set_header\"\n\tconst case3SendJSON = \"/send_json\"\n\tts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {\n\t\t// check method is PATCH before going to check other features\n\t\tif r.Method != PATCH {\n\t\t\tt.Errorf(\"Expected method %q; got %q\", PATCH, r.Method)\n\t\t}\n\t\tif r.Header == nil {\n\t\t\tt.Errorf(\"Expected non-nil request Header\")\n\t\t}\n\t\tswitch r.URL.Path {\n\t\tdefault:\n\t\t\tt.Errorf(\"No testing for this case yet : %q\", r.URL.Path)\n\t\tcase case1Empty:\n\t\t\tt.Logf(\"case %v \", case1Empty)\n\t\tcase case2SetHeader:\n\t\t\tt.Logf(\"case %v \", case2SetHeader)\n\t\t\tif r.Header.Get(\"API-Key\") != \"fookey\" {\n\t\t\t\tt.Errorf(\"Expected 'API-Key' == %q; got %q\", \"fookey\", r.Header.Get(\"API-Key\"))\n\t\t\t}\n\t\tcase case3SendJSON:\n\t\t\tt.Logf(\"case %v \", case3SendJSON)\n\t\t\tdefer r.Body.Close()\n\t\t\tbody, _ := ioutil.ReadAll(r.Body)\n\t\t\tif string(body) != `{\"query1\":\"test\",\"query2\":\"test\"}` {\n\t\t\t\tt.Error(`Expected Body with {\"query1\":\"test\",\"query2\":\"test\"}`, \"| but got\", string(body))\n\t\t\t}\n\t\t}\n\t}))\n\n\tdefer ts.Close()\n\n\tNew().Patch(ts.URL + case1Empty).\n\t\tEnd()\n\n\tNew().Patch(ts.URL+case2SetHeader).\n\t\tSetHeader(\"API-Key\", \"fookey\").\n\t\tEnd()\n\n\tNew().Patch(ts.URL + case3SendJSON).\n\t\tSendMapString(`{\"query1\":\"test\"}`).\n\t\tSendMapString(`{\"query2\":\"test\"}`).\n\t\tEnd()\n}", "func (c *Client) Patch(rawurl string, in, out interface{}) error {\n\treturn c.Do(rawurl, \"PATCH\", in, out)\n}", "func (p patchList) patch(f *funcProto, pc int) {\n\tfor _, ipc := range p {\n\t\tf.code[ipc].setSBx(mkoffset(ipc, pc)) // -1 to correct for the automatic +1 to the PC after each instruction.\n\t}\n}", "func (r *Reconciler) patch(\n\tctx context.Context, object client.Object,\n\tpatch client.Patch, options ...client.PatchOption,\n) error {\n\toptions = append([]client.PatchOption{r.Owner}, options...)\n\treturn r.Client.Patch(ctx, object, patch, options...)\n}", "func (p *Patch) Patch() {\n\tp.patched = true\n\tif p.funcInfo != nil {\n\t\tp.applyFunc()\n\t} else if p.varInfo != nil {\n\t\tp.applyVar()\n\t}\n}", "func (*ItfparamsPrimary) PatchPath(ref string) string {\n\treturn fmt.Sprintf(\"/api/objects/itfparams/primary/%s\", ref)\n}", "func (node *Node) PATCH(functions ...interface{}) *Handler {\n\n\thandler := &Handler{}\n\n\tif len(functions) > 0 { handler.function = functions[0].(func (req web.RequestInterface) *web.ResponseStatus) }\n\n\tnode.addHandler(\"PATCH\", handler)\n\n\treturn handler\n}", "func (m *FeatureRolloutPolicyItemRequestBuilder) Patch(ctx context.Context, body iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.FeatureRolloutPolicyable, requestConfiguration *FeatureRolloutPolicyItemRequestBuilderPatchRequestConfiguration)(iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.FeatureRolloutPolicyable, error) {\n requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);\n if err != nil {\n return nil, err\n }\n errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {\n \"4XX\": ia572726a95efa92ddd544552cd950653dc691023836923576b2f4bf716cf204a.CreateODataErrorFromDiscriminatorValue,\n \"5XX\": ia572726a95efa92ddd544552cd950653dc691023836923576b2f4bf716cf204a.CreateODataErrorFromDiscriminatorValue,\n }\n res, err := m.requestAdapter.SendAsync(ctx, requestInfo, iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.CreateFeatureRolloutPolicyFromDiscriminatorValue, errorMapping)\n if err != nil {\n return nil, err\n }\n if res == nil {\n return nil, nil\n }\n return res.(iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.FeatureRolloutPolicyable), nil\n}", "func (c *SubresourceClient) Patch(namespace string, name string, data []byte) (e error) {\n\tif c.Error != \"\" {\n\t\te = fmt.Errorf(c.Error)\n\t}\n\treturn\n}", "func (c *meshPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.MeshPolicy, err error) {\n\tresult = &v1alpha1.MeshPolicy{}\n\terr = c.client.Patch(pt).\n\t\tResource(\"meshpolicies\").\n\t\tSubResource(subresources...).\n\t\tName(name).\n\t\tBody(data).\n\t\tDo().\n\t\tInto(result)\n\treturn\n}", "func (fkw *FakeClientWrapper) Patch(ctx context.Context, obj runtime.Object,\n\tpatch k8sCl.Patch, opts ...k8sCl.PatchOption) error {\n\treturn fkw.client.Patch(ctx, obj, patch, opts...)\n}", "func (mr *MockJobClientMockRecorder) Patch(arg0, arg1, arg2, arg3 interface{}, arg4 ...interface{}) *gomock.Call {\n\tmr.mock.ctrl.T.Helper()\n\tvarargs := append([]interface{}{arg0, arg1, arg2, arg3}, arg4...)\n\treturn mr.mock.ctrl.RecordCallWithMethodType(mr.mock, \"Patch\", reflect.TypeOf((*MockJobClient)(nil).Patch), varargs...)\n}", "func createPatch(pod *corev1.Pod, inj *config.InjectionConfig, annotations map[string]string) ([]byte, error) {\n\tvar patch []patchOperation\n\n\t// make sure any injected containers in our config get the EnvVars and VolumeMounts injected\n\t// this mutates inj.Containers with our environment vars\n\tmutatedInjectedContainers := mergeEnvVars(inj.Environment, inj.Containers)\n\tmutatedInjectedContainers = mergeVolumeMounts(inj.VolumeMounts, mutatedInjectedContainers)\n\n\t// make sure any injected init containers in our config get the EnvVars and VolumeMounts injected\n\t// this mutates inj.InitContainers with our environment vars\n\tmutatedInjectedInitContainers := mergeEnvVars(inj.Environment, inj.InitContainers)\n\tmutatedInjectedInitContainers = mergeVolumeMounts(inj.VolumeMounts, mutatedInjectedInitContainers)\n\n\t// patch all existing containers with the env vars and volume mounts\n\tpatch = append(patch, setVolumeMounts(pod.Spec.Containers, inj.VolumeMounts, \"/spec/containers\")...)\n\t// TODO: fix set env\n\t// setEnvironment may not work, because we replace the whole container in `setVolumeMounts`\n\tpatch = append(patch, setEnvironment(pod.Spec.Containers, inj.Environment)...)\n\n\t// patch containers with our injected containers\n\tpatch = append(patch, addContainers(pod.Spec.Containers, mutatedInjectedContainers, \"/spec/containers\")...)\n\n\t// add initContainers, hostAliases and volumes\n\tpatch = append(patch, addContainers(pod.Spec.InitContainers, mutatedInjectedInitContainers, \"/spec/initContainers\")...)\n\tpatch = append(patch, addHostAliases(pod.Spec.HostAliases, inj.HostAliases, \"/spec/hostAliases\")...)\n\tpatch = append(patch, addVolumes(pod.Spec.Volumes, inj.Volumes, \"/spec/volumes\")...)\n\n\t// set annotations\n\tpatch = append(patch, updateAnnotations(pod.Annotations, annotations)...)\n\n\t// set shareProcessNamespace\n\tpatch = append(patch, updateShareProcessNamespace(inj.ShareProcessNamespace)...)\n\n\t// TODO: remove injecting commands when sidecar container supported\n\t// set commands and args\n\tpatch = append(patch, setCommands(pod.Spec.Containers, inj.PostStart)...)\n\n\treturn json.Marshal(patch)\n}", "func prepareResourceForPatch(current runtime.Object, modified client.Object) {\n\t// when object is get from client via client.Get, GVK is wiped. To prevent\n\t// the diff being generated by one object having GVK and other not, we make\n\t// sure that the empty GVK is reset to the one of the modified object\n\tif current.GetObjectKind().GroupVersionKind() == schema.EmptyObjectKind.GroupVersionKind() &&\n\t\tmodified.GetObjectKind().GroupVersionKind() != schema.EmptyObjectKind.GroupVersionKind() {\n\t\tcurrent.GetObjectKind().SetGroupVersionKind(modified.GetObjectKind().GroupVersionKind())\n\t}\n}", "func (apiContext Context) UsersByIDPatch(w http.ResponseWriter, r *http.Request) {\n\n\t// Get context variables.\n\tmodelContext := context.Get(r, \"modelContext\").(model.Context)\n\n\t// Get path parameters.\n\tvars := mux.Vars(r)\n\tid := vars[\"id\"]\n\n\t// Validate parameters.\n\tif id == \"\" {\n\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusBadRequest, \"The 'id' parameter is required.\", nil)\n\t\treturn\n\t}\n\n\t// Parse body.\n\tvar patchBody map[string]*json.RawMessage\n\tdecoder := json.NewDecoder(r.Body)\n\tif err := decoder.Decode(&patchBody); err != nil {\n\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusBadRequest, \"Invalid request payload\", errors.WithStack(err))\n\t\treturn\n\t}\n\tdefer r.Body.Close()\n\n\t// Parse specific fields from the body.\n\tvar updates = map[string]interface{}{}\n\tif rawName, ok := patchBody[\"name\"]; ok {\n\t\tvar name string\n\t\tif err := json.Unmarshal(*rawName, &name); err != nil {\n\t\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusBadRequest, \"Body is not properly formatted JSON.\", errors.WithStack(err))\n\t\t\treturn\n\t\t}\n\t\tupdates[\"name\"] = name\n\t}\n\tif rawStatus, ok := patchBody[\"status\"]; ok {\n\t\tvar status string\n\t\tif err := json.Unmarshal(*rawStatus, &status); err != nil {\n\t\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusBadRequest, \"Body is not properly formatted JSON.\", errors.WithStack(err))\n\t\t\treturn\n\t\t}\n\t\tupdates[\"status\"] = status\n\t}\n\tif rawPassword, ok := patchBody[\"password\"]; ok {\n\t\tvar password string\n\t\tif err := json.Unmarshal(*rawPassword, &password); err != nil {\n\t\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusBadRequest, \"Body is not properly formatted JSON.\", errors.WithStack(err))\n\t\t\treturn\n\t\t}\n\t\tupdates[\"password\"] = password\n\t}\n\n\t// Access model.\n\t_, err := modelContext.UpdateUser(id, updates)\n\tif errors.Cause(err) == model.ErrNotFound {\n\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusNotFound, http.StatusText(http.StatusNotFound), errors.WithStack(err))\n\t\treturn\n\t} else if errors.Cause(err) == model.ErrBadInput {\n\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusBadRequest, http.StatusText(http.StatusBadRequest), errors.WithStack(err))\n\t\treturn\n\t} else if err != nil {\n\t\tresponses.Context(apiContext).RespondWithError(w, r, http.StatusInternalServerError, \"Something went wrong.\", errors.WithStack(err))\n\t\treturn\n\t}\n\n\t// Return response.\n\tw.WriteHeader(http.StatusOK)\n}", "func CreatePatch(in *ecr.Repository, target *v1alpha1.RepositoryParameters) (*v1alpha1.RepositoryParameters, error) {\n\tcurrentParams := &v1alpha1.RepositoryParameters{}\n\tLateInitializeRepository(currentParams, in)\n\n\tjsonPatch, err := awsclients.CreateJSONPatch(currentParams, target)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpatch := &v1alpha1.RepositoryParameters{}\n\tif err := json.Unmarshal(jsonPatch, patch); err != nil {\n\t\treturn nil, err\n\t}\n\treturn patch, nil\n}", "func RawPatch(patchType types.PatchType, data []byte) Patch {\n\treturn &patch{patchType, data}\n}", "func (c *Config) Patch(patch map[string]interface{}) (map[string]string, error) {\n\tvalues, err := c.Dump() // Use current values as defaults\n\tif err != nil {\n\t\treturn nil, errors.WithStack(err)\n\t}\n\tfor name, value := range patch {\n\t\tvalues[name] = value\n\t}\n\treturn c.update(values)\n}", "func (c *rpcServices) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.RpcService, err error) {\n\tresult = &v1.RpcService{}\n\terr = c.client.Patch(pt).\n\t\tNamespace(c.ns).\n\t\tResource(\"rpcservices\").\n\t\tSubResource(subresources...).\n\t\tName(name).\n\t\tBody(data).\n\t\tDo().\n\t\tInto(result)\n\treturn\n}", "func patchPi(w http.ResponseWriter, r *http.Request) {\n\t// Get pi name from request\n\tvars := mux.Vars(r)\n\tname := vars[\"piname\"]\n\n\t// Retrieve pi object from data store\n\tc := appengine.NewContext(r)\n\tq := datastore.NewQuery(piListKind).Filter(\"name =\", name)\n\tt := q.Run(c)\n\tvar pi Pi\n\t_, err := t.Next(&pi)\n\tif err == datastore.Done {\n\t\thttp.Error(w, \"404 Not found\", http.StatusNotFound)\n\t\treturn\n\t}\n\tif err != nil {\n\t\thttp.Error(w, err.Error(), http.StatusInternalServerError)\n\t\treturn\n\t}\n\n\t// Set Pi object property\n\tr.ParseForm()\n\n\t// Updating the name is not allowed\n\tformName := r.Form.Get(\"name\")\n\tif len(formName) != 0 {\n\t\thttp.Error(w, \"404 Not found\", http.StatusNotFound)\n\t\treturn\n\t}\n\tip := r.Form.Get(\"ip\")\n\tif len(ip) != 0 {\n\t\tpi.Ip = ip\n\t}\n\tlastSeen := r.Form.Get(\"lastSeen\")\n\tif len(lastSeen) != 0 {\n\t\tpi.LastSeen = lastSeen\n\t}\n\tpingCount := r.Form.Get(\"pingCount\")\n\tif len(pingCount) != 0 {\n\t\tpi.PingCount, _ = strconv.Atoi(r.Form.Get(\"pingCount\"))\n\t}\n\n\t//\tfmt.Fprint(w, \"name \", , \"\\n\")\n\tfmt.Fprint(w, \"pingCount \", r.Form.Get(\"pingCount\"), \" \", pi.PingCount, \"\\n\")\n\n\t// Store pi object in data store\n\t_, err = datastore.Put(c, datastore.NewKey(c, piListKind, name, 0, nil), &pi)\n\tif err != nil {\n\t\thttp.Error(w, err.Error(), http.StatusInternalServerError)\n\t\treturn\n\t}\n\thttp.Error(w, \"200 OK\", http.StatusOK)\n\treturn\n}", "func (api *Api) Patch(path string, endpoint http.HandlerFunc, queries ...string) {\n\tapi.Router.HandleFunc(path, endpoint).Methods(\"PATCH\").Queries(queries...)\n}", "func newUpdateInterconnectPatchRequest(ctx context.Context, f *Interconnect, c *Client) (map[string]interface{}, error) {\n\treq := map[string]interface{}{}\n\n\tif v := f.Description; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"description\"] = v\n\t}\n\tif v := f.Name; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"name\"] = v\n\t}\n\tif v := f.Location; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"location\"] = v\n\t}\n\tif v := f.LinkType; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"linkType\"] = v\n\t}\n\tif v := f.RequestedLinkCount; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"requestedLinkCount\"] = v\n\t}\n\tif v := f.InterconnectType; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"interconnectType\"] = v\n\t}\n\tif v := f.AdminEnabled; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"adminEnabled\"] = v\n\t}\n\tif v := f.NocContactEmail; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"nocContactEmail\"] = v\n\t}\n\tif v := f.CustomerName; !dcl.IsEmptyValueIndirect(v) {\n\t\treq[\"customerName\"] = v\n\t}\n\treturn req, nil\n}", "func (res *Resource) Patch(storage store.Update) {\n\tres.HandleFuncC(\n\t\tpat.Patch(patID),\n\t\tfunc(ctx context.Context, w http.ResponseWriter, r *http.Request) {\n\t\t\tres.patchHandler(ctx, w, r, storage)\n\t\t},\n\t)\n\n\tres.addRoute(patch, patID)\n}", "func SchedulePatch(ctx context.Context, patchId string, version *model.Version, patchUpdateReq PatchUpdate) (error, int, string, string) {\n\tvar err error\n\tp, err := patch.FindOneId(patchId)\n\tif err != nil {\n\t\treturn errors.Errorf(\"error loading patch: %s\", err), http.StatusInternalServerError, \"\", \"\"\n\t}\n\n\t// only modify parameters if the patch hasn't been finalized\n\tif patchUpdateReq.ParametersModel != nil && p.Version == \"\" {\n\t\tvar parameters []patch.Parameter\n\t\tfor _, param := range patchUpdateReq.ParametersModel {\n\t\t\tparameters = append(parameters, param.ToService())\n\t\t}\n\t\tif err = p.SetParameters(parameters); err != nil {\n\t\t\treturn errors.Errorf(\"error setting patch parameters: %s\", err), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\t}\n\n\tif p.IsCommitQueuePatch() {\n\t\treturn errors.New(\"can't schedule commit queue patch\"), http.StatusBadRequest, \"\", \"\"\n\t}\n\n\t// Unmarshal the project config and set it in the project context\n\tproject := &model.Project{}\n\tif _, err = model.LoadProjectInto(ctx, []byte(p.PatchedConfig), nil, p.Project, project); err != nil {\n\t\treturn errors.Errorf(\"Error unmarshaling project config: %v\", err), http.StatusInternalServerError, \"\", \"\"\n\t}\n\n\taddDisplayTasksToPatchReq(&patchUpdateReq, *project)\n\ttasks := model.VariantTasksToTVPairs(patchUpdateReq.VariantsTasks)\n\n\ttasks.ExecTasks, err = model.IncludeDependencies(project, tasks.ExecTasks, p.GetRequester())\n\tgrip.Warning(message.WrapError(err, message.Fields{\n\t\t\"message\": \"error including dependencies for patch\",\n\t\t\"patch\": patchId,\n\t}))\n\n\tif err = model.ValidateTVPairs(project, tasks.ExecTasks); err != nil {\n\t\treturn err, http.StatusBadRequest, \"\", \"\"\n\t}\n\n\t// update the description for both reconfigured and new patches\n\tif err = p.SetDescription(patchUpdateReq.Description); err != nil {\n\t\treturn errors.Wrap(err, \"Error setting description\"), http.StatusInternalServerError, \"\", \"\"\n\t}\n\n\t// update the description for both reconfigured and new patches\n\tif err = p.SetVariantsTasks(tasks.TVPairsToVariantTasks()); err != nil {\n\t\treturn errors.Wrap(err, \"Error setting description\"), http.StatusInternalServerError, \"\", \"\"\n\t}\n\n\t// create a separate context from the one the callar has so that the caller\n\t// can't interrupt the db operations here\n\tnewCxt := context.Background()\n\n\tprojectRef, err := model.FindMergedProjectRef(project.Identifier)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"unable to find project ref\"), http.StatusInternalServerError, \"\", \"\"\n\t}\n\tif projectRef == nil {\n\t\treturn errors.Errorf(\"project '%s' not found\", project.Identifier), http.StatusInternalServerError, \"\", \"\"\n\t}\n\n\tif p.Version != \"\" {\n\t\tp.Activated = true\n\t\t// This patch has already been finalized, just add the new builds and tasks\n\t\tif version == nil {\n\t\t\treturn errors.Errorf(\"Couldn't find patch for id %v\", p.Version), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\t\t// First add new tasks to existing builds, if necessary\n\t\terr = model.AddNewTasksForPatch(context.Background(), p, version, project, tasks, projectRef.Identifier)\n\t\tif err != nil {\n\t\t\treturn errors.Wrapf(err, \"Error creating new tasks for version `%s`\", version.Id), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\n\t\terr = model.AddNewBuildsForPatch(newCxt, p, version, project, tasks, projectRef)\n\t\tif err != nil {\n\t\t\treturn errors.Wrapf(err, \"Error creating new builds for version `%s`\", version.Id), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\n\t\treturn nil, http.StatusOK, \"Builds and tasks successfully added to patch.\", version.Id\n\n\t} else {\n\t\tsettings, err := evergreen.GetConfig()\n\t\tif err != nil {\n\t\t\treturn err, http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\t\tgithubOauthToken, err := settings.GetGithubOauthToken()\n\t\tif err != nil {\n\t\t\treturn err, http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\t\tp.Activated = true\n\t\terr = p.SetVariantsTasks(tasks.TVPairsToVariantTasks())\n\t\tif err != nil {\n\t\t\treturn errors.Wrap(err, \"Error setting patch variants and tasks\"), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\n\t\t// Process additional patch trigger aliases added via UI.\n\t\t// Child patches created with the CLI --trigger-alias flag go through a separate flow, so ensure that new child patches are also created before the parent is finalized.\n\t\tchildPatchIds, err := units.ProcessTriggerAliases(ctx, p, projectRef, evergreen.GetEnvironment(), patchUpdateReq.PatchTriggerAliases)\n\t\tif err != nil {\n\t\t\treturn errors.Wrap(err, \"Error processing patch trigger aliases\"), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\t\tif len(childPatchIds) > 0 {\n\t\t\tif err = p.SetChildPatches(); err != nil {\n\t\t\t\treturn errors.Wrapf(err, \"error attaching child patches '%s'\", p.Id.Hex()), http.StatusInternalServerError, \"\", \"\"\n\t\t\t}\n\t\t\tp.Triggers.Aliases = patchUpdateReq.PatchTriggerAliases\n\t\t\tif err = p.SetTriggerAliases(); err != nil {\n\t\t\t\treturn errors.Wrapf(err, \"error attaching trigger aliases '%s'\", p.Id.Hex()), http.StatusInternalServerError, \"\", \"\"\n\t\t\t}\n\t\t}\n\n\t\trequester := p.GetRequester()\n\t\tver, err := model.FinalizePatch(newCxt, p, requester, githubOauthToken)\n\t\tif err != nil {\n\t\t\treturn errors.Wrap(err, \"Error finalizing patch\"), http.StatusInternalServerError, \"\", \"\"\n\t\t}\n\t\tif requester == evergreen.PatchVersionRequester {\n\t\t\tgrip.Info(message.Fields{\n\t\t\t\t\"operation\": \"patch creation\",\n\t\t\t\t\"message\": \"finalized patch\",\n\t\t\t\t\"from\": \"UI\",\n\t\t\t\t\"patch_id\": p.Id,\n\t\t\t\t\"variants\": p.BuildVariants,\n\t\t\t\t\"tasks\": p.Tasks,\n\t\t\t\t\"variant_tasks\": p.VariantsTasks,\n\t\t\t\t\"alias\": p.Alias,\n\t\t\t})\n\t\t}\n\n\t\tif p.IsGithubPRPatch() {\n\t\t\tjob := units.NewGithubStatusUpdateJobForNewPatch(p.Id.Hex())\n\t\t\tif err := evergreen.GetEnvironment().LocalQueue().Put(newCxt, job); err != nil {\n\t\t\t\treturn errors.Wrap(err, \"Error adding github status update job to queue\"), http.StatusInternalServerError, \"\", \"\"\n\t\t\t}\n\t\t}\n\n\t\treturn nil, http.StatusOK, \"Patch builds are scheduled.\", ver.Id\n\t}\n}", "func ApplyPatch(obj Obj, patches []JSONPatchOp) (Obj, error) {\n\tfor _, patch := range patches {\n\t\tval, ok := patch.Value.(float64)\n\t\tif !ok {\n\t\t\treturn Obj{}, fmt.Errorf(\"unsupported value for path '\"+patch.Path+\"': %T\", patch.Value)\n\t\t}\n\n\t\tpath := strings.Split(patch.Path, \"/\")\n\t\tif len(path) != 4 {\n\t\t\treturn Obj{}, fmt.Errorf(\"unsupported patch path for Obj, expected 4 parts: '%v' got '%+v'\", patch.Path, path)\n\t\t}\n\t\tpath = path[1:] // remove initial empty /\n\t\tif path[0] == \"foo-a\" {\n\t\t\tif path[1] == \"bar-a\" {\n\t\t\t\tif path[2] == \"baz-a\" {\n\t\t\t\t\tobj.FooA.BarA.BazA = int64(val)\n\t\t\t\t} else if path[2] == \"baz-b\" {\n\t\t\t\t\tobj.FooA.BarA.BazB = int64(val)\n\t\t\t\t} else {\n\t\t\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[2] + \"' in '\" + patch.Path + \"'\")\n\t\t\t\t}\n\t\t\t} else if path[1] == \"bar-b\" {\n\t\t\t\tif path[2] == \"baz-a\" {\n\t\t\t\t\tobj.FooA.BarB.BazA = int64(val)\n\t\t\t\t} else if path[2] == \"baz-b\" {\n\t\t\t\t\tobj.FooA.BarB.BazB = int64(val)\n\t\t\t\t} else {\n\t\t\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[2] + \"' in '\" + patch.Path + \"'\")\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[1] + \"' in '\" + patch.Path + \"'\")\n\t\t\t}\n\t\t} else if path[0] == \"foo-b\" {\n\t\t\tif path[1] == \"bar-a\" {\n\t\t\t\tif path[2] == \"baz-a\" {\n\t\t\t\t\tobj.FooB.BarA.BazA = int64(val)\n\t\t\t\t} else if path[2] == \"baz-b\" {\n\t\t\t\t\tobj.FooB.BarA.BazB = int64(val)\n\t\t\t\t} else {\n\t\t\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[2] + \"' in '\" + patch.Path + \"'\")\n\t\t\t\t}\n\t\t\t} else if path[1] == \"bar-b\" {\n\t\t\t\tif path[2] == \"baz-a\" {\n\t\t\t\t\tobj.FooB.BarB.BazA = int64(val)\n\t\t\t\t} else if path[2] == \"baz-b\" {\n\t\t\t\t\tobj.FooB.BarB.BazB = int64(val)\n\t\t\t\t} else {\n\t\t\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[2] + \"' in '\" + patch.Path + \"'\")\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[1] + \"' in '\" + patch.Path + \"'\")\n\t\t\t}\n\t\t} else {\n\t\t\treturn Obj{}, errors.New(\"unsupported patch path for Obj, unsupported part: '\" + path[0] + \"' in '\" + patch.Path + \"'\")\n\t\t}\n\t}\n\treturn obj, nil\n}", "func (a *APITest) Patch(url string) *Request {\n\ta.request.method = http.MethodPatch\n\ta.request.url = url\n\treturn a.request\n}", "func Patch(dev1, dev2 Patchable) error {\n\tif dev1.IsPatched() {\n\t\treturn fmt.Errorf(\"unable to patch %v as it is laready patched\", dev1.GetName())\n\t}\n\n\tif dev2.IsPatched() {\n\t\treturn fmt.Errorf(\"unable to patch %v as it is laready patched\", dev2.GetName())\n\t}\n\tdev1.patch(dev2)\n\tdev2.patch(dev1)\n\treturn nil\n}", "func (m *DeviceLocalCredentialInfoItemRequestBuilder) Patch(ctx context.Context, body ie233ee762e29b4ba6970aa2a2efce4b7fde11697ca9ea81099d0f8269309c1be.DeviceLocalCredentialInfoable, requestConfiguration *DeviceLocalCredentialInfoItemRequestBuilderPatchRequestConfiguration)(ie233ee762e29b4ba6970aa2a2efce4b7fde11697ca9ea81099d0f8269309c1be.DeviceLocalCredentialInfoable, error) {\n requestInfo, err := m.ToPatchRequestInformation(ctx, body, requestConfiguration);\n if err != nil {\n return nil, err\n }\n errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {\n \"4XX\": i20a3050780ee0b0cde0a884a4f35429a20d60067e3bcda382ec5400079147459.CreateODataErrorFromDiscriminatorValue,\n \"5XX\": i20a3050780ee0b0cde0a884a4f35429a20d60067e3bcda382ec5400079147459.CreateODataErrorFromDiscriminatorValue,\n }\n res, err := m.BaseRequestBuilder.RequestAdapter.Send(ctx, requestInfo, ie233ee762e29b4ba6970aa2a2efce4b7fde11697ca9ea81099d0f8269309c1be.CreateDeviceLocalCredentialInfoFromDiscriminatorValue, errorMapping)\n if err != nil {\n return nil, err\n }\n if res == nil {\n return nil, nil\n }\n return res.(ie233ee762e29b4ba6970aa2a2efce4b7fde11697ca9ea81099d0f8269309c1be.DeviceLocalCredentialInfoable), nil\n}", "func (m *FeatureRolloutPolicyItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.FeatureRolloutPolicyable, requestConfiguration *FeatureRolloutPolicyItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {\n requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()\n requestInfo.UrlTemplate = m.urlTemplate\n requestInfo.PathParameters = m.pathParameters\n requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH\n requestInfo.Headers[\"Accept\"] = \"application/json\"\n requestInfo.SetContentFromParsable(ctx, m.requestAdapter, \"application/json\", body)\n if requestConfiguration != nil {\n requestInfo.AddRequestHeaders(requestConfiguration.Headers)\n requestInfo.AddRequestOptions(requestConfiguration.Options)\n }\n return requestInfo, nil\n}", "func (*PatchConceptsRequest) Descriptor() ([]byte, []int) {\n\treturn file_proto_clarifai_api_service_proto_rawDescGZIP(), []int{34}\n}", "func overrideParameters(input interface{}, options *ProcessorOptions) {\n\tif options == nil || len(options.ParameterOverrides) == 0 {\n\t\treturn\n\t}\n\n\t// Check the template is a map\n\tif template, ok := input.(map[string]interface{}); ok {\n\t\t// Check there is a parameters section\n\t\tif uparameters, ok := template[\"Parameters\"]; ok {\n\t\t\t// Check the parameters section is a map\n\t\t\tif parameters, ok := uparameters.(map[string]interface{}); ok {\n\t\t\t\tfor name, value := range options.ParameterOverrides {\n\t\t\t\t\t// Check there is a parameter with the same name as the Ref\n\t\t\t\t\tif uparameter, ok := parameters[name]; ok {\n\t\t\t\t\t\t// Check the parameter is a map\n\t\t\t\t\t\tif parameter, ok := uparameter.(map[string]interface{}); ok {\n\t\t\t\t\t\t\t// Set the default value\n\t\t\t\t\t\t\tparameter[\"Default\"] = value\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\t}\n}", "func patchPods(cluster *imec_db.DB_INFRASTRUCTURE_CLUSTER, namespace string, podName string) (string, error) {\n\tlog.Println(pathLOG + \"COMPSs [patchPods] Generating 'pod patch' json ...\")\n\tlK8sPatchPod := structs.StructNewPodPatch(podName) // returns []structs.K8S_POD_PATCH_LINE\n\n\tstrTxt, _ := structs.CommPatchPodsListToString(lK8sPatchPod)\n\tlog.Println(pathLOG + \"COMPSs [patchPods] [\" + strTxt + \"]\")\n\n\t// CALL to Kubernetes API to launch a new deployment\n\tlog.Println(pathLOG + \"COMPSs [patchPods] Patching pod \" + podName + \" ...\")\n\tstatus, _, err := common.HTTPPATCHStruct(\n\t\turls.GetPathKubernetesPod(cluster, namespace, podName),\n\t\t//cfg.Config.Clusters[clusterIndex].KubernetesEndPoint+\"/api/v1/namespaces/\"+namespace+\"/pods/\"+podName,\n\t\ttrue,\n\t\tlK8sPatchPod)\n\tif err != nil {\n\t\tlog.Error(pathLOG+\"COMPSs [patchPods] ERROR\", err)\n\t\treturn \"error\", err\n\t}\n\tlog.Println(pathLOG + \"COMPSs [patchPods] RESPONSE: OK\")\n\n\treturn strconv.Itoa(status), nil\n}", "func (s *Service) patchHalResource(ctx context.Context, resourceName, url string, r interface{}, pf patchFunction) ([]byte, *status.Status) {\n\n\tvar body []byte\n\tvar code int\n\tvar err error\n\n\tb := new(bytes.Buffer)\n\tjson.NewEncoder(b).Encode(r)\n\n\tbody, code, err = pf(ctx, url, b, \"application/json\")\n\tif err != nil {\n\t\tlog.WithFields(event.Fields{\n\t\t\t\"resourceName\": resourceName,\n\t\t\t\"code\": code,\n\t\t\t\"url\": url,\n\t\t}).Error(\"Can not patch HAL resource: \" + err.Error())\n\t\treturn []byte{}, status.NewStatus(body, code, \"Can not modify resource \"+resourceName)\n\t}\n\n\t// A PATCH request should return a value in range of [200,300[\n\tif code < http.StatusOK || code >= http.StatusMultipleChoices {\n\t\tlog.WithFields(event.Fields{\n\t\t\t\"resourceName\": resourceName,\n\t\t\t\"code\": code,\n\t\t\t\"url\": url,\n\t\t}).Error(\"Can not patch HAL resource\")\n\t\treturn []byte{}, status.NewStatus(body, code, \"Can not modify resource \"+resourceName)\n\t}\n\treturn body, nil\n}", "func (m *TermStoreRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ia3c27b33aa3d3ed80f9de797c48fbb8ed73f13887e301daf51f08450e9a634a3.Storeable, requestConfiguration *TermStoreRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {\n requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()\n requestInfo.UrlTemplate = m.urlTemplate\n requestInfo.PathParameters = m.pathParameters\n requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH\n requestInfo.Headers[\"Accept\"] = \"application/json\"\n requestInfo.SetContentFromParsable(ctx, m.requestAdapter, \"application/json\", body)\n if requestConfiguration != nil {\n requestInfo.AddRequestHeaders(requestConfiguration.Headers)\n requestInfo.AddRequestOptions(requestConfiguration.Options)\n }\n return requestInfo, nil\n}", "func (m *WindowsUpdatesCatalogRequestBuilder) Patch(ctx context.Context, body i17376df570f19ff3c32da2d66a677d31250ed0ff64059351645f48a152316b3c.Catalogable, requestConfiguration *WindowsUpdatesCatalogRequestBuilderPatchRequestConfiguration)(i17376df570f19ff3c32da2d66a677d31250ed0ff64059351645f48a152316b3c.Catalogable, error) {\n requestInfo, err := m.ToPatchRequestInformation(ctx, body, requestConfiguration);\n if err != nil {\n return nil, err\n }\n errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {\n \"4XX\": i20a3050780ee0b0cde0a884a4f35429a20d60067e3bcda382ec5400079147459.CreateODataErrorFromDiscriminatorValue,\n \"5XX\": i20a3050780ee0b0cde0a884a4f35429a20d60067e3bcda382ec5400079147459.CreateODataErrorFromDiscriminatorValue,\n }\n res, err := m.BaseRequestBuilder.RequestAdapter.Send(ctx, requestInfo, i17376df570f19ff3c32da2d66a677d31250ed0ff64059351645f48a152316b3c.CreateCatalogFromDiscriminatorValue, errorMapping)\n if err != nil {\n return nil, err\n }\n if res == nil {\n return nil, nil\n }\n return res.(i17376df570f19ff3c32da2d66a677d31250ed0ff64059351645f48a152316b3c.Catalogable), nil\n}", "func patch(a, b interface{}) interface{} {\n\tif m, ok := a.(map[string]interface{}); ok {\n\t\treturn handleMap(m, b)\n\t}\n\n\tif m, ok := b.(map[string]interface{}); ok {\n\t\treturn removeNull(m)\n\t}\n\n\treturn b\n}", "func patchResource(mapping *meta.RESTMapping, config *rest.Config, group string,\n\tversion string, namespace string, data []byte) error {\n\trestClient, err := getRESTClient(config, group, version)\n\tif err != nil {\n\t\treturn &kfapis.KfError{\n\t\t\tCode: int(kfapis.INVALID_ARGUMENT),\n\t\t\tMessage: fmt.Sprintf(\"patchResource error: %v\", err),\n\t\t}\n\t}\n\n\tif _, err = restClient.\n\t\tPatch(k8stypes.JSONPatchType).\n\t\tResource(mapping.Resource.Resource).\n\t\tNamespaceIfScoped(namespace, mapping.Scope.Name() == \"namespace\").\n\t\tBody(data).\n\t\tDo().\n\t\tGet(); err == nil {\n\t\treturn nil\n\t} else {\n\t\treturn &kfapis.KfError{\n\t\t\tCode: int(kfapis.INVALID_ARGUMENT),\n\t\t\tMessage: fmt.Sprintf(\"patchResource error: %v\", err),\n\t\t}\n\t}\n}", "func (mr *MockPodInterfaceMockRecorder) Patch(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call {\n\tvarargs := append([]interface{}{arg0, arg1, arg2}, arg3...)\n\treturn mr.mock.ctrl.RecordCallWithMethodType(mr.mock, \"Patch\", reflect.TypeOf((*MockPodInterface)(nil).Patch), varargs...)\n}", "func createPatch(cur, desired interface{}) ([]byte, error) {\n\tpatch, err := duck.CreatePatch(cur, desired)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn patch.MarshalJSON()\n}", "func (o *APICheck) Patch(sparse elemental.SparseIdentifiable) {\n\tif !sparse.Identity().IsEqual(o.Identity()) {\n\t\tpanic(\"cannot patch from a parse with different identity\")\n\t}\n\n\tso := sparse.(*SparseAPICheck)\n\tif so.Authorized != nil {\n\t\to.Authorized = *so.Authorized\n\t}\n\tif so.Namespace != nil {\n\t\to.Namespace = *so.Namespace\n\t}\n\tif so.Operation != nil {\n\t\to.Operation = *so.Operation\n\t}\n\tif so.TargetIdentities != nil {\n\t\to.TargetIdentities = *so.TargetIdentities\n\t}\n}", "func (a *APITest) Patchf(format string, args ...interface{}) *Request {\n\treturn a.Patch(fmt.Sprintf(format, args...))\n}", "func (v *version) Patch() int {\n\treturn v.patch\n}", "func (a *PostsApiService) PatchGlipPost(ctx context.Context, chatId string, postId string, body GlipPatchPostBody) (GlipPostInfo, *http.Response, error) {\n\tvar (\n\t\tlocalVarHttpMethod = strings.ToUpper(\"Patch\")\n\t\tlocalVarPostBody interface{}\n\t\tlocalVarFormFileName string\n\t\tlocalVarFileName string\n\t\tlocalVarFileBytes []byte\n\t\tlocalVarReturnValue GlipPostInfo\n\t)\n\n\t// create path and map variables\n\tlocalVarPath := a.client.cfg.BasePath + \"/restapi/v1.0/glip/chats/{chatId}/posts/{postId}\"\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"chatId\"+\"}\", fmt.Sprintf(\"%v\", chatId), -1)\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"postId\"+\"}\", fmt.Sprintf(\"%v\", postId), -1)\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := url.Values{}\n\tlocalVarFormParams := url.Values{}\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{\"application/json\"}\n\n\t// set Accept header\n\tlocalVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)\n\tif localVarHttpHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHttpHeaderAccept\n\t}\n\t// body params\n\tlocalVarPostBody = &body\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 == 200 {\n\t\t\tvar v GlipPostInfo\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\treturn localVarReturnValue, localVarHttpResponse, newErr\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 (a *App) Patch(w http.ResponseWriter, r *http.Request) {\n\tw.Write([]byte(\"patching in testing mode. Get ready to send multipart-form data\"))\n}", "func (r *versionResolver) Patch(ctx context.Context, obj *restModel.APIVersion) (*restModel.APIPatch, error) {\n\tif !evergreen.IsPatchRequester(*obj.Requester) {\n\t\treturn nil, nil\n\t}\n\tapiPatch, err := data.FindPatchById(*obj.Id)\n\tif err != nil {\n\t\treturn nil, InternalServerError.Send(ctx, fmt.Sprintf(\"Couldn't find a patch with id '%s': %s\", *obj.Id, err.Error()))\n\t}\n\treturn apiPatch, nil\n}", "func (s *policyClient) Patch(o *v1alpha1.Policy, patchType types.PatchType, data []byte, subresources ...string) (*v1alpha1.Policy, error) {\n\tobj, err := s.objectClient.Patch(o.Name, o, patchType, data, subresources...)\n\treturn obj.(*v1alpha1.Policy), err\n}", "func (r *Request) Patch(url string) *Request {\n\tr.method = http.MethodPatch\n\tr.url = url\n\treturn r\n}", "func Patch(route string, do interface{}) *handler {\n\treturn handlerByMethod(&route, do, \"PATCH\")\n}", "func setNonPrimitiveParams(params *CmdLineParams) {\n\n\tif params.StartDateStr != \"\" {\n\t\tparams.StartDate = parseDate(params.StartDateStr)\n\t}\n\n\tif params.EndDateStr != \"\" {\n\t\tparams.EndDate = parseDate(params.EndDateStr)\n\t} else {\n\t\tparams.EndDate = time.Now()\n\t}\n\n\tif params.FilterFpr != \"\" {\n\t\tfprs := strings.Split(params.FilterFpr, \",\")\n\t\tfor _, fpr := range fprs {\n\t\t\tparams.Filter.AddFingerprint(tor.Fingerprint(fpr))\n\t\t}\n\t}\n\n\tif params.FilterAddr != \"\" {\n\t\taddrs := strings.Split(params.FilterAddr, \",\")\n\t\tfor _, addr := range addrs {\n\t\t\tparams.Filter.AddIPAddr(net.ParseIP(addr))\n\t\t}\n\t}\n\n\tif params.FilterNickname != \"\" {\n\t\tnicks := strings.Split(params.FilterNickname, \",\")\n\t\tfor _, nick := range nicks {\n\t\t\tparams.Filter.AddNickname(nick)\n\t\t}\n\t}\n\n\tlog.Printf(\"Object filter is empty: %t\", params.Filter.IsEmpty())\n}", "func (m *DeviceRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body iadcd81124412c61e647227ecfc4449d8bba17de0380ddda76f641a29edf2b242.Deviceable, requestConfiguration *DeviceRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {\n requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()\n requestInfo.UrlTemplate = m.urlTemplate\n requestInfo.PathParameters = m.pathParameters\n requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH\n requestInfo.Headers[\"Accept\"] = \"application/json\"\n requestInfo.SetContentFromParsable(ctx, m.requestAdapter, \"application/json\", body)\n if requestConfiguration != nil {\n requestInfo.AddRequestHeaders(requestConfiguration.Headers)\n requestInfo.AddRequestOptions(requestConfiguration.Options)\n }\n return requestInfo, nil\n}" ]
[ "0.62402534", "0.61877155", "0.6032005", "0.59996474", "0.5926835", "0.592449", "0.5880058", "0.579319", "0.5792935", "0.57902384", "0.57578284", "0.5726518", "0.5697806", "0.56827646", "0.56526625", "0.5620683", "0.5607507", "0.56057024", "0.56056166", "0.5601641", "0.5589956", "0.55394477", "0.55346125", "0.5531774", "0.5511673", "0.5476432", "0.5469475", "0.54615134", "0.54599535", "0.5457026", "0.5456833", "0.5452163", "0.5449723", "0.54412365", "0.5433317", "0.5428543", "0.54226446", "0.5413645", "0.541316", "0.5408949", "0.54071903", "0.5385439", "0.5378263", "0.53746766", "0.53640056", "0.5362781", "0.5340952", "0.53377867", "0.53377676", "0.5335398", "0.53353566", "0.53217316", "0.5313054", "0.5312959", "0.5297553", "0.52838296", "0.527118", "0.5263527", "0.5255338", "0.5248763", "0.52425367", "0.52358615", "0.52331", "0.5231213", "0.52310103", "0.5227064", "0.5225757", "0.5224408", "0.5223866", "0.5219918", "0.5217075", "0.52104264", "0.52099836", "0.52096283", "0.5199318", "0.51929253", "0.5190733", "0.51822996", "0.51821214", "0.51785225", "0.5176429", "0.5161554", "0.51582193", "0.5153195", "0.51531357", "0.5150955", "0.5150571", "0.5149437", "0.5149194", "0.5144775", "0.5142733", "0.51247984", "0.51234806", "0.5120962", "0.5120303", "0.51178974", "0.5113741", "0.5109199", "0.51080954" ]
0.5559666
22
pause transform feedback operations
func PauseTransformFeedback() { C.glowPauseTransformFeedback(gpPauseTransformFeedback) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PauseTransformFeedback() {\n C.glowPauseTransformFeedback(gpPauseTransformFeedback)\n}", "func PAUSE() { ctx.PAUSE() }", "func PauseTransformFeedback() {\n\tsyscall.Syscall(gpPauseTransformFeedback, 0, 0, 0, 0)\n}", "func pause() tea.Msg {\n\ttime.Sleep(time.Millisecond * 600)\n\treturn DoneMsg{}\n}", "func ResumeTransformFeedback() {\n C.glowResumeTransformFeedback(gpResumeTransformFeedback)\n}", "func pause() {\n\ttime.Sleep(500 * time.Millisecond)\n}", "func (c *Compound) Pause() {\n\tc.lock.RLock()\n\tif cp, ok := c.subRenderables[c.curRenderable].(CanPause); ok {\n\t\tcp.Pause()\n\t}\n\tc.lock.RUnlock()\n}", "func (self *Tween) _pause() {\n self.Object.Call(\"_pause\")\n}", "func (self *Tween) Pause() {\n self.Object.Call(\"pause\")\n}", "func (_ERC20Pausable *ERC20PausableTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _ERC20Pausable.contract.Transact(opts, \"pause\")\n}", "func (_Pausable *PausableTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Pausable.contract.Transact(opts, \"pause\")\n}", "func (_Pausable *PausableTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Pausable.contract.Transact(opts, \"pause\")\n}", "func (c *Context) PAUSE() {\n\tc.addinstruction(x86.PAUSE())\n}", "func (self *PhysicsP2) Pause() {\n self.Object.Call(\"pause\")\n}", "func (e *Emulator) Pause() {}", "func (_Cakevault *CakevaultTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Cakevault.contract.Transact(opts, \"pause\")\n}", "func (c *Compound) Unpause() {\n\tc.lock.RLock()\n\tif cp, ok := c.subRenderables[c.curRenderable].(CanPause); ok {\n\t\tcp.Unpause()\n\t}\n\tc.lock.RUnlock()\n}", "func (self *Tween) _pauseI(args ...interface{}) {\n self.Object.Call(\"_pause\", args)\n}", "func (_OracleMgr *OracleMgrTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _OracleMgr.contract.Transact(opts, \"pause\")\n}", "func (self *Tween) _resume() {\n self.Object.Call(\"_resume\")\n}", "func (self *Tween) Resume() {\n self.Object.Call(\"resume\")\n}", "func (c *Switch) Pause() {\n\tc.lock.RLock()\n\tif cp, ok := c.subRenderables[c.curRenderable].(CanPause); ok {\n\t\tcp.Pause()\n\t}\n\tc.lock.RUnlock()\n}", "func (play *Play) Done() {\n\tcount := play.PhaseCount()\n\tplay.phases[count-1].active = false\n}", "func suspend() {}", "func (_LifToken *LifTokenTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _LifToken.contract.Transact(opts, \"pause\")\n}", "func (_ERC20Pausable *ERC20PausableTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _ERC20Pausable.contract.Transact(opts, \"unpause\")\n}", "func (_ElvToken *ElvTokenTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _ElvToken.contract.Transact(opts, \"pause\")\n}", "func (_Token *TokenTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Token.contract.Transact(opts, \"pause\")\n}", "func (e *Enumeration) Pause() {\n\te.pause <- struct{}{}\n}", "func (e *Enumeration) Pause() {\n\te.pause <- struct{}{}\n}", "func (_DelegateProfile *DelegateProfileTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _DelegateProfile.contract.Transact(opts, \"pause\")\n}", "func (cr *ConflictResolver) Pause() {\n\tcr.stopProcessing()\n}", "func (cg *CgroupImpl) Pause() error {\n\treturn cg.setFreezeState(1)\n}", "func (c *Switch) Unpause() {\n\tc.lock.RLock()\n\tif cp, ok := c.subRenderables[c.curRenderable].(CanPause); ok {\n\t\tcp.Unpause()\n\t}\n\tc.lock.RUnlock()\n}", "func (_ChpRegistry *ChpRegistryTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _ChpRegistry.contract.Transact(opts, \"pause\")\n}", "func (c *chrono) Continue() {\n\tc.paused = false\n}", "func (self *PhysicsP2) Resume() {\n self.Object.Call(\"resume\")\n}", "func ResumeTransformFeedback() {\n\tsyscall.Syscall(gpResumeTransformFeedback, 0, 0, 0, 0)\n}", "func (_Pausable *PausableTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Pausable.contract.Transact(opts, \"unpause\")\n}", "func (_Pausable *PausableTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Pausable.contract.Transact(opts, \"unpause\")\n}", "func (_MonsterAccessControl *MonsterAccessControlTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _MonsterAccessControl.contract.Transact(opts, \"pause\")\n}", "func (j Jibi) Pause() {\n\tj.RunCommand(CmdPause, nil)\n}", "func MWAIT() { ctx.MWAIT() }", "func (l *renderLoop) Pause() chan int {\n\treturn l.pause\n}", "func (_PausableToken *PausableTokenTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _PausableToken.contract.Transact(opts, \"pause\")\n}", "func (w *Walker) Pause() {\n\tw.pauseRequested = true\n}", "func (self *Tween) PauseI(args ...interface{}) {\n self.Object.Call(\"pause\", args)\n}", "func (helper *testHelper) Pause(secs int) {}", "func (self *PhysicsP2) PauseI(args ...interface{}) {\n self.Object.Call(\"pause\", args)\n}", "func ResumeTransformFeedback() {\n\tC.glowResumeTransformFeedback(gpResumeTransformFeedback)\n}", "func ResumeTransformFeedback() {\n\tC.glowResumeTransformFeedback(gpResumeTransformFeedback)\n}", "func (l *LightningLoader) Pause() {\n\tl.Lock()\n\tdefer l.Unlock()\n\tif l.isClosed() {\n\t\tl.logger.Warn(\"try to pause, but already closed\")\n\t\treturn\n\t}\n\tif l.cancel != nil {\n\t\tl.cancel()\n\t}\n\tl.core.Stop()\n}", "func (_Cakevault *CakevaultTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Cakevault.contract.Transact(opts, \"unpause\")\n}", "func (self *Tween) _resumeI(args ...interface{}) {\n self.Object.Call(\"_resume\", args)\n}", "func (p *ProgressMeter) Pause() {\n\tif atomic.CompareAndSwapInt32(&p.started, 1, 0) {\n\t\tp.finished <- true\n\t}\n}", "func (p *literalProcessor) stop() { syncClose(p.done) }", "func (n *BaseNode) Pause() {\n\tn.pauseFunc(func() {\n\t\tn.ctxPause, n.cancelPause = context.WithCancel(n.ctx)\n\t})\n}", "func (s *Surface) ResetTransform() {\n\ts.Ctx.Call(\"resetTransform\")\n}", "func (_MonsterOwnership *MonsterOwnershipTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _MonsterOwnership.contract.Transact(opts, \"pause\")\n}", "func (cg *CgroupImpl) Unpause() error {\n\treturn cg.setFreezeState(0)\n}", "func (st *LevelCompleteState) OnPause(world w.World) {}", "func (p *Pacer) Pause() {\n\tp.pause <- struct{}{} // block this channel\n\tp.paused <- struct{}{} // set flag to indicate paused\n}", "func (apu *APU) Step() {\n\tvar sampleLeft float32\n\tvar sampleRight float32\n\tapu.sampleT += stepDuration\n\n\tif !apu.active {\n\t\tapu.sampleLeft = 0\n\t\tapu.sampleRight = 0\n\n\t\tif apu.sampleT >= sampleDuration {\n\t\t\tapu.sampleT -= sampleDuration\n\t\t\tapu.m.Lock()\n\t\t\tapu.soundBuffer = append(apu.soundBuffer, sampleLeft, sampleRight)\n\t\t\tsampleCount := len(apu.soundBuffer)\n\t\t\tapu.m.Unlock()\n\t\t\tif sampleCount > sampleBufferLength*channelCount*2 {\n\t\t\t\tsleepTime := sampleDuration * sampleBufferLength\n\t\t\t\ttime.Sleep(sleepTime)\n\t\t\t}\n\t\t}\n\t\treturn\n\t}\n\n\tstep := apu.fs.step()\n\n\tfor i, sc := range apu.generators {\n\t\tsc.Step(step)\n\t\tsample := sc.CurrentSample()\n\t\tsampleLeft += (sample * apu.getVolume(left, i))\n\t\tsampleRight += (sample * apu.getVolume(right, i))\n\t}\n\n\tgenCount := float32(len(apu.generators))\n\tapu.sampleLeft = mix(apu.sampleLeft, (sampleLeft / genCount))\n\tapu.sampleRight = mix(apu.sampleRight, (sampleLeft / genCount))\n\n\tif apu.sampleT >= sampleDuration {\n\t\tapu.sampleT -= sampleDuration\n\n\t\tsampleLeft = apu.sampleLeft * apu.masterVolume\n\t\tsampleRight = apu.sampleRight * apu.masterVolume\n\t\tapu.sampleLeft = 0\n\t\tapu.sampleRight = 0\n\n\t\tapu.m.Lock()\n\t\tapu.soundBuffer = append(apu.soundBuffer, sampleLeft, sampleRight)\n\t\tsampleCount := len(apu.soundBuffer)\n\t\tapu.m.Unlock()\n\n\t\tif (sampleCount > sampleBufferLength*channelCount*2) && !apu.TestMode {\n\t\t\tsleepTime := sampleDuration * sampleBufferLength\n\t\t\ttime.Sleep(sleepTime)\n\t\t}\n\t}\n}", "func (_OracleMgr *OracleMgrTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _OracleMgr.contract.Transact(opts, \"unpause\")\n}", "func (_Pausable *PausableTransactorSession) Pause() (*types.Transaction, error) {\n\treturn _Pausable.Contract.Pause(&_Pausable.TransactOpts)\n}", "func (_OracleMgr *OracleMgrTransactorSession) Pause() (*types.Transaction, error) {\n\treturn _OracleMgr.Contract.Pause(&_OracleMgr.TransactOpts)\n}", "func (c *canvasRenderer) ResetTransform() {\n\tif c.currentLayer == c.topLayer {\n\t\tc.currentLayer.Transform = sprec.IdentityMat4()\n\t} else {\n\t\tc.currentLayer.Transform = c.currentLayer.previous.Transform\n\t}\n}", "func Finish() {\n C.glowFinish(gpFinish)\n}", "func (_Token *TokenTransactor) PauseTrigger(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Token.contract.Transact(opts, \"pauseTrigger\")\n}", "func (_Cakevault *CakevaultTransactorSession) Pause() (*types.Transaction, error) {\n\treturn _Cakevault.Contract.Pause(&_Cakevault.TransactOpts)\n}", "func (t Track) Pause(bool) {\n\tpanic(\"implement me\")\n}", "func (_DelegateProfile *DelegateProfileTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _DelegateProfile.contract.Transact(opts, \"unpause\")\n}", "func (s *BaseSyslParserListener) ExitTransform(ctx *TransformContext) {}", "func (p *Playlist) UnPause() {\n\tp.ch <- \"unpause\"\n}", "func (self Sound) Pause() {\n\tC.sfSound_pause(self.Cref)\n}", "func (r *reaper) stop() {\n\tr.stopCh <- struct{}{}\n}", "func (c *Timer) Pause() {\n\tc.ticker.Stop()\n\tc.passed += time.Now().Sub(c.lastTick)\n\tc.lastTick = time.Now()\n\tc.options.OnPaused()\n}", "func (p *Playlist) Pause() {\n\tp.ch <- \"pause\"\n}", "func (p *Pipeline) Stop() {\n\tC.gstreamer_receive_stop_pipeline(p.Pipeline)\n}", "func (p *Pipeline) Stop() {\n\t// Lock Pipelines\n\tC.gstreamer_stop_pipeline(p.Pipeline)\n}", "func (this *AVTransport) Pause(instanceId uint32) error {\n\ttype Response struct {\n\t\tXMLName xml.Name\n\t\tErrorResponse\n\t}\n\targs := []Arg{\n\t\t{\"InstanceID\", instanceId},\n\t}\n\tresponse := this.Svc.Call(\"Pause\", args)\n\tdoc := Response{}\n\txml.Unmarshal([]byte(response), &doc)\n\treturn doc.Error()\n}", "func (_DelegateProfile *DelegateProfileTransactorSession) Pause() (*types.Transaction, error) {\n\treturn _DelegateProfile.Contract.Pause(&_DelegateProfile.TransactOpts)\n}", "func BeginTransformFeedback(primitiveMode uint32) {\n C.glowBeginTransformFeedback(gpBeginTransformFeedback, (C.GLenum)(primitiveMode))\n}", "func (c *canvasRenderer) Translate(delta sprec.Vec2) {\n\tc.currentLayer.Transform = sprec.Mat4Prod(\n\t\tc.currentLayer.Transform,\n\t\tsprec.TranslationMat4(delta.X, delta.Y, 0.0),\n\t)\n}", "func Pause(msg string) {\n\tfmt.Print(msg, \"[Press Enter to Continue]: \")\n\tvar s string\n\t_, err := fmt.Scan(&s)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func (c *chrono) Pause() {\n\tc.pausedAt = c.Now()\n\tc.paused = true\n}", "func (_MonsterAccessControl *MonsterAccessControlTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _MonsterAccessControl.contract.Transact(opts, \"unpause\")\n}", "func (v *VpxEncoder) Stop() {\n\tv.release()\n}", "func (session *RtpRtcpSession) PauseTransfer() error {\n\tsession.IfPause = true\n\treturn nil\n}", "func (_Token *TokenTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _Token.contract.Transact(opts, \"unpause\")\n}", "func (self *Tween) ResumeI(args ...interface{}) {\n self.Object.Call(\"resume\", args)\n}", "func (container *container) Pause() error {\r\n\treturn convertSystemError(container.system.Pause(context.Background()), container)\r\n}", "func Pass1(ctx context.Context, fi FileInfo, cropArg string, ch chan<- progress.Report) {\n\tdefer close(ch)\n\tch <- progress.Report{Completed: 0.0}\n\targs := []string{\n\t\t\"-i\", fi.Filename,\n\t\t// Process all streams.\n\t\t\"-map\", \"0\",\n\t\t// Copy streams by default, eg subtitles.\n\t\t\"-c\", \"copy\",\n\t\t// Increase buffer.\n\t\t\"-max_muxing_queue_size\", \"400\",\n\t}\n\tvideoQualityArgs(&args, &fi, cropArg, 1)\n\tfor _, s := range fi.Streams {\n\t\tif s.ShouldSkip() {\n\t\t\targs = append(args, \"-map\", \"-0:\"+s.Id)\n\t\t}\n\t}\n\tif *darFlag != \"\" {\n\t\targs = append(args, \"-vf\", \"setdar=dar=\"+*darFlag)\n\t}\n\targs = append(args, \"-passlogfile\", fi.passlogfile(), \"-pass\", \"1\", \"-f\", \"matroska\", \"-y\", \"/dev/null\")\n\tif *showCmdFlag {\n\t\tfmt.Printf(\"$ ffmpeg '%s'\\n\", strings.Join(args, \"' '\"))\n\t}\n\tcmd := exec.CommandContext(ctx, \"ffmpeg\", args...)\n\toutput, err := start(cmd)\n\tif err != nil {\n\t\tch <- progress.Report{Err: err}\n\t\treturn\n\t}\n\treadConversionProgress(output, fi, ch)\n\tif err = cmd.Wait(); err != nil {\n\t\tch <- progress.Report{Err: err}\n\t}\n}", "func (ts *TextState) ProcDQ(data []byte, aw, ac float64, ctx Context) {\n\tts.Tw = aw\n\tts.Tc = ac\n\tts.ProcQ(data, ctx)\n}", "func (p *Pacer) Resume() {\n\t<-p.paused // clear flag to indicate paused\n\t<-p.pause // unblock this channel\n}", "func (_MonsterAccessControl *MonsterAccessControlTransactorSession) Pause() (*types.Transaction, error) {\n\treturn _MonsterAccessControl.Contract.Pause(&_MonsterAccessControl.TransactOpts)\n}", "func (converger *converger) Stop() {\n\tconverger.stop <- struct{}{}\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 Pause() {\n\tatomic.AddUint64(&sched0.pausing, 1)\n\tsched0.pause()\n}" ]
[ "0.64732456", "0.6374028", "0.59985703", "0.5946686", "0.57284206", "0.55461264", "0.55041975", "0.5480023", "0.5430506", "0.54232055", "0.53961205", "0.53961205", "0.53875226", "0.5371025", "0.53265905", "0.5313194", "0.5306876", "0.5282202", "0.52798045", "0.52267754", "0.5219205", "0.51888615", "0.51544434", "0.5148082", "0.5112154", "0.510014", "0.50702214", "0.50680023", "0.5061619", "0.5061619", "0.5061338", "0.50444084", "0.5029931", "0.5029661", "0.5018655", "0.501464", "0.5011116", "0.49872205", "0.49856946", "0.49856946", "0.49848655", "0.498049", "0.4980375", "0.49546936", "0.4951009", "0.49403572", "0.49376655", "0.4933964", "0.49315724", "0.4918723", "0.4918723", "0.49105108", "0.49055424", "0.49021396", "0.4874341", "0.48586306", "0.48472553", "0.48429605", "0.48222053", "0.4810573", "0.4809739", "0.4802629", "0.48006475", "0.47923073", "0.4773814", "0.47716907", "0.47382826", "0.47090542", "0.47085762", "0.47070417", "0.46947086", "0.46822676", "0.46758738", "0.4673565", "0.46574527", "0.46572012", "0.46564192", "0.46542975", "0.46493244", "0.4645633", "0.46089667", "0.4606449", "0.46031913", "0.46000507", "0.45955878", "0.4587176", "0.45785838", "0.45769393", "0.45737627", "0.45529142", "0.4552347", "0.45514283", "0.4550654", "0.4539488", "0.45261985", "0.45175", "0.4516448", "0.4514351", "0.45114926" ]
0.5880575
5
set pixel storage modes
func PixelStorei(pname uint32, param int32) { C.glowPixelStorei(gpPixelStorei, (C.GLenum)(pname), (C.GLint)(param)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func Bcm2835_spi_setDataMode(Mode byte) {\n\tcMode, _ := (C.uint8_t)(Mode), cgoAllocsUnknown\n\tC.bcm2835_spi_setDataMode(cMode)\n}", "func (gbc *GomeboyColor) setHardwareMode(isColor bool) {\n\tif isColor {\n\t\tgbc.cpu.R.A = 0x11\n\t\tgbc.gpu.RunningColorGBHardware = gbc.mmu.IsCartridgeColor()\n\t\tgbc.mmu.RunningColorGBHardware = true\n\t} else {\n\t\tgbc.cpu.R.A = 0x01\n\t\tgbc.gpu.RunningColorGBHardware = false\n\t\tgbc.mmu.RunningColorGBHardware = false\n\t}\n}", "func (m *DeviceHealthAttestationState) SetSafeMode(value *string)() {\n err := m.GetBackingStore().Set(\"safeMode\", value)\n if err != nil {\n panic(err)\n }\n}", "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func (b *Bitmap) PixelMode() int {\n\treturn int(b.handle.pixel_mode)\n}", "func SetMode(value string) {\n\trgin.SetMode(value)\n}", "func (p *Periph) StoreMODE(mode Mode) {\n\tp.mode.StoreBits(0xf, uint32(mode))\n}", "func (pix *Pixel) Set(keyName string, val int) Pixel {\n\tswitch keyName {\n\tcase \"R\":\n\t\tpix.R = val\n\tcase \"G\":\n\t\tpix.G = val\n\tcase \"B\":\n\t\tpix.B = val\n\tcase \"A\":\n\t\tpix.A = val\n\t}\n\treturn *pix\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 *Container) setBitmap(bitmap []uint64) {\n\tif c == nil || c.frozen() {\n\t\tpanic(\"setBitmap on nil or frozen container\")\n\t}\n\tif roaringParanoia {\n\t\tif c.typeID != ContainerBitmap {\n\t\t\tpanic(\"attempt to write non-bitmap's bitmap\")\n\t\t}\n\t}\n\tif len(bitmap) != 1024 {\n\t\tpanic(fmt.Sprintf(\"illegal bitmap length %v\", len(bitmap)))\n\t}\n\tc.pointer, c.len, c.cap = (*uint16)(unsafe.Pointer(&bitmap[0])), bitmapN, bitmapN\n\tc.flags &^= flagPristine\n}", "func (r *Reg) setOSMode(mode Mode) {\n\tcurr := r.getOSMode()\n\tr.CPSR = (r.CPSR & 0b1111_1111_1111_1111_1111_1111_1110_0000) | uint32(mode)\n\tr.copyRegToBank(curr)\n\tr.copyBankToReg(mode)\n}", "func (f v4l2Format) setPixFormat(newPix PixFormat) {\n\t*(*PixFormat)(unsafe.Pointer(&f.fmt[0])) = newPix\n}", "func (s *memStat) Mode() os.FileMode { return 0444 }", "func (o IopingSpecVolumeVolumeSourceScaleIOPtrOutput) StorageMode() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *IopingSpecVolumeVolumeSourceScaleIO) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn v.StorageMode\n\t}).(pulumi.StringPtrOutput)\n}", "func PixelStorei(pname uint32, param int32) {\n\tsyscall.Syscall(gpPixelStorei, 2, uintptr(pname), uintptr(param), 0)\n}", "func (o IopingSpecVolumeVolumeSourceScaleIOOutput) StorageMode() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v IopingSpecVolumeVolumeSourceScaleIO) *string { return v.StorageMode }).(pulumi.StringPtrOutput)\n}", "func (v *Bitmap256) Set(pos uint8) {\n\tv[pos>>6] |= 1 << (pos & 63)\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 (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 SetMode(mode uint8) {\n\t_, _, errno := syscall.Syscall(syscall.SYS_IOCTL, spiFile.Fd(), spiIOCWrMode, uintptr(unsafe.Pointer(&mode)))\n\tif errno != 0 {\n\t\terr := syscall.Errno(errno)\n\t\tlog.Fatal(err)\n\t}\n}", "func (d *ModeDiff) setMode(mode rune) {\n\td.pos.setMode(mode)\n\td.neg.unsetMode(mode)\n}", "func (o FioSpecVolumeVolumeSourceScaleIOPtrOutput) StorageMode() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v *FioSpecVolumeVolumeSourceScaleIO) *string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn v.StorageMode\n\t}).(pulumi.StringPtrOutput)\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 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 (h *header) setMode(md mode) {\n\th.LiVnMode = (h.LiVnMode & 0xf8) | uint8(md)\n}", "func (o FioSpecVolumeVolumeSourceScaleIOOutput) StorageMode() pulumi.StringPtrOutput {\n\treturn o.ApplyT(func(v FioSpecVolumeVolumeSourceScaleIO) *string { return v.StorageMode }).(pulumi.StringPtrOutput)\n}", "func (s spiff) WithMode(mode int) Spiff {\n\tif s.fs != nil {\n\t\tmode = mode & ^MODE_OS_ACCESS\n\t}\n\ts.mode = mode\n\treturn s.Reset()\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 (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 PixelStorei(pname Enum, param int32) {\n\tgl.PixelStorei(uint32(pname), param)\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 FloatSetMode(z *big.Float, mode big.RoundingMode,) *big.Float", "func (i *Image) restore() error {\n\tw, h := i.image.Size()\n\tif i.screen {\n\t\t// The screen image should also be recreated because framebuffer might\n\t\t// be changed.\n\t\ti.image = graphics.NewScreenFramebufferImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.volatile {\n\t\ti.image = graphics.NewImage(w, h)\n\t\ti.basePixels = nil\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn nil\n\t}\n\tif i.stale {\n\t\t// TODO: panic here?\n\t\treturn errors.New(\"restorable: pixels must not be stale when restoring\")\n\t}\n\tgimg := graphics.NewImage(w, h)\n\tif i.basePixels != nil {\n\t\tgimg.ReplacePixels(i.basePixels, 0, 0, w, h)\n\t} else {\n\t\t// Clear the image explicitly.\n\t\tpix := make([]uint8, w*h*4)\n\t\tgimg.ReplacePixels(pix, 0, 0, w, h)\n\t}\n\tfor _, c := range i.drawImageHistory {\n\t\t// All dependencies must be already resolved.\n\t\tif c.image.hasDependency() {\n\t\t\tpanic(\"not reached\")\n\t\t}\n\t\tvs := []float32{}\n\t\tfor _, v := range c.vertices {\n\t\t\tvs = append(vs, v...)\n\t\t}\n\t\tgimg.DrawImage(c.image.image, vs, c.colorm, c.mode, c.filter)\n\t}\n\ti.image = gimg\n\n\tvar err error\n\ti.basePixels, err = gimg.Pixels()\n\tif err != nil {\n\t\treturn err\n\t}\n\ti.drawImageHistory = nil\n\ti.stale = false\n\treturn nil\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 (z *Float) SetMode(mode RoundingMode) *Float {}", "func (dev *Device) SetVideoMode(mode FrameMode) int {\n\treturn int(C.freenect_set_video_mode(dev.ptr(), *mode.ptr()))\n}", "func (d *Data) setResolution(uuid dvid.UUID, jsonBytes []byte) error {\n\tconfig := make(dvid.NdFloat32, 3)\n\tif err := json.Unmarshal(jsonBytes, &config); err != nil {\n\t\treturn err\n\t}\n\td.Properties.VoxelSize = config\n\treturn datastore.SaveDataByUUID(uuid, d)\n}", "func (r *Resources) Set(kind string, value float64) {\n\tswitch kind {\n\tcase common.CPU:\n\t\tr.CPU = value\n\tcase common.GPU:\n\t\tr.GPU = value\n\tcase common.MEMORY:\n\t\tr.MEMORY = value\n\tcase common.DISK:\n\t\tr.DISK = value\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 (s *sizes) setSizes(width int, height int) {\n\ts.width = width\n\ts.height = height\n\ts.curStreamsPerStreamDisplay = 1 + height/10\n}", "func MatrixMode(mode uint32) {\n C.glowMatrixMode(gpMatrixMode, (C.GLenum)(mode))\n}", "func (d *Detector) SetMode(x int) error {\n\terrno := C.fvad_set_mode(d.fvad, C.int(x))\n\tif errno != 0 {\n\t\treturn fmt.Errorf(\"invalid mode: %v\", x)\n\t}\n\treturn nil\n}", "func (dev *Device) SetDepthMode(mode FrameMode) int {\n\treturn int(C.freenect_set_depth_mode(dev.ptr(), *mode.ptr()))\n}", "func (m *Mock) SetStorageRadius(uint8) {\n\tpanic(\"not implemented\")\n}", "func (api *PrivateStorageHostManagerAPI) SetFilterMode(fm string, hostInfos []enode.ID) (resp string, err error) {\n\tvar filterMode FilterMode\n\tif filterMode, err = ToFilterMode(fm); err != nil {\n\t\terr = fmt.Errorf(\"failed to set the filter mode: %s\", err.Error())\n\t\treturn\n\t}\n\n\tif err = api.shm.SetFilterMode(filterMode, hostInfos); err != nil {\n\t\terr = fmt.Errorf(\"failed to set the filter mode: %s\", err.Error())\n\t\treturn\n\t}\n\n\tresp = fmt.Sprintf(\"the filter mode has been successfully set to %s\", fm)\n\treturn\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 Set(img image.Image) error {\n\t// Get the absolute path of the directory.\n\tusr, err := user.Current()\n\tif err != nil {\n\t\treturn err\n\t}\n\timgPath := filepath.Join(usr.HomeDir, \"AppData\", \"Roaming\", \"Himawari\", \"background.png\")\n\n\t// Create the file.\n\tif err := createFile(img, imgPath); err != nil {\n\t\treturn err\n\t}\n\n\t// Set the background, hoping it worked.\n\tproc.Call(\n\t\tspiSETDESKWALLPAPER,\n\t\t0,\n\t\tuintptr(unsafe.Pointer(syscall.StringToUTF16Ptr(imgPath))),\n\t\tspifUPDATEINIFILE,\n\t)\n\treturn nil\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 Bcm2835_pwm_set_mode(Channel byte, Markspace byte, Enabled byte) {\n\tcChannel, _ := (C.uint8_t)(Channel), cgoAllocsUnknown\n\tcMarkspace, _ := (C.uint8_t)(Markspace), cgoAllocsUnknown\n\tcEnabled, _ := (C.uint8_t)(Enabled), cgoAllocsUnknown\n\tC.bcm2835_pwm_set_mode(cChannel, cMarkspace, cEnabled)\n}", "func (s *Swarm64) ChangeMode(mode Mode) {\n\ts.mode = mode\n}", "func hookSetImageSize(e *evtx.GoEvtxMap) {\n\tvar path *evtx.GoEvtxPath\n\tvar modpath *evtx.GoEvtxPath\n\tswitch e.EventID() {\n\tcase 1:\n\t\tpath = &sysmonImage\n\t\tmodpath = &imSizePath\n\tdefault:\n\t\tpath = &sysmonImageLoaded\n\t\tmodpath = &imLoadedSizePath\n\t}\n\tif image, err := e.GetString(path); err == nil {\n\t\tif fsutil.IsFile(image) {\n\t\t\tif stat, err := os.Stat(image); err == nil {\n\t\t\t\te.Set(modpath, stat.Size())\n\t\t\t}\n\t\t}\n\t}\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 SetPixelFormat(hdc unsafe.Pointer, ipfd unsafe.Pointer, ppfd unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpSetPixelFormat, 3, uintptr(hdc), uintptr(ipfd), uintptr(ppfd))\n\treturn (unsafe.Pointer)(ret)\n}", "func SetStorage(storage storage) {\n\tcurrentStorage = storage\n}", "func (m *DeviceHealthAttestationState) SetVirtualSecureMode(value *string)() {\n err := m.GetBackingStore().Set(\"virtualSecureMode\", value)\n if err != nil {\n panic(err)\n }\n}", "func (m *BitPrecMat) Set(x, y int, to uint32) {\n\tbitOfs := (x + y*m.w) * m.bits\n\tdataI, maskI := bitOfs/32, bitOfs%32\n\tto64 := uint64(to) << (64 - uint64(m.bits) - uint64(maskI))\n\tmask64 := bitMasks[m.bits][maskI]\n\toldData64 := uint64(m.data[dataI])<<32 | uint64(m.data[dataI+1])\n\tnewData64 := (oldData64 & ^mask64) | to64\n\tm.data[dataI] = uint32(newData64 & 0xFFFFFFFF00000000 >> 32)\n\tm.data[dataI+1] = uint32(newData64 & 0xFFFFFFFF)\n}", "func SetOpModes(flag int) optBucket {\n\treturn func(o *bucketOpts) {\n\t\to.isAppend = flag&os.O_APPEND != 0\n\t}\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 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 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 (m *Mutator) Set(ctx context.Context, config ispec.ImageConfig, meta Meta, annotations map[string]string, history *ispec.History) error {\n\tif err := m.cache(ctx); err != nil {\n\t\treturn errors.Wrap(err, \"getting cache failed\")\n\t}\n\n\t// Ensure the mediatype is correct.\n\tm.manifest.MediaType = ispec.MediaTypeImageManifest\n\n\t// Set annotations.\n\tm.manifest.Annotations = annotations\n\n\t// Set configuration.\n\tm.config.Config = config\n\n\t// Set metadata.\n\tm.config.Created = timePtr(meta.Created)\n\tm.config.Author = meta.Author\n\tm.config.Architecture = meta.Architecture\n\tm.config.OS = meta.OS\n\n\t// Append history.\n\tif history != nil {\n\t\thistory.EmptyLayer = true\n\t\tm.config.History = append(m.config.History, *history)\n\t}\n\treturn nil\n}", "func SetPixFormat(fd uintptr, pixFmt PixFormat) error {\n\tformat := v4l2Format{StreamType: BufTypeVideoCapture}\n\tformat.setPixFormat(pixFmt)\n\n\tif err := Send(fd, VidiocSetFormat, uintptr(unsafe.Pointer(&format))); err != nil {\n\t\tswitch {\n\t\tcase errors.Is(err, ErrorUnsupported):\n\t\t\treturn fmt.Errorf(\"pix format: unsupported operation: %w\", err)\n\t\tdefault:\n\t\t\treturn fmt.Errorf(\"pix format failed: %w\", err)\n\t\t}\n\t}\n\treturn nil\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpRenderbufferStorage, 4, uintptr(target), uintptr(internalformat), uintptr(width), uintptr(height), 0, 0)\n}", "func (bm Bitmap) Set(i Sym) {\n\tn, r := uint(i)/32, uint(i)%32\n\tbm[n] |= 1 << r\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 SetMode(mode Mode) error {\n\tmodeString := fmt.Sprintf(\"%d\", mode)\n\treturn writeSysfsValue(\"mode\", modeString)\n}", "func (m *AndroidCompliancePolicy) SetStorageRequireEncryption(value *bool)() {\n err := m.GetBackingStore().Set(\"storageRequireEncryption\", value)\n if err != nil {\n panic(err)\n }\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 (s *ImageSpec) SetFormat(format TypeDesc) {\n\tC.ImageSpec_set_format(s.ptr, (C.TypeDesc)(format))\n\truntime.KeepAlive(s)\n}", "func qr_decoder_set_image_size(p _QrDecoderHandle, width, height, depth, channel int) _QrDecoderHandle {\n\tv := C.qr_decoder_set_image_size(C.QrDecoderHandle(p),\n\t\tC.int(width), C.int(height), C.int(depth), C.int(channel),\n\t)\n\treturn _QrDecoderHandle(v)\n}", "func (me *TxsdFeBlendTypeMode) Set(s string) { (*xsdt.String)(me).Set(s) }", "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 assignImages() {\n\tvar iconsSize = 18\n\tSetPict(obj.ButtonExit, \"\")\n\tSetPict(obj.ButtonProceed, \"\")\n\tSetPict(obj.EditButtonClose, \"\")\n\tSetPict(obj.EditSpinAudioDelay, \"\")\n\tSetPict(obj.EditSpinAudioTrack, \"\")\n\tSetPict(obj.EditSpinCutSec, \"\")\n\tSetPict(obj.EditSpinCutSecDuration, \"\")\n\tSetPict(obj.EditSpinSplit, \"\")\n\tSetPict(obj.EditSpinTextTrack, \"\")\n\tSetPict(obj.EditWindow, \"\")\n\tSetPict(obj.InfosButtonClose, \"\")\n\tSetPict(obj.InfosButtonShowFilesList, \"\")\n\tSetPict(obj.MainToolButtonClear, \"\")\n\tSetPict(obj.MainToolButtonEdit, \"\")\n\tSetPict(obj.MainToolButtonInvertChecked, \"\")\n\tSetPict(obj.MainToolButtonUnckeckAll, \"\")\n\tSetPict(obj.MainWindow, movieIcon, iconsSize)\n\tSetPict(obj.WindowInfos, movieIcon, iconsSize)\n}", "func (m *AospDeviceOwnerDeviceConfiguration) SetStorageBlockExternalMedia(value *bool)() {\n err := m.GetBackingStore().Set(\"storageBlockExternalMedia\", value)\n if err != nil {\n panic(err)\n }\n}", "func (a *Agent) setStorages() error {\n\ta.MetadataStorages = &storage.MetadataStorages{}\n\n\ta.MetadataStorages.ResourcedMaster = storage.NewResourcedMasterMetadataStorage(a.GeneralConfig.ResourcedMaster.URL, a.GeneralConfig.ResourcedMaster.AccessToken)\n\n\ta.Db = storage.NewStorage()\n\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 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 hookSetImageSize(e *evtx.GoEvtxMap) {\n\tvar path *evtx.GoEvtxPath\n\tvar modpath *evtx.GoEvtxPath\n\tswitch e.EventID() {\n\tcase 1:\n\t\tpath = &pathSysmonImage\n\t\tmodpath = &pathImSize\n\tdefault:\n\t\tpath = &pathSysmonImageLoaded\n\t\tmodpath = &pathImLoadedSize\n\t}\n\tif image, err := e.GetString(path); err == nil {\n\t\tif fsutil.IsFile(image) {\n\t\t\tif stat, err := os.Stat(image); err == nil {\n\t\t\t\te.Set(modpath, toString(stat.Size()))\n\t\t\t}\n\t\t}\n\t}\n}", "func Sty(c *CPU) {\n\tc.Set(c.EffAddr, c.Y)\n}", "func (ctx *DefaultContext) setStorage(addr, key, value []byte) {\n\t// todo: removed account?\n\taccInfo := ctx.getOrSetAccountInfo(addr)\n\tif accInfo.account.HasSuicide() {\n\t\tlog.Errorf(\"Fatal error, set storage on a suicide account(%s), key: %s, value: %s\", string(addr), string(key), string(value))\n\t}\n\taccInfo.storage[string(key)] = &storageData{\n\t\tvalue: value,\n\t\tupdated: true,\n\t}\n}", "func SetBitsPerWord(bitsPerWord uint8) {\n\t_, _, errno := syscall.Syscall(syscall.SYS_IOCTL, spiFile.Fd(), spiIOCWrBitsPerWord, uintptr(unsafe.Pointer(&bitsPerWord)))\n\tif errno != 0 {\n\t\terr := syscall.Errno(errno)\n\t\tlog.Fatal(err)\n\t}\n\n\tdefaultSpiTransferData.bitsPerWord = bitsPerWord\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 (v *Video) AttrSet(attr int32, bit uint) {\n\tv.Attribute = v.Attribute&(^(1 << bit)) | (attr << bit)\n}", "func (obj *Device) SetCursorProperties(\n\txHotSpot uint,\n\tyHotSpot uint,\n\tcursorBitmap *Surface,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.SetCursorProperties,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(xHotSpot),\n\t\tuintptr(yHotSpot),\n\t\tuintptr(unsafe.Pointer(cursorBitmap)),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func SnapshotDatasetMode(value string) SnapshotDatasetAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"mode\"] = value\n\t}\n}", "func imgSetGain(camera int, gain int) int {\n\tlog.Printf(\"imgSetGain camera:%d gain:%d\", camera, gain)\n\tvar f = mod.NewProc(\"img_set_gain\")\n\tret, _, _ := f.Call(uintptr(camera), uintptr(gain))\n\treturn int(ret) // retval is cameraID\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 initMode() {\n\tmode = NormalModeFlag\n\tif os.Getenv(\"GS_RECORD_MODE\") != \"\" {\n\t\tmode |= RecordModeFlag\n\t}\n\tif os.Getenv(\"GS_REPLAY_MODE\") != \"\" {\n\t\tmode |= ReplayModeFlag\n\t}\n\tfor _, arg := range os.Args {\n\t\tif strings.HasPrefix(arg, \"-test.\") {\n\t\t\tmode |= TestModeFlag\n\t\t\tbreak\n\t\t}\n\t}\n}", "func (key Key) SetMode(mode C.DWORD) error {\n\tif C.CryptSetKeyParam(key.hKey, C.KP_MODE, C.LPBYTE(unsafe.Pointer(&mode)), 0) == 0 {\n\t\treturn getErr(\"Error setting mode for key\")\n\t}\n\treturn nil\n}", "func (b *builder) SetFormat(format *pic.ImageFormat, colorSpace *pic.ColorSpace) {\n\tswitch *format {\n\tcase pic.SVG:\n\t\tb.RendererProvider = chart.SVG\n\tdefault:\n\t\tb.RendererProvider = chart.PNG\n\t\t*format = pic.PNG\n\t}\n\t*colorSpace = pic.RGB\n}", "func SetFrontFace(mode Enum) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tC.glFrontFace(cmode)\n}", "func RenderbufferStorage(target, internalFormat Enum, width, height int) {\n\tgl.RenderbufferStorage(uint32(target), uint32(internalFormat), int32(width), int32(height))\n}", "func SetFirewallMode(v string) { firewallMode.Store(v) }", "func cls(context *Context) {\n for i := range(context.screen) {\n for j := range context.screen[i] {\n context.screen[i][j] = 0\n }\n }\n context.window.Clear()\n context.cpu.pc += 2\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 SetMode(flag int) (reset func()) {\n\tMustTestMode()\n\told := mode\n\treset = func() {\n\t\tmode = old\n\t}\n\tmode = flag\n\treturn\n}", "func TexStorage2D(target uint32, levels int32, internalformat uint32, width int32, height int32) {\n\tsyscall.Syscall6(gpTexStorage2D, 5, uintptr(target), uintptr(levels), uintptr(internalformat), uintptr(width), uintptr(height), 0)\n}", "func SetMemPolicy(mode int, nodemask Bitmask) error {\n\treturn syscall.ENOSYS\n}", "func FileModePerm(m os.FileMode,) os.FileMode" ]
[ "0.53576237", "0.5322374", "0.5274655", "0.5273496", "0.5212715", "0.5152814", "0.5145573", "0.5082095", "0.50106245", "0.49678805", "0.49541643", "0.49476367", "0.48985445", "0.489562", "0.48617205", "0.4840752", "0.48168546", "0.4816795", "0.48006248", "0.4795217", "0.47521248", "0.47408718", "0.47286093", "0.47200707", "0.47171262", "0.47099146", "0.47093767", "0.47086716", "0.4706808", "0.46981746", "0.46805647", "0.4677679", "0.46601278", "0.46594188", "0.46570176", "0.4645212", "0.4641921", "0.46406054", "0.4638538", "0.4638538", "0.46234825", "0.4619033", "0.46176946", "0.46129555", "0.4608414", "0.46053773", "0.45973828", "0.458918", "0.4584997", "0.4580571", "0.45803308", "0.45705128", "0.4569431", "0.45694143", "0.45690706", "0.45655444", "0.45625672", "0.4561684", "0.45530495", "0.455135", "0.45500204", "0.45435902", "0.4537393", "0.45266142", "0.45223317", "0.4504474", "0.4498309", "0.44973394", "0.44911584", "0.44814375", "0.4481133", "0.44712532", "0.44695565", "0.44557065", "0.44540718", "0.445247", "0.44403282", "0.44368088", "0.44368088", "0.44362083", "0.4430822", "0.4421531", "0.4413012", "0.44059873", "0.44038966", "0.44031632", "0.43986988", "0.43956834", "0.43945217", "0.4394229", "0.4386734", "0.4383048", "0.4382694", "0.4381903", "0.43813983", "0.4374785", "0.43729702", "0.43622515", "0.4349749", "0.4342236", "0.433836" ]
0.0
-1
specify the pixel zoom factors
func PixelZoom(xfactor float32, yfactor float32) { C.glowPixelZoom(gpPixelZoom, (C.GLfloat)(xfactor), (C.GLfloat)(yfactor)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PixelZoom(xfactor float32, yfactor float32) {\n C.glowPixelZoom(gpPixelZoom, (C.GLfloat)(xfactor), (C.GLfloat)(yfactor))\n}", "func PixelZoom(xfactor float32, yfactor float32) {\n\tsyscall.Syscall(gpPixelZoom, 2, uintptr(math.Float32bits(xfactor)), uintptr(math.Float32bits(yfactor)), 0)\n}", "func Scale(zoom float64) float64 {\n\treturn 256 * math.Pow(2, zoom)\n}", "func (r *ImageRef) Zoom(xFactor int, yFactor int) error {\n\tout, err := vipsZoom(r.image, xFactor, yFactor)\n\tif err != nil {\n\t\treturn err\n\t}\n\tr.setImage(out)\n\treturn nil\n}", "func (c *Camera) Zoom() float64 {\n\treturn c.zoom\n}", "func scale_pixel(x, y int) (float64, float64) {\n\tnewx := float64(x)/(float64(maxX)/3) - 2.0\n\tnewy := float64(y)/(float64(maxY)/2) - 0.0 \n\treturn newx, newy\n}", "func (s *Sprite) Zoom(length float64) DrawingBuilder {\n\tif s.op == nil {\n\t\ts.err = errors.New(\"add a &ebiten.DrawImageOptions{} to s.op\")\n\t\treturn s\n\t}\n\ts.scale += length\n\ts.Width += length\n\ts.Height += length\n\n\ts.op.GeoM.Scale(float64(s.scale), float64(s.scale))\n\treturn s\n}", "func Zoom(xPerc, yPerc float64, frames int, zoomRate float64) func(*image.RGBA, int) bool {\n\treturn func(buf *image.RGBA, frame int) bool {\n\t\tif frame > frames {\n\t\t\treturn false\n\t\t}\n\t\tz := mod.Zoom(xPerc, yPerc, 1+zoomRate*float64(frame))\n\t\tdraw.Draw(buf, buf.Bounds(), z(buf), zeroPoint, draw.Src)\n\t\treturn true\n\t}\n}", "func (c *Camera) SetZoom(z float64) {\n\tif z == 0.0 {\n\t\treturn\n\t}\n\tc.zoom = z\n\tc.zoomInv = 1 / z\n\tc.sTop = c.lookAtY + float64(c.screenH/2)*c.zoomInv\n\tc.sBottom = c.lookAtY - float64(c.screenH/2)*c.zoomInv\n\tc.sLeft = c.lookAtX - float64(c.screenW/2)*c.zoomInv\n\tc.sRight = c.lookAtX + float64(c.screenW/2)*c.zoomInv\n}", "func (p *point) scaleBy(factor int) {\n\tp.x *= factor\n\tp.y *= factor\n}", "func (p *Panorama) ResetZoom() {\n\tswitch p.viewMode {\n\tcase core.ViewFixed:\n\t\tp.resolution[p.viewMode] = defaultFixedResolution\n\tcase core.ViewCentered:\n\t\tp.resolution[p.viewMode] = defaultCenteredResolution\n\t}\n\tp.updateFrequencyRange()\n}", "func wmPageZoom(ctx context.Context, tconn *chrome.TestConn, a *arc.ARC, d *ui.Device) error {\n\tact, err := arc.NewActivity(a, wm.Pkg24, wm.ResizableLandscapeActivity)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer act.Close()\n\tif err := act.StartWithDefaultOptions(ctx, tconn); err != nil {\n\t\treturn err\n\t}\n\tdefer act.Stop(ctx, tconn)\n\n\tif err := wm.WaitUntilActivityIsReady(ctx, tconn, act, d); err != nil {\n\t\treturn err\n\t}\n\n\tzoom, err := settings.DefaultZoom(ctx, tconn)\n\tif err != nil {\n\t\treturn err\n\t}\n\ttesting.ContextLog(ctx, \"Default zoom is: \", zoom)\n\n\tboundsOld, err := act.WindowBounds(ctx)\n\tif err != nil {\n\t\treturn err\n\t}\n\ttesting.ContextLogf(ctx, \"Window bounds before changing page zoom: %+v\", boundsOld)\n\n\tbutton := d.Object(ui.PackageName(act.PackageName()),\n\t\tui.ClassName(\"android.widget.Button\"),\n\t\tui.ID(\"org.chromium.arc.testapp.windowmanager:id/button_show\"))\n\tif err := button.WaitForExists(ctx, 10*time.Second); err != nil {\n\t\treturn err\n\t}\n\tbuttonBoundsOld, err := button.GetBounds(ctx)\n\tif err != nil {\n\t\treturn err\n\t}\n\ttesting.ContextLogf(ctx, \"Button bounds before changing page zoom: %+v\", buttonBoundsOld)\n\n\t// Chrome has zoom factors that go from 0.25x to 5x. But Android only supports zoom factors\n\t// from 0.8x to 1.5x. Android clamps values that are outside the valid range. E.g: a 2.0 zoom factor\n\t// will be \"transformed\" to 1.5x in Android.\n\tconst zoomFactor = 1.5\n\ttesting.ContextLog(ctx, \"Setting page zoom to \", zoomFactor)\n\tif err := settings.SetDefaultZoom(ctx, tconn, zoomFactor); err != nil {\n\t\treturn err\n\t}\n\t// Be nice and restore default zoom on exit.\n\tdefer settings.SetDefaultZoom(ctx, tconn, zoom)\n\n\tif zoom, err := settings.DefaultZoom(ctx, tconn); err != nil {\n\t\treturn err\n\t} else if zoom != zoomFactor {\n\t\t// Checking that zoomFactor got applied correctly and was not converted to any another value.\n\t\treturn errors.Errorf(\"unexpected zoom value: got %f, want %f\", zoom, zoomFactor)\n\t}\n\n\t// After changing the zoom factor, the Android window size should remain the same.\n\t// But the content should be adjusted to the new zoom factor.\n\treturn testing.Poll(ctx, func(ctx context.Context) error {\n\t\tboundsNew, err := act.WindowBounds(ctx)\n\t\tif err != nil {\n\t\t\treturn testing.PollBreak(err)\n\t\t}\n\t\tif boundsNew != boundsOld {\n\t\t\treturn errors.Errorf(\"invalid window bounds: got %v, want %v\", boundsNew, boundsOld)\n\t\t}\n\n\t\tbuttonBoundsNew, err := button.GetBounds(ctx)\n\t\tif err != nil {\n\t\t\treturn testing.PollBreak(err)\n\t\t}\n\n\t\t// Widget size should be bigger by zoomFactor +/- some error margin to deal with rounding issues.\n\t\tconst errorMargin = zoomFactor * 0.1\n\t\twIncrease := float64(buttonBoundsNew.Width) / float64(buttonBoundsOld.Width)\n\t\thIncrease := float64(buttonBoundsNew.Height) / float64(buttonBoundsOld.Height)\n\n\t\tif math.Abs(wIncrease-zoomFactor) > errorMargin {\n\t\t\treturn errors.Errorf(\"invalid button width increase: got %v; want value in [%v, %v] range\",\n\t\t\t\twIncrease, zoomFactor-errorMargin, zoomFactor+errorMargin)\n\t\t}\n\n\t\tif math.Abs(hIncrease-zoomFactor) > errorMargin {\n\t\t\treturn errors.Errorf(\"invalid button height increase: got %v; want value in [%v, %v] range\",\n\t\t\t\thIncrease, zoomFactor-errorMargin, zoomFactor+errorMargin)\n\t\t}\n\t\treturn nil\n\t}, &testing.PollOptions{Timeout: 10 * time.Second})\n}", "func Scale(w, h int) int {\n\ta := w / WIDTH\n\tb := h / HEIGHT\n\tif a < b {\n\t\treturn a\n\t}\n\treturn b\n}", "func (tr *trooper) setScale(scale float64) { tr.part.SetScale(scale, scale, scale) }", "func (this *osmTileIdStruct) Zoom() uint8 {\n\tzoom := this.zoom\n\treturn zoom\n}", "func ZoomIn(image *dali.Canvas, iterations, zoomLevel *dali.InputElement, vp *ViewPort,\n\tcontrol *sync.Mutex, progress *dali.ProgressElement) {\n\tcontrol.Lock()\n\tdefer control.Unlock()\n\n\tvp.ZoomLevel *= 0.9\n\n\tzoomLevel.Set(fmt.Sprintf(\"%.14f\", vp.ZoomLevel))\n\tiv := iterations.Value()\n\ti, _ := strconv.Atoi((iv))\n\tDrawMandelbrot(\n\t\tvp,\n\t\ti,\n\t\timage,\n\t\tprogress)\n}", "func (contour DrawContour) resizeByFactor(factor int) {\n\tcontour.factor = factor\n}", "func (dw *DrawingWand) Scale(x, y float64) {\n\tC.MagickDrawScale(dw.dw, C.double(x), C.double(y))\n}", "func (contour DrawContour) ResizeByFactor(factor int) {\n\tcontour.Factor = factor\n}", "func (c *Camera) ZoomIn() {\n\tc.zoom++\n\tc.Update()\n}", "func tilesForZoom(o *Overlay, zoom int64) (tiles []*Tile) {\n\tl := scaleCoord(min(o.TopLeft[0], o.TopRight[0], o.BottomRight[0], o.BottomLeft()[0]), zoom)\n\tr := scaleCoord(max(o.TopLeft[0], o.TopRight[0], o.BottomRight[0], o.BottomLeft()[0]), zoom)\n\tt := scaleCoord(min(o.TopLeft[1], o.TopRight[1], o.BottomRight[1], o.BottomLeft()[1]), zoom)\n\tb := scaleCoord(max(o.TopLeft[1], o.TopRight[1], o.BottomRight[1], o.BottomLeft()[1]), zoom)\n\n\tif (r-l+1)*(b-t+1) > tilesPerZoom {\n\t\treturn\n\t}\n\n\tfor x := l; x <= r; x++ {\n\t\tfor y := t; y <= b; y++ {\n\t\t\ttiles = append(tiles, &Tile{X: x, Y: y, Zoom: zoom})\n\t\t}\n\t}\n\treturn\n}", "func (o *LineSearch) zoom(fini, gini, alo, ahi, flo, fhi float64) (a, f float64) {\n\n\t// auxiliary\n\tglo := o.G(alo)\n\tvar g, aprev, fprev float64\n\tvar interpOk bool\n\tvar da, achk, bchk, dchk float64\n\tvar err error\n\n\t// iterations\n\tfor o.NumIterZoom = 0; o.NumIterZoom < o.MaxItZoom; o.NumIterZoom++ {\n\n\t\t// variables for checking range\n\t\tda = ahi - alo\n\t\tachk, bchk = alo, ahi\n\t\tif da < 0 {\n\t\t\tachk, bchk = ahi, alo\n\t\t}\n\n\t\t// cubic interpolation because we have previous values and the gap=ahi-alo is not small\n\t\tinterpOk = false\n\t\tif o.NumIterZoom > 0 {\n\t\t\ta = cubicmin(alo, flo, glo, ahi, fhi, aprev, fprev)\n\t\t\tdchk = o.CoefCubic * da\n\t\t\tif a >= achk+dchk && a <= bchk-dchk { // accept only if a didn't change much\n\t\t\t\tinterpOk = true\n\t\t\t}\n\t\t}\n\n\t\t// quadratic interpolation and the gap=ahi-alo is not small\n\t\tif !interpOk {\n\t\t\terr = o.interp2.Fit2pointsD(alo, flo, ahi, fhi, alo, glo)\n\t\t\tif err == nil {\n\t\t\t\ta, _ = o.interp2.Optimum()\n\t\t\t\tdchk = o.CoefQuad * da\n\t\t\t\tif a >= achk+dchk && a <= bchk-dchk { // accept only if a didn't change much\n\t\t\t\t\tinterpOk = true\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// bi-section because interpolation failed or the gap is too small\n\t\tif !interpOk {\n\t\t\ta = alo + 0.5*(ahi-alo)\n\t\t}\n\n\t\t// evaluate F\n\t\tf = o.F(a)\n\n\t\t// update\n\t\tif f > fini+o.Coef1*a*gini || f >= flo {\n\t\t\taprev = ahi\n\t\t\tfprev = fhi\n\t\t\tahi = a\n\t\t\tfhi = f\n\t\t} else {\n\n\t\t\t// evaluate G\n\t\t\tg = o.G(a)\n\n\t\t\t// exit condition\n\t\t\tif math.Abs(g) <= -o.Coef2*gini {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\t// swap hi;lo\n\t\t\tif g*(ahi-alo) >= 0 {\n\t\t\t\taprev = ahi\n\t\t\t\tfprev = fhi\n\t\t\t\tahi = alo\n\t\t\t\tfhi = flo\n\t\t\t} else {\n\t\t\t\taprev = alo\n\t\t\t\tfprev = flo\n\t\t\t}\n\n\t\t\t// next 'lo' values\n\t\t\talo = a\n\t\t\tflo = f\n\t\t\tglo = g\n\t\t}\n\t}\n\n\t// failure\n\tchk.Panic(\"zoom did not converge after %d iterations\\n\", o.NumIterZoom)\n\treturn\n}", "func (v *Vertex) scale(factor float64) {\n\tv.X = v.X * factor\n\tv.Y = v.Y * factor\n}", "func scale(val float64, min float64, max float64, outMin float64, outMax float64) float64 {\r\n\tdenom := 1.0\r\n\ty := 0.0\r\n\tif outMin - min != 0 {\r\n\t\tdenom = outMin - min\r\n\t\ty = (outMax - max) / denom * val - min + outMin\r\n\t} else {\r\n\t\ty = outMax / max * val - min + outMin\r\n\t}\r\n\treturn y\r\n}", "func (t *Theme) Pixels(v unit.Value) fixed.Int26_6 {\n\tc := t.Convert(v, unit.Px)\n\treturn fixed.Int26_6(c.F * 64)\n}", "func (wv *Spectrum) Scale(s float32) {\n\twv.C[0] *= s\n\twv.C[1] *= s\n\twv.C[2] *= s\n\twv.C[3] *= s\n}", "func Scale(p point, factor int) point {\n\treturn point{p.x * factor, p.y * factor, p.z * factor}\n}", "func ZoomOut(image *dali.Canvas, iterations, zoomLevel *dali.InputElement, vp *ViewPort,\n\tcontrol *sync.Mutex, progress *dali.ProgressElement) {\n\tcontrol.Lock()\n\tdefer control.Unlock()\n\n\tvp.ZoomLevel *= (10.0 / 9.0)\n\tzoomLevel.Set(fmt.Sprintf(\"%.14f\", vp.ZoomLevel))\n\tiv := iterations.Value()\n\ti, _ := strconv.Atoi((iv))\n\tDrawMandelbrot(\n\t\tvp,\n\t\ti,\n\t\timage,\n\t\tprogress)\n}", "func Pixelate(imageRef *ImageRef, factor float64) (err error) {\n\tif factor < 1 {\n\t\treturn errors.New(\"factor must be greater then 1\")\n\t}\n\n\twidth := imageRef.Width()\n\theight := imageRef.Height()\n\n\tif err = imageRef.Resize(1/factor, KernelAuto); err != nil {\n\t\treturn\n\t}\n\n\thScale := float64(width) / float64(imageRef.Width())\n\tvScale := float64(height) / float64(imageRef.Height())\n\tif err = imageRef.ResizeWithVScale(hScale, vScale, KernelNearest); err != nil {\n\t\treturn\n\t}\n\n\treturn\n}", "func (fx *fx) Render(t float64) image.Image {\n\tconst (\n\t\tDecimalPointLog = 16\n\t\tDecimalMul = 1 << DecimalPointLog\n\t)\n\t// tt is our reverse zoom as 16.16 fixed point\n\ttt := int(t * t * 12 * DecimalMul)\n\n\txMask := (1 << fx.logW) - 1\n\tyMask := (1 << fx.logH) - 1\n\n\t// Center of zoom (screen space)\n\tcenterX, centerY := renderWidth/2, renderHeight/2\n\t// Store the reverse transformation for the center of screen.\n\tx0 := -tt * centerX\n\ty0 := -tt * centerY\n\n\t// Center on texture (texture space)\n\ttexCenterX, texCenterY := 173, 106\n\tx0 += texCenterX * DecimalMul\n\ty0 += texCenterY * DecimalMul\n\n\tfor y, line := range fx.lines {\n\t\tsrcY := ((y0 + y*tt) >> DecimalPointLog) & yMask\n\t\t// Pre-shift, so srcY is offset for x=0 at our line.\n\t\tsrcY <<= fx.logW\n\t\tfor x := range line {\n\t\t\tsrcX := ((x0 + x*tt) >> DecimalPointLog) & xMask\n\t\t\tline[x] = fx.img.Pix[srcX+srcY]\n\t\t}\n\t}\n\treturn fx.draw\n}", "func (c *Camera) ZoomOut() {\n\tc.zoom--\n\tc.Update()\n}", "func (w *windowImpl) Scale(dr image.Rectangle, src screen.Texture, sr image.Rectangle, op draw.Op, opts *screen.DrawOptions) {\n\tpanic(\"not implemented\") // TODO: Implement\n}", "func (xs *Sheet) SetZoom(zoom int) {\n\txs.xb.lib.NewProc(\"xlSheetSetZoomW\").\n\t\tCall(xs.self, I(zoom))\n}", "func (tt *telloTrackT) deriveScale() (scale float32) {\n\tscale = 1.0 // minimum scale value\n\tif tt.maxX > scale {\n\t\tscale = tt.maxX\n\t}\n\tif -tt.minX > scale {\n\t\tscale = -tt.minX\n\t}\n\tif tt.maxY > scale {\n\t\tscale = tt.maxY\n\t}\n\tif -tt.minY > scale {\n\t\tscale = -tt.minY\n\t}\n\tscale = float32(math.Ceil(float64(scale)))\n\treturn scale\n}", "func (c *Camera) Init() {\n\tc.pixelPosition = pixel.ZV\n\tc.zoom = 1.0\n\tc.zoomSpeed = 1.2\n\tc.minZoom = 0.4\n\tc.maxZoom = 5\n}", "func (xs *Sheet) SetPrintZoom(zoom int) {\n\txs.xb.lib.NewProc(\"xlSheetSetPrintZoomW\").\n\t\tCall(xs.self, I(zoom))\n}", "func ViewBoundScale(value float64) *SimpleElement { return newSEFloat(\"viewBoundScale\", value) }", "func (r *RAM) SetAmplScaleFactor(x uint16) {\n\tbinary.BigEndian.PutUint16(r[0:2], x<<2)\n}", "func (self *TileSprite) SetTileScaleA(member *Point) {\n self.Object.Set(\"tileScale\", member)\n}", "func (c Charset) Scale(factor int) {\n\tif factor <= 1 {\n\t\t// A factor of zero results in zero-sized glyphs and\n\t\t// is therefore not valid. A factor of 1 does not change\n\t\t// the glyphs, so we can ignore it.\n\t\treturn\n\t}\n\n\t// Multiply each glyph field by the given factor\n\t// to scale them up to the new size.\n\tfor i := range c {\n\t\tc[i].X *= factor\n\t\tc[i].Y *= factor\n\t\tc[i].Width *= factor\n\t\tc[i].Height *= factor\n\t\tc[i].Advance *= factor\n\t}\n}", "func (canvas *Canvas) Scale(x, y float32) {\n\twriteCommand(canvas.contents, \"cm\", x, 0, 0, y, 0, 0)\n}", "func Scale(value float64) *SimpleElement { return newSEFloat(\"scale\", value) }", "func (v *Vertex) Scale(f float64) {\n v.X = v.X * f\n v.Y = v.Y * f\n}", "func (v Vertex) Scale(f int) {\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (v *Vertex) Scale(f float64) {\n v.X = v.X * f\n v.Y = v.Y * f\n}", "func (ki *KernelInfo) Scale(scale float64, normalizeType KernelNormalizeType) {\n\tC.ScaleKernelInfo(ki.info, C.double(scale), C.GeometryFlags(normalizeType))\n\truntime.KeepAlive(ki)\n}", "func TestRescale(t *testing.T) {\n\tname := filepath.Join(datadir, \"f1.jpg\")\n\tt.Logf(\"rescaling %s with half-width and half-height\", name)\n\tf, err := os.Open(name)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tdefer f.Close()\n\trescaledIm, _, err := Decode(f, &DecodeOpts{ScaleWidth: 0.5, ScaleHeight: 0.5})\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\tsmallIm := smallStraightFImage(t)\n\n\tgotB, wantB := rescaledIm.Bounds(), smallIm.Bounds()\n\tif !gotB.Eq(wantB) {\n\t\tt.Errorf(\"(scale) %v bounds not equal, got %v want %v\", name, gotB, wantB)\n\t}\n\tif !equals(rescaledIm, smallIm) {\n\t\tt.Errorf(\"(scale) %v pixels not equal\", name)\n\t}\n\n\t_, err = f.Seek(0, os.SEEK_SET)\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\n\trescaledIm, _, err = Decode(f, &DecodeOpts{MaxWidth: 2000, MaxHeight: 40})\n\tif err != nil {\n\t\tt.Fatal(err)\n\t}\n\tgotB = rescaledIm.Bounds()\n\tif !gotB.Eq(wantB) {\n\t\tt.Errorf(\"(max) %v bounds not equal, got %v want %v\", name, gotB, wantB)\n\t}\n\tif !equals(rescaledIm, smallIm) {\n\t\tt.Errorf(\"(max) %v pixels not equal\", name)\n\t}\n}", "func getPixVal(c color.Color) float64 {\n\tr, _, _, _ := c.RGBA()\n\treturn float64(r >> 8)\n}", "func scaleDestinationPixels(destinationBounds image.Rectangle, destinationCoordinates []complex128, viewPortMin complex128, viewPortMax complex128) []complex128 {\n\tscaledCoordinates := []complex128{}\n\tfor _, destinationCoordinate := range destinationCoordinates {\n\t\tdestinationScaledX := mathutility.ScaleValueBetweenTwoRanges(\n\t\t\treal(destinationCoordinate),\n\t\t\tfloat64(destinationBounds.Min.X),\n\t\t\tfloat64(destinationBounds.Max.X),\n\t\t\treal(viewPortMin),\n\t\t\treal(viewPortMax),\n\t\t)\n\t\tdestinationScaledY := mathutility.ScaleValueBetweenTwoRanges(\n\t\t\timag(destinationCoordinate),\n\t\t\tfloat64(destinationBounds.Min.Y),\n\t\t\tfloat64(destinationBounds.Max.Y),\n\t\t\timag(viewPortMin),\n\t\t\timag(viewPortMax),\n\t\t)\n\t\tscaledCoordinates = append(scaledCoordinates, complex(destinationScaledX, destinationScaledY))\n\t}\n\treturn scaledCoordinates\n}", "func (frac Fractal) X(r float64) int {\n\treturn int(frac.xZoom*(r+real(frac.Offset)) + float64(frac.Width)/2.0)\n}", "func (p *Point) Scale(v float64) {\n\tp.x *= v\n\tp.y *= v\n}", "func Scale(v *Vertex, f float64) {\n\tv.x *= f\n\tv.y *= f\n}", "func Scale(v *Vertex, f float64) {\n\tv.X *= f\n\tv.Y *= f\n}", "func (s *Server) handleZoomLogin() http.HandlerFunc {\n\treturn func(w http.ResponseWriter, r *http.Request) {\n\t\tctx, logger := GetLogger(s.getCtx(r))\n\n\t\t//probe for a provider\n\t\tctx, provider, ok := s.loadProvider(w, r.WithContext(ctx))\n\t\tif !ok {\n\t\t\ts.SetCookieErr(w, ErrOAuthZoom)\n\t\t\thttp.Redirect(w, r.WithContext(ctx), provider.GetURLAddOns(), http.StatusSeeOther)\n\t\t\treturn\n\t\t}\n\n\t\t//read the host\n\t\thost, err := s.GetCookieHost(r)\n\t\tif err != nil {\n\t\t\tlogger.Warnw(\"get cookie host\", \"error\", err)\n\t\t\thttp.Redirect(w, r.WithContext(ctx), URIErr, http.StatusSeeOther)\n\t\t\treturn\n\t\t}\n\n\t\t//generate a token used to validate the callback\n\t\ttimeZone := GetCtxTimeZone(ctx)\n\t\tisSignUp := GetCtxIsSignUp(ctx)\n\t\ttoken, err := GenerateOAuthToken(isSignUp, timeZone, \"\", host)\n\t\tif err != nil {\n\t\t\tlogger.Errorw(\"zoom token\", \"error\", err)\n\t\t\thttp.Redirect(w, r.WithContext(ctx), provider.GetURLAddOns(), http.StatusSeeOther)\n\t\t\treturn\n\t\t}\n\n\t\t//create the url for the zoom oauth callback\n\t\turl, err := createZoomURL(URICallback)\n\t\tif err != nil {\n\t\t\tlogger.Errorw(\"zoom callback url\", \"error\", err)\n\t\t\thttp.Redirect(w, r.WithContext(ctx), provider.GetURLAddOns(), http.StatusSeeOther)\n\t\t\treturn\n\t\t}\n\n\t\t//create url for the zoom oauth\n\t\turl, err = CreateOAuthURLZoom(ctx, token, url)\n\t\tif err != nil {\n\t\t\tlogger.Errorw(\"zoom oauth url\", \"error\", err)\n\t\t\thttp.Redirect(w, r.WithContext(ctx), provider.GetURLAddOns(), http.StatusSeeOther)\n\t\t\treturn\n\t\t}\n\t\thttp.Redirect(w, r.WithContext(ctx), url, http.StatusSeeOther)\n\t}\n}", "func intScale(val int, val_range int, out_range int) int {\n\tnum := val*(out_range-1)*2 + (val_range - 1)\n\tdem := (val_range - 1) * 2\n\treturn num / dem\n}", "func (s *Surface) Scale(x, y float64) {\n\ts.Ctx.Call(\"scale\", x, y)\n}", "func (s *sizes) setSizes(width int, height int) {\n\ts.width = width\n\ts.height = height\n\ts.curStreamsPerStreamDisplay = 1 + height/10\n}", "func getBitsForScaling() int64 {\n\tfs := cpuid.HostFeatureSet()\n\tif fs.Intel() {\n\t\treturn 48 // See vmx.c (kvm sources).\n\t} else if fs.AMD() {\n\t\treturn 32 // See svm.c (svm sources).\n\t} else {\n\t\treturn 63 // Unknown: theoretical maximum.\n\t}\n}", "func (ct *Ciphertext) ScalingFactor() float64 {\n\treturn ct.Scale\n}", "func (v *vertex) Scale(f float64) {\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (c *Circle) Scale(f float64) {\n\tc.radius *= f\n}", "func (t *Theme) pixelsPer(u unit.Unit) float64 {\n\tswitch u {\n\t// case unit.Px:\n\t// \treturn 1\n\t// case unit.Dp:\n\t// \treturn t.GetDPI() / unit.DensityIndependentPixelsPerInch\n\t// case unit.Pt:\n\t// \treturn t.GetDPI() / unit.PointsPerInch\n\t// case unit.Mm:\n\t// \treturn t.GetDPI() / unit.MillimetresPerInch\n\tcase unit.In:\n\t\treturn t.getDPI()\n\t}\n\t// f := t.AcquireFontFace(FontFaceOptions{})\n\t// defer t.ReleaseFontFace(FontFaceOptions{}, f)\n\t// The 64 is because Height is in 26.6 fixed-point units.\n\t// h := float64(f.Metrics().Height) / 64\n\t// switch u {\n\t// case unit.Em:\n\t// \treturn h\n\t// case unit.Ex:\n\t// \treturn h / 2\n\t// case unit.Ch:\n\t// \tif advance, ok := f.GlyphAdvance('0'); ok {\n\t// \t\treturn float64(advance) / 64\n\t// \t}\n\t// \treturn h / 2\n\t// }\n\treturn 1\n}", "func (c *canvasRenderer) Scale(amount sprec.Vec2) {\n\tc.currentLayer.Transform = sprec.Mat4Prod(\n\t\tc.currentLayer.Transform,\n\t\tsprec.ScaleMat4(amount.X, amount.Y, 1.0),\n\t)\n}", "func (c *RGB) Scale(f float32) {\n\tfor k := range c {\n\t\tc[k] *= f\n\t}\n}", "func (c2d *C2DMatrix) Scale(xScale, yScale float64) {\n\tvar mat Matrix\n\n\tmat.m11 = xScale\n\tmat.m12 = 0\n\tmat.m13 = 0\n\n\tmat.m21 = 0\n\tmat.m22 = yScale\n\tmat.m23 = 0\n\n\tmat.m31 = 0\n\tmat.m32 = 0\n\tmat.m33 = 1\n\n\t//and multiply\n\tc2d.MatrixMultiply(mat)\n}", "func CoordsZoomToBounds(centre Coord, zoom float64, defaultBound float64) *Bounds {\n\treturn &Bounds{\n\t\tXmax: centre.X + (zoom * defaultBound),\n\t\tYmax: centre.Y + (zoom * defaultBound),\n\t\tXmin: centre.X - (zoom * defaultBound),\n\t\tYmin: centre.Y - (zoom * defaultBound),\n\t}\n}", "func (t *Tree) Scale(s float32) {\n\tif t.Leaf != nil {\n\t\tfor i, x := range t.Leaf.OutputDelta {\n\t\t\tt.Leaf.OutputDelta[i] = x * s\n\t\t}\n\t} else {\n\t\tt.Branch.FalseBranch.Scale(s)\n\t\tt.Branch.TrueBranch.Scale(s)\n\t}\n}", "func (v *V_elem) Scale(ofs, scale *[3]float32) *[3]int {\n\treturn &[3]int{\n\t\tint((v.x[0] + ofs[0]) * scale[0]),\n\t\tint((v.x[1] + ofs[1]) * scale[1]),\n\t\tint((v.x[2] + ofs[2]) * scale[2]),\n\t}\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 Scale(f float64, d Number) Number {\n\treturn Number{Real: f * d.Real, E1mag: f * d.E1mag, E2mag: f * d.E2mag, E1E2mag: f * d.E1E2mag}\n}", "func (me TxsdViewTypeZoomAndPan) IsZoom() bool { return me.String() == \"zoom\" }", "func scale(bytes int64) (scaled int64, scale string) {\n\tif bytes < 0 {\n\t\tscaled, scale = uscale(uint64(bytes * -1))\n\t\tscaled *= -1\n\t} else {\n\t\tscaled, scale = uscale(uint64(bytes))\n\t}\n\treturn\n}", "func modifyNumericMetric(data interface{}, scale float64, shift float64) interface{} {\n\t//check if scale and shift parameters are set\n\tif scale == 1.0 && shift == 0.0 {\n\t\treturn data\n\t}\n\tvar modifiedData interface{}\n\t//use shift and scale and convert data to float64\n\tswitch data.(type) {\n\tcase uint32:\n\t\tmodifiedData = float64(data.(uint32))*scale + shift\n\tcase uint64:\n\t\tmodifiedData = float64(data.(uint64))*scale + shift\n\tcase int:\n\t\tmodifiedData = float64(data.(int))*scale + shift\n\tcase int32:\n\t\tmodifiedData = float64(data.(int32))*scale + shift\n\tcase int64:\n\t\tmodifiedData = float64(data.(int64))*scale + shift\n\tdefault:\n\t\tmodifiedData = data\n\t}\n\treturn modifiedData\n}", "func (mw *MagickWand) Scale(cols, rows uint) error {\n\treturn mw.ScaleImage(cols, rows)\n}", "func (r *RAM) AmplScaleFactor() uint16 {\n\treturn binary.BigEndian.Uint16(r[0:2]) >> 2\n}", "func (s SamplesC64) Scale(r float32) {\n\tsimd.ScaleComplex(r, s)\n}", "func (ref *UIElement) ZoomButton() *UIElement {\n\tret, _ := ref.UIElementAttr(ZoomButtonAttribute)\n\treturn ret\n}", "func (m *PrinterDefaults) SetDpi(value *int32)() {\n err := m.GetBackingStore().Set(\"dpi\", value)\n if err != nil {\n panic(err)\n }\n}", "func (d *Data) setResolution(uuid dvid.UUID, jsonBytes []byte) error {\n\tconfig := make(dvid.NdFloat32, 3)\n\tif err := json.Unmarshal(jsonBytes, &config); err != nil {\n\t\treturn err\n\t}\n\td.Properties.VoxelSize = config\n\treturn datastore.SaveDataByUUID(uuid, d)\n}", "func (v *Vertex) Scale(f float64) {\r\n\tv.X = v.X * f\r\n\tv.Y = v.Y * f\r\n}", "func (t *Theme) getDPI() float64 {\n\tif t != nil && t.DPI != 0 {\n\t\treturn t.DPI\n\t}\n\treturn defaultDPI\n}", "func (g *GameObject) SetScale(scale float64) {\r\n\tg.Hitbox.maxX *= scale / g.Scale\r\n\tg.Hitbox.maxY *= scale / g.Scale\r\n\tg.Scale = scale\r\n}", "func (m *Matrix3) Scale(s float64) {\n\tfor i, x := range m {\n\t\tm[i] = x * s\n\t}\n}", "func (this *Transformable) Scale(factor Vector2f) {\n\tC.sfTransformable_scale(this.cptr, factor.toC())\n}", "func Adjust(img image.Image, value float64) image.Image {\n\treturn utils.MapColor(img, AdjustC(value))\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X *= f\n\tv.Y *= f\n}", "func TileNum(zoom int, lat, lon float64) (x, y float64) {\n\tlatRad := lat * DegToRad\n\tn := zooms[zoom]\n\tx = (lon + 180.0) / 360.0 * n\n\ty = (1.0 - math.Log(math.Tan(latRad)+(1/math.Cos(latRad)))/math.Pi) / 2.0 * n\n\treturn\n}", "func (v *mandelbrotViewer) Update() error {\n\t// Click to zoom and pan.\n\tif ebiten.IsMouseButtonPressed(ebiten.MouseButtonLeft) {\n\t\tinterpolation := 1.0 / zoomFactor\n\t\tmouseRe, mouseIm := v.mouseLocation()\n\t\tv.rMin = interpolate(mouseRe, v.rMin, interpolation)\n\t\tv.iMin = interpolate(mouseIm, v.iMin, interpolation)\n\t\tv.rMax = interpolate(mouseRe, v.rMax, interpolation)\n\t\tv.iMax = interpolate(mouseIm, v.iMax, interpolation)\n\t\tv.zoomIn()\n\t}\n\n\tif ebiten.IsKeyPressed(ebiten.KeyLeft) {\n\t\tv.pan(left)\n\t}\n\n\tif ebiten.IsKeyPressed(ebiten.KeyRight) {\n\t\tv.pan(right)\n\t}\n\n\tif ebiten.IsKeyPressed(ebiten.KeyUp) {\n\t\tv.pan(up)\n\t}\n\n\tif ebiten.IsKeyPressed(ebiten.KeyDown) {\n\t\tv.pan(down)\n\t}\n\n\t// Increase/Decrease the max iterations.\n\tif ebiten.IsKeyPressed(ebiten.KeyEqual) {\n\t\tv.increaseMaxIterations()\n\t}\n\tif ebiten.IsKeyPressed(ebiten.KeyMinus) {\n\t\tv.decreaseMaxIterations()\n\t}\n\n\t// Zoom in and out based on the scroll wheel, preserving location on the\n\t// complex plane.\n\t_, dY := ebiten.Wheel()\n\tif dY < 0.0 {\n\t\tv.zoomOut()\n\t}\n\tif dY > 0.0 {\n\t\tv.zoomIn()\n\t}\n\n\t// Zoom out based on the scroll wheel, preserving location on the complex\n\t// plane.\n\tif ebiten.IsMouseButtonPressed(ebiten.MouseButtonRight) {\n\t\tv.zoomOut()\n\t}\n\n\t// Reset back to factory defaults.\n\tif inpututil.IsKeyJustPressed(ebiten.KeySpace) {\n\t\tv.reset()\n\t}\n\n\t// Exit the proram if 'q' is pressed.\n\tif inpututil.IsKeyJustPressed(ebiten.KeyQ) {\n\t\tos.Exit(0)\n\t}\n\n\tif inpututil.IsKeyJustPressed(ebiten.KeyEnter) {\n\t\tebiten.SetFullscreen(!ebiten.IsFullscreen())\n\t}\n\n\tif inpututil.IsKeyJustPressed(ebiten.KeyD) {\n\t\tv.displayDebug = !v.displayDebug\n\t}\n\n\t// draw to screen buffer.\n\tif len(v.screenBuffer) == 0 || v.redraw {\n\t\tv.screenBuffer = v.render()\n\t\tv.redraw = false\n\t}\n\treturn nil\n}", "func (f *Font) emScaleX(v int16) Position { return Position(v) * f.XScale / f.faceUpem }", "func (v *Vertex) Scale(f float64) {\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * 1\n\tv.Y = v.Y * 1\n}", "func zoomInOutTakePhoto(ctx context.Context, app *cca.App) error {\n\tif err := app.Click(ctx, cca.OpenPTZPanelButton); err != nil {\n\t\treturn errors.Wrap(err, \"failed to open ptz panel\")\n\t}\n\n\tconst zoomFactor int = 3\n\tfor i := 0; i < zoomFactor; i++ {\n\t\tif err := app.ClickPTZButton(ctx, cca.ZoomInButton); err != nil {\n\t\t\treturn errors.Wrap(err, \"failed to click zoom in button\")\n\t\t}\n\t\t// Take photo after increasing zoom.\n\t\tif _, err := app.TakeSinglePhoto(ctx, cca.TimerOff); err != nil {\n\t\t\treturn errors.Wrap(err, \"failed to take photo\")\n\t\t}\n\t}\n\n\tfor i := 0; i < zoomFactor; i++ {\n\t\tif err := app.ClickPTZButton(ctx, cca.ZoomOutButton); err != nil {\n\t\t\treturn errors.Wrap(err, \"failed to click zoom out button\")\n\t\t}\n\t\t// Take photo after decreasing zoom.\n\t\tif _, err := app.TakeSinglePhoto(ctx, cca.TimerOff); err != nil {\n\t\t\treturn errors.Wrap(err, \"failed to take photo\")\n\t\t}\n\t}\n\n\treturn nil\n}", "func (xf *Transform) SetScale(scale float32) {\n\txf.Scale = mgl32.Vec2{scale, scale}\n}", "func imgSetGain(camera int, gain int) int {\n\tlog.Printf(\"imgSetGain camera:%d gain:%d\", camera, gain)\n\tvar f = mod.NewProc(\"img_set_gain\")\n\tret, _, _ := f.Call(uintptr(camera), uintptr(gain))\n\treturn int(ret) // retval is cameraID\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}" ]
[ "0.7620284", "0.7229312", "0.6994161", "0.632281", "0.6245468", "0.6168897", "0.59914464", "0.58316785", "0.5804397", "0.55369234", "0.5508602", "0.5482765", "0.5473459", "0.54622185", "0.5448507", "0.54473126", "0.53862494", "0.5375114", "0.5372329", "0.5305802", "0.5275662", "0.52537394", "0.5237171", "0.52170265", "0.51946795", "0.51909655", "0.5129775", "0.5112596", "0.5099556", "0.5084683", "0.5049228", "0.5038773", "0.50355434", "0.5021203", "0.5020751", "0.49823704", "0.49676633", "0.49666393", "0.49602568", "0.49528146", "0.4952306", "0.48769754", "0.48691866", "0.48687494", "0.48451018", "0.48439854", "0.48303747", "0.48032838", "0.47974658", "0.47910443", "0.47892696", "0.47872052", "0.476566", "0.47584566", "0.47169143", "0.47094718", "0.47048253", "0.4701259", "0.46999082", "0.469066", "0.46844092", "0.46783793", "0.46680665", "0.4666643", "0.46657446", "0.465637", "0.46468377", "0.46424538", "0.46409494", "0.46360606", "0.46332264", "0.46306482", "0.4622537", "0.46205464", "0.46106142", "0.4607588", "0.46005544", "0.45966354", "0.4588925", "0.4586603", "0.45808342", "0.4579197", "0.45730764", "0.4571598", "0.45587936", "0.4557184", "0.45537528", "0.45480728", "0.45456117", "0.45407963", "0.4534227", "0.45307487", "0.4523117", "0.4509595", "0.45087385", "0.45087385", "0.45087385", "0.45087385", "0.45087385", "0.45087385" ]
0.7009906
2
specify the diameter of rasterized points
func PointSize(size float32) { C.glowPointSize(gpPointSize, (C.GLfloat)(size)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (c circle) methodDiameter() int {\n\treturn c.radius * 2\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 (w *LDRWrapper) Size() int {\n\treturn w.Bounds().Dx() * w.Bounds().Dy()\n}", "func PointSize(size float32) {\n C.glowPointSize(gpPointSize, (C.GLfloat)(size))\n}", "func diameter(root *Node, d *int) {\n\tif root == nil {\n\t\treturn\n\t}\n\n\t//Get height of left and right subtree\n\thl := height(root.left)\n\thr := height(root.right)\n\n\t//Update diameter if the current one is smaller than the new one\n\tif hl+hr+1 > *d {\n\t\t*d = hl + hr + 1\n\t}\n\n\t//calcualte diameter of left and right subtree\n\tdiameter(root.left, d)\n\tdiameter(root.right, d)\n}", "func (is ImageSurface) Size() Point {\n\treturn Point{float64(is.width), float64(is.height)}\n}", "func (o *Grid) Size() int {\n\treturn o.npts[0] * o.npts[1] * o.npts[2]\n}", "func TestCircleDiameter(t *testing.T) {\n\tvar r float64 = 10\n\texpD := 20.0\n\n\tc := Circle{r}\n\tif c.radius == 0 {\n\t\tt.Error(\"Expected struct Circle, got empty struct\")\n\t}\n\n\tif d := c.Diameter(); d != expD {\n\t\tt.Errorf(\"Expected diameter of circle %5.20f, got %5.20f\", expD, d)\n\t}\n}", "func dimen(xp, yp, w, h float64) (float64, float64) {\n\treturn pct(xp, w), pct(100-yp, h)\n}", "func (skeleton *Skeleton) ExtremaSphereRadius() uint {\n\n\tvar value C.uint\n\n\tC.getObjParamUint((C.gpointer)(skeleton.skeleton), C.CString(\"extrema-sphere-radius\"), &value)\n\n\treturn uint(value)\n}", "func MinLodPixel(value int) *SimpleElement { return newSEInt(\"minLodPixels\", value) }", "func (gd Grid) Size() Point {\n\treturn gd.Rg.Size()\n}", "func (r Rect) Radius() float64 { return math.Min(r.Width(), r.Height()) / 2.0 }", "func (g *MarsGrid) Size() image.Point {\n\treturn g.bounds.Max\n}", "func (e *Explosion) Size() (int, int) {\n\treturn int(e.radius)*2 - 1, int(e.radius) - 1\n}", "func (bbn *BigBaseNumerics) PixelSize() (big.Float, big.Float) {\n\treturn bbn.Runit, bbn.Iunit\n}", "func PointSize(size float32) {\n\tsyscall.Syscall(gpPointSize, 1, uintptr(math.Float32bits(size)), 0, 0)\n}", "func (o ChunkCoords) Radius(r int) []ChunkCoords {\n\tregion := make([]ChunkCoords, (r*2+1)*(r*2+1))\n\tregion[0] = o\n\tchunkIdx := 1\n\tfor i := 1; i <= r; i++ {\n\t\tring := o.Ring(i)\n\t\tfor _, c := range ring {\n\t\t\tregion[chunkIdx] = c\n\t\t\tchunkIdx++\n\t\t}\n\t}\n\treturn region\n}", "func (r rect) permi() int {\n\tr.width = 5 // Can't mutate the `r` outside.\n\treturn 2*r.width + 2*r.height\n}", "func (s square) perim() float64 {\n\treturn 2*s.width + 2*s.height\n}", "func (el *Fill) Circle() {}", "func (skeleton *Skeleton) DimensionReduction() uint {\n\n\tvar value C.uint\n\n\tC.getObjParamUint((C.gpointer)(skeleton.skeleton), C.CString(\"dimension-reduction\"), &value)\n\n\treturn uint(value)\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 (x circle) Len() int { return len(x) }", "func MaxLodPixel(value int) *SimpleElement { return newSEInt(\"maxLodPixels\", value) }", "func (c *Circle) MetaballDistBound(d float64) float64 {\n\treturn d\n}", "func (g *NormalGrid) Size() int {\n\treturn g.rows * g.cols\n}", "func (skeleton *Skeleton) ShouldersCircumferenceRadius() uint {\n\n\tvar value C.uint\n\n\tC.getObjParamUint((C.gpointer)(skeleton.skeleton), C.CString(\"shoulders-circumference-radius\"), &value)\n\n\treturn uint(value)\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 main() {\n\traster := bridge.RasterRenderer{}\n\tvector := bridge.VectorRenderer{}\n\n\tcircleR := bridge.NewCircle(&raster, 5)\n\tcircleR.Draw()\n\tcircleR.Resize(2)\n\tcircleR.Draw()\n\n\tcircleV := bridge.NewCircle(&vector, 5)\n\tcircleV.Draw()\n\tcircleV.Resize(2)\n\tcircleV.Draw()\n\n\ttriangleR := bridge.NewTriangle(&raster, 1,2,3.5)\n\ttriangleR.Draw()\n\ttriangleR.Resize(3)\n\ttriangleR.Draw()\n\n\ttriangleV := bridge.NewTriangle(&vector, 2,4,7)\n\ttriangleV.Draw()\n\ttriangleV.Resize(5)\n\ttriangleV.Draw()\n}", "func treeDiameter(edges [][]int) int {\n\tif len(edges) == 0 {\n\t\treturn 0\n\t}\n\tm := make(map[int][]int)\n\tfor _, e := range edges {\n\t\tm[e[0]] = append(m[e[0]], e[1])\n\t\tm[e[1]] = append(m[e[1]], e[0])\n\t}\n\n\t// start with a random node, find the node which is the farthest from the starting node.\n\t// it must be one end of the longest path\n\tstart, _ := bfs(0, m)\n\n\t// find another end\n\t_, dis := bfs(start, m)\n\n\treturn dis\n}", "func Dist(ax, ay, bx, by int) float64 {\n\treturn math.Sqrt(math.Pow(float64(bx-ax), 2) + math.Pow(float64(by-ay), 2))\n}", "func dimen(d deck.Deck, x, y, s float64) (xo, yo, so openvg.VGfloat) {\n\txf, yf, sf := deck.Dimen(d.Canvas, x, y, s)\n\txo, yo, so = openvg.VGfloat(xf), openvg.VGfloat(yf), openvg.VGfloat(sf)*0.8\n\treturn\n}", "func (r *Rect) MetaballDistBound(d float64) float64 {\n\treturn d\n}", "func (r Rectangle) Dx() int { return r.Max.X - r.Min.X }", "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 (o *Grid) Npts(idim int) int {\n\treturn o.npts[idim]\n}", "func d4rectSphericalVolume(rect *d4rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d4numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d4numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d4unitSphereVolume)\n\t} else if d4numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d4unitSphereVolume)\n\t} else if d4numDims == 3 {\n\t\treturn (radius * radius * radius * d4unitSphereVolume)\n\t} else if d4numDims == 2 {\n\t\treturn (radius * radius * d4unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d4numDims) * d4unitSphereVolume)\n\t}\n}", "func (a *Agent) SizeRadius() float64 {\n\treturn a.sizeRadius\n}", "func (r intrect) perim() int {\n\treturn 2*r.width + 2*r.height\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 (r rect) perim() int {\n\treturn 2*r.width + 2*r.height\n}", "func (d *RabinKarp64) Size() int { return Size }", "func (r rect) perim() int {\n\treturn 2*(r.width + r.height)\n}", "func (c *Config) dimensions(arg string) (*geometry.Size, error) {\n\tvalues := strings.Split(arg, \"x\")\n\n\tif len(values) != 2 {\n\t\treturn nil, errors.New(\"Expected size to be two-dimensional\")\n\t}\n\n\tw, err := strconv.Atoi(values[0])\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\th, err := strconv.Atoi(values[1])\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn geometry.NewSize(w, h), nil\n}", "func drip(in image.Image, out *image.RGBA, ltr int, ttb int, degree float64) {\n\trand.Seed(time.Now().UTC().UnixNano())\n\tw, h := in.Bounds().Max.X, in.Bounds().Max.Y\n\tfor y := 0; y < h; y++ {\n\t\tfor x := 0; x < w; x++ {\n\t\t\tif rand.Float64() < degree {\n\t\t\t\t//the pixel to drip from the in image\n\t\t\t\tif isInBounds(out, x+ltr, y+ttb) {\n\t\t\t\t\tout.Set(x, y, in.At(x+ltr, y+ttb))\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif isInBounds(out, x, y) {\n\t\t\t\t\tout.Set(x, y, in.At(x, y))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func (d *Dataset) Size() int64 {\n\tsize := int64(0)\n\tfor _, block := range d.blocks {\n\t\tsize += block.size\n\t}\n\n\treturn size\n}", "func d12rectSphericalVolume(rect *d12rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d12numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d12numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d12unitSphereVolume)\n\t} else if d12numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d12unitSphereVolume)\n\t} else if d12numDims == 3 {\n\t\treturn (radius * radius * radius * d12unitSphereVolume)\n\t} else if d12numDims == 2 {\n\t\treturn (radius * radius * d12unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d12numDims) * d12unitSphereVolume)\n\t}\n}", "func pixelBufferLength(bytesPerPixel int, r Rectangle, imageTypeName string) int {\n\ttotalLength := mul3NonNeg(bytesPerPixel, r.Dx(), r.Dy())\n\tif totalLength < 0 {\n\t\tpanic(\"image: New\" + imageTypeName + \" Rectangle has huge or negative dimensions\")\n\t}\n\treturn totalLength\n}", "func d11rectSphericalVolume(rect *d11rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d11numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d11numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d11unitSphereVolume)\n\t} else if d11numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d11unitSphereVolume)\n\t} else if d11numDims == 3 {\n\t\treturn (radius * radius * radius * d11unitSphereVolume)\n\t} else if d11numDims == 2 {\n\t\treturn (radius * radius * d11unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d11numDims) * d11unitSphereVolume)\n\t}\n}", "func (c circle) perim() float64 {\n\treturn 2 * math.Pi * c.radius\n}", "func d16rectSphericalVolume(rect *d16rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d16numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d16numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d16unitSphereVolume)\n\t} else if d16numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d16unitSphereVolume)\n\t} else if d16numDims == 3 {\n\t\treturn (radius * radius * radius * d16unitSphereVolume)\n\t} else if d16numDims == 2 {\n\t\treturn (radius * radius * d16unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d16numDims) * d16unitSphereVolume)\n\t}\n}", "func ArcDensity(n, a int) float64 {\n\treturn float64(a) / (float64(n) * float64(n-1))\n}", "func LRNGradDepthRadius(value int64) LRNGradAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"depth_radius\"] = value\n\t}\n}", "func (lc *LineChart) minSize() image.Point {\n\t// At the very least we need:\n\t// - n cells width for the Y axis and its labels as reported by it.\n\t// - at least 1 cell width for the graph.\n\treqWidth := axes.RequiredWidth(lc.yMin, lc.yMax) + 1\n\n\t// And for the height:\n\t// - n cells width for the X axis and its labels as reported by it.\n\t// - at least 2 cell height for the graph.\n\treqHeight := axes.RequiredHeight(lc.maxXValue(), lc.xLabels, lc.opts.xLabelOrientation) + 2\n\treturn image.Point{reqWidth, reqHeight}\n}", "func (n *Node) Size(size float64) *Node {\n\t// Pango size is 1/1024ths of a point.\n\treturn n.setAttr(\"size\", strconv.Itoa(int(size*1024)))\n}", "func (r rect) peri() int {\n\treturn 2*r.width + 2*r.height\n}", "func (interp Interpolator) SizeHint() int { return surge.SizeHint(interp.basis) }", "func (r rectangle) perim() int {\n\treturn 2*r.width + 2*r.height\n}", "func (r *Ring) Size() int {\n\treturn (r.in - r.out + r.size) % r.size\n}", "func d10rectSphericalVolume(rect *d10rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d10numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d10numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d10unitSphereVolume)\n\t} else if d10numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d10unitSphereVolume)\n\t} else if d10numDims == 3 {\n\t\treturn (radius * radius * radius * d10unitSphereVolume)\n\t} else if d10numDims == 2 {\n\t\treturn (radius * radius * d10unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d10numDims) * d10unitSphereVolume)\n\t}\n}", "func (rra *RoundRobinArchive) DPs() map[int64]float64 { return rra.dps }", "func (c *curve) PointLen() int {\n\treturn (c.P.BitLen() + 7 + 1) / 8\n}", "func (r Rectangle) Dy() int { return r.Max.Y - r.Min.Y }", "func (el *Fill) Polygon() {}", "func (o *Shape) CellBryDist(R []float64) float64 {\n\tr, s, t := R[0], R[1], 0.0\n\tif len(R) > 2 {\n\t\tt = R[2]\n\t}\n\tbgeo := o.BasicType // fundamental geometry of cell\n\tif bgeo == \"tri3\" {\n\t\treturn utl.Min(r, utl.Min(s, 1.0-r-s))\n\t}\n\tif bgeo == \"qua4\" {\n\t\treturn utl.Min(1.0-math.Abs(r), 1.0-math.Abs(s))\n\t}\n\tif bgeo == \"hex8\" {\n\t\treturn utl.Min(1.0-math.Abs(r), utl.Min(1.0-math.Abs(s), 1.0-math.Abs(t)))\n\t}\n\tif bgeo == \"tet4\" {\n\t\treturn utl.Min(r, utl.Min(s, utl.Min(t, 1.0-r-s-t)))\n\t}\n\tchk.Panic(\"cannot handle BasicType=%q yet\", bgeo)\n\treturn 0 // must not reach this point\n}", "func SobelDx(src, dst View) {\n\tC.SimdSobelDx((*C.uint8_t)(src.data), C.size_t(src.stride), C.size_t(src.width), C.size_t(src.height), (*C.uint8_t)(dst.data), C.size_t(dst.stride))\n}", "func fractionRadius(mass, imf, rmf, cmf float64) float64 {\n\tmass /= SunMassInEarthMasses\n\ticeFraction := imf * IceDensity\n\tcarbonFraction := (cmf * rmf) * CarbonDensity\n\tsilicateFraction := (rmf - (cmf * rmf)) * RockDensity\n\tironFraction := (1.0 - (rmf + imf)) * IronDensity\n\tdensity := iceFraction + silicateFraction + carbonFraction + ironFraction\n\tradius := volumeRadius(mass, density) / EarthRadiusInKM\n\treturn radius\n}", "func d1rectSphericalVolume(rect *d1rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d1numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d1numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d1unitSphereVolume)\n\t} else if d1numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d1unitSphereVolume)\n\t} else if d1numDims == 3 {\n\t\treturn (radius * radius * radius * d1unitSphereVolume)\n\t} else if d1numDims == 2 {\n\t\treturn (radius * radius * d1unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d1numDims) * d1unitSphereVolume)\n\t}\n}", "func (f Floats) Size() (w, h int) {\n\th = len(f)\n\tw = len(f[0])\n\treturn\n}", "func d2rectSphericalVolume(rect *d2rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d2numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d2numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d2unitSphereVolume)\n\t} else if d2numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d2unitSphereVolume)\n\t} else if d2numDims == 3 {\n\t\treturn (radius * radius * radius * d2unitSphereVolume)\n\t} else if d2numDims == 2 {\n\t\treturn (radius * radius * d2unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d2numDims) * d2unitSphereVolume)\n\t}\n}", "func (c *Circle) Points() []*Point {\n\tx, y, dx, dy := c.R-1, 0, 1, 1\n\te := dx - (c.R * 2)\n\n\tpoints := make([]*Point, 0)\n\n\tfor x > y {\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X + x,\n\t\t\tY: c.Center.Y + y,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X + y,\n\t\t\tY: c.Center.Y + x,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X - y,\n\t\t\tY: c.Center.Y + x,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X - x,\n\t\t\tY: c.Center.Y + y,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X - x,\n\t\t\tY: c.Center.Y - y,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X - y,\n\t\t\tY: c.Center.Y - x,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X + y,\n\t\t\tY: c.Center.Y - x,\n\t\t})\n\t\tpoints = append(points, &Point{\n\t\t\tX: c.Center.X + x,\n\t\t\tY: c.Center.Y - y,\n\t\t})\n\n\t\tif e <= 0 {\n\t\t\ty++\n\t\t\te += dy\n\t\t\tdy += 2\n\t\t}\n\n\t\tif e > 0 {\n\t\t\tx--\n\t\t\tdx += 2\n\t\t\te += dx - (c.R * 2)\n\t\t}\n\t}\n\n\treturn points\n}", "func d14rectSphericalVolume(rect *d14rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d14numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d14numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d14unitSphereVolume)\n\t} else if d14numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d14unitSphereVolume)\n\t} else if d14numDims == 3 {\n\t\treturn (radius * radius * radius * d14unitSphereVolume)\n\t} else if d14numDims == 2 {\n\t\treturn (radius * radius * d14unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d14numDims) * d14unitSphereVolume)\n\t}\n}", "func Coords(x, y, r uint32) ([]uint8, bool) {\n\tif r >= uint32(len(CoordOffset)) {\n\t\t// log.Printf(\"Coord radius too large: %d\\n\", r)\n\t\treturn []uint8{0, 0, 0}, false\n\t}\n\tdx := CoordOffset[r][0]\n\tdy := CoordOffset[r][1]\n\tif int(x)+dx < 0 || int(x)+dx >= WindowImage.Rect.Max.X || int(y)+dy < 0 || int(y)+dy >= WindowImage.Rect.Max.Y {\n\t\treturn []uint8{0, 0, 0}, false\n\t}\n\ti := (int(x)+dx)*4 + (int(y)+dy)*WindowImage.Stride\n\treturn WindowImage.Pix[i : i+3], true\n}", "func sharpen(centerPosition, texelPosition mgl32.Vec2, texel *terraindto.TerrainTexel, centerHeight, amount, regionSize float32) {\n\theightDifference := texel.Height - centerHeight\n\ttexel.Height = texel.Height + heightDifference*amount\n\ttexel.Normalize()\n}", "func (p *Point) Dist(oth *Point) float64 {\n\treturn math.Sqrt((oth.X-p.X)*(oth.X-p.X) + (oth.Y-p.Y)*(oth.Y-p.Y))\n}", "func (rg Range) Size() Point {\n\treturn rg.Max.Sub(rg.Min)\n}", "func (d *Device) Size() (w, h int16) {\n\tif d.rotation == drivers.Rotation0 || d.rotation == drivers.Rotation180 {\n\t\treturn d.width, d.height\n\t}\n\treturn d.height, d.width\n}", "func (frac Fractal) X(r float64) int {\n\treturn int(frac.xZoom*(r+real(frac.Offset)) + float64(frac.Width)/2.0)\n}", "func (d *Diagram) AdaptSize() (int, int) {\n\tfor _, s := range d.Content {\n\t\ts, ok := s.(shape.Shape)\n\t\tif !ok {\n\t\t\tcontinue\n\t\t}\n\t\tx, y := s.Position()\n\t\tswitch s := s.(type) {\n\t\tcase *shape.Line:\n\t\t\tx = min(s.Start.X, s.End.X)\n\t\t\ty = min(s.Start.Y, s.End.Y)\n\t\tcase *shape.Arrow:\n\t\t\tx = min(s.Start.X, s.End.X)\n\t\t\ty = min(s.Start.Y, s.End.Y)\n\t\t}\n\t\tw := x + s.Width()\n\t\tif w > d.Width() {\n\t\t\td.SetWidth(w)\n\t\t}\n\t\th := y + s.Height()\n\t\tif h > d.Height() {\n\t\t\td.SetHeight(h)\n\t\t}\n\t}\n\td.SetWidth(d.Width() + 1) // Fixes right most pixels not visible\n\td.SetHeight(d.Height() + 1) // Fixes bottom pixels not visible\n\treturn d.Width(), d.Height()\n}", "func dist(p1, p2 Pool) float64 {\r\n\treturn 6371 * 2 * math.Asin(math.Sqrt(math.Pow(math.Sin((p2.ltR-p1.ltR)/2), 2)+math.Pow(math.Sin((p2.lnR-p1.lnR)/2), 2)*math.Cos(p1.ltR)*math.Cos(p2.ltR)))\r\n}", "func (is ImageSurface) Stride() int {\n\treturn is.stride\n}", "func LRNDepthRadius(value int64) LRNAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"depth_radius\"] = value\n\t}\n}", "func (m *maps) subMass(p0, p1 Point) (mass uint64) {\n\tx0 := int(p0.X >> fpmbits)\n\ty0 := int(p0.Y >> fpmbits)\n\tx1 := int(p1.X >> fpmbits)\n\ty1 := int(p1.Y >> fpmbits)\n\tfxp0 := (0x400 - (p0.X & 0x3FF)) & 0x400\n\tfyp0 := (0x400 - (p0.Y & 0x3FF)) & 0x400\n\tfxp1 := p1.X & 0x3FF\n\tfyp1 := p1.Y & 0x3FF\n\n\t// top-left corner and bottem-left corner\n\tif fxp0 != 0 {\n\t\tif fyp0 != 0 {\n\t\t\tmass += (fxp0 * fyp0 * m.dmap.ValueAt(x0, y0)) >> fpmbits\n\t\t} else {\n\t\t\tmass += fxp0 * m.dmap.ValueAt(x0, y0)\n\t\t}\n\n\t\tif fyp1 != 0 {\n\t\t\tmass += (fxp0 * fyp1 * m.dmap.ValueAt(x0, y1)) >> fpmbits\n\t\t}\n\t} else {\n\t\tif fyp0 != 0 {\n\t\t\tmass += fyp0 * m.dmap.ValueAt(x0, y0)\n\t\t} else {\n\t\t\tmass += m.dmap.ValueAt(x0, y0) << fpmbits\n\t\t}\n\t\tif fyp1 != 0 {\n\t\t\tmass += fyp1 * m.dmap.ValueAt(x0, y1)\n\t\t}\n\t}\n\n\t// top right corner and bottom-right corner\n\tif fxp1 != 0 {\n\t\tif fyp0 != 0 {\n\t\t\tmass += (fxp1 * fyp0 * m.dmap.ValueAt(x1, y0)) >> fpmbits\n\t\t}\n\t\tif fyp1 != 0 {\n\t\t\tmass += (fxp1 * fyp1 * m.dmap.ValueAt(x1, y1)) >> fpmbits\n\t\t}\n\t}\n\n\t// top factional row, without fractional corners\n\tif fyp0 != 0 {\n\t\tmass += fyp0 * (m.sumx.ValueAt(x1, y0) - m.sumx.ValueAt(x0, y0))\n\t}\n\n\t// bottom fractional row without fractional corners\n\tif fyp1 != 0 {\n\t\tmass += fyp1 * (m.sumx.ValueAt(x1, y1) - m.sumx.ValueAt(x0, y1))\n\t}\n\n\t// left-most fractional column, without fractional corners\n\tif fxp0 != 0 {\n\t\tmass += fxp0 * (m.sumy.ValueAt(x0, y1) - m.sumy.ValueAt(x0, y0))\n\t}\n\n\t// right-most fractional column, without fractional corners\n\tif fxp1 != 0 {\n\t\tmass += fxp1 * (m.sumy.ValueAt(x1, y1) - m.sumy.ValueAt(x1, y0))\n\t}\n\n\t// center area, without fractional borders\n\tmass += m.dsum.AreaSum(x0, y0, x1, y1) << fpmbits\n}", "func digDist(p1, p2 Coord) int {\n return max(abs(p1.x-p2.x)+abs(p1.y-p2.y)-1, 0)\n}", "func drawCircle(rgba *image.RGBA, c color.Color, radius, thickness float64, offsets ...float64) {\n\toffX := 0.0\n\toffY := 0.0\n\tif len(offsets) > 0 {\n\t\toffX = offsets[0]\n\t\tif len(offsets) > 1 {\n\t\t\toffY = offsets[1]\n\t\t}\n\t}\n\trVec := physics.NewVector(radius+offX, radius+offY)\n\tdelta := physics.AngleVector(0)\n\tcircum := 2 * radius * math.Pi\n\trotation := 180 / circum\n\tfor j := 0.0; j < circum*2; j++ {\n\t\t// Todo: determine angle increment needed\n\t\t// uh duh its the circumference\n\t\tdelta.Rotate(rotation)\n\t\t// We add rVec to move from -1->1 to 0->2 in terms of radius scale\n\t\tstart := delta.Copy().Scale(radius).Add(rVec)\n\t\t//fmt.Println(\"Start\", start.X(), start.Y(), \"Delta\", delta.X(), delta.Y())\n\t\tfor i := 0.0; i < thickness; i++ {\n\t\t\t// this pixel is radius minus the delta, to move inward\n\t\t\tcur := start.Add(delta.Copy().Scale(-1))\n\t\t\t//fmt.Println(\"Setting pixel\", cur.X(), cur.Y())\n\t\t\trgba.Set(alg.RoundF64(cur.X()), alg.RoundF64(cur.Y()), c)\n\t\t}\n\t}\n}", "func d9rectSphericalVolume(rect *d9rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d9numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d9numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d9unitSphereVolume)\n\t} else if d9numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d9unitSphereVolume)\n\t} else if d9numDims == 3 {\n\t\treturn (radius * radius * radius * d9unitSphereVolume)\n\t} else if d9numDims == 2 {\n\t\treturn (radius * radius * d9unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d9numDims) * d9unitSphereVolume)\n\t}\n}", "func (*Secp256k1) PointLen() int { return egPoint.MarshalSize() }", "func dline (x int, y int, height int) {\n\tadd := 1\n\tn := 0\n\theight += height % 2\n\tif height < 0 {\n\t\tadd = -1\n\t}\n\tfor n != height {\n\t\timg.Set(x, y - n, col)\n\t\timg.Set(x, y - n - add, col)\n\t\tx += 1;\n\t\tn += 2 * add\n\t}\n}", "func (d *Datapoint) Dimensionality() int {\n\treturn len(d.set)\n}", "func init() {\n\tred := color.RGBA{255, 0, 0, 255}\n\tblue := color.RGBA{0, 0, 255, 255}\n\n\t//!+indirect\n\ttype ColoredPoint struct {\n\t\t*Point\n\t\tColor color.RGBA\n\t}\n\n\tp := ColoredPoint{&Point{1, 1}, red}\n\tq := ColoredPoint{&Point{5, 4}, blue}\n\tfmt.Println(p.Distance(*q.Point)) // \"5\"\n\tq.Point = p.Point // p and q now share the same Point\n\tp.ScaleBy(2)\n\tfmt.Println(*p.Point, *q.Point) // \"{2 2} {2 2}\"\n\tfmt.Println(p.Distance(*q.Point)) // \"0\"\n\t//!-indirect\n}", "func d20rectSphericalVolume(rect *d20rectT) float64 {\n\tvar sumOfSquares float64 = 0\n\tvar radius float64\n\n\tfor index := 0; index < d20numDims; index++ {\n\t\thalfExtent := (rect.max[index] - rect.min[index]) * 0.5\n\t\tsumOfSquares += halfExtent * halfExtent\n\t}\n\n\tradius = math.Sqrt(sumOfSquares)\n\n\t// Pow maybe slow, so test for common dims just use x*x, x*x*x.\n\tif d20numDims == 5 {\n\t\treturn (radius * radius * radius * radius * radius * d20unitSphereVolume)\n\t} else if d20numDims == 4 {\n\t\treturn (radius * radius * radius * radius * d20unitSphereVolume)\n\t} else if d20numDims == 3 {\n\t\treturn (radius * radius * radius * d20unitSphereVolume)\n\t} else if d20numDims == 2 {\n\t\treturn (radius * radius * d20unitSphereVolume)\n\t} else {\n\t\treturn (math.Pow(radius, d20numDims) * d20unitSphereVolume)\n\t}\n}", "func Perimeter(width, length float64) float64 {\n\treturn 2*(width+length) + b\n}", "func scale_pixel(x, y int) (float64, float64) {\n\tnewx := float64(x)/(float64(maxX)/3) - 2.0\n\tnewy := float64(y)/(float64(maxY)/2) - 0.0 \n\treturn newx, newy\n}", "func initDensityInfo(h *Halo, cFunc num.Func1D, m, r float64) {\n\trho500c := cosmo.RhoCritical(h.Z) * 500\n\trho200a := cosmo.RhoAverage(h.Z) * 200\n\n\t// This sets c200 for us.\n\tinitSearching(h, cFunc, m, r)\n\n\th.A200.R = h.OverdensityRadius(Corrected, rho200a)\n\th.A200.C = h.A200.R / h.Rs\n\th.A200.M = haloMass(h.A200.R, rho200a)\n\n\th.C500.R = h.OverdensityRadius(Corrected, rho500c)\n\th.C500.C = h.C500.R / h.Rs\n\th.C500.M = haloMass(h.C500.R, rho500c)\n\n\t// This will already be set if the biased mass is required.\n\tif !h.ppt.RequiresBiasedMass() {\n\t\th.R500cBias = h.OverdensityRadius(Biased, rho500c)\n\t\th.M500cBias = haloMass(h.R500cBias, rho500c)\n\t}\n}", "func Density(n, m int) float64 {\n\treturn float64(m) * 2 / (float64(n) * float64(n-1))\n}", "func thermometer(sw, sh int) (img draw.Image, err error) {\n\n\t// dynamic SVG\n\n\twt, ht := 120, 120\n\n\timg = image.NewRGBA(image.Rect(0, 0, sw, sh))\n\tvar iconMem = new(bytes.Buffer)\n\n\tvar canvas = svg.New(iconMem)\n\tcanvas.Start(wt, ht)\n\n\tbfs := svg.Filterspec{In: `SourceGraphic`}\n\tcanvas.Def()\n\tcanvas.Filter(`blur_f`, `filterUnits=\"objectBoundingBox\" x=\"-50%\" y=\"-50%\" width=\"200%\" height=\"200%\"`)\n\tcanvas.FeGaussianBlur(bfs, 6, 6)\n\tcanvas.Fend()\n\tcanvas.Filter(`blur_z`, `filterUnits=\"objectBoundingBox\" x=\"-50%\" y=\"-50%\" width=\"200%\" height=\"200%\"`)\n\tcanvas.FeGaussianBlur(bfs, 2, 2)\n\tcanvas.Fend()\n\tcanvas.Filter(`blur_k`, `filterUnits=\"objectBoundingBox\"`)\n\tcanvas.FeGaussianBlur(bfs, 1, 1)\n\tcanvas.Fend()\n\tcanvas.DefEnd()\n\n\tdegF := `m12.04517,17c0,-1.49271 0.53737,-2.77643 1.58227,-3.82133s2.32862,-1.58227 3.82133,-1.58227c1.46285,0 2.74658,0.53737 3.79148,1.58227c1.04489,1.07475 1.58227,2.32862 1.58227,3.82133c0,1.49271 -0.53737,2.77643 -1.58227,3.85118c-1.04489,1.07475 -2.32862,1.61212 -3.79148,1.61212s-2.74658,-0.53737 -3.82133,-1.61212c-1.04489,-1.07475 -1.58227,-2.35848 -1.58227,-3.85118zm2.62716,0c0,0.77621 0.26869,1.433 0.80606,2.00023c0.56723,0.56723 1.22402,0.83592 2.00023,0.83592s1.433,-0.26869 2.00023,-0.83592s0.83592,-1.22402 0.83592,-2.00023c0,-0.77621 -0.26869,-1.433 -0.83592,-1.97037c-0.56723,-0.53737 -1.22402,-0.83592 -2.00023,-0.83592c-0.77621,0 -1.433,0.26869 -2.00023,0.80606c-0.53737,0.53737 -0.80606,1.19417 -0.80606,2.00023zm13.16568,20.5695c0,0.41796 0.14927,0.80606 0.44781,1.1046s0.68665,0.44781 1.1046,0.44781c0.41796,0 0.80606,-0.14927 1.1046,-0.44781c0.29854,-0.29854 0.44781,-0.68665 0.44781,-1.1046l0,-11.31472l8.53828,0c0.41796,0 0.80606,-0.14927 1.1046,-0.47767s0.44781,-0.68665 0.44781,-1.13446c0,-0.44781 -0.14927,-0.80606 -0.44781,-1.13446c-0.29854,-0.29854 -0.68665,-0.44781 -1.13446,-0.44781l-8.53828,0l0,-8.15018l11.40428,0c0.41796,0 0.77621,-0.14927 1.07475,-0.44781s0.41796,-0.68665 0.41796,-1.13446s-0.14927,-0.80606 -0.41796,-1.13446s-0.62694,-0.44781 -1.07475,-0.44781l-14.24042,0c-0.20898,0 -0.29854,0.11942 -0.29854,0.3284l0,25.49544l0.05971,0z`\n\tdegC := `m75.50005,17c0,-1.49186 0.53707,-2.77486 1.58137,-3.81916c1.07414,-1.07414 2.3273,-1.58137 3.81916,-1.58137c1.46202,0 2.74502,0.53707 3.78933,1.58137c1.0443,1.07414 1.58137,2.3273 1.58137,3.81916c0,1.49186 -0.53707,2.77486 -1.58137,3.81916c-1.0443,1.07414 -2.3273,1.58137 -3.78933,1.58137c-1.49186,0 -2.77486,-0.53707 -3.81916,-1.58137s-1.58137,-2.3273 -1.58137,-3.81916zm2.62567,0c0,0.77577 0.26853,1.43219 0.8056,1.99909c0.56691,0.56691 1.22333,0.83544 1.99909,0.83544c0.77577,0 1.43219,-0.26853 1.99909,-0.83544s0.83544,-1.22333 0.83544,-1.99909c0,-0.77577 -0.26853,-1.43219 -0.83544,-1.99909s-1.22333,-0.83544 -1.99909,-0.83544c-0.77577,0 -1.43219,0.26853 -1.99909,0.83544c-0.53707,0.53707 -0.8056,1.22333 -0.8056,1.99909zm11.60667,13.18805c0,2.29747 0.62658,4.3264 1.90958,6.11663c0.65642,0.92495 1.58137,1.67088 2.77486,2.23779c1.16365,0.53707 2.50633,0.83544 3.99819,0.83544c4.35623,0 7.10126,-1.67088 8.20523,-4.98281c0.11935,-0.41772 0.05967,-0.83544 -0.17902,-1.22333c-0.2387,-0.38788 -0.56691,-0.59674 -0.98463,-0.68626c-0.41772,-0.11935 -0.83544,-0.05967 -1.19349,0.20886c-0.35805,0.2387 -0.59674,0.56691 -0.68626,1.01447c0,0.02984 0,0.05967 -0.02984,0.14919l-0.05967,0.20886c-0.32821,0.56691 -0.77577,1.01447 -1.34267,1.34267c-0.92495,0.56691 -2.14828,0.83544 -3.66998,0.83544c-0.92495,0 -1.7604,-0.14919 -2.47649,-0.4774c-1.19349,-0.50723 -2.02893,-1.40235 -2.53616,-2.65551c-0.32821,-0.8056 -0.50723,-1.79023 -0.50723,-2.89421l0,-9.60758c0,-0.44756 0.02984,-0.89512 0.08951,-1.34267c0.11935,-1.13381 0.56691,-2.17812 1.34267,-3.10307c0.86528,-1.0443 2.23779,-1.55153 4.11753,-1.55153c1.55153,0 2.77486,0.26853 3.66998,0.8056c0.59674,0.35805 1.0443,0.8056 1.34267,1.34267c0.02984,0.05967 0.02984,0.14919 0.05967,0.2387c0.02984,0.08951 0.02984,0.14919 0.02984,0.17902c0.11935,0.41772 0.35805,0.71609 0.68626,0.89512c0.35805,0.20886 0.74593,0.2387 1.19349,0.14919c0.41772,-0.08951 0.74593,-0.32821 0.98463,-0.68626c0.2387,-0.35805 0.29837,-0.74593 0.17902,-1.19349l0,-0.02984l-0.2387,-0.68626c-0.14919,-0.32821 -0.41772,-0.77577 -0.83544,-1.283c-0.38788,-0.53707 -0.86528,-0.95479 -1.34267,-1.31284c-0.62658,-0.44756 -1.43219,-0.8056 -2.44665,-1.13381c-1.01447,-0.29837 -2.11844,-0.44756 -3.31193,-0.44756c-1.5217,0 -2.83453,0.26853 -4.02802,0.8056c-1.16365,0.53707 -2.0886,1.25316 -2.71519,2.17812c-1.283,1.7604 -1.93942,3.81916 -1.93942,6.1763l0,9.57774l-0.05967,0z`\n\n\t// rear plane shadow -\n\tcanvas.Group(`style=\"fill:black;filter:url(#blur_f);\"`)\n\tcanvas.Path(\"m39.90978,78.17153c0,-3.4036 0.80084,-6.56694 2.36249,-9.53009s3.76398,-5.40572 6.60699,-7.3678l0,-39.72202c0,-3.20339 1.08115,-5.92626 3.28348,-8.12859s4.9252,-3.36355 8.12859,-3.36355c3.24344,0 5.96631,1.12118 8.16864,3.32351c2.20233,2.24237 3.32351,4.9252 3.32351,8.12859l0,39.72202c2.84301,1.96208 5.00529,4.4447 6.56694,7.3678s2.32246,6.12647 2.32246,9.53009c0,3.68389 -0.92097,7.12753 -2.72287,10.25083s-4.28452,5.60593 -7.40783,7.40783s-6.5269,2.72287 -10.25083,2.72287c-3.68389,0 -7.08749,-0.92097 -10.21079,-2.72287s-5.60593,-4.28452 -7.44787,-7.40783s-2.72287,-6.5269 -2.72287,-10.21079l-0.00004,0zm7.04746,0c0,3.72394 1.3214,6.92733 3.92416,9.57013c2.60276,2.6428 5.7661,3.96418 9.45,3.96418c3.72394,0 6.92733,-1.3214 9.61015,-4.00423s4.04427,-5.84617 4.04427,-9.49004c0,-2.48262 -0.64068,-4.80509 -1.92203,-6.92733c-1.28136,-2.12224 -3.04321,-3.76398 -5.28559,-4.9252l-1.12118,-0.56059c-0.40043,-0.16016 -0.60063,-0.56059 -0.60063,-1.16122l0,-43.08557c0,-1.28136 -0.44047,-2.36249 -1.36145,-3.24344c-0.92097,-0.84088 -2.04215,-1.28136 -3.4036,-1.28136c-1.28136,0 -2.40253,0.44047 -3.32351,1.28136c-0.92097,0.84088 -1.36145,1.92203 -1.36145,3.24344l0,43.00548c0,0.60063 -0.2002,1.00106 -0.56059,1.16122l-1.08115,0.56059c-2.20233,1.16122 -3.92416,2.80296 -5.16547,4.9252c-1.24131,2.12224 -1.84195,4.40466 -1.84195,6.96737l0.00002,0.00001zm3.1233,0c0,2.84301 0.96102,5.28559 2.9231,7.28771s4.28452,3.00317 7.04746,3.00317s5.12543,-1.00106 7.16758,-3.00317c2.04215,-2.00212 3.04321,-4.4447 3.04321,-7.24767c0,-2.52267 -0.88093,-4.76504 -2.60276,-6.68708c-1.72183,-1.92203 -3.84407,-3.08326 -6.32669,-3.4036l-2.44258,-0.08011c-2.44258,0.36038 -4.52479,1.48156 -6.2466,3.4036c-1.72183,1.96208 -2.56271,4.16441 -2.56271,6.72712l0,0.00002l-0.00001,0.00001z\")\n\tcanvas.Path(degF)\n\tcanvas.Path(degC)\n\tcanvas.Gend()\n\n\t// glassback -\n\tcanvas.Path(\"m39.90978,78.17153c0,-3.4036 0.80084,-6.56694 2.36249,-9.53009s3.76398,-5.40572 6.60699,-7.3678l0,-39.72202c0,-3.20339 1.08115,-5.92626 3.28348,-8.12859s4.9252,-3.36355 8.12859,-3.36355c3.24344,0 5.96631,1.12118 8.16864,3.32351c2.20233,2.24237 3.32351,4.9252 3.32351,8.12859l0,39.72202c2.84301,1.96208 5.00529,4.4447 6.56694,7.3678s2.32246,6.12647 2.32246,9.53009c0,3.68389 -0.92097,7.12753 -2.72287,10.25083s-4.28452,5.60593 -7.40783,7.40783s-6.5269,2.72287 -10.25083,2.72287c-3.68389,0 -7.08749,-0.92097 -10.21079,-2.72287s-5.60593,-4.28452 -7.44787,-7.40783s-2.72287,-6.5269 -2.72287,-10.21079l-0.00004,0z\",\n\t\t`style=\"fill:green;fill-opacity:0.45\"`)\n\n\t// glass -\n\tcanvas.Path(\"m39.90978,78.17153c0,-3.4036 0.80084,-6.56694 2.36249,-9.53009s3.76398,-5.40572 6.60699,-7.3678l0,-39.72202c0,-3.20339 1.08115,-5.92626 3.28348,-8.12859s4.9252,-3.36355 8.12859,-3.36355c3.24344,0 5.96631,1.12118 8.16864,3.32351c2.20233,2.24237 3.32351,4.9252 3.32351,8.12859l0,39.72202c2.84301,1.96208 5.00529,4.4447 6.56694,7.3678s2.32246,6.12647 2.32246,9.53009c0,3.68389 -0.92097,7.12753 -2.72287,10.25083s-4.28452,5.60593 -7.40783,7.40783s-6.5269,2.72287 -10.25083,2.72287c-3.68389,0 -7.08749,-0.92097 -10.21079,-2.72287s-5.60593,-4.28452 -7.44787,-7.40783s-2.72287,-6.5269 -2.72287,-10.21079l-0.00004,0zm7.04746,0c0,3.72394 1.3214,6.92733 3.92416,9.57013c2.60276,2.6428 5.7661,3.96418 9.45,3.96418c3.72394,0 6.92733,-1.3214 9.61015,-4.00423s4.04427,-5.84617 4.04427,-9.49004c0,-2.48262 -0.64068,-4.80509 -1.92203,-6.92733c-1.28136,-2.12224 -3.04321,-3.76398 -5.28559,-4.9252l-1.12118,-0.56059c-0.40043,-0.16016 -0.60063,-0.56059 -0.60063,-1.16122l0,-43.08557c0,-1.28136 -0.44047,-2.36249 -1.36145,-3.24344c-0.92097,-0.84088 -2.04215,-1.28136 -3.4036,-1.28136c-1.28136,0 -2.40253,0.44047 -3.32351,1.28136c-0.92097,0.84088 -1.36145,1.92203 -1.36145,3.24344l0,43.00548c0,0.60063 -0.2002,1.00106 -0.56059,1.16122l-1.08115,0.56059c-2.20233,1.16122 -3.92416,2.80296 -5.16547,4.9252c-1.24131,2.12224 -1.84195,4.40466 -1.84195,6.96737z\",\n\t\t`style=\"fill:lightskyblue;fill-opacity:0.3;stroke-width:0.4;stroke-opacity:0.2;stroke:midnightblue;\"`)\n\t// capillary -\n\tcanvas.Path(\"m46.95724,78.17153c0,3.72394 1.3214,6.92733 3.92416,9.57013c2.60276,2.6428 5.7661,3.96418 9.45,3.96418c3.72394,0 6.92733,-1.3214 9.61015,-4.00423s4.04427,-5.84617 4.04427,-9.49004c0,-2.48262 -0.64068,-4.80509 -1.92203,-6.92733c-1.28136,-2.12224 -3.04321,-3.76398 -5.28559,-4.9252l-1.12118,-0.56059c-0.40043,-0.16016 -0.60063,-0.56059 -0.60063,-1.16122l0,-43.08557c0,-1.28136 -0.44047,-2.36249 -1.36145,-3.24344c-0.92097,-0.84088 -2.04215,-1.28136 -3.4036,-1.28136c-1.28136,0 -2.40253,0.44047 -3.32351,1.28136c-0.92097,0.84088 -1.36145,1.92203 -1.36145,3.24344l0,43.00548c0,0.60063 -0.2002,1.00106 -0.56059,1.16122l-1.08115,0.56059c-2.20233,1.16122 -3.92416,2.80296 -5.16547,4.9252c-1.24131,2.12224 -1.84195,4.40466 -1.84195,6.96737z\",\n\t\t`style=\"fill:linen;filter:url(#blur_shadow);fill-opacity:0.4;\"`)\n\n\tcanvas.Group()\n\tcanvas.Path(degF, `style=\"fill:#0099ff;stroke-width:1.5;stroke-opacity:0.4;stroke:#0099ff;stroke-alignment:outside;\"`)\n\tcanvas.Path(degC, `style=\"fill:#66ff99;stroke-width:1.5;stroke-opacity:0.4;stroke:#66ff99;stroke-alignment:outside;\"`)\n\tcanvas.Gend()\n\n\talcoCol := `red`\n\talcoWidth := `3.1`\n\tif w.Current.tempF <= 32 {\n\t\talcoCol = `navy`\n\t}\n\t// bulb -\n\tcanvas.Circle(60, 78, 10, fmt.Sprintf(\"style=\\\"fill:%s\\\"\", alcoCol))\n\n\t// temperature -\n\t// ( 31 = -20) .. (11 = 120)\n\tcanvas.Group()\n\tcanvas.Line(60, 78, 60, 62, fmt.Sprintf(\"style=\\\"stroke-width:%s;stroke:%s;stroke-linecap:round\\\"\", alcoWidth, alcoCol))\n\tif w.Current.tempF > -20 {\n\t\ty2 := int(40.0 * (float64(20+w.Current.tempF) / 140.00))\n\t\tcanvas.Line(60, 78, 60, 62-y2, fmt.Sprintf(\"style=\\\"stroke-width:%s;stroke:%s;stroke-linecap:round\\\"\", alcoWidth, alcoCol))\n\t}\n\tcanvas.Gend()\n\n\t// pop -\n\tcanvas.Circle(60, 78, 8,\n\t\t`style=\"fill:orangered;filter:url(#blur_k);filter-opacity:0.1;fill-opacity:0.2;\"`)\n\tcanvas.Circle(60, 78, 7,\n\t\t`style=\"fill:white;filter:url(#blur_k);filter-opacity:0.1;fill-opacity:0.2;\"`)\n\tcanvas.Circle(56, 74, 4,\n\t\t`style=\"fill:white;filter:url(#blur_k);filter-opacity:0.1;fill-opacity:0.1;\"`)\n\n\t// ticks\n\tfor tick := 22; tick < 64; tick += 3 {\n\t\tdash := tick % 2\n\t\tcanvas.Line(50, tick, 56+(10*dash), tick, `style=\"stroke-width:1;stroke:greenyellow;stroke-linecap:round;stroke-opacity:0.3;\"`)\n\t}\n\n\t// glass 2 -\n\tcanvas.Path(\"m39.90978,78.17153c0,-3.4036 0.80084,-6.56694 2.36249,-9.53009s3.76398,-5.40572 6.60699,-7.3678l0,-39.72202c0,-3.20339 1.08115,-5.92626 3.28348,-8.12859s4.9252,-3.36355 8.12859,-3.36355c3.24344,0 5.96631,1.12118 8.16864,3.32351c2.20233,2.24237 3.32351,4.9252 3.32351,8.12859l0,39.72202c2.84301,1.96208 5.00529,4.4447 6.56694,7.3678s2.32246,6.12647 2.32246,9.53009c0,3.68389 -0.92097,7.12753 -2.72287,10.25083s-4.28452,5.60593 -7.40783,7.40783s-6.5269,2.72287 -10.25083,2.72287c-3.68389,0 -7.08749,-0.92097 -10.21079,-2.72287s-5.60593,-4.28452 -7.44787,-7.40783s-2.72287,-6.5269 -2.72287,-10.21079l-0.00004,0z\",\n\t\t`style=\"fill:lightskyblue;fill-opacity:0.2;stroke-width:1;stroke-opacity:0.4;stroke:midnightblue;\"`)\n\n\tcanvas.End()\n\n\ticonI, err := oksvg.ReadIconStream(iconMem)\n\tif err != nil {\n\t\treturn img, err\n\t}\n\n\tgv := rasterx.NewScannerGV(wt, ht, img, img.Bounds())\n\tr := rasterx.NewDasher(wt, ht, gv)\n\ticonI.SetTarget(0, 0, float64(sw), float64(sh))\n\ticonI.Draw(r, 1.0)\n\n\treturn img, nil\n\n}", "func findRadius(workstations, sterilizers []int) int {\n\tsort.Ints(workstations)\n\tsort.Ints(sterilizers)\n\tsterilizers = append(sterilizers, 1<<32)\n\tsterilizers = append([]int{-1 << 32}, sterilizers...)\n\n\tvar res int\n\tfor _, w := range workstations {\n\t\tl, r := 0, len(sterilizers)\n\n\t\tfor l < r {\n\t\t\tmid := (l + r) / 2\n\t\t\tif sterilizers[mid] < w {\n\t\t\t\tl = mid + 1\n\t\t\t} else {\n\t\t\t\tr = mid\n\t\t\t}\n\t\t}\n\n\t\tres = common.Max(res, common.Min(sterilizers[l]-w, w-sterilizers[l-1]))\n\t}\n\treturn res\n}", "func (geom Geometry) Dimension() int {\n\tdim := C.OGR_G_GetDimension(geom.cval)\n\treturn int(dim)\n}" ]
[ "0.54266196", "0.52950555", "0.52080727", "0.51301914", "0.50911796", "0.50345653", "0.50208837", "0.49921605", "0.49690863", "0.49007654", "0.4881917", "0.48346436", "0.47907463", "0.47518173", "0.4751527", "0.47513434", "0.47317082", "0.47248155", "0.46796593", "0.46615195", "0.46299022", "0.46238196", "0.46164602", "0.4609622", "0.4598656", "0.45901242", "0.4588898", "0.456431", "0.4530944", "0.45247242", "0.4519738", "0.4518503", "0.4516812", "0.45099336", "0.44974935", "0.44916093", "0.44898382", "0.44877145", "0.4482005", "0.44715598", "0.44712228", "0.44692293", "0.44616115", "0.44587028", "0.44469187", "0.44430792", "0.44412598", "0.44293797", "0.44272482", "0.4426371", "0.44243768", "0.44204277", "0.44189724", "0.44172317", "0.4415732", "0.44063622", "0.44056934", "0.44046432", "0.44002315", "0.43942595", "0.43892467", "0.4387791", "0.43869045", "0.43796825", "0.43749943", "0.43670225", "0.4366012", "0.43638155", "0.43627578", "0.43626022", "0.43565142", "0.4355981", "0.43557823", "0.43442747", "0.43423745", "0.43415344", "0.43409005", "0.43358594", "0.4331394", "0.4328142", "0.43270272", "0.43268457", "0.43267822", "0.43221503", "0.43105695", "0.43076637", "0.4303361", "0.42891973", "0.428595", "0.42829064", "0.42814088", "0.42721087", "0.42638075", "0.42603537", "0.42587188", "0.42573398", "0.42540026", "0.42476445", "0.42465872" ]
0.48797992
12
select a polygon rasterization mode
func PolygonMode(face uint32, mode uint32) { C.glowPolygonMode(gpPolygonMode, (C.GLenum)(face), (C.GLenum)(mode)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PolygonMode(face uint32, mode uint32) {\n C.glowPolygonMode(gpPolygonMode, (C.GLenum)(face), (C.GLenum)(mode))\n}", "func PolygonMode(face uint32, mode uint32) {\n\tsyscall.Syscall(gpPolygonMode, 2, uintptr(face), uintptr(mode), 0)\n}", "func (native *OpenGL) PolygonMode(face uint32, mode uint32) {\n\tgl.PolygonMode(face, mode)\n}", "func (debugging *debuggingOpenGL) PolygonMode(face uint32, mode uint32) {\n\tdebugging.recordEntry(\"PolygonMode\", face, mode)\n\tdebugging.gl.PolygonMode(face, mode)\n\tdebugging.recordExit(\"PolygonMode\")\n}", "func (rs *RenderSystem) TogglePolygons() {\n\trs.drawPolygon = !rs.drawPolygon\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 (el *Fill) Polygon() {}", "func (win *window) Polygon(pt []image.Point, fill bool) {\n\tif len(pt) < 2 {\n\t\treturn\n\t}\n\tpts := make([]xgb.Point, len(pt))\n\tfor i, p := range pt {\n\t\tpts[i].X, pts[i].Y = int16(p.X), int16(p.Y)\n\t}\n\tif !fill {\n\t\tif !pt[0].Eq(pt[len(pt)-1]) {\n\t\t\tpts = append(pts, xgb.Point{int16(pt[0].X), int16(pt[0].Y)})\n\t\t}\n\t\txwin.PolyLine(xgb.CoordModeOrigin, win.id, win.gc, pts)\n\t\treturn\n\t}\n\txwin.FillPoly(win.id, win.gc, xgb.PolyShapeComplex, xgb.CoordModeOrigin, pts)\n}", "func (s *VisvalingamSimplifier) Polygon(p orb.Polygon) orb.Polygon {\n\treturn polygon(s, p)\n}", "func (dw *DrawingWand) Polygon(coordinates []PointInfo) {\n\tccoordinates := [1 << 16]C.PointInfo{}\n\tfor k, v := range coordinates {\n\t\tccoordinates[k] = C.PointInfo{C.double(v.X), C.double(v.Y)}\n\t}\n\tC.MagickDrawPolygon(dw.dw, C.ulong(len(coordinates)), (*C.PointInfo)(&ccoordinates[0]))\n}", "func Polygon(p orb.Polygon, z maptile.Zoom) (maptile.Set, error) {\n\tset := make(maptile.Set)\n\n\terr := polygon(set, p, z)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn set, nil\n}", "func (w *SVGWriter) Polygon(p *Polygon) {\n\tw.PolygonWithClass(p, \"\")\n}", "func (r *Relation) Polygon() bool {\n\tt := r.Tags.Find(\"type\")\n\treturn t == \"multipolygon\" || t == \"boundary\"\n}", "func (geom Geometry) Polygonize() Geometry {\n\tnewGeom := C.OGR_G_Polygonize(geom.cval)\n\treturn Geometry{newGeom}\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 (self *Graphics) DrawPolygon(path interface{}) *Graphics{\n return &Graphics{self.Object.Call(\"drawPolygon\", path)}\n}", "func (w *Way) Polygon() bool {\n\tif len(w.Nodes) <= 3 {\n\t\t// need more than 3 nodes to be a polygon since first/last is repeated.\n\t\treturn false\n\t}\n\n\tif w.Nodes[0].ID != w.Nodes[len(w.Nodes)-1].ID {\n\t\t// must be closed\n\t\treturn false\n\t}\n\n\tif area := w.Tags.Find(\"area\"); area == \"no\" {\n\t\treturn false\n\t} else if area != \"\" {\n\t\treturn true\n\t}\n\n\tfor _, c := range polyConditions {\n\t\tv := w.Tags.Find(c.Key)\n\t\tif v == \"\" || v == \"no\" {\n\t\t\tcontinue\n\t\t}\n\n\t\tif c.Condition == conditionAll {\n\t\t\treturn true\n\t\t} else if c.Condition == conditionWhitelist {\n\t\t\tindex := sort.SearchStrings(c.Values, v)\n\t\t\tif index != len(c.Values) && c.Values[index] == v {\n\t\t\t\treturn true\n\t\t\t}\n\t\t} else if c.Condition == conditionBlacklist {\n\t\t\tindex := sort.SearchStrings(c.Values, v)\n\t\t\tif index == len(c.Values) || c.Values[index] != v {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\n\treturn false\n}", "func (p *PDF) Polygon(pts []gofpdf.PointType, opts ...PDFOption) {\n\n\tfor _, opt := range opts {\n\t\topt(p.fpdf)\n\t}\n\tp.fpdf.Polygon(pts, \"F\")\n}", "func (p *Polygon) Reverse() {\n\tp.reverse = true\n}", "func (s *WeatherData) fetchPolygon(APIstub shim.ChaincodeStubInterface, polyId string ) sc.Response {\n\tif len(polyId) == 0 {\n\t\tmessage := \"Required Polygon id to fetch polygon details\";\n\t\tfmt.Println(message);\n\t\treturn shim.Error(message);\n\t}\n\tfmt.Println(\"============= START : Fetching polygon details by the polygon id =============\")\n\tvar datasource = \"URL\" // Setting the Oraclize datasource\n\tvar query = \"json(http://api.agromonitoring.com/agro/1.0/polygons/\" + polyId + \"?appid=\" + API_KEY + \")\" // Setting the query\n\tresult, proof := oraclizeapi.OraclizeQuery_sync(APIstub, datasource, query, oraclizeapi.TLSNOTARY)\n\tfmt.Printf(\"proof: %s\", proof)\n\tfmt.Printf(\"\\nresult: %s\\n\", result)\n\tvar response = {\n\t\t\"result\": result,\n\t\t\"proof\": proof\n\t}", "func (s *VisvalingamSimplifier) MultiPolygon(mp orb.MultiPolygon) orb.MultiPolygon {\n\treturn multiPolygon(s, mp)\n}", "func GetPolygonStipple(mask *uint8) {\n\tsyscall.Syscall(gpGetPolygonStipple, 1, uintptr(unsafe.Pointer(mask)), 0, 0)\n}", "func (this *Poly) setType(t int) {\n\tthis.areaAndtype = (this.areaAndtype & 0x3f) | (t << 6)\n}", "func (g *Circle) Polygon() Object {\n\treturn g.getObject()\n}", "func (w *Walker) MultiPolygon(ctx context.Context) (mplyg geom.MultiPolygon) {\n\tif w == nil {\n\t\tif debug {\n\t\t\tlog.Printf(\"walker is nil.\")\n\t\t}\n\t\treturn mplyg\n\t}\n\tif w.edgeMap == nil {\n\t\tw.edgeMap = edgeMapFromTriangles(w.Triangles...)\n\t}\n\tseen := make(map[int]bool, len(w.Triangles))\n\tfor i := range w.Triangles {\n\t\tif ctx.Err() != nil {\n\t\t\treturn nil\n\t\t}\n\t\tif seen[i] {\n\t\t\tcontinue\n\t\t}\n\t\tseen[i] = true\n\t\tplyg := w.PolygonForTriangle(ctx, i, seen)\n\t\tif debug {\n\t\t\tlog.Printf(\" %v : got the following plyg\\n%v\\n\", i, wkt.MustEncode(geom.Polygon(plyg)))\n\t\t}\n\t\tif len(plyg) > 0 {\n\t\t\tmplyg = append(mplyg, plyg)\n\t\t}\n\t}\n\treturn geom.MultiPolygon(mplyg)\n}", "func CreatePolygon(polygon [][][]float64, minp, maxp int) *Poly {\n\twest, south, east, north := 180.0, 90.0, -180.0, -90.0\n\tmaxpmap := map[string]string{}\n\tfor _, cont := range polygon {\n\t\tfor _, pt := range cont {\n\t\t\tx, y := pt[0], pt[1]\n\t\t\t// can only be one condition\n\t\t\t// using else if reduces one comparison\n\t\t\tif x < west {\n\t\t\t\twest = x\n\t\t\t} else if x > east {\n\t\t\t\teast = x\n\t\t\t}\n\n\t\t\tif y < south {\n\t\t\t\tsouth = y\n\t\t\t} else if y > north {\n\t\t\t\tnorth = y\n\t\t\t}\n\t\t\tghash := Geohash(pt, maxp)\n\t\t\tmaxpmap[ghash] = \"\"\n\t\t}\n\t}\n\n\t// logic for creating the smaller maps of each geohash\n\tcurrentmap := maxpmap\n\ttotalmap := map[int]map[string]string{}\n\ttotalmap[maxp] = maxpmap\n\tfor i := maxp - 1; i >= minp; i-- {\n\t\tnewmap := map[string]string{}\n\t\tfor k := range currentmap {\n\t\t\tnewmap[k[:len(k)-1]] = \"\"\n\t\t}\n\t\ttotalmap[i] = newmap\n\t\tcurrentmap = newmap\n\t}\n\n\treturn &Poly{\n\t\tPolygon: polygon,\n\t\tExtrema: Extrema{N: north, S: south, E: east, W: west},\n\t\tMap: totalmap,\n\t\tMin: minp,\n\t\tMax: maxp,\n\t}\n}", "func (r *Rasterizer8BitsSample) RenderNonZeroWinding(img *image.RGBA, color color.Color, polygons []Polygon, tr [6]float64) {\n\n\tr.MaskBuffer = make([]SUBPIXEL_DATA, r.BufferWidth*r.Height)\n\tr.WindingBuffer = make([]NON_ZERO_MASK_DATA_UNIT, r.BufferWidth*r.Height*SUBPIXEL_COUNT)\n\n\t// inline matrix multiplication\r\n\ttransform := [6]float64{\n\t\ttr[0]*r.RemappingMatrix[0] + tr[1]*r.RemappingMatrix[2],\n\t\ttr[1]*r.RemappingMatrix[3] + tr[0]*r.RemappingMatrix[1],\n\t\ttr[2]*r.RemappingMatrix[0] + tr[3]*r.RemappingMatrix[2],\n\t\ttr[3]*r.RemappingMatrix[3] + tr[2]*r.RemappingMatrix[1],\n\t\ttr[4]*r.RemappingMatrix[0] + tr[5]*r.RemappingMatrix[2] + r.RemappingMatrix[4],\n\t\ttr[5]*r.RemappingMatrix[3] + tr[4]*r.RemappingMatrix[1] + r.RemappingMatrix[5],\n\t}\n\n\tclipRect := clip(img.Bounds().Min.X, img.Bounds().Min.Y, img.Bounds().Dx(), img.Bounds().Dy(), SUBPIXEL_COUNT)\n\tclipRect = intersect(clipRect, r.ClipBound)\n\n\tbound := [4]float64{polygons[0][0], polygons[0][1], polygons[0][0], polygons[0][1]}\n\tvar edges [32]PolygonEdge\n\tfor _, polygon := range polygons {\n\t\tp := 0\n\t\tl := len(polygon) / 2\n\n\t\tfor p < l {\n\t\t\tedgeCount, subbound := polygon.getEdges(p, 16, edges[:], transform, clipRect)\n\t\t\tbound = union(bound, subbound)\n\n\t\t\tfor k := 0; k < edgeCount; k++ {\n\t\t\t\tr.addNonZeroEdge(&edges[k])\n\t\t\t}\n\t\t\tp += 16\n\t\t}\n\t}\n\tclipRect = intersect(clipRect, bound)\n\tr.fillNonZero(img, color, clipRect)\n}", "func (e *Ellipsoid) PolygonInit(polyline bool) Polygon {\n\tvar p Polygon\n\tif polyline {\n\t\tC.geod_polygon_init(&p.p, 1)\n\t} else {\n\t\tC.geod_polygon_init(&p.p, 0)\n\t}\n\tp.e = e\n\treturn p\n}", "func GetPolygonStipple(mask *uint8) {\n C.glowGetPolygonStipple(gpGetPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func (self *Graphics) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func Make_Tile_Polygon_Index(config Layer_Config, size int) {\n\t// making tilemap for polygon\n\t//layervals := t.Lint_Layer_Polygons(layer)\n\tnewlayer := config.Layer\n\tfirstlayer := config.Layer[0]\n\tif string(firstlayer.Area[0]) != \"{\" {\n\t\tnewlayer = Lint_Polygon_Layer_Map(newlayer)\n\t}\n\n\ttilemap := Make_Tilemap(newlayer, size)\n\n\t// creating tiles from a given layer\n\tMake_Layer_Xmap_Write(tilemap, newlayer)\n}", "func PolygonForRing(ctx context.Context, rng [][2]float64) (plyg [][][2]float64) {\n\tif debug {\n\t\tlog.Printf(\"turn ring into polygon.\")\n\t\tlog.Printf(\"ring: %v\", wkt.MustEncode(rng))\n\t}\n\n\tif len(rng) <= 2 {\n\t\treturn nil\n\t}\n\n\t// normalize ring\n\tcmppkg.RotateToLeftMostPoint(rng)\n\n\tpIdx := func(i int) int {\n\t\tif i == 0 {\n\t\t\treturn len(rng) - 1\n\t\t}\n\t\treturn i - 1\n\t}\n\tnIdx := func(i int) int {\n\t\tif i == len(rng)-1 {\n\t\t\treturn 0\n\t\t}\n\t\treturn i + 1\n\t}\n\n\t// Allocate space for the initial ring.\n\tplyg = make([][][2]float64, 1)\n\n\t// Remove bubbles. There are two types of bubbles we have to look for.\n\t// 1. ab … bc, in which case we need to hold on to b.\n\t// It is possible that b is absolutely not necessary. It could lie on the line between a and c, in which case\n\t// we should remove the extra point.\n\t// 2. ab … ba, which case we do not need to have b in the ring.\n\n\t// let's build an index of where the points that we are walking are. That way when we encounter the same\n\t// point we are able to “jump” to that point.\n\tptIndex := map[[2]float64]int{}\n\tvar ok bool\n\tvar idx int\n\n\t// Let's walk the points\n\tfor i := 0; i < len(rng); i++ {\n\t\t// Context has been cancelled.\n\t\tif ctx.Err() != nil {\n\t\t\treturn nil\n\t\t}\n\n\t\t// check to see if we have already seen this point.\n\t\tif idx, ok = ptIndex[rng[i]]; !ok {\n\t\t\tptIndex[rng[i]] = i\n\t\t\tcontinue\n\t\t}\n\n\t\t// ➠ what type of bubble are we dealing with\n\t\tpidx, nidx := pIdx(idx), nIdx(i)\n\n\t\t// clear out ptIndex of the values we are going to cut.\n\t\tfor j := idx; j <= i; j++ {\n\t\t\tdelete(ptIndex, rng[j])\n\t\t}\n\n\t\t// ab…ba ring. So we need to remove all the way to a.\n\t\tif nidx != pidx && cmp.PointEqual(rng[pidx], rng[nidx]) {\n\t\t\tif debug {\n\t\t\t\tlog.Printf(\"bubble type ab…ba: (% 5v)(% 5v) … (% 5v)(% 5v)\", pidx, idx, i, nidx)\n\t\t\t}\n\n\t\t\t// delete the ʽaʼ point as well from point index\n\t\t\tdelete(ptIndex, rng[pidx])\n\n\t\t\tsliver := cut(&rng, pidx, nidx)\n\t\t\t// remove the start ab\n\t\t\tsliver = sliver[2:]\n\t\t\tif len(sliver) >= 3 { // make a copy to free up memory.\n\t\t\t\tps := make([][2]float64, len(sliver))\n\t\t\t\tcopy(ps, sliver)\n\t\t\t\tcmppkg.RotateToLeftMostPoint(ps)\n\t\t\t\tif debug {\n\t\t\t\t\tlog.Printf(\"ring: %v\", wkt.MustEncode(rng))\n\t\t\t\t\tlog.Printf(\"sliver: %v\", wkt.MustEncode(sliver))\n\t\t\t\t}\n\t\t\t\tplyg = append(plyg, ps)\n\t\t\t}\n\n\t\t\tif i = idx - 1; i < 0 {\n\t\t\t\ti = 0\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\n\t\t// do a quick check to see if b is on ac\n\t\tremoveB := planar.IsPointOnLine(cmp, rng[i], rng[pidx], rng[nidx])\n\n\t\t// ab … bc The sliver is going to be from b … just before b. So, the ring will be …abc… or …ac… depending on removeB\n\t\tif debug {\n\t\t\tlog.Printf(\"bubble type ab…bc: (% 5v)(% 5v) … (% 5v)(% 5v) == %t\", pidx, idx, i, nidx, removeB)\n\t\t\tlog.Printf(\"ab..bc: [%v][%v]..[%v][%v]\",\n\t\t\t\twkt.MustEncode(geom.Point(rng[pidx])),\n\t\t\t\twkt.MustEncode(geom.Point(rng[idx])),\n\t\t\t\twkt.MustEncode(geom.Point(rng[i])),\n\t\t\t\twkt.MustEncode(geom.Point(rng[nidx])),\n\t\t\t)\n\t\t\tlog.Printf(\"%v , %v\",\n\t\t\t\twkt.MustEncode(geom.Point(rng[i])),\n\t\t\t\twkt.MustEncode(geom.Line{rng[pidx], rng[nidx]}),\n\t\t\t)\n\t\t}\n\n\t\t// Quick hack to remove extra bridges that are geting left over.\n\t\tsliver := removeBridge(cut(&rng, idx, i))\n\n\t\tif len(sliver) >= 3 {\n\t\t\tcmppkg.RotateToLeftMostPoint(sliver)\n\t\t\tif debug {\n\t\t\t\tlog.Printf(\"ring: %v\", wkt.MustEncode(rng))\n\t\t\t\tlog.Printf(\"sliver: %v\", wkt.MustEncode(sliver))\n\t\t\t}\n\t\t\tplyg = append(plyg, sliver)\n\t\t}\n\n\t\ti = idx\n\t\tif removeB {\n\t\t\tcut(&rng, idx, idx+1)\n\t\t\tif idx == 0 {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\ti = idx - 1\n\t\t}\n\t} // for\n\n\tif len(rng) <= 2 {\n\t\tif debug {\n\t\t\tlog.Println(\"rng:\", rng)\n\t\t\tlog.Println(\"plyg:\", plyg)\n\t\t\tpanic(\"main ring is not correct!\")\n\t\t}\n\t\treturn nil\n\t}\n\n\tplyg[0] = make([][2]float64, len(rng))\n\tcopy(plyg[0], rng)\n\tcmppkg.RotateToLeftMostPoint(plyg[0])\n\treturn plyg\n}", "func (this *Poly) getType() int {\n\treturn this.areaAndtype >> 6\n}", "func (el *Fill) Polyline() {}", "func PolygonOffset(factor float32, units float32) {\n\tsyscall.Syscall(gpPolygonOffset, 2, uintptr(math.Float32bits(factor)), uintptr(math.Float32bits(units)), 0)\n}", "func Ring(r orb.Ring, z maptile.Zoom) (maptile.Set, error) {\n\tif len(r) == 0 {\n\t\treturn make(maptile.Set), nil\n\t}\n\n\treturn Polygon(orb.Polygon{r}, z)\n}", "func PolygonStipple(mask *uint8) {\n\tsyscall.Syscall(gpPolygonStipple, 1, uintptr(unsafe.Pointer(mask)), 0, 0)\n}", "func PolygonTile(tileid TileID) [][][]float64 {\n\tbds := Bounds(tileid)\n\treturn [][][]float64{\n\t\t{\n\t\t\t{bds.E, bds.N},\n\t\t\t{bds.E, bds.S},\n\t\t\t{bds.W, bds.S},\n\t\t\t{bds.W, bds.N},\n\t\t\t{bds.E, bds.N},\n\t\t},\n\t}\n\n}", "func (p *Polygon) Clear() {\n\tC.geod_polygon_clear(&p.p)\n}", "func (mp MultiPolygon) Polygons() []Polygon {\n\treturn mp\n}", "func (imd *IMDraw) Polygon(thickness float64) {\n\tif thickness == 0 {\n\t\timd.fillPolygon()\n\t} else {\n\t\timd.polyline(thickness, true)\n\t}\n}", "func (s *DatatypeGeoShape) Source(includeName bool) (interface{}, error) {\n\t// {\n\t// \t\"test\": {\n\t// \t\t\"type\": \"geo_shape\",\n\t// \t\t\"copy_to\": [\"field_1\", \"field_2\"],\n\t// \t\t\"tree\": \"quadtree\",\n\t// \t\t\"precision\": \"50m\",\n\t// \t\t\"tree_levels\": \"various\",\n\t// \t\t\"strategy\": \"recursive\",\n\t// \t\t\"distance_error_pct\": 0.0,\n\t// \t\t\"orientation\": \"ccw\",\n\t// \t\t\"points_only\": true,\n\t// \t\t\"ignore_malformed\": true,\n\t// \t\t\"ignore_z_value\": true,\n\t// \t\t\"coerce\": true\n\t// \t}\n\t// }\n\toptions := make(map[string]interface{})\n\toptions[\"type\"] = \"geo_shape\"\n\n\tif len(s.copyTo) > 0 {\n\t\tvar copyTo interface{}\n\t\tswitch {\n\t\tcase len(s.copyTo) > 1:\n\t\t\tcopyTo = s.copyTo\n\t\t\tbreak\n\t\tcase len(s.copyTo) == 1:\n\t\t\tcopyTo = s.copyTo[0]\n\t\t\tbreak\n\t\tdefault:\n\t\t\tcopyTo = \"\"\n\t\t}\n\t\toptions[\"copy_to\"] = copyTo\n\t}\n\tif s.tree != \"\" {\n\t\toptions[\"tree\"] = s.tree\n\t}\n\tif s.precision != \"\" {\n\t\toptions[\"precision\"] = s.precision\n\t}\n\tif s.treeLevels != \"\" {\n\t\toptions[\"tree_levels\"] = s.treeLevels\n\t}\n\tif s.strategy != \"\" {\n\t\toptions[\"strategy\"] = s.strategy\n\t}\n\tif s.distanceErrorPct != nil {\n\t\toptions[\"distance_error_pct\"] = s.distanceErrorPct\n\t}\n\tif s.orientation != \"\" {\n\t\toptions[\"orientation\"] = s.orientation\n\t}\n\tif s.pointsOnly != nil {\n\t\toptions[\"points_only\"] = s.pointsOnly\n\t}\n\tif s.ignoreMalformed != nil {\n\t\toptions[\"ignore_malformed\"] = s.ignoreMalformed\n\t}\n\tif s.ignoreZValue != nil {\n\t\toptions[\"ignore_z_value\"] = s.ignoreZValue\n\t}\n\tif s.coerce != nil {\n\t\toptions[\"coerce\"] = s.coerce\n\t}\n\n\tif !includeName {\n\t\treturn options, nil\n\t}\n\n\tsource := make(map[string]interface{})\n\tsource[s.name] = options\n\treturn source, nil\n}", "func PolygonOffset(factor float32, units float32) {\n C.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func (self *Graphics) DrawPolygonI(args ...interface{}) *Graphics{\n return &Graphics{self.Object.Call(\"drawPolygon\", args)}\n}", "func Decode_Polygon(geom []uint32) [][][][]int {\n\tpos := 0\n\tcurrentpt := []int{0, 0}\n\tnewline := [][]int{}\n\tpolygons := [][][][]int{}\n\tfor pos < len(geom) {\n\t\tgeomval := geom[pos]\n\n\t\tcmd, length := Get_Command_Length(geomval)\n\n\t\t// conde for a move to cmd\n\t\tif cmd == 1 {\n\t\t\txdelta := DecodeDelta(geom[pos+1])\n\t\t\tydelta := DecodeDelta(geom[pos+2])\n\t\t\tcurrentpt = []int{currentpt[0] + xdelta, currentpt[1] + ydelta}\n\t\t\t//fmt.Println(firstpt)\n\t\t\tpos += 2\n\n\t\t} else if cmd == 2 {\n\t\t\tnewline = [][]int{currentpt}\n\t\t\tcurrentpos := pos + 1\n\t\t\tendpos := currentpos + int(length*2)\n\t\t\tfor currentpos < endpos {\n\t\t\t\txdelta := DecodeDelta(geom[currentpos])\n\t\t\t\tydelta := DecodeDelta(geom[currentpos+1])\n\t\t\t\tcurrentpt = []int{currentpt[0] + xdelta, currentpt[1] + ydelta}\n\t\t\t\tnewline = append(newline, currentpt)\n\t\t\t\tcurrentpos += 2\n\t\t\t}\n\n\t\t\tpos = currentpos - 1\n\n\t\t} else if cmd == 7 {\n\t\t\t//newline = append(newline,newline[0])\n\t\t\tif Exterior_Ring(newline) == false {\n\t\t\t\tpolygons = append(polygons, [][][]int{newline})\n\t\t\t\tnewline = [][]int{}\n\t\t\t} else {\n\t\t\t\tif len(polygons) == 0 {\n\t\t\t\t\tpolygons = append(polygons, [][][]int{newline})\n\n\t\t\t\t} else {\n\t\t\t\t\tpolygons[len(polygons)-1] = append(polygons[len(polygons)-1], newline)\n\n\t\t\t\t}\n\t\t\t\tnewline = [][]int{}\n\t\t\t}\n\n\t\t}\n\n\t\t//fmt.Println(cmd,length)\n\t\tpos += 1\n\t}\n\n\treturn polygons\n}", "func fillPolygon(c vg.Canvas, clr color.Color, pts []vg.Point) {\n\tif len(pts) == 0 {\n\t\treturn\n\t}\n\n\tc.SetColor(clr)\n\tp := make(vg.Path, 0, len(pts)+1)\n\tp.Move(pts[0])\n\tfor _, pt := range pts[1:] {\n\t\tp.Line(pt)\n\t}\n\tp.Close()\n\tc.Fill(p)\n}", "func (t *Table) Polygon(colNm string) *Table {\n\tt.columns = append(t.columns, &column{Name: colNm, ColumnType: TypePolygon})\n\treturn t\n}", "func NewPolygon() *Polygon {\n\treturn &Polygon{}\n}", "func PolygonStipple(mask *uint8) {\n C.glowPolygonStipple(gpPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func (s *WeatherData) listAllPolygons(APIstub shim.ChaincodeStubInterface) sc.Response {\n\tfmt.Println(\"============= START : Fetching all polygons =============\")\n\tvar datasource = \"URL\" // Setting the Oraclize datasource\n\tvar query = \"json(http://api.agromonitoring.com/agro/1.0/polygons?appid=\" + API_KEY + \")\" // Setting the query\n\tresult, proof := oraclizeapi.OraclizeQuery_sync(APIstub, datasource, query, oraclizeapi.TLSNOTARY)\n\tfmt.Printf(\"proof: %s\", proof)\n\tfmt.Printf(\"\\nresult: %s\\n\", result)\n\tvar response = {\n\t\t\"result\": result,\n\t\t\"proof\": proof\n\t}", "func NewPolygon(latlngs []*LatLng) *Polygon {\n\tInitialize()\n\treturn &Polygon{\n\t\tPolyline: Polyline{\n\t\t\tPath: Path{\n\t\t\t\tLayer: Layer{\n\t\t\t\t\tValue: L.Call(\"polygon\", latlngs),\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t}\n}", "func (pp *privPath) bestpolygon() {\n\t//int i, j, m, k;\n\tn := len(pp.Pt)\n\tvar (\n\t\tpen = make([]float64, n+1) // penalty vector\n\t\tprev = make([]int, n+1) // best path pointer vector\n\t\tclip0 = make([]int, n) // longest segment pointer, non-cyclic\n\t\tclip1 = make([]int, n+1) // backwards segment pointer, non-cyclic\n\t\tseg0 = make([]int, n+1) // forward segment bounds, m<=n\n\t\tseg1 = make([]int, n+1) // backward segment bounds, m<=n\n\t\tthispen float64\n\t\tbest float64\n\t\tc int\n\t)\n\n\t// calculate clipped paths\n\tfor i := 0; i < n; i++ {\n\t\tc = mod(pp.Lon[mod(i-1, n)]-1, n)\n\t\tif c == i {\n\t\t\tc = mod(i+1, n)\n\t\t}\n\t\tif c < i {\n\t\t\tclip0[i] = n\n\t\t} else {\n\t\t\tclip0[i] = c\n\t\t}\n\t}\n\n\t// calculate backwards path clipping, non-cyclic. j <= clip0[i] iff clip1[j] <= i, for i,j=0..n.\n\tj := 1\n\tfor i := 0; i < n; i++ {\n\t\tfor j <= clip0[i] {\n\t\t\tclip1[j] = i\n\t\t\tj++\n\t\t}\n\t}\n\n\t// calculate seg0[j] = longest path from 0 with j segments\n\ti := 0\n\tfor j = 0; i < n; j++ {\n\t\tseg0[j] = i\n\t\ti = clip0[i]\n\t}\n\tseg0[j] = n\n\tm := j\n\n\t// calculate seg1[j] = longest path to n with m-j segments\n\ti = n\n\tfor j = m; j > 0; j-- {\n\t\tseg1[j] = i\n\t\ti = clip1[i]\n\t}\n\tseg1[0] = 0\n\n\t// now find the shortest path with m segments, based on penalty3\n\t// note: the outer 2 loops jointly have at most n iterations, thus\n\t// the worst-case behavior here is quadratic. In practice, it is\n\t// close to linear since the inner loop tends to be short.\n\tpen[0] = 0\n\tfor j = 1; j <= m; j++ {\n\t\tfor i = seg1[j]; i <= seg0[j]; i++ {\n\t\t\tbest = -1\n\t\t\tfor k := seg0[j-1]; k >= clip1[i]; k-- {\n\t\t\t\tthispen = penalty3(pp, k, i) + pen[k]\n\t\t\t\tif best < 0 || thispen < best {\n\t\t\t\t\tprev[i] = k\n\t\t\t\t\tbest = thispen\n\t\t\t\t}\n\t\t\t}\n\t\t\tpen[i] = best\n\t\t}\n\t}\n\n\tpp.Po = make([]int, m)\n\n\t// read off shortest path\n\tfor i, j = n, m-1; i > 0; j-- {\n\t\ti = prev[i]\n\t\tpp.Po[j] = i\n\t}\n}", "func LayerKeyModeByName(name string) (LayerKeyMode, error) {\n\tswitch name {\n\tcase \"L2\":\n\t\treturn L2KeyMode, nil\n\tcase \"L3\":\n\t\treturn L3PreferredKeyMode, nil\n\t}\n\treturn L2KeyMode, errors.New(\"LayerKeyMode unknown\")\n}", "func GetPolygonStipple(mask *uint8) {\n\tC.glowGetPolygonStipple(gpGetPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func (order Order) RectifyPolygon(plyg2r [][][2]float64) [][][2]float64 {\n\tplyg := make([][][2]float64, 0, len(plyg2r))\n\treverse := func(idx int) {\n\t\tfor i := len(plyg[idx])/2 - 1; i >= 0; i-- {\n\t\t\topp := len(plyg[idx]) - 1 - i\n\t\t\tplyg[idx][i], plyg[idx][opp] = plyg[idx][opp], plyg[idx][i]\n\t\t}\n\t}\n\n\t// Let's make sure each of the rings have the correct windingorder.\n\n\tfor i := range plyg2r {\n\n\t\two := order.OfPoints(plyg2r[i]...)\n\n\t\t// Drop collinear rings\n\t\tif wo.IsColinear() {\n\t\t\tif i == 0 {\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\n\t\tplyg = append(plyg, plyg2r[i])\n\n\t\tif (i == 0 && wo.IsCounterClockwise()) || (i != 0 && wo.IsClockwise()) {\n\t\t\t// 0 ring should be clockwise.\n\t\t\t// all others should be conterclockwise\n\t\t\t// reverse the ring.\n\t\t\treverse(len(plyg) - 1)\n\t\t}\n\t}\n\treturn plyg\n}", "func (s *CubicSplineSDF2) Polygonize(n int) *Polygon {\n\tp := NewPolygon()\n\tdt := float64(len(s.spline)) / float64(n-1)\n\tt := 0.0\n\tfor i := 0; i < n; i++ {\n\t\tp.AddV2(s.f0(t))\n\t\tt += dt\n\t}\n\treturn p\n}", "func NewPolygon() *Polygon {\n\tthis := Polygon{}\n\treturn &this\n}", "func PolygonOffset(factor, units float32) {\n\tgl.PolygonOffset(factor, units)\n}", "func (this *Poly) setArea(a int) {\n\tthis.areaAndtype = (this.areaAndtype & 0xc0) | (a & 0x3f)\n}", "func Lint_Polygon_Layer_Map(layer []l.Polygon) []l.Polygon {\n\tvar newlayer []l.Polygon\n\tfor _, feat := range layer {\n\t\tif len(feat.Layers) == 0 {\n\t\t\tarea := feat.Area\n\t\t\tlayer := feat.Layer\n\t\t\tfeat.Area = fmt.Sprintf(\"{'%s':'%s'}\", area, layer)\n\t\t} else {\n\t\t\tnewlist := []string{}\n\t\t\tfor k, v := range feat.Layers {\n\t\t\t\tnewlist = append(newlist, fmt.Sprintf(\"'%s':'%s'\", k, v))\n\t\t\t}\n\t\t\tfeat.Area = fmt.Sprintf(\"{%s}\", strings.Join(newlist, \",\"))\n\t\t}\n\t\tnewlayer = append(newlayer, feat)\n\n\t}\n\treturn newlayer\n}", "func (g *Pin) PinMode(pin GpioId, mode PinMode, activeLow ...bool){\n\tg.pin = pin\n\tg.mode = mode\n\n\ts := []string{PATH_PREFIX,strconv.Itoa(int(g.pin)),\"/\"}\n \tg.path = strings.Join(s,\"\")\n\n\tif len(activeLow) > 0 {\n\t\tg.activeLow = activeLow[0]\n\t}\n\n\tg.export()\n\treturn\n}", "func UnmarshalPolygon(s string) (p orb.Polygon, srid int, err error) {\n\ts, srid, err = splitEWKT(s)\n\tif err != nil {\n\t\treturn orb.Polygon{}, 0, wkt.ErrWrap(err, errInvalidSRID)\n\t}\n\tp, err = wkt2.UnmarshalPolygon(s)\n\treturn p, srid, err\n}", "func (this *DtPoly) GetType() DtPolyTypes {\n\treturn DtPolyTypes(this.AreaAndtype >> 6)\n}", "func (b *Blueprint) MultiPolygon(column string) *ColumnDefinition {\n\treturn b.addColumn(\"multipolygon\", column, nil)\n}", "func (self *TileSprite) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func (this *DtNavMeshQuery) queryPolygonsInTile(tile *DtMeshTile, qmin, qmax []float32,\n\tfilter *DtQueryFilter, query DtPolyQuery) {\n\tDtAssert(this.m_nav != nil)\n\tconst batchSize int = 32\n\tvar polyRefs [batchSize]DtPolyRef\n\tvar polys [batchSize]*DtPoly\n\tn := 0\n\n\tif tile.BvTree != nil {\n\t\tnodeIndex := 0\n\t\tendIndex := int(tile.Header.BvNodeCount)\n\t\ttbmin := tile.Header.Bmin[:]\n\t\ttbmax := tile.Header.Bmax[:]\n\t\tqfac := tile.Header.BvQuantFactor\n\n\t\t// Calculate quantized box\n\t\tvar bmin, bmax [3]uint16\n\t\t// dtClamp query box to world box.\n\t\tminx := DtClampFloat32(qmin[0], tbmin[0], tbmax[0]) - tbmin[0]\n\t\tminy := DtClampFloat32(qmin[1], tbmin[1], tbmax[1]) - tbmin[1]\n\t\tminz := DtClampFloat32(qmin[2], tbmin[2], tbmax[2]) - tbmin[2]\n\t\tmaxx := DtClampFloat32(qmax[0], tbmin[0], tbmax[0]) - tbmin[0]\n\t\tmaxy := DtClampFloat32(qmax[1], tbmin[1], tbmax[1]) - tbmin[1]\n\t\tmaxz := DtClampFloat32(qmax[2], tbmin[2], tbmax[2]) - tbmin[2]\n\t\t// Quantize\n\t\tbmin[0] = (uint16)(qfac*minx) & 0xfffe\n\t\tbmin[1] = (uint16)(qfac*miny) & 0xfffe\n\t\tbmin[2] = (uint16)(qfac*minz) & 0xfffe\n\t\tbmax[0] = (uint16)(qfac*maxx+1) | 1\n\t\tbmax[1] = (uint16)(qfac*maxy+1) | 1\n\t\tbmax[2] = (uint16)(qfac*maxz+1) | 1\n\n\t\t// Traverse tree\n\t\tbase := this.m_nav.GetPolyRefBase(tile)\n\t\tfor nodeIndex < endIndex {\n\t\t\tnode := &tile.BvTree[nodeIndex]\n\t\t\toverlap := DtOverlapQuantBounds(bmin[:], bmax[:], node.Bmin[:], node.Bmax[:])\n\t\t\tisLeafNode := (node.I >= 0)\n\n\t\t\tif isLeafNode && overlap {\n\t\t\t\tref := base | (DtPolyRef)(node.I)\n\t\t\t\tif filter.PassFilter(ref, tile, &tile.Polys[node.I]) {\n\t\t\t\t\tpolyRefs[n] = ref\n\t\t\t\t\tpolys[n] = &tile.Polys[node.I]\n\n\t\t\t\t\tif n == batchSize-1 {\n\t\t\t\t\t\tquery.Process(tile, polys[:], polyRefs[:], batchSize)\n\t\t\t\t\t\tn = 0\n\t\t\t\t\t} else {\n\t\t\t\t\t\tn++\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif overlap || isLeafNode {\n\t\t\t\tnodeIndex++\n\t\t\t} else {\n\t\t\t\tescapeIndex := int(-node.I)\n\t\t\t\tnodeIndex += escapeIndex\n\t\t\t}\n\t\t}\n\t} else {\n\t\tvar bmin, bmax [3]float32\n\t\tbase := this.m_nav.GetPolyRefBase(tile)\n\t\tfor i := 0; i < int(tile.Header.PolyCount); i++ {\n\t\t\tp := &tile.Polys[i]\n\t\t\t// Do not return off-mesh connection polygons.\n\t\t\tif p.GetType() == DT_POLYTYPE_OFFMESH_CONNECTION {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// Must pass filter\n\t\t\tref := base | (DtPolyRef)(i)\n\t\t\tif !filter.PassFilter(ref, tile, p) {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// Calc polygon bounds.\n\t\t\tv := tile.Verts[p.Verts[0]*3:]\n\t\t\tDtVcopy(bmin[:], v)\n\t\t\tDtVcopy(bmax[:], v)\n\t\t\tfor j := 1; j < int(p.VertCount); j++ {\n\t\t\t\tv = tile.Verts[p.Verts[j]*3:]\n\t\t\t\tDtVmin(bmin[:], v)\n\t\t\t\tDtVmax(bmax[:], v)\n\t\t\t}\n\t\t\tif DtOverlapBounds(qmin, qmax, bmin[:], bmax[:]) {\n\t\t\t\tpolyRefs[n] = ref\n\t\t\t\tpolys[n] = p\n\n\t\t\t\tif n == batchSize-1 {\n\t\t\t\t\tquery.Process(tile, polys[:], polyRefs[:], batchSize)\n\t\t\t\t\tn = 0\n\t\t\t\t} else {\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Process the last polygons that didn't make a full batch.\n\tif n > 0 {\n\t\tquery.Process(tile, polys[:], polyRefs[:], n)\n\t}\n}", "func (o StreamProcessorOutput) PolygonRegionsOfInterest() StreamProcessorPointArrayArrayOutput {\n\treturn o.ApplyT(func(v *StreamProcessor) StreamProcessorPointArrayArrayOutput { return v.PolygonRegionsOfInterest }).(StreamProcessorPointArrayArrayOutput)\n}", "func PolygonOffset(factor Float, units Float) {\n\tcfactor, _ := (C.GLfloat)(factor), cgoAllocsUnknown\n\tcunits, _ := (C.GLfloat)(units), cgoAllocsUnknown\n\tC.glPolygonOffset(cfactor, cunits)\n}", "func (this *Poly) getArea() int {\n\treturn this.areaAndtype & 0x3f\n}", "func (this *DtPoly) SetType(t DtPolyTypes) {\n\tthis.AreaAndtype = (this.AreaAndtype & 0x3f) | (uint8(t) << 6)\n}", "func PolygonStipple(mask *uint8) {\n\tC.glowPolygonStipple(gpPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func ExampleFacettedPolygon() {\n\tf := FacettedNib{LineNib: LineNib{unitX, unitY}}\n\tPrintGraph(f.Polygon([][2]x{{0, 0}, {5 * unitX, 5 * unitX}, {5 * unitX, -5 * unitX}}...), -10*unitX, 10*unitX, -10*unitX, 10*unitX, unitX)\n\t// Output:\n\t/*\n\t\tGraph\n\t\t -10\t---------------------\n\t\t -9\t---------------------\n\t\t -8\t---------------------\n\t\t -7\t---------------------\n\t\t -6\t---------------------\n\t\t -5\t---------------X-----\n\t\t -4\t--------------XX-----\n\t\t -3\t-------------X-X-----\n\t\t -2\t------------X--X-----\n\t\t -1\t-----------X---X-----\n\t\t 0\t----------X----X-----\n\t\t 1\t-----------X---X-----\n\t\t 2\t------------X--X-----\n\t\t 3\t-------------X-X-----\n\t\t 4\t--------------XX-----\n\t\t 5\t---------------X-----\n\t\t 6\t---------------------\n\t\t 7\t---------------------\n\t\t 8\t---------------------\n\t\t 9\t---------------------\n\t\t 10\t---------------------\n\t*/\n}", "func CullFace(mode uint32) {\n C.glowCullFace(gpCullFace, (C.GLenum)(mode))\n}", "func SetMode(value string) {\n\trgin.SetMode(value)\n}", "func ImportGeoJSONFile(filename string, debug bool, fields []string) error {\n\tvar loopID int\n\n\tb, err := ioutil.ReadFile(filename)\n\tif err != nil {\n\t\treturn err\n\t}\n\tvar geo geojson.FeatureCollection\n\n\terr = json.Unmarshal(b, &geo)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tvar geoData GeoData\n\n\tcl := make(map[s2.CellID][]int)\n\n\tfor _, f := range geo.Features {\n\t\tgeom, err := f.GetGeometry()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\trc := &s2.RegionCoverer{MinLevel: 1, MaxLevel: 30, MaxCells: 8}\n\n\t\tswitch geom.GetType() {\n\t\tcase \"Polygon\":\n\t\t\tmp := geom.(*geojson.Polygon)\n\t\t\t// multipolygon\n\t\t\tfor _, p := range mp.Coordinates {\n\t\t\t\t// polygon\n\t\t\t\tvar points []s2.Point\n\t\t\t\tvar cpoints []CPoint\n\t\t\t\t// For type \"MultiPolygon\", the \"coordinates\" member must be an array of Polygon coordinate arrays.\n\t\t\t\t// \"Polygon\", the \"coordinates\" member must be an array of LinearRing coordinate arrays.\n\t\t\t\t// For Polygons with multiple rings, the first must be the exterior ring and any others must be interior rings or holes.\n\n\n\t\t\t\t// reverse the slice\n\t\t\t\tfor i := len(p)/2 - 1; i >= 0; i-- {\n\t\t\t\t\topp := len(p) - 1 - i\n\t\t\t\t\tp[i], p[opp] = p[opp], p[i]\n\t\t\t\t}\n\n\t\t\t\tfor i, c := range p {\n\t\t\t\t\tll := s2.LatLngFromDegrees(float64(c[1]), float64(c[0]))\n\t\t\t\t\tpoint := s2.PointFromLatLng(ll)\n\t\t\t\t\tpoints = append(points, point)\n\t\t\t\t\t// do not add cpoint on storage (first point is last point)\n\t\t\t\t\tif i == len(p)-1 {\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t\tcpoints = append(cpoints, CPoint{Coordinate: []float64{float64(c[1]), float64(c[0])}})\n\t\t\t\t}\n\n\t\t\t\tl := LoopRegionFromPoints(points)\n\n\t\t\t\tif l.IsEmpty() || l.IsFull() {\n\t\t\t\t\tlog.Println(\"invalid loop\")\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tcovering := rc.Covering(l)\n\n\t\t\t\tdata := make(map[string]string)\n\t\t\t\tfor _, field := range fields {\n\t\t\t\t\tif v, ok := f.Properties[field].(string); !ok {\n\t\t\t\t\t\tlog.Println(\"can't find field on\", f.Properties)\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdata[field] = v\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif debug {\n\t\t\t\t\tfmt.Println(\"import\", loopID, data)\n\t\t\t\t}\n\n\t\t\t\tr := RegionStorage{\n\t\t\t\t\tData: data,\n\t\t\t\t\tPoints: cpoints,\n\t\t\t\t\tCellUnion: covering,\n\t\t\t\t}\n\n\t\t\t\tgeoData.RS = append(geoData.RS, r)\n\n\t\t\t\tfor _, cell := range covering {\n\t\t\t\t\tcl[cell] = append(cl[cell], loopID)\n\t\t\t\t}\n\n\t\t\t\tloopID = loopID + 1\n\t\t\t}\n\n\t\tcase \"MultiPolygon\":\n\t\t\tmp := geom.(*geojson.MultiPolygon)\n\t\t\t// multipolygon\n\t\t\tfor _, m := range mp.Coordinates {\n\t\t\t\t// polygon\n\t\t\t\tvar points []s2.Point\n\t\t\t\tvar cpoints []CPoint\n\t\t\t\t// For type \"MultiPolygon\", the \"coordinates\" member must be an array of Polygon coordinate arrays.\n\t\t\t\t// \"Polygon\", the \"coordinates\" member must be an array of LinearRing coordinate arrays.\n\t\t\t\t// For Polygons with multiple rings, the first must be the exterior ring and any others must be interior rings or holes.\n\n\t\t\t\tif len(m) < 1 {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tp := m[0]\n\t\t\t\t// coordinates\n\n\t\t\t\t// reverse the slice\n\t\t\t\tfor i := len(p)/2 - 1; i >= 0; i-- {\n\t\t\t\t\topp := len(p) - 1 - i\n\t\t\t\t\tp[i], p[opp] = p[opp], p[i]\n\t\t\t\t}\n\n\t\t\t\tfor i, c := range p {\n\t\t\t\t\tll := s2.LatLngFromDegrees(float64(c[1]), float64(c[0]))\n\t\t\t\t\tpoint := s2.PointFromLatLng(ll)\n\t\t\t\t\tpoints = append(points, point)\n\t\t\t\t\t// do not add cpoint on storage (first point is last point)\n\t\t\t\t\tif i == len(p)-1 {\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t\tcpoints = append(cpoints, CPoint{Coordinate: []float64{float64(c[1]), float64(c[0])}})\n\t\t\t\t}\n\n\t\t\t\tl := LoopRegionFromPoints(points)\n\n\t\t\t\tif l.IsEmpty() || l.IsFull() {\n\t\t\t\t\tlog.Println(\"invalid loop\")\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tcovering := rc.Covering(l)\n\n\t\t\t\tdata := make(map[string]string)\n\t\t\t\tfor _, field := range fields {\n\t\t\t\t\tif v, ok := f.Properties[field].(string); !ok {\n\t\t\t\t\t\tlog.Println(\"can't find field on\", f.Properties)\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdata[field] = v\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif debug {\n\t\t\t\t\tfmt.Println(\"import\", loopID, data)\n\t\t\t\t}\n\n\t\t\t\tr := RegionStorage{\n\t\t\t\t\tData: data,\n\t\t\t\t\tPoints: cpoints,\n\t\t\t\t\tCellUnion: covering,\n\t\t\t\t}\n\n\t\t\t\tgeoData.RS = append(geoData.RS, r)\n\n\t\t\t\tfor _, cell := range covering {\n\t\t\t\t\tcl[cell] = append(cl[cell], loopID)\n\t\t\t\t}\n\n\t\t\t\tloopID = loopID + 1\n\t\t\t}\n\t\tdefault:\n\t\t\treturn errors.New(\"unknown type\")\n\t\t}\n\n\t}\n\n\tfor k, v := range cl {\n\t\tgeoData.CL = append(geoData.CL, CellIDLoopStorage{C: k, Loops: v})\n\t}\n\n\tlog.Println(\"imported\", filename, len(geoData.RS), \"regions\")\n\n\tb, err = msgpack.Marshal(geoData)\n\tif err != nil {\n\t\treturn err\n\t}\n\terr = ioutil.WriteFile(\"geodata\", b, 0644)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func BlendEquation(mode uint32) {\n C.glowBlendEquation(gpBlendEquation, (C.GLenum)(mode))\n}", "func NewStrictPolygon(bounds floatgeom.Rect2, points ...floatgeom.Point2) (*Polygon, error) {\n\tif len(points) < 3 {\n\t\treturn nil, oakerr.InsufficientInputs{AtLeast: 3, InputName: \"points\"}\n\t}\n\treturn &Polygon{\n\t\tSprite: NewSprite(bounds.Min.X(), bounds.Min.Y(),\n\t\t\timage.NewRGBA(image.Rect(0, 0, int(bounds.W()), int(bounds.H())))),\n\t\tRect2: bounds,\n\t\tpoints: points,\n\t}, nil\n}", "func PolygonOffset(factor float32, units float32) {\n\tC.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func PolygonOffset(factor float32, units float32) {\n\tC.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func Make_Layer_Rect_Xmap(tile m.TileID, finds []l.Polygon) Tile_Xmap {\n\tnewlist := []l.Polygon{}\n\n\t// getting rectangle\n\tfirst := l.Polygon{Polygon: Make_Tile_Poly(tile)}\n\t//first.Polygon.Add(val)\n\tval := first.Polygon[0]\n\tval = pc.Contour{val[0], val[1], val[2], val[3], val[2], val[1], val[0]}\n\tfirst.Polygon.Add(val)\n\t// iterating through each found area\n\tfor _, i := range finds {\n\t\ti.Polygon.Add(val)\n\t\t//if IsReachable(first, i, \"INTERSECTION\") == true {\n\t\tresult := first.Polygon.Construct(pc.INTERSECTION, i.Polygon)\n\t\t//}\n\n\t\t// adding the the result to newlist if possible\n\t\tif len(result) != 0 {\n\t\t\tamap := map[string]string{}\n\t\t\tamap[i.Layer] = i.Area\n\t\t\tamap[\"tile\"] = m.Tilestr(tile)\n\n\t\t\t//fmt.Print(amap, \"\\n\")\n\t\t\ti.Polygon = result\n\t\t\ti.Layers = amap\n\t\t\tnewlist = append(newlist, i)\n\t\t} else {\n\t\t\t//\tfmt.Print(\"here\\n\", first.Polystring, \"\\n\", i.Polystring, \"\\n\")\n\t\t\t//fmt.Print(\"here\\n\")\n\t\t}\n\n\t}\n\t// linting the output polygons\n\tstringlist := Lint_Layer_Polygons(newlist)\n\n\t// iterating through each value in newlist\n\txmaptotal := map[string][]Yrow{}\n\tfor _, i := range stringlist {\n\t\txmap := Make_Xmap_Total(get_coords_json(i[1]), i[0], tile)\n\t\tfor k, v := range xmap {\n\t\t\txmaptotal[k] = append(xmaptotal[k], v...)\n\t\t}\n\t}\n\tvalbool := false\n\n\tif valbool == true {\n\t\tstringlist2 := []string{\"LONG,LAT,AREA\"}\n\t\tfor k, v := range xmaptotal {\n\t\t\tx := Get_Middle(k)[0]\n\t\t\tfor _, vv := range v {\n\t\t\t\tarea := strings.Replace(vv.Area, \",\", \"\", -1)\n\t\t\t\tstringlist2 = append(stringlist2, fmt.Sprintf(\"%f,%f,%s\", x, vv.Range[0], area))\n\t\t\t\tstringlist2 = append(stringlist2, fmt.Sprintf(\"%f,%f,%s\", x, vv.Range[1], area))\n\t\t\t}\n\n\t\t}\n\t\t//fmt.Print(xmap, \"\\n\")\n\t\tbds := m.Bounds(tile)\n\t\tcount := 0\n\t\tlatconst := bds.N\n\n\t\tfor count < 100000 {\n\t\t\tcount += 1\n\t\t\tpt := RandomPt(bds)\n\t\t\tareat := strings.Replace(Pip_Simple(pt, xmaptotal, latconst), \",\", \"\", -1)\n\t\t\tfmt.Print(areat)\n\t\t\tif areat != \"\" {\n\t\t\t\tfmt.Print(\"Here\\n\")\n\t\t\t\tstringlist2 = append(stringlist2, fmt.Sprintf(\"%f,%f,%s\", pt[0], pt[1], areat))\n\t\t\t}\n\t\t}\n\n\t\ta := strings.Join(stringlist2, \"\\n\")\n\t\tff, _ := os.Create(\"d.csv\")\n\t\tff.WriteString(a)\n\t\tfmt.Print(a, \"\\n\")\n\t}\n\t//ff, _ := os.Create(\"d.csv\")\n\t//ff.WriteString(a)\n\treturn Tile_Xmap{Tile: tile, Xmap: xmaptotal}\n}", "func (c *Context) rasterize(glyph truetype.Index, fx, fy fixed.Int26_6) (\n\tfixed.Int26_6, *image.Alpha, image.Point, error) {\n\n\tif err := c.glyphBuf.Load(c.f, c.scale, glyph, c.hinting); err != nil {\n\t\treturn 0, nil, image.Point{}, err\n\t}\n\txmin := int(fx+c.glyphBuf.Bounds.Min.X) >> 6\n\tymin := int(fy-c.glyphBuf.Bounds.Max.Y) >> 6\n\txmax := int(fx+c.glyphBuf.Bounds.Max.X+0x3f) >> 6\n\tymax := int(fy-c.glyphBuf.Bounds.Min.Y+0x3f) >> 6\n\tif xmin > xmax || ymin > ymax {\n\t\treturn 0, nil, image.Point{}, errors.New(\"freetype: negative sized glyph\")\n\t}\n\tfx -= fixed.Int26_6(xmin << 6)\n\tfy -= fixed.Int26_6(ymin << 6)\n\tc.r.Clear()\n\te0 := 0\n\tfor _, e1 := range c.glyphBuf.Ends {\n\t\tc.drawContour(c.glyphBuf.Points[e0:e1], fx, fy)\n\t\te0 = e1\n\t}\n\ta := image.NewAlpha(image.Rect(0, 0, xmax-xmin, ymax-ymin))\n\tc.r.Rasterize(raster.NewAlphaSrcPainter(a))\n\treturn c.glyphBuf.AdvanceWidth, a, image.Point{xmin, ymin}, nil\n}", "func MultiPolygon(mp orb.MultiPolygon, z maptile.Zoom) (maptile.Set, error) {\n\tset := make(maptile.Set)\n\tfor _, p := range mp {\n\t\terr := polygon(set, p, z)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\treturn set, nil\n}", "func (p WOFPointInPolygon) InflateSpatialResults(results []rtreego.Spatial) []*geojson.WOFSpatial {\n\n\tinflated := make([]*geojson.WOFSpatial, 0)\n\n\tfor _, r := range results {\n\n\t\t// https://golang.org/doc/effective_go.html#interface_conversions\n\t\twof := r.(*geojson.WOFSpatial)\n\t\tinflated = append(inflated, wof)\n\t}\n\n\treturn inflated\n}", "func (db *DB) GetPolygons(p *model.PolygonSummary) error {\n\ttx, err := db.Begin()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tpoly, err := tx.Query(\n\t\t`SELECT array_to_string(array_agg, ',') FROM \n\t\t(SELECT array_agg( ST_x(geom)||' '||ST_y(geom)) FROM \n\t\t\t(SELECT (ST_dumppoints(polygon)).geom FROM CLIENT_POLYGON\n\t\t\t) AS foo_1\n\t\t) AS foo_2;`)\n\n\tfor poly.Next() {\n\t\terr = poly.Scan(\n\t\t\t&p.PolygonSummary,\n\t\t)\n\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\terr = poly.Err()\n\tif err != nil {\n\t\ttx.Rollback()\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func SetStencilFunc(_func Enum, ref Int, mask Uint) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tcref, _ := (C.GLint)(ref), cgoAllocsUnknown\n\tcmask, _ := (C.GLuint)(mask), cgoAllocsUnknown\n\tC.glStencilFunc(c_func, cref, cmask)\n}", "func (s *square) getRegion() error {\n\treg := region{}\n\tswitch {\n\tcase s.pos.rowNumber >= 0 && s.pos.rowNumber <= 2:\n\t\treg.minRowNumber = 0\n\t\treg.maxRowNumber = 2\n\tcase s.pos.rowNumber >= 3 && s.pos.rowNumber <= 5:\n\t\treg.minRowNumber = 3\n\t\treg.maxRowNumber = 5\n\tcase s.pos.rowNumber >= 6 && s.pos.rowNumber <= 8:\n\t\treg.minRowNumber = 6\n\t\treg.maxRowNumber = 8\n\tdefault:\n\t\treturn fmt.Errorf(\"rowNumber %d is invalid\", s.pos.rowNumber)\n\t}\n\n\tswitch {\n\tcase s.pos.colNumber >= 0 && s.pos.colNumber <= 2:\n\t\treg.minColNumber = 0\n\t\treg.maxColNumber = 2\n\tcase s.pos.colNumber >= 3 && s.pos.colNumber <= 5:\n\t\treg.minColNumber = 3\n\t\treg.maxColNumber = 5\n\tcase s.pos.colNumber >= 6 && s.pos.colNumber <= 8:\n\t\treg.minColNumber = 6\n\t\treg.maxColNumber = 8\n\tdefault:\n\t\treturn fmt.Errorf(\"colNumber %d is invalid\", s.pos.colNumber)\n\t}\n\ts.reg = reg\n\treturn nil\n}", "func Polygon(children ...Element) *CompoundElement { return newCE(\"Polygon\", children) }", "func nativeLayer() native { return &lin{} }", "func C_spatial_segment(sted, prov int) int {\n\tswitch {\n\tcase sted == 0:\n\t\treturn 0\n\tcase sted == 1:\n\t\treturn 1\n\tcase sted == 2:\n\t\treturn 2\n\tcase prov == 4 || prov == 9 || prov == 11 || prov == 12:\n\t\treturn 4\n\tdefault:\n\t\treturn 3\n\t}\n}", "func (self *Graphics) SetBlendModeA(member int) {\n self.Object.Set(\"blendMode\", member)\n}", "func encodeGeometry(ctx context.Context, geometry geom.Geometry) (g []uint32, vtyp vectorTile.Tile_GeomType, err error) {\n\tif geometry == nil {\n\t\treturn nil, vectorTile.Tile_UNKNOWN, ErrNilGeometryType\n\t}\n\n\tc := NewCursor()\n\n\tswitch t := geometry.(type) {\n\tcase geom.Point:\n\t\tg = append(g, c.MoveTo(t)...)\n\t\treturn g, vectorTile.Tile_POINT, nil\n\n\tcase geom.MultiPoint:\n\t\tg = append(g, c.MoveTo(t.Points()...)...)\n\t\treturn g, vectorTile.Tile_POINT, nil\n\n\tcase geom.LineString:\n\t\tpoints := t.Verticies()\n\t\tg = append(g, c.MoveTo(points[0])...)\n\t\tg = append(g, c.LineTo(points[1:]...)...)\n\t\treturn g, vectorTile.Tile_LINESTRING, nil\n\n\tcase geom.MultiLineString:\n\t\tlines := t.LineStrings()\n\t\tfor _, l := range lines {\n\t\t\tpoints := geom.LineString(l).Verticies()\n\t\t\tg = append(g, c.MoveTo(points[0])...)\n\t\t\tg = append(g, c.LineTo(points[1:]...)...)\n\t\t}\n\t\treturn g, vectorTile.Tile_LINESTRING, nil\n\n\tcase geom.Polygon:\n\t\t// TODO: Right now c.ScaleGeo() never returns a Polygon, so this is dead code.\n\t\tlines := t.LinearRings()\n\t\tfor _, l := range lines {\n\t\t\tpoints := geom.LineString(l).Verticies()\n\t\t\tg = append(g, c.MoveTo(points[0])...)\n\t\t\tg = append(g, c.LineTo(points[1:]...)...)\n\t\t\tg = append(g, c.ClosePath())\n\t\t}\n\t\treturn g, vectorTile.Tile_POLYGON, nil\n\n\tcase geom.MultiPolygon:\n\t\tpolygons := t.Polygons()\n\t\tfor _, p := range polygons {\n\t\t\tlines := geom.Polygon(p).LinearRings()\n\t\t\tfor _, l := range lines {\n\t\t\t\tpoints := geom.LineString(l).Verticies()\n\t\t\t\tg = append(g, c.MoveTo(points[0])...)\n\t\t\t\tg = append(g, c.LineTo(points[1:]...)...)\n\t\t\t\tg = append(g, c.ClosePath())\n\t\t\t}\n\t\t}\n\t\treturn g, vectorTile.Tile_POLYGON, nil\n\n\tdefault:\n\t\treturn nil, vectorTile.Tile_UNKNOWN, ErrUnknownGeometryType\n\t}\n}", "func ColorMode(value string) *SimpleElement { return newSEString(\"colorMode\", value) }", "func (this *DtNavMesh) queryPolygonsInTile(tile *DtMeshTile, qmin, qmax []float32, polys []DtPolyRef, maxPolys int) int {\n\tif tile.BvTree != nil {\n\t\tnodeIndex := 0\n\t\tendIndex := int(tile.Header.BvNodeCount)\n\t\ttbmin := tile.Header.Bmin[:]\n\t\ttbmax := tile.Header.Bmax[:]\n\t\tqfac := tile.Header.BvQuantFactor\n\n\t\t// Calculate quantized box\n\t\tvar bmin, bmax [3]uint16\n\t\t// dtClamp query box to world box.\n\t\tminx := DtClampFloat32(qmin[0], tbmin[0], tbmax[0]) - tbmin[0]\n\t\tminy := DtClampFloat32(qmin[1], tbmin[1], tbmax[1]) - tbmin[1]\n\t\tminz := DtClampFloat32(qmin[2], tbmin[2], tbmax[2]) - tbmin[2]\n\t\tmaxx := DtClampFloat32(qmax[0], tbmin[0], tbmax[0]) - tbmin[0]\n\t\tmaxy := DtClampFloat32(qmax[1], tbmin[1], tbmax[1]) - tbmin[1]\n\t\tmaxz := DtClampFloat32(qmax[2], tbmin[2], tbmax[2]) - tbmin[2]\n\t\t// Quantize\n\t\tbmin[0] = uint16(qfac*minx) & 0xfffe\n\t\tbmin[1] = uint16(qfac*miny) & 0xfffe\n\t\tbmin[2] = uint16(qfac*minz) & 0xfffe\n\t\tbmax[0] = uint16(qfac*maxx+1) | 1\n\t\tbmax[1] = uint16(qfac*maxy+1) | 1\n\t\tbmax[2] = uint16(qfac*maxz+1) | 1\n\n\t\t// Traverse tree\n\t\tbase := this.GetPolyRefBase(tile)\n\t\tn := 0\n\t\tfor nodeIndex < endIndex {\n\t\t\tnode := &tile.BvTree[nodeIndex]\n\t\t\toverlap := DtOverlapQuantBounds(bmin[:], bmax[:], node.Bmin[:], node.Bmax[:])\n\t\t\tisLeafNode := (node.I >= 0)\n\n\t\t\tif isLeafNode && overlap {\n\t\t\t\tif n < maxPolys {\n\t\t\t\t\tpolys[n] = base | (DtPolyRef)(node.I)\n\t\t\t\t\tn = n + 1\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif overlap || isLeafNode {\n\t\t\t\tnodeIndex++\n\t\t\t} else {\n\t\t\t\tescapeIndex := int(-node.I)\n\t\t\t\tnodeIndex += escapeIndex\n\t\t\t}\n\t\t}\n\n\t\treturn n\n\t} else {\n\t\tvar bmin, bmax [3]float32\n\t\tn := 0\n\t\tbase := this.GetPolyRefBase(tile)\n\t\tfor i := 0; i < int(tile.Header.PolyCount); i++ {\n\t\t\tp := &tile.Polys[i]\n\t\t\t// Do not return off-mesh connection polygons.\n\t\t\tif p.GetType() == DT_POLYTYPE_OFFMESH_CONNECTION {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// Calc polygon bounds.\n\t\t\tv := tile.Verts[p.Verts[0]*3:]\n\t\t\tDtVcopy(bmin[:], v)\n\t\t\tDtVcopy(bmax[:], v)\n\t\t\tfor j := 1; j < int(p.VertCount); j++ {\n\t\t\t\tv = tile.Verts[p.Verts[j]*3:]\n\t\t\t\tDtVmin(bmin[:], v)\n\t\t\t\tDtVmax(bmax[:], v)\n\t\t\t}\n\t\t\tif DtOverlapBounds(qmin, qmax, bmin[:], bmax[:]) {\n\t\t\t\tif n < maxPolys {\n\t\t\t\t\tpolys[n] = base | (DtPolyRef)(i)\n\t\t\t\t\tn = n + 1\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn n\n\t}\n}", "func (o *Polygon) GetType() string {\n\tif o == nil || o.Type == nil {\n\t\tvar ret string\n\t\treturn ret\n\t}\n\treturn *o.Type\n}", "func (b *Blueprint) MultiPolygonZ(column string) *ColumnDefinition {\n\treturn b.addColumn(\"multipolygonz\", column, nil)\n}", "func Poly(p *sdf.Polygon, path string) error {\n\n\tvlist := p.Vertices()\n\tif vlist == nil {\n\t\treturn errors.New(\"no vertices\")\n\t}\n\n\tfmt.Printf(\"rendering %s\\n\", path)\n\td := NewDXF(path)\n\n\tfor i := 0; i < len(vlist)-1; i++ {\n\t\tp0 := vlist[i]\n\t\tp1 := vlist[i+1]\n\t\td.Line(p0, p1)\n\t}\n\n\tif p.Closed() {\n\t\tp0 := vlist[len(vlist)-1]\n\t\tp1 := vlist[0]\n\t\tif !p0.Equals(p1, tolerance) {\n\t\t\td.Line(p0, p1)\n\t\t}\n\t}\n\n\treturn d.Save()\n}", "func (b *Blueprint) Polygon(column string) *ColumnDefinition {\n\treturn b.addColumn(\"polygon\", column, nil)\n}", "func (c *container) Polygon(pts ...Point) *Polygon {\n\tp := &Polygon{Points: pts}\n\tc.contents = append(c.contents, p)\n\n\treturn p\n}" ]
[ "0.6919152", "0.6893959", "0.65704346", "0.6379355", "0.57647014", "0.5743732", "0.5730423", "0.56987244", "0.5472931", "0.5318191", "0.5272084", "0.5144626", "0.51434165", "0.5122657", "0.5079967", "0.50327384", "0.50296843", "0.50275695", "0.49617174", "0.4942237", "0.49104893", "0.4890489", "0.48729107", "0.48678595", "0.48648623", "0.48565066", "0.48412687", "0.48390067", "0.48106366", "0.47780702", "0.4711392", "0.46958527", "0.4694258", "0.46844172", "0.46575096", "0.4653974", "0.46342525", "0.46228698", "0.4621593", "0.46155608", "0.4614683", "0.46144116", "0.4614246", "0.46134853", "0.45918345", "0.45830262", "0.4581213", "0.45709282", "0.4569397", "0.45614618", "0.4560222", "0.45577306", "0.45527062", "0.45412216", "0.45406237", "0.45229426", "0.44859794", "0.4484254", "0.44558096", "0.4440474", "0.44391334", "0.44331598", "0.44323274", "0.43851134", "0.43814787", "0.43579116", "0.43575397", "0.43494904", "0.43491733", "0.43362048", "0.43354002", "0.43306902", "0.43269238", "0.43013585", "0.42944625", "0.4260554", "0.42533058", "0.42500845", "0.42466536", "0.42466536", "0.42394468", "0.4224347", "0.42202726", "0.421885", "0.42164215", "0.4203791", "0.4190889", "0.41848162", "0.41675156", "0.41648382", "0.41644877", "0.41643488", "0.41619837", "0.41542724", "0.41523322", "0.41442314", "0.41381824", "0.41322866", "0.4126813" ]
0.6604887
3
set the scale and units used to calculate depth values
func PolygonOffset(factor float32, units float32) { C.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (tr *trooper) setScale(scale float64) { tr.part.SetScale(scale, scale, scale) }", "func (t *Tree) Scale(s float32) {\n\tif t.Leaf != nil {\n\t\tfor i, x := range t.Leaf.OutputDelta {\n\t\t\tt.Leaf.OutputDelta[i] = x * s\n\t\t}\n\t} else {\n\t\tt.Branch.FalseBranch.Scale(s)\n\t\tt.Branch.TrueBranch.Scale(s)\n\t}\n}", "func Scale(value float64) *SimpleElement { return newSEFloat(\"scale\", value) }", "func Scale(zoom float64) float64 {\n\treturn 256 * math.Pow(2, zoom)\n}", "func (d *Data) setResolution(uuid dvid.UUID, jsonBytes []byte) error {\n\tconfig := make(dvid.NdFloat32, 3)\n\tif err := json.Unmarshal(jsonBytes, &config); err != nil {\n\t\treturn err\n\t}\n\td.Properties.VoxelSize = config\n\treturn datastore.SaveDataByUUID(uuid, d)\n}", "func (v *Vertex) scale(factor float64) {\n\tv.X = v.X * factor\n\tv.Y = v.Y * factor\n}", "func (dw *DrawingWand) Scale(x, y float64) {\n\tC.MagickDrawScale(dw.dw, C.double(x), C.double(y))\n}", "func (ki *KernelInfo) Scale(scale float64, normalizeType KernelNormalizeType) {\n\tC.ScaleKernelInfo(ki.info, C.double(scale), C.GeometryFlags(normalizeType))\n\truntime.KeepAlive(ki)\n}", "func ViewBoundScale(value float64) *SimpleElement { return newSEFloat(\"viewBoundScale\", value) }", "func (c *canvasRenderer) Scale(amount sprec.Vec2) {\n\tc.currentLayer.Transform = sprec.Mat4Prod(\n\t\tc.currentLayer.Transform,\n\t\tsprec.ScaleMat4(amount.X, amount.Y, 1.0),\n\t)\n}", "func (g *GameObject) SetScale(scale float64) {\r\n\tg.Hitbox.maxX *= scale / g.Scale\r\n\tg.Hitbox.maxY *= scale / g.Scale\r\n\tg.Scale = scale\r\n}", "func (v *Vertex) Scale(f float64) {\n v.X = v.X * f\n v.Y = v.Y * f\n}", "func (v *vertex) Scale(f float64) {\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (v *Vertex) Scale(f float64) {\n v.X = v.X * f\n v.Y = v.Y * f\n}", "func (o *Dig) SetDepth(v int32) {\n\to.Depth = v\n}", "func (canvas *Canvas) Scale(x, y float32) {\n\twriteCommand(canvas.contents, \"cm\", x, 0, 0, y, 0, 0)\n}", "func Scale(f float64, d Number) Number {\n\treturn Number{Real: f * d.Real, E1mag: f * d.E1mag, E2mag: f * d.E2mag, E1E2mag: f * d.E1E2mag}\n}", "func (f *FenceComponent) SetScale(scale float64) {\n\tf.bottom.SetPosition(0.0, scale)\n\tf.bottom.SetScale(scale)\n\tf.right.SetPosition(scale, 0.0)\n\tf.right.SetScale(scale)\n\tf.top.SetPosition(0.0, -scale)\n\tf.top.SetScale(scale)\n\tf.left.SetPosition(-scale, 0.0)\n\tf.left.SetScale(scale)\n\n\tfd := box2d.MakeB2FixtureDef()\n\tfd.Filter.CategoryBits = f.categoryBits\n\tfd.Filter.MaskBits = f.maskBits\n\tfd.UserData = f.bottom\n\n\t// Bottom fixture\n\tgln := f.bottom.(*custom.LineNode)\n\tf.b2Shape = box2d.MakeB2EdgeShape()\n\tf.b2Shape.Set(box2d.MakeB2Vec2(gln.P1().X()*scale, scale), box2d.MakeB2Vec2(gln.P2().X()*scale, scale))\n\tfd.Shape = &f.b2Shape\n\tf.b2Body.CreateFixtureFromDef(&fd) // attach Fixture to body\n\n\t// Top fixture\n\tgln = f.top.(*custom.LineNode)\n\tfd.UserData = f.top\n\tf.b2Shape = box2d.MakeB2EdgeShape()\n\tf.b2Shape.Set(box2d.MakeB2Vec2(gln.P1().X()*scale, -scale), box2d.MakeB2Vec2(gln.P2().X()*scale, -scale))\n\tfd.Shape = &f.b2Shape\n\tf.b2Body.CreateFixtureFromDef(&fd) // attach Fixture to body\n\n\t// Right fixture\n\tgln = f.right.(*custom.LineNode)\n\tfd.UserData = f.right\n\tf.b2Shape = box2d.MakeB2EdgeShape()\n\tf.b2Shape.Set(box2d.MakeB2Vec2((gln.P1().X()*scale)+scale, gln.P1().Y()*scale), box2d.MakeB2Vec2((gln.P1().X()*scale)+scale, gln.P2().Y()*scale))\n\tfd.Shape = &f.b2Shape\n\tf.b2Body.CreateFixtureFromDef(&fd) // attach Fixture to body\n\n\t// Left fixture\n\tgln = f.left.(*custom.LineNode)\n\tfd.UserData = f.left\n\tf.b2Shape = box2d.MakeB2EdgeShape()\n\tf.b2Shape.Set(box2d.MakeB2Vec2((gln.P1().X()*scale)-scale, gln.P1().Y()*scale), box2d.MakeB2Vec2((gln.P1().X()*scale)-scale, gln.P2().Y()*scale))\n\tfd.Shape = &f.b2Shape\n\tf.b2Body.CreateFixtureFromDef(&fd) // attach Fixture to body\n}", "func (wv *Spectrum) Scale(s float32) {\n\twv.C[0] *= s\n\twv.C[1] *= s\n\twv.C[2] *= s\n\twv.C[3] *= s\n}", "func (self *TileSprite) SetTileScaleA(member *Point) {\n self.Object.Set(\"tileScale\", member)\n}", "func (t *Transform) SetDepth(depth float64) *Transform {\n\tt.Depth = depth\n\treturn t\n}", "func (s *sizes) setSizes(width int, height int) {\n\ts.width = width\n\ts.height = height\n\ts.curStreamsPerStreamDisplay = 1 + height/10\n}", "func Scale(v *Vertex, f float64) {\n\tv.x *= f\n\tv.y *= f\n}", "func (m *PrinterDefaults) SetDpi(value *int32)() {\n err := m.GetBackingStore().Set(\"dpi\", value)\n if err != nil {\n panic(err)\n }\n}", "func Scale(v *Vertex, f float64) {\n\tv.X *= f\n\tv.Y *= f\n}", "func (v Vertex) Scale(f int) {\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (v *Vertex) Scale(f float64) {\r\n\tv.X = v.X * f\r\n\tv.Y = v.Y * f\r\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * 1\n\tv.Y = v.Y * 1\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 (tt *telloTrackT) deriveScale() (scale float32) {\n\tscale = 1.0 // minimum scale value\n\tif tt.maxX > scale {\n\t\tscale = tt.maxX\n\t}\n\tif -tt.minX > scale {\n\t\tscale = -tt.minX\n\t}\n\tif tt.maxY > scale {\n\t\tscale = tt.maxY\n\t}\n\tif -tt.minY > scale {\n\t\tscale = -tt.minY\n\t}\n\tscale = float32(math.Ceil(float64(scale)))\n\treturn scale\n}", "func (xf *Transform) SetScale(scale float32) {\n\txf.Scale = mgl32.Vec2{scale, scale}\n}", "func main() {\n\t\n\tvar dimen_ft float64= 1362\n\t\n\tfmt.Print(\"The height of WTC is: \")\n\tfmt.Println(dimen_ft)\n\t\n\tvar f2m_conv = 0.3048\n\n\tvar dimen_m = dimen_ft * f2m_conv\n\n\tfmt.Print(\"The height in meters is: \")\n\tfmt.Println(dimen_m)\n\n}", "func (s *Sprite) Zoom(length float64) DrawingBuilder {\n\tif s.op == nil {\n\t\ts.err = errors.New(\"add a &ebiten.DrawImageOptions{} to s.op\")\n\t\treturn s\n\t}\n\ts.scale += length\n\ts.Width += length\n\ts.Height += length\n\n\ts.op.GeoM.Scale(float64(s.scale), float64(s.scale))\n\treturn s\n}", "func (z *Big) SetScale(scale int) *Big {\n\tz.exp = -scale\n\treturn z\n}", "func (s *Surface) Scale(x, y float64) {\n\ts.Ctx.Call(\"scale\", x, y)\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X = v.X * f\n\tv.Y = v.Y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (v *Vertex) Scale(f float64) {\n\tv.X *= f\n\tv.Y *= f\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func (p *Proc) Scale(x, y float64) {\n\tp.stk.scale(x, y)\n}", "func (p *P1D) Scale(factor float64) {\n\tp.bng.scaleW(factor)\n}", "func (c *Circle) Scale(f float64) {\n\tc.radius *= f\n}", "func (z *Rat) SetFrac64(a, b int64) *Rat {}", "func (p *Part) SetScale(scale vector.Vector) {\n\tif scale.Len() != 3 && scale.Kind() != reflect.Float32 {\n\t\tlog.Fatalf(\"Part.SetScale: expects 3D-Float32 vector, got %dD-%v\", scale.Len(), scale.Kind())\n\t}\n\t// Create scaling matrix\n\tp.scaling = matrix.NewMatrix([][]float32{\n\t\t{scale.Get(0).(float32), 0.0, 0.0},\n\t\t{0.0, scale.Get(1).(float32), 0.0},\n\t\t{0.0, 0.0, scale.Get(2).(float32)},\n\t})\n}", "func (m *PrinterDefaults) SetQuality(value *PrintQuality)() {\n err := m.GetBackingStore().Set(\"quality\", value)\n if err != nil {\n panic(err)\n }\n}", "func (this *Transformable) Scale(factor Vector2f) {\n\tC.sfTransformable_scale(this.cptr, factor.toC())\n}", "func (m *PrinterDefaults) SetScaling(value *PrintScaling)() {\n err := m.GetBackingStore().Set(\"scaling\", value)\n if err != nil {\n panic(err)\n }\n}", "func (z *Rat) SetFrac(a, b *Int) *Rat {}", "func (z *Float) SetRat(x *Rat) *Float {}", "func Scale(w, h int) int {\n\ta := w / WIDTH\n\tb := h / HEIGHT\n\tif a < b {\n\t\treturn a\n\t}\n\treturn b\n}", "func (v *Vertex) Scale(l float64) {\n\tv.x *= l\n\tv.y *= l\n}", "func (c *LinehaulCostComputation) Scale(factor float64) {\n\tc.BaseLinehaul = c.BaseLinehaul.MultiplyFloat64(factor)\n\tc.OriginLinehaulFactor = c.OriginLinehaulFactor.MultiplyFloat64(factor)\n\tc.DestinationLinehaulFactor = c.DestinationLinehaulFactor.MultiplyFloat64(factor)\n\tc.ShorthaulCharge = c.ShorthaulCharge.MultiplyFloat64(factor)\n\tc.LinehaulChargeTotal = c.LinehaulChargeTotal.MultiplyFloat64(factor)\n}", "func (self *Tween) TimeScale() int{\n return self.Object.Get(\"timeScale\").Int()\n}", "func (c *Camera) SetZoom(z float64) {\n\tif z == 0.0 {\n\t\treturn\n\t}\n\tc.zoom = z\n\tc.zoomInv = 1 / z\n\tc.sTop = c.lookAtY + float64(c.screenH/2)*c.zoomInv\n\tc.sBottom = c.lookAtY - float64(c.screenH/2)*c.zoomInv\n\tc.sLeft = c.lookAtX - float64(c.screenW/2)*c.zoomInv\n\tc.sRight = c.lookAtX + float64(c.screenW/2)*c.zoomInv\n}", "func (v *Vec4) Scale(s float32) {\n\tv.X *= s\n\tv.Y *= s\n\tv.Z *= s\n\tv.W *= s\n}", "func (self *Tween) SetTimeScaleA(member int) {\n self.Object.Set(\"timeScale\", member)\n}", "func (c Charset) Scale(factor int) {\n\tif factor <= 1 {\n\t\t// A factor of zero results in zero-sized glyphs and\n\t\t// is therefore not valid. A factor of 1 does not change\n\t\t// the glyphs, so we can ignore it.\n\t\treturn\n\t}\n\n\t// Multiply each glyph field by the given factor\n\t// to scale them up to the new size.\n\tfor i := range c {\n\t\tc[i].X *= factor\n\t\tc[i].Y *= factor\n\t\tc[i].Width *= factor\n\t\tc[i].Height *= factor\n\t\tc[i].Advance *= factor\n\t}\n}", "func (level *DepthOfMarketLevel) Set(price, volume float64, isBid bool) {\n\t(*level)[0] = price\n\tif isBid {\n\t\t(*level)[0] *= -1\n\t}\n\t(*level)[1] = volume\n}", "func SetDepthFunc(_func Enum) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tC.glDepthFunc(c_func)\n}", "func (level *Level) SetProperties(properties model.LevelProperties) {\n\t{\n\t\tinfoStore := level.store.Get(res.ResourceID(4000 + level.id*100 + 4))\n\t\tinfoData := infoStore.BlockData(0)\n\t\tinfoReader := bytes.NewReader(infoData)\n\t\tinfoWriter := bytes.NewBuffer(nil)\n\t\tvar info data.LevelInformation\n\n\t\tbinary.Read(infoReader, binary.LittleEndian, &info)\n\t\tif properties.CyberspaceFlag != nil {\n\t\t\tinfo.CyberspaceFlag = 0\n\t\t\tif *properties.CyberspaceFlag {\n\t\t\t\tinfo.CyberspaceFlag = 1\n\t\t\t}\n\t\t}\n\t\tif properties.HeightShift != nil {\n\t\t\tinfo.HeightShift = uint32(*properties.HeightShift)\n\t\t}\n\t\tbinary.Write(infoWriter, binary.LittleEndian, &info)\n\t\tinfoStore.SetBlockData(0, infoWriter.Bytes())\n\t}\n\t{\n\t\tvarsStore := level.store.Get(res.ResourceID(4000 + level.id*100 + 45))\n\t\tvarsData := varsStore.BlockData(0)\n\t\tvarsReader := bytes.NewReader(varsData)\n\t\tvarsWriter := bytes.NewBuffer(nil)\n\t\tvar vars data.LevelVariables\n\n\t\tbinary.Read(varsReader, binary.LittleEndian, &vars)\n\t\tif properties.CeilingHasRadiation != nil {\n\t\t\tvars.RadiationRegister = 0\n\t\t\tif *properties.CeilingHasRadiation {\n\t\t\t\tvars.RadiationRegister = 2\n\t\t\t}\n\t\t}\n\t\tif properties.CeilingEffectLevel != nil {\n\t\t\tvars.Radiation = byte(*properties.CeilingEffectLevel)\n\t\t}\n\t\tif properties.FloorHasBiohazard != nil {\n\t\t\tvars.BioRegister = 0\n\t\t\tif *properties.FloorHasBiohazard {\n\t\t\t\tvars.BioRegister = 2\n\t\t\t}\n\t\t}\n\t\tif properties.FloorHasGravity != nil {\n\t\t\tvars.GravitySwitch = 0\n\t\t\tif *properties.FloorHasGravity {\n\t\t\t\tvars.GravitySwitch = 1\n\t\t\t}\n\t\t}\n\t\tif properties.FloorEffectLevel != nil {\n\t\t\tvars.BioOrGravity = byte(*properties.FloorEffectLevel)\n\t\t}\n\t\tbinary.Write(varsWriter, binary.LittleEndian, &vars)\n\t\tvarsStore.SetBlockData(0, varsWriter.Bytes())\n\t}\n}", "func (t *Transform) SetScale(sx, sy float64) *Transform {\n\tt.Scale1.X = sx - 1\n\tt.Scale1.Y = sy - 1\n\treturn t\n}", "func (z *Big) SetMantScale(value int64, scale int) *Big {\n\tz.SetUint64(arith.Abs(value))\n\tz.exp = -scale // compiler should optimize out z.exp = 0 in SetUint64\n\tif value < 0 {\n\t\tz.form |= signbit\n\t}\n\treturn z\n}", "func scale(n int) string {\n\tswitch n {\n\tcase 1:\n\t\treturn \"Celcius\"\n\tcase 2:\n\t\treturn \"Fahrenheit\"\n\tdefault:\n\t\treturn \"\"\n\t}\n}", "func (this *Transformable) SetScale(scale Vector2f) {\n\tC.sfTransformable_setScale(this.cptr, scale.toC())\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func main() {\n\tv := Vertex{1, 2}\n\tc := float64(rand.Intn(1337))\n\n\tfmt.Println(\"original\", v.Abs())\n\n\tv.Scale(c)\n\tfmt.Println(v.Abs())\n\n\tScale(&v, 1/c)\n\tfmt.Println(\"rescaled\", Abs(v))\n\n\tp := &Vertex{3,4}\n\tp.Scale(3)\n\tScale(p,8)\n\n\tfmt.Println(v,p)\n}", "func DepthRange(near float64, far float64) {\n C.glowDepthRange(gpDepthRange, (C.GLdouble)(near), (C.GLdouble)(far))\n}", "func scale(val float64, min float64, max float64, outMin float64, outMax float64) float64 {\r\n\tdenom := 1.0\r\n\ty := 0.0\r\n\tif outMin - min != 0 {\r\n\t\tdenom = outMin - min\r\n\t\ty = (outMax - max) / denom * val - min + outMin\r\n\t} else {\r\n\t\ty = outMax / max * val - min + outMin\r\n\t}\r\n\treturn y\r\n}", "func (s Size) ScaleDown(x, y int) Size {\n\ts.W /= x\n\ts.H /= y\n\treturn s\n}", "func ( v Vertex ) Scale1( f float64 ) {\n\t// Value receiver, no change to the struct\n\tv.x = v.x * f\n\tv.y = v.y * f\n}", "func (dev *Device) SetDepthMode(mode FrameMode) int {\n\treturn int(C.freenect_set_depth_mode(dev.ptr(), *mode.ptr()))\n}", "func (s *Scale) SetValue(v float64) *Scale {\n\ts.Value = &v\n\treturn s\n}", "func (self Text) SetScale(x, y float32) {\n\tv := C.sfVector2f{C.float(x), C.float(y)}\n\tC.sfText_setScale(self.Cref, v)\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 (nt nodeTasks) setScale(node *Node, scale, buffer int) {\n\tst := nt[node]\n\tst.Lock()\n\tdefer st.RUnlock()\n\n\tcurrScale := len(st.buffers)\n\n\t// Increase the number of tasks for the given node.\n\t// a scale of 1 only adds a buffer with no scale.\n\tif scale > currScale {\n\t\tfor ; scale > currScale; currScale++ {\n\t\t\ttask := make(chan Record, buffer)\n\t\t\tst.buffers = append(st.buffers, task)\n\t\t\tgo func() {\n\t\t\t\tfor record := range task {\n\t\t\t\t\tnode.forward(record)\n\t\t\t\t}\n\t\t\t}()\n\t\t}\n\t}\n\n\tif scale < currScale {\n\t\tfor ; scale < currScale; currScale-- {\n\t\t\tclose(st.buffers[currScale-1])\n\t\t\tst.buffers = st.buffers[:currScale-1]\n\t\t}\n\t}\n}", "func (sc *Scene) normalizeLum(minvalue float64, maxvalue float64, newMax float64, exponent float64) {\n\n\t// find max\n\tvar maxlum float64\n\tvar lumDivisor float64\n\n\tfor i, s := range sc.Lums {\n\t\t// boosting small lums up to minimal value\n\t\tif sc.Lums[i] < minvalue {\n\t\t\tsc.Lums[i] = minvalue\n\t\t}\n\t\tif sc.Lums[i] > maxvalue {\n\t\t\tsc.Lums[i] = maxvalue\n\t\t}\n\t\t// collecting max lum\n\t\tif s > maxlum {\n\t\t\tmaxlum = s\n\t\t}\n\t}\n\n\tlumDivisor = maxlum / newMax\n\t//lumDivisor = newMax / maxlum\n\n\tfor i, l := range sc.Lums {\n\t\tsc.Lums[i] = math.Pow((float64(l / lumDivisor)), exponent)\n\t}\n}", "func PixelZoom(xfactor float32, yfactor float32) {\n C.glowPixelZoom(gpPixelZoom, (C.GLfloat)(xfactor), (C.GLfloat)(yfactor))\n}", "func (vr *vectorRenderer) SetDPI(dpi float64) {\n\tvr.dpi = dpi\n\tvr.c.dpi = dpi\n}", "func (self *Rectangle) Scale(x int) *Rectangle{\n return &Rectangle{self.Object.Call(\"scale\", x)}\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 DepthToSpaceDataFormat(value string) DepthToSpaceAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"data_format\"] = value\n\t}\n}", "func (self *T) Scale(f float64) *T {\n\tself[0] *= f\n\tself[1] *= f\n\treturn self\n}", "func DepthRange(n float64, f float64) {\n\tsyscall.Syscall(gpDepthRange, 2, uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)), 0)\n}", "func (fpsc *FloorPlanScaleCreate) SetScaleInMeters(f float64) *FloorPlanScaleCreate {\n\tfpsc.mutation.SetScaleInMeters(f)\n\treturn fpsc\n}", "func (p *Point) Scale(v float64) {\n\tp.x *= v\n\tp.y *= v\n}", "func (t *Transform) Scale(sx, sy float64) {\n\tout := fmt.Sprintf(\"scale(%g,%g)\", sx, sy)\n\n\tt.transforms = append(t.transforms, out)\n}", "func (adaType *AdaSuperType) SetFractional(x uint32) {\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 (w *windowImpl) Scale(dr image.Rectangle, src screen.Texture, sr image.Rectangle, op draw.Op, opts *screen.DrawOptions) {\n\tpanic(\"not implemented\") // TODO: Implement\n}", "func (this *RectangleShape) SetScale(scale Vector2f) {\n\tC.sfRectangleShape_setScale(this.cptr, scale.toC())\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 (r *RAM) SetAmplScaleFactor(x uint16) {\n\tbinary.BigEndian.PutUint16(r[0:2], x<<2)\n}", "func (this *RectangleShape) Scale(factor Vector2f) {\n\tC.sfRectangleShape_scale(this.cptr, factor.toC())\n}", "func (self *T) Scale(f float32) *T {\n\tself[0][0] *= f\n\tself[1][1] *= f\n\treturn self\n}", "func (b *Base) Scale(w http.ResponseWriter, r *http.Request) {\n\tb.log.Printf(\"%s %s -> %s\", r.Method, r.URL.Path, r.RemoteAddr)\n\n\tsOptions, pOptions, kOptions, oOptions := render.SetDefaultScaleOptions()\n\n\tpv := render.PageVars{\n\t\tTitle: \"Practice Scales and Arpeggios\", // default scale initially displayed is A Major\n\t\tScalearp: \"Scale\",\n\t\tPitch: \"Major\",\n\t\tKey: \"A\",\n\t\tScaleImgPath: \"img/scale/major/a1.png\",\n\t\tGifPath: \"\",\n\t\tAudioPath: \"mp3/scale/major/a1.mp3\",\n\t\tAudioPath2: \"mp3/drone/a1.mp3\",\n\t\tLeftLabel: \"Listen to Major scale\",\n\t\tRightLabel: \"Listen to Drone\",\n\t\tScaleOptions: sOptions,\n\t\tPitchOptions: pOptions,\n\t\tKeyOptions: kOptions,\n\t\tOctaveOptions: oOptions,\n\t}\n\n\tif err := render.Render(w, \"scale.html\", pv); err != nil {\n\t\tb.log.Printf(\"%s %s -> %s : ERROR : %v\", r.Method, r.URL.Path, r.RemoteAddr, err)\n\t\treturn\n\t}\n}" ]
[ "0.5953051", "0.5782099", "0.5592689", "0.5478918", "0.5475763", "0.5397865", "0.5370801", "0.5360635", "0.5354044", "0.5284855", "0.5265641", "0.5252814", "0.5225897", "0.5223125", "0.520359", "0.5150167", "0.5144686", "0.5120575", "0.51115435", "0.51027197", "0.5099922", "0.5060021", "0.50508505", "0.5049571", "0.5040248", "0.5026123", "0.49930862", "0.4987523", "0.49661434", "0.4958836", "0.4952143", "0.49141392", "0.4910984", "0.4905921", "0.49000445", "0.4899354", "0.4899354", "0.4899354", "0.4899354", "0.4899354", "0.4899354", "0.4899354", "0.4897154", "0.4889404", "0.48798785", "0.48477563", "0.48440436", "0.48346373", "0.4828062", "0.48203027", "0.48034853", "0.47886264", "0.47845516", "0.47781056", "0.47735003", "0.47715476", "0.47666198", "0.4765513", "0.47636604", "0.4763644", "0.47561914", "0.47553414", "0.47493944", "0.4725176", "0.47240114", "0.4716791", "0.47090203", "0.47080907", "0.47079116", "0.46948478", "0.4685539", "0.46723142", "0.46648574", "0.46632636", "0.46582204", "0.46535408", "0.4628809", "0.46233764", "0.46157563", "0.46120238", "0.46047738", "0.45911014", "0.45603153", "0.45468783", "0.45439672", "0.4543416", "0.45408824", "0.45348066", "0.45312688", "0.45273712", "0.45268205", "0.45253104", "0.45231825", "0.4521124", "0.45188466", "0.45115134", "0.45031735", "0.44935283", "0.44933498", "0.4489977", "0.448647" ]
0.0
-1
set the polygon stippling pattern
func PolygonStipple(mask *uint8) { C.glowPolygonStipple(gpPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PolygonStipple(mask *uint8) {\n\tsyscall.Syscall(gpPolygonStipple, 1, uintptr(unsafe.Pointer(mask)), 0, 0)\n}", "func (el *Fill) Polygon() {}", "func (s *Surface) StylePattern(t DrawType, p Pattern) {\n\tif p.Type == \"\" {\n\t\tp.Type = RepeatXY\n\t}\n\tpat := s.Ctx.Call(\"createPattern\", p.Source.Canvas, p.Type)\n\ts.Ctx.Set(string(t)+\"Style\", pat)\n}", "func PolygonStipple(mask *uint8) {\n C.glowPolygonStipple(gpPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func (win *window) Polygon(pt []image.Point, fill bool) {\n\tif len(pt) < 2 {\n\t\treturn\n\t}\n\tpts := make([]xgb.Point, len(pt))\n\tfor i, p := range pt {\n\t\tpts[i].X, pts[i].Y = int16(p.X), int16(p.Y)\n\t}\n\tif !fill {\n\t\tif !pt[0].Eq(pt[len(pt)-1]) {\n\t\t\tpts = append(pts, xgb.Point{int16(pt[0].X), int16(pt[0].Y)})\n\t\t}\n\t\txwin.PolyLine(xgb.CoordModeOrigin, win.id, win.gc, pts)\n\t\treturn\n\t}\n\txwin.FillPoly(win.id, win.gc, xgb.PolyShapeComplex, xgb.CoordModeOrigin, pts)\n}", "func fillPolygon(c vg.Canvas, clr color.Color, pts []vg.Point) {\n\tif len(pts) == 0 {\n\t\treturn\n\t}\n\n\tc.SetColor(clr)\n\tp := make(vg.Path, 0, len(pts)+1)\n\tp.Move(pts[0])\n\tfor _, pt := range pts[1:] {\n\t\tp.Line(pt)\n\t}\n\tp.Close()\n\tc.Fill(p)\n}", "func (self *TileSprite) SetTilePatternA(member *PIXITexture) {\n self.Object.Set(\"tilePattern\", member)\n}", "func SetPattern(pattern string) Option {\n\treturn func(g *Generator) error {\n\t\tif pattern == \"\" {\n\t\t\treturn ErrInvalidPattern\n\t\t}\n\n\t\tnumPatternChar := numberOfChar(pattern, patternChar)\n\t\tif g.Length == 0 || g.Length != numPatternChar {\n\t\t\tg.Length = numPatternChar\n\t\t}\n\n\t\tg.Pattern = pattern\n\t\treturn nil\n\t}\n}", "func (w *SVGWriter) Polygon(p *Polygon) {\n\tw.PolygonWithClass(p, \"\")\n}", "func (shape *Shape) PolyShapeSetRadius(radius float64) {\n\tC.cpPolyShapeSetRadius(\n\t\t(*C.cpShape)(unsafe.Pointer(shape)),\n\t\tC.cpFloat(radius),\n\t)\n}", "func (m *spiralMemory) set(x int, y int, i int) {\n\trx := x + m.offset\n\try := y + m.offset\n\tif ry < 0 || ry > len(m.grid)-1 || rx < 0 || rx > len(m.grid[ry])-1 {\n\t\tm.grow()\n\t\tm.set(x, y, i)\n\t} else {\n\t\tm.grid[ry][rx] = i\n\t}\n}", "func (this *Poly) setType(t int) {\n\tthis.areaAndtype = (this.areaAndtype & 0x3f) | (t << 6)\n}", "func (el *Fill) Polyline() {}", "func (s *VisvalingamSimplifier) Polygon(p orb.Polygon) orb.Polygon {\n\treturn polygon(s, p)\n}", "func (this *Poly) setArea(a int) {\n\tthis.areaAndtype = (this.areaAndtype & 0xc0) | (a & 0x3f)\n}", "func (this *DtPoly) SetType(t DtPolyTypes) {\n\tthis.AreaAndtype = (this.AreaAndtype & 0x3f) | (uint8(t) << 6)\n}", "func Set(chars string) *Pattern {\n\tmask := [...]uint32{0, 0, 0, 0, 0, 0, 0, 0}\n\tfor i := 0; i < len(chars); i++ {\n\t\tc := chars[i]\n\t\tmask[c>>5] |= 1 << (c & 0x1F)\n\t}\n\treturn Seq(&ICharset{mask})\n}", "func (dw *DrawingWand) Polygon(coordinates []PointInfo) {\n\tccoordinates := [1 << 16]C.PointInfo{}\n\tfor k, v := range coordinates {\n\t\tccoordinates[k] = C.PointInfo{C.double(v.X), C.double(v.Y)}\n\t}\n\tC.MagickDrawPolygon(dw.dw, C.ulong(len(coordinates)), (*C.PointInfo)(&ccoordinates[0]))\n}", "func (p *Patch) SetRegion(value mat.AABB) {\n\tif value == mat.ZA {\n\t\tp.Patch.SetIntensity(0)\n\t} else {\n\t\tp.Patch = ggl.NPatch(value, p.Padding)\n\t}\n}", "func (options *CreateEdgeFunctionsTriggerOptions) SetPattern(pattern string) *CreateEdgeFunctionsTriggerOptions {\n\toptions.Pattern = core.StringPtr(pattern)\n\treturn options\n}", "func (shape *Shape) PolyShapeSetVerts(verts []Vect, transform Transform) {\n\tC.cpPolyShapeSetVerts(\n\t\t(*C.cpShape)(unsafe.Pointer(shape)),\n\t\tC.int(len(verts)),\n\t\t(*C.cpVect)(unsafe.Pointer(&verts[0])),\n\t\ttransform.c(),\n\t)\n}", "func (rs *RenderSystem) TogglePolygons() {\n\trs.drawPolygon = !rs.drawPolygon\n}", "func (options *UpdateEdgeFunctionsTriggerOptions) SetPattern(pattern string) *UpdateEdgeFunctionsTriggerOptions {\n\toptions.Pattern = core.StringPtr(pattern)\n\treturn options\n}", "func (fe FullEdge) Set(i int, d Dimensional) Spanning {\n\tfe[i] = d.(Point)\n\treturn fe\n}", "func (params *JourneyParams)SetPoles(poles []string)error{\n\tvar err error\n\tfor _,v:=range poles {\n\t\terr=validatePole(v)\t\n\t\tif err!=nil{return err}\n\t\tparams.AddPole(v)\n\t}\n\t//temp:=GetLinesSeparated(poles)// TODO rename GetLinesSeparated, to something else.\n\t//params.Poles=&temp\n\treturn nil\n}", "func (m *ParameterMutator) Pattern(v string) *ParameterMutator {\n\tm.lock.Lock()\n\tdefer m.lock.Unlock()\n\tm.proxy.pattern = v\n\treturn m\n}", "func (w *Window) Setxy(x, y int, r, g, b byte) {\n\tif x < 0 || x > w.width || y < 0 || y > w.height {\n\t\treturn\n\t}\n\ti := y*3*w.width + x*3\n\tw.tex[i] = r\n\tw.tex[i+1] = g\n\tw.tex[i+2] = b\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 PolygonMode(face uint32, mode uint32) {\n\tsyscall.Syscall(gpPolygonMode, 2, uintptr(face), uintptr(mode), 0)\n}", "func (imd *IMDraw) Polygon(thickness float64) {\n\tif thickness == 0 {\n\t\timd.fillPolygon()\n\t} else {\n\t\timd.polyline(thickness, true)\n\t}\n}", "func (dw *DrawingWand) PushPattern(patternId string, x, y, width, height float64) {\n\tcstr := C.CString(patternId)\n\tdefer C.free(unsafe.Pointer(cstr))\n\tC.MagickDrawPushPattern(dw.dw, cstr, C.double(x), C.double(y), C.double(width), C.double(height))\n}", "func PitchPatternAt(p synth.Pitch, n int) Option {\n\treturn func(g Generator) {\n\t\tif hpp, ok := g.(HasPitches); ok {\n\t\t\tpitches := hpp.GetPitchPattern()\n\t\t\tif len(pitches) < n {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tpitches[n] = p\n\t\t\thpp.SetPitchPattern(pitches)\n\t\t}\n\t}\n}", "func (o *Indicator) SetPattern(s string) error {\n\to.Pattern = s\n\treturn nil\n}", "func TestPointInPolygonWithHole(t *testing.T) {\n\tnsw := Contour{ { 150.703782730764544, -35.120441501962588 }, { 150.673521763018982, -35.124264010875365 }, { 150.636418085326397, -35.14446949567072 }, { 150.613055464931449, -35.187267234778744 }, { 150.61304772200009, -35.187269789999931 }, { 150.585948113000143, -35.196221612999878 }, { 150.55396569100003, -35.213555596999953 }, { 150.548106316000087, -35.221368096999939 }, { 150.543711785000028, -35.237969658999901 }, { 150.539724155000044, -35.247735283999944 }, { 150.534434441000087, -35.254978122999958 }, { 150.52312259200005, -35.26433684699991 }, { 150.49952233200014, -35.289727471999925 }, { 150.489105665000068, -35.305759372999916 }, { 150.484629754000082, -35.324314059999921 }, { 150.485036655000101, -35.350192966999927 }, { 150.488454623000109, -35.364515882999925 }, { 150.491872592000107, -35.369398695999891 }, { 150.492035352000073, -35.373142184999921 }, { 150.485036655000101, -35.384372653999918 }, { 150.455821160000028, -35.403985283999887 }, { 150.45093834700009, -35.408461195999863 }, { 150.445485873000052, -35.425469658999916 }, { 150.43295332100007, -35.440687757999896 }, { 150.41920006600003, -35.454522393999895 }, { 150.40992272200009, -35.466892184999921 }, { 150.406993035000028, -35.487399997999972 }, { 150.409353061000104, -35.538506768999952 }, { 150.406504754000082, -35.548760674999883 }, { 150.389659050000148, -35.557875257999882 }, { 150.372325066000087, -35.578871351999908 }, { 150.332530144000089, -35.639418226999908 }, { 150.306895379000025, -35.700290622999916 }, { 150.291677280000044, -35.722832940999893 }, { 150.273692254000025, -35.730645440999893 }, { 150.253428582000083, -35.726250908999901 }, { 150.231781446000014, -35.7133114559999 }, { 150.221934441000087, -35.717705987999892 }, { 150.19092858200014, -35.726820570999877 }, { 150.21810957100007, -35.751153252999941 }, { 150.225840691000087, -35.778903903999918 }, { 150.228688998000109, -35.785251559999949 }, { 150.238536004000025, -35.799493096999953 }, { 150.240977410000085, -35.809747002999885 }, { 150.238617384, -35.833103122999972 }, { 150.232432488000143, -35.843845309999978 }, { 150.21810957100007, -35.850192966999927 }, { 150.19092858200014, -35.857191664999903 }, { 150.189300977000016, -35.85955169099995 }, { 150.152598504000025, -35.893731377999941 }, { 150.149750196000014, -35.898207289999917 }, { 150.150238477000073, -35.9125302059999 }, { 150.160817905000044, -35.939711195999905 }, { 150.163422071000014, -35.956638278999975 }, { 150.156586134, -36.025079033999944 }, { 150.148692254000025, -36.062595309999963 }, { 150.129649285000028, -36.059502862999892 }, { 150.106781446000014, -36.048597914999903 }, { 150.087738477000016, -36.06267669099995 }, { 150.09115644600007, -36.070245049999897 }, { 150.090179884000065, -36.07529062299993 }, { 150.081553582000083, -36.083754164999874 }, { 150.087657097000033, -36.082777601999894 }, { 150.092539910000028, -36.08269622199991 }, { 150.097015821000014, -36.081312757999939 }, { 150.102061394000089, -36.076348565999893 }, { 150.119151238000086, -36.085056247999958 }, { 150.135752800000091, -36.097751559999935 }, { 150.143321160000085, -36.11443450299997 }, { 150.123057488000143, -36.152601820999934 }, { 150.121104363000086, -36.17376067499994 }, { 150.124196811000104, -36.195245049999969 }, { 150.144786004000025, -36.252862237999935 }, { 150.146494988000143, -36.273532809999949 }, { 150.132823113000086, -36.282403252999899 }, { 150.132823113000086, -36.286797783999887 }, { 150.140391472000033, -36.30974700299997 }, { 150.14234459700009, -36.320000908999901 }, { 150.13819420700014, -36.330010674999883 }, { 150.12842858200014, -36.338311455999957 }, { 150.108246290000011, -36.35133228999986 }, { 150.092295769000089, -36.367852471999925 }, { 150.079274936000104, -36.386000257999925 }, { 150.070485873000052, -36.406345309999921 }, { 150.067393425000148, -36.429294528999904 }, { 150.073008660000028, -36.453057549999912 }, { 150.074229363000143, -36.463311455999929 }, { 150.070974155000101, -36.470147393999952 }, { 150.056813998000109, -36.488946221999896 }, { 150.053558790000068, -36.500909112999935 }, { 150.063649936000104, -36.54314544099995 }, { 150.065765821000014, -36.566582940999936 }, { 150.056976759000065, -36.587172132999868 }, { 150.029063347000033, -36.624281507999882 }, { 149.99537194100003, -36.686455987999892 }, { 149.989105665000068, -36.704685153999961 }, { 149.986094597000033, -36.722914320999863 }, { 149.985362175000148, -36.744805596999896 }, { 149.979502800000091, -36.769952080999957 }, { 149.965098504000025, -36.794528903999975 }, { 149.94703209700009, -36.815687757999882 }, { 149.930023634000065, -36.830498955999957 }, { 149.939952019000145, -36.852959893999952 }, { 149.93482506600003, -36.870700778999947 }, { 149.90967858200014, -36.905531507999896 }, { 149.903819207000083, -36.928399346999896 }, { 149.91138756600003, -36.938571872999944 }, { 149.926524285000028, -36.944105726999865 }, { 149.943695509000065, -36.953383070999919 }, { 149.932139519000145, -36.96550872199991 }, { 149.92310631600003, -36.983493747999944 }, { 149.920176629000025, -37.002618096999925 }, { 149.926768425000091, -37.01824309699991 }, { 149.93482506600003, -37.026625257999868 }, { 149.939952019000145, -37.033868096999896 }, { 149.94288170700014, -37.04216887799997 }, { 149.943695509000065, -37.053399346999882 }, { 149.941579623000052, -37.06218840899993 }, { 149.93685957100007, -37.06894296699997 }, { 149.932302280000101, -37.07097747199991 }, { 149.930023634000065, -37.066338799999883 }, { 149.922536655000044, -37.061781507999925 }, { 149.90577233200014, -37.07097747199991 }, { 149.89031009200005, -37.084079684999963 }, { 149.885508660000028, -37.090508721999882 }, { 149.876149936000104, -37.095879815999936 }, { 149.88209069100003, -37.107598565999922 }, { 149.896657748000052, -37.119317315999922 }, { 149.913096550000148, -37.124688408999972 }, { 149.930186394000089, -37.122816664999903 }, { 149.938975457000083, -37.11980559699991 }, { 149.946055535000028, -37.119235934999935 }, { 149.95875084700009, -37.124688408999972 }, { 149.997569207000083, -37.150485934999907 }, { 150.005869988000086, -37.158868096999953 }, { 150.011403842000107, -37.173435153999989 }, { 150.014414910000028, -37.205336195999905 }, { 150.019541863000086, -37.220879815999908 }, { 150.053558790000068, -37.268731377999941 }, { 150.053558790000068, -37.276136976999922 }, { 150.030039910000085, -37.266045830999957 }, { 150.00733483200014, -37.259372653999904 }, { 149.985362175000148, -37.259047132999882 }, { 149.964366082000083, -37.268731377999941 }, { 149.951019727000073, -37.284274997999944 }, { 149.951345248000109, -37.299737237999963 }, { 149.971690300000091, -37.337579033999901 }, { 149.957286004000025, -37.377862237999892 }, { 149.956797722000033, -37.415459893999881 }, { 149.967133009000065, -37.453708591999927 }, { 149.985362175000148, -37.495863539999874 }, { 149.972097201, -37.51026783599994 }, { 149.972075076275758, -37.510291859955558 }, { 149.761070998227979, -37.425105483031643 }, { 149.544185012228468, -37.33756560546837 }, { 149.32729902622907, -37.249974053759516 }, { 149.110413039330297, -37.16238250115147 }, { 148.89357872927485, -37.074790947644061 }, { 148.676641067331389, -36.987199395036015 }, { 148.459806757275942, -36.899607842427969 }, { 148.242972447220609, -36.812016289819923 }, { 148.216824172197789, -36.801681003875245 }, { 148.160393507953927, -36.798373711977206 }, { 148.134658644980391, -36.792792656955527 }, { 148.123289830261456, -36.788245130708219 }, { 148.122979770999621, -36.784214369297715 }, { 148.195120070634744, -36.691196791298893 }, { 148.20617882699122, -36.672489923271286 }, { 148.21403364513651, -36.65130258564578 }, { 148.217030877772743, -36.628151544158442 }, { 148.214860468335928, -36.616886082226955 }, { 148.197962273639973, -36.585466810544887 }, { 148.185404901415097, -36.581591077865923 }, { 148.171400588366396, -36.57957569806004 }, { 148.161788771934198, -36.576630140468595 }, { 148.154812452932333, -36.569860527940989 }, { 148.150316604427644, -36.562470797789103 }, { 148.147836134829788, -36.554512627755557 }, { 148.146905958842979, -36.545830987310268 }, { 148.148766310816598, -36.504283136157866 }, { 148.146595901379669, -36.499632257122983 }, { 148.141893344602124, -36.494671318826292 }, { 148.13724246556734, -36.487798353511195 }, { 148.13403852825553, -36.46650766399749 }, { 148.13098961787648, -36.458859551427125 }, { 148.120809360663486, -36.446870619083782 }, { 148.085204298839244, -36.424856459158235 }, { 148.067582636429563, -36.409715264547771 }, { 148.05993452385917, -36.388217868559735 }, { 148.06303511018217, -36.377624200196664 }, { 148.076264275975575, -36.360364272093463 }, { 148.079261508611694, -36.354421481865899 }, { 148.077814568687359, -36.341915784685696 }, { 148.074352248057721, -36.332355645096925 }, { 148.065567254824941, -36.316542656918131 }, { 148.043398065268434, -36.258510024018349 }, { 148.042312859650735, -36.247657973236883 }, { 148.031925896862617, -36.237115980817876 }, { 148.034303012773762, -36.213344821706087 }, { 148.045465122817063, -36.172572116909677 }, { 148.035956659172427, -36.151746514490057 }, { 147.999473098204817, -36.130559176864452 }, { 147.991411573585253, -36.114177747904733 }, { 147.995752395156842, -36.087047620950941 }, { 148.001333449279173, -36.070304456785252 }, { 147.996889275819456, -36.059245700428733 }, { 147.970947707270852, -36.049013767271546 }, { 147.949346959394632, -36.045293064223486 }, { 147.94066531804998, -36.042605889949897 }, { 147.929296503330875, -36.035371188529552 }, { 147.921286655554752, -36.025345960947334 }, { 147.915963982951439, -36.014183851803338 }, { 147.909711135260636, -36.005037122465211 }, { 147.898600702060662, -36.001213066629674 }, { 147.871780634368804, -35.998370863624459 }, { 147.741297641672759, -35.945970960791229 }, { 147.731634149296497, -35.944575697710235 }, { 147.713805780412372, -35.939408053838662 }, { 147.703418816724934, -35.939769789044547 }, { 147.694737177178979, -35.94390390414182 }, { 147.677942336169849, -35.95687468751683 }, { 147.672361282047575, -35.959665215477273 }, { 147.556761102442977, -35.996355482919199 }, { 147.538932732659475, -35.990671075110029 }, { 147.533661736899603, -35.972429295075969 }, { 147.520122511844477, -35.958011569977984 }, { 147.502294142960352, -35.948813164695807 }, { 147.48369062682093, -35.945970960791229 }, { 147.475629104, -35.948399753545786 }, { 147.457490675853933, -35.957649834772013 }, { 147.446741977859972, -35.959665215477273 }, { 147.419560174962044, -35.957339775510192 }, { 147.408604771393016, -35.959665215477273 }, { 147.396615839049673, -35.966693210423372 }, { 147.382198113951802, -35.97961231875351 }, { 147.369175652834144, -35.994650159677121 }, { 147.360804070751215, -36.008086032844133 }, { 147.348246697626962, -36.062449639539196 }, { 147.340288527593486, -36.076350599800307 }, { 147.324010451421145, -36.061674493183304 }, { 147.306337112167967, -36.051959323963615 }, { 147.286751744097671, -36.049323825634005 }, { 147.272023960637171, -36.049013767271546 }, { 147.266701288033971, -36.0502540016209 }, { 147.215851678811873, -36.061519463552386 }, { 147.184329055241619, -36.064258314669488 }, { 147.165260451108963, -36.059245700428733 }, { 147.154046666020804, -36.047618504190567 }, { 147.144176467170212, -36.040487155557798 }, { 147.134719680368903, -36.039350273995922 }, { 147.124591099099916, -36.04560312258603 }, { 147.097719353665184, -36.07325001347732 }, { 147.093895297829704, -36.080071302848367 }, { 147.091879918023835, -36.086169121807558 }, { 147.082578159954096, -36.097899671732492 }, { 147.079632603261985, -36.103635755485726 }, { 147.079322544899469, -36.112110691255424 }, { 147.081647983967343, -36.118931979727094 }, { 147.084593540659341, -36.125133151473776 }, { 147.086453891733697, -36.131592705638838 }, { 147.090019566050103, -36.156242363893924 }, { 147.093791945941518, -36.168024590662384 }, { 147.100096469576386, -36.179393406280624 }, { 147.108933139652663, -36.189470309806907 }, { 147.11983686727757, -36.197428480739816 }, { 147.132859328395284, -36.203371270068018 }, { 147.147897170218187, -36.207298678691046 }, { 147.176835972302229, -36.206936943485161 }, { 147.18856652222712, -36.209469089926571 }, { 147.196317986685756, -36.22032113980876 }, { 147.106917758947418, -36.241198419071807 }, { 147.093895297829704, -36.23401539449489 }, { 147.05152062437736, -36.19536142319113 }, { 147.040978631958353, -36.173708997572177 }, { 147.038601516047038, -36.138413995009799 }, { 147.044906040581282, -36.107614840952095 }, { 147.01617394407225, -36.093042088021932 }, { 147.005321894190047, -36.090148207273927 }, { 146.990232374624384, -36.089993177643009 }, { 146.973799269720416, -36.09474740946537 }, { 146.966357863624467, -36.103015638760738 }, { 146.962327102213976, -36.111800631993518 }, { 146.956125929568032, -36.117898450952708 }, { 146.931114537006238, -36.115728040616631 }, { 146.906051466701797, -36.099604994075207 }, { 146.87876631101642, -36.087564385787829 }, { 146.84688195224021, -36.097434583739044 }, { 146.829311964875274, -36.080071302848367 }, { 146.82073367721739, -36.073611748683291 }, { 146.812723830340531, -36.06952931042936 }, { 146.785386997811656, -36.068909193704272 }, { 146.771124302344674, -36.066893812999112 }, { 146.75639651888423, -36.046326592997872 }, { 146.735829298883004, -36.04327768261895 }, { 146.710921259108829, -36.044052829874218 }, { 146.68921715664635, -36.042192477900514 }, { 146.670768671037308, -36.031495456749951 }, { 146.638005813117786, -36.000282891542227 }, { 146.624053176013263, -35.993771660533724 }, { 146.545194939794555, -35.993771660533724 }, { 146.535376417787404, -35.990154311172518 }, { 146.514550816267047, -35.976873467636409 }, { 146.504267206266491, -35.97392791094434 }, { 146.49656741775209, -35.97599496759365 }, { 146.484630162252074, -35.98540007845088 }, { 146.473209669790322, -35.987570488787057 }, { 146.464062942250962, -35.98509002008835 }, { 146.453314244256944, -35.980594170684384 }, { 146.442152134213586, -35.978682142766701 }, { 146.431920201056414, -35.983849785738997 }, { 146.385049677300685, -36.047463473660372 }, { 146.369495070640937, -36.052734469420244 }, { 146.301127150897287, -36.046068210579477 }, { 146.266607293791537, -36.035061131066385 }, { 146.243559605091605, -36.035371188529552 }, { 146.229245232781182, -36.037696628496633 }, { 146.222837356358809, -36.039505303626839 }, { 146.216222771663581, -36.055835055743216 }, { 146.198962843560366, -36.050409031251817 }, { 146.182736444231466, -36.042192477900514 }, { 146.15912031475068, -36.037644951653206 }, { 146.09685021396615, -36.033459160611784 }, { 146.076282993964981, -36.025139256271643 }, { 146.062330356860457, -36.017387790913801 }, { 146.03101443886527, -36.013873792541517 }, { 145.99225711477402, -36.01604420287768 }, { 145.98347212064175, -36.014287204590815 }, { 145.973550245847207, -36.006122328083023 }, { 145.96936445480577, -35.996200453288296 }, { 145.96631554622553, -35.985968520131095 }, { 145.959597609641946, -35.977028497267327 }, { 145.939753860052576, -35.96684824005419 }, { 145.918359816851989, -35.964057712993025 }, { 145.896138951351475, -35.967003268785817 }, { 145.829889765100575, -35.983488050533111 }, { 145.786946649068625, -35.979974053959396 }, { 145.744623650660856, -35.964936212136507 }, { 145.572592807711885, -35.843599948778603 }, { 145.536574334737679, -35.829130547736654 }, { 145.493786249235995, -35.828975519005013 }, { 145.450791457259925, -35.839569186468808 }, { 145.375963983351085, -35.872900486068559 }, { 145.334106072936891, -35.876001071492254 }, { 145.291421340222712, -35.869799899745573 }, { 145.250441928951773, -35.857242526621306 }, { 145.217937452551439, -35.851196383606265 }, { 145.120785761253899, -35.851196383606265 }, { 145.008441196703757, -35.867629490308687 }, { 144.993144973361723, -35.873985690786995 }, { 144.976401809196147, -35.88731821116653 }, { 144.971234166223837, -35.894811293206629 }, { 144.96244917209151, -35.953464043730591 }, { 144.939194777816795, -35.987673841574534 }, { 144.933923782056809, -36.005553888201376 }, { 144.945085891200847, -36.025139256271643 }, { 144.960485468229763, -36.039970391620287 }, { 144.977435337970405, -36.060175876415556 }, { 144.985858595997342, -36.081001478835176 }, { 144.975471633209338, -36.097434583739044 }, { 144.956248000344942, -36.099243258869336 }, { 144.910927769301111, -36.081311537197635 }, { 144.890153842825555, -36.076350599800307 }, { 144.872118768366363, -36.083636977164801 }, { 144.830984328364082, -36.118880303782944 }, { 144.810933873199644, -36.131592705638838 }, { 144.766905552449259, -36.136398614304625 }, { 144.740705600582999, -36.13500335122373 }, { 144.729078404344818, -36.127872002590877 }, { 144.728148228358009, -36.116554863815864 }, { 144.724479201254098, -36.111542249575123 }, { 144.717296176677166, -36.110302016125132 }, { 144.705513950808154, -36.110457044856759 }, { 144.705824009170726, -36.106581313077157 }, { 144.698020867868649, -36.097847995788356 }, { 144.681897821327311, -36.083792005896342 }, { 144.662519158832083, -36.078107598986449 }, { 144.620041131692801, -36.075162042294465 }, { 144.602781202690323, -36.066118665743829 }, { 144.49265872621919, -35.959665215477273 }, { 144.45255781499111, -35.947159519196433 }, { 144.435711298038029, -35.932173354216886 }, { 144.422585484132753, -35.913931573283449 }, { 144.37602501784022, -35.814351087432698 }, { 144.353287388402293, -35.777557468102657 }, { 144.324348586318195, -35.754199721040266 }, { 144.312669713236573, -35.751305841191623 }, { 144.288278435601285, -35.750479017992291 }, { 144.27659956341904, -35.747998549293669 }, { 144.268021274861951, -35.741797376647625 }, { 144.253293492300884, -35.724330742969371 }, { 144.238152296791043, -35.717096042448404 }, { 144.218928663926647, -35.700921319063639 }, { 144.215156284934551, -35.696477145603822 }, { 144.21107384668062, -35.689810885863693 }, { 144.201565383035984, -35.686090182815732 }, { 144.190093214630167, -35.683144627022855 }, { 144.180378046309841, -35.679113864713059 }, { 144.150974156232223, -35.650071709841498 }, { 144.100072870166741, -35.586768080282653 }, { 144.064932896336074, -35.569249769761058 }, { 144.020077753285648, -35.563720391582805 }, { 143.99842532766678, -35.55540048544411 }, { 143.980700310670727, -35.523361097936331 }, { 143.960753209193172, -35.513129163879768 }, { 143.899154901077736, -35.491735120679294 }, { 143.858433873124682, -35.470599460796407 }, { 143.835644565943937, -35.45132415108877 }, { 143.826342807874198, -35.445588066436173 }, { 143.816162550661147, -35.440833835513089 }, { 143.79476850835988, -35.436854750046635 }, { 143.788774042188265, -35.431893812649307 }, { 143.784639927090893, -35.425227552909277 }, { 143.776940138576549, -35.41840626353823 }, { 143.733790317868909, -35.401818129003459 }, { 143.65121137860217, -35.389312432722619 }, { 143.595504184770277, -35.360528660269452 }, { 143.585995722024904, -35.352932223643222 }, { 143.578864374291413, -35.342700290485951 }, { 143.576435582436147, -35.329006035799893 }, { 143.581241490202558, -35.32104786576636 }, { 143.587959425886822, -35.314536634757857 }, { 143.591370070572282, -35.305441583162533 }, { 143.591370070572282, -35.286372979029778 }, { 143.58919966023609, -35.267356051740435 }, { 143.581396518934184, -35.24942433006882 }, { 143.564601678824431, -35.233456313158314 }, { 143.547135045146206, -35.225911554274802 }, { 143.459905226844739, -35.209375094784789 }, { 143.437684361344225, -35.199556572777624 }, { 143.418357374793061, -35.188032728427658 }, { 143.406988560074012, -35.178834324044857 }, { 143.383837517687198, -35.14570973091935 }, { 143.363993768097885, -35.107210789246508 }, { 143.350196160624307, -35.066024671501424 }, { 143.34275475542762, -35.006648450565521 }, { 143.333452997357881, -34.979208266148561 }, { 143.331282587021803, -34.962826837188842 }, { 143.333194614939487, -34.955075371830986 }, { 143.342186313747334, -34.935283298185652 }, { 143.344925164864435, -34.924948012240975 }, { 143.343633253671726, -34.91859181086339 }, { 143.340274285829537, -34.911047051979878 }, { 143.337535434712436, -34.902003675429242 }, { 143.338052198649962, -34.890841567184523 }, { 143.341876255384875, -34.886965833606354 }, { 143.349110955905928, -34.882211602683284 }, { 143.35608727400853, -34.875752047618931 }, { 143.359187860331417, -34.866605320079458 }, { 143.358206008400543, -34.85911223714001 }, { 143.353400099734813, -34.845883070447314 }, { 143.351746454235467, -34.835599460446787 }, { 143.358412713975611, -34.81704762115082 }, { 143.360479770624806, -34.806247247212696 }, { 143.355467157283442, -34.801441338546908 }, { 143.328130323855362, -34.784388116018761 }, { 143.314074334862653, -34.782889500150304 }, { 143.296969436390384, -34.791106051702869 }, { 143.282706740024025, -34.792501315683211 }, { 143.276660597908176, -34.770693862231909 }, { 143.268754103818765, -34.75395069806622 }, { 143.251029086822939, -34.748007907838655 }, { 143.23221886600777, -34.743925469584809 }, { 143.221418492069688, -34.733176771590735 }, { 143.156719599429948, -34.702997735157311 }, { 143.142611932694535, -34.699018649690942 }, { 143.05011111863314, -34.692197361219272 }, { 143.012697381678834, -34.672870374668022 }, { 142.995747511938077, -34.668684583626685 }, { 142.988616164204586, -34.682275485525253 }, { 142.981381463683533, -34.690595391663948 }, { 142.96458662267446, -34.681241956750867 }, { 142.934045851934457, -34.658039238420102 }, { 142.921746861228598, -34.658039238420102 }, { 142.914925571857566, -34.66181161921088 }, { 142.909137811260962, -34.667082614970653 }, { 142.880354038807809, -34.679329928833184 }, { 142.878648715565816, -34.674834079429218 }, { 142.869191928764451, -34.66181161921088 }, { 142.864437697841538, -34.652458185197077 }, { 142.860045201225091, -34.629720553960397 }, { 142.855187615715863, -34.62083220794004 }, { 142.847074416051498, -34.614837741768412 }, { 142.817980585235773, -34.603468927049363 }, { 142.807231887241812, -34.591893405856055 }, { 142.799738804302365, -34.585433851690894 }, { 142.790023635082662, -34.582333266267185 }, { 142.779223261144637, -34.584193616442249 }, { 142.757157424375578, -34.593753756930312 }, { 142.745323520763861, -34.595975844109901 }, { 142.726099887899466, -34.603210544630969 }, { 142.716798129829726, -34.62088388388409 }, { 142.708116490283714, -34.665532322258841 }, { 142.705015903960827, -34.670544935600233 }, { 142.700158319350862, -34.675609225785124 }, { 142.695765822734586, -34.681396987281147 }, { 142.693853794816732, -34.689096774896299 }, { 142.696644321877898, -34.705219821437623 }, { 142.69886640815821, -34.712764581220412 }, { 142.700675084187765, -34.712661227533559 }, { 142.694680617116774, -34.730903008467095 }, { 142.687342563808215, -34.735657241188733 }, { 142.676438837082628, -34.733951917946641 }, { 142.659643996073612, -34.733176771590735 }, { 142.64005862890258, -34.734417005940088 }, { 142.630808546777018, -34.736329033857871 }, { 142.629206578121057, -34.743615411222265 }, { 142.632358840388065, -34.761082044900434 }, { 142.643727655107114, -34.778497002634538 }, { 142.642797479120304, -34.787643731073288 }, { 142.625537551017146, -34.795240166800312 }, { 142.608794386851457, -34.781442560225983 }, { 142.594531692283738, -34.777721856278632 }, { 142.578511997630585, -34.777411797916187 }, { 142.556601189593152, -34.774156182861489 }, { 142.547971225991205, -34.770900566907599 }, { 142.536654087216391, -34.764957777579312 }, { 142.526732212421678, -34.75767140111428 }, { 142.522494745436177, -34.750229994118882 }, { 142.52363162699794, -34.727440687837515 }, { 142.522494745436177, -34.719534193748032 }, { 142.494589472126393, -34.665532322258841 }, { 142.471645136214022, -34.643311455859049 }, { 142.467924433166047, -34.634164727420213 }, { 142.468647902678526, -34.62413949983808 }, { 142.470094842602862, -34.617783297561118 }, { 142.470404900965377, -34.611995537863748 }, { 142.467924433166047, -34.603468927049363 }, { 142.458570998252867, -34.591583346594135 }, { 142.394802280700674, -34.546934910018038 }, { 142.385758905049329, -34.533395684962898 }, { 142.371392856794841, -34.444718926737139 }, { 142.372323032781651, -34.42466847067341 }, { 142.378317498953379, -34.403171074685361 }, { 142.398057895755187, -34.373715508663778 }, { 142.40642947783806, -34.356403903717151 }, { 142.396455927099339, -34.338007094052173 }, { 142.38239993720731, -34.335681654984384 }, { 142.365036656316533, -34.340280857175827 }, { 142.344934524308769, -34.342761325874534 }, { 142.328191360143194, -34.334699802154134 }, { 142.305143671443318, -34.317129814789126 }, { 142.284886508905174, -34.297854505980666 }, { 142.272897576561832, -34.280439548246562 }, { 142.265869581615846, -34.277493991554493 }, { 142.258789910725852, -34.272843112519624 }, { 142.255637649357936, -34.263903089655841 }, { 142.253984002959328, -34.240493665750108 }, { 142.248816359987075, -34.218634534556102 }, { 142.238377720355459, -34.19625863942467 }, { 142.235122105300945, -34.191917819651707 }, { 142.224218377675925, -34.190367526939809 }, { 142.199775424995835, -34.192796318795089 }, { 142.190421990982031, -34.188197116603646 }, { 142.175952589940096, -34.171608982068861 }, { 142.164170364070969, -34.16246225363011 }, { 142.150114374178997, -34.158586520951147 }, { 142.128720330978524, -34.157811374595241 }, { 142.122932571281126, -34.159826756199863 }, { 142.105259231128628, -34.16881845500771 }, { 142.094252150716159, -34.170833835712955 }, { 142.077457309707029, -34.136675713813162 }, { 142.051257358740088, -34.115953464181018 }, { 142.025160760560652, -34.112232761133043 }, { 141.971210565015554, -34.123704928639498 }, { 141.960358515133294, -34.124635104626321 }, { 141.94940311066506, -34.124118340688895 }, { 141.938137648733459, -34.121637871990188 }, { 141.926665481226905, -34.116831964223778 }, { 141.905271438026375, -34.126598810286879 }, { 141.887391392298809, -34.13047454206648 }, { 141.840985955637279, -34.13047454206648 }, { 141.817008090950594, -34.126185398237496 }, { 141.770706007975832, -34.10742685246727 }, { 141.748536819318758, -34.103189385481784 }, { 141.706110468123597, -34.11001067485283 }, { 141.665906203208692, -34.127063896481602 }, { 141.630972934952979, -34.149078058205802 }, { 141.60451460156753, -34.170833835712955 }, { 141.581466912867654, -34.201943048133117 }, { 141.567927687812528, -34.213880303633104 }, { 141.546171910305361, -34.218634534556102 }, { 141.53733524022914, -34.215844007494937 }, { 141.529583774871298, -34.208660983817396 }, { 141.524054396693032, -34.198842461810131 }, { 141.518835076877338, -34.176569919466189 }, { 141.510670201268738, -34.172229098793849 }, { 141.459303827209908, -34.169180190213581 }, { 141.44628136609208, -34.164012547241285 }, { 141.415223829616082, -34.145770766307763 }, { 141.408970981925222, -34.140706476122958 }, { 141.391917759397131, -34.133678481176943 }, { 141.368663365122188, -34.13729583053815 }, { 141.345925734784885, -34.143652031915749 }, { 141.330784540174363, -34.144737236634185 }, { 141.321741163623813, -34.136210625819714 }, { 141.309545525705403, -34.114351494625794 }, { 141.299727003698251, -34.11001067485283 }, { 141.285774366593728, -34.105721531023832 }, { 141.274767287080635, -34.096316420166687 }, { 141.265827265116229, -34.086962986152884 }, { 141.258489210908408, -34.082673841424608 }, { 141.252753127155074, -34.081381931131205 }, { 141.241849400429544, -34.076007581684564 }, { 141.234614699009114, -34.07523243622795 }, { 141.228206821687479, -34.077557875295739 }, { 141.21415083179545, -34.086859632466115 }, { 141.206657749755379, -34.089495130795655 }, { 141.190121291164644, -34.089288425220687 }, { 141.181181268300861, -34.084379163767409 }, { 141.173016391792999, -34.077041110458865 }, { 141.158857050012784, -34.069031263581991 }, { 141.134104038970122, -34.063966974296378 }, { 141.045582310375266, -34.062209975110235 }, { 141.024084914387231, -34.051254570641916 }, { 141.000107049700546, -34.018543389565721 }, { 141.000107049700546, -33.711533704516853 }, { 141.000107049700546, -33.397444349477112 }, { 141.000107049700546, -33.083354993538094 }, { 141.000107049700546, -32.769213962554304 }, { 141.000107049700546, -32.455072930671236 }, { 141.000107049700546, -32.141035251575644 }, { 141.000107049700546, -31.826945895636626 }, { 141.000107049700546, -31.512804863753459 }, { 141.000107049700546, -31.198663831870377 }, { 141.000107049700546, -30.88457447683065 }, { 141.000107049700546, -30.570536797735059 }, { 141.000107049700546, -30.256344089008465 }, { 141.000107049700546, -29.942203058024674 }, { 141.000107049700546, -29.628165378929083 }, { 141.000107049700546, -29.314076022990065 }, { 141.000107049700546, -28.999934991106983 }, { 141.485865513382748, -28.999934991106983 }, { 141.971675653008901, -28.999934991106983 }, { 142.457434116691104, -28.999934991106983 }, { 142.943192580373193, -28.999934991106983 }, { 143.428899367212068, -28.999934991106983 }, { 143.914657830894157, -28.999934991106983 }, { 144.400519647363865, -28.999934991106983 }, { 144.886278111045954, -28.999934991106983 }, { 145.37203657382878, -28.999934991106983 }, { 145.857795038410245, -28.999934991106983 }, { 146.343553502092448, -28.999934991106983 }, { 146.829311964875274, -28.999934991106983 }, { 147.315070428557476, -28.999934991106983 }, { 147.800828892239565, -28.999934991106983 }, { 148.286587355921711, -28.999934991106983 }, { 148.772397496447297, -28.999934991106983 }, { 148.966339145635061, -28.999934991106983 }, { 148.971403435819866, -28.999728284632653 }, { 148.998171827567717, -28.977507420031401 }, { 149.024423456277475, -28.968050631431467 }, { 149.046489293046477, -28.954097996125583 }, { 149.063387485943679, -28.936321303185608 }, { 149.073877802418565, -28.915444023922547 }, { 149.083644646683069, -28.869193616891849 }, { 149.093566522377046, -28.848419692215018 }, { 149.11175662736639, -28.839738050870352 }, { 149.134597609591992, -28.836844171021625 }, { 149.157386915873474, -28.829196058451345 }, { 149.178625930342378, -28.818240654882302 }, { 149.196816034432402, -28.805579928970559 }, { 149.204670851678486, -28.795813083806721 }, { 149.210665317850101, -28.784547620975957 }, { 149.217589960008581, -28.775349215693694 }, { 149.237433709598008, -28.768114516072004 }, { 149.249939406778196, -28.760052991452326 }, { 149.260946487190665, -28.75002776476957 }, { 149.265649042169514, -28.740726006699816 }, { 149.275157504914944, -28.739330742719645 }, { 149.377166782620861, -28.691788424496167 }, { 149.399180943445742, -28.689514662271876 }, { 149.416337518761509, -28.68072966903901 }, { 149.432357213414662, -28.661040948181167 }, { 149.469357538319628, -28.594998467505221 }, { 149.484447056086765, -28.583939711148702 }, { 149.577878046134913, -28.572570895530447 }, { 149.595241327025576, -28.56538787185282 }, { 149.610175816060973, -28.577738538502743 }, { 149.614878371039993, -28.593861585943444 }, { 149.620872838110984, -28.607814223047967 }, { 149.639321323720139, -28.613808689219596 }, { 149.675339796694175, -28.610604750109133 }, { 149.690946080197364, -28.614015394794649 }, { 149.704485305252604, -28.627451267062298 }, { 149.730116815438635, -28.613808689219596 }, { 149.741744012576078, -28.609622898178174 }, { 149.759158970310182, -28.606987399848649 }, { 149.870573357974081, -28.604558607993368 }, { 149.907677036565929, -28.608899427766417 }, { 149.95087853411701, -28.600114434533552 }, { 149.971807489324135, -28.599184258546728 }, { 150.003278436050948, -28.602491549545405 }, { 150.019814894641684, -28.600114434533552 }, { 150.058468865945372, -28.583991387992128 }, { 150.1045642442445, -28.573914482667206 }, { 150.158514438890165, -28.554587497914696 }, { 150.173345575138171, -28.552107029215989 }, { 150.236132439860228, -28.556086113783152 }, { 150.258353306260062, -28.553140557990375 }, { 150.276801792768424, -28.542391859996386 }, { 150.298144159125684, -28.534950453000988 }, { 150.322432082174885, -28.543632093446377 }, { 150.361809523890315, -28.572829277948841 }, { 150.417826776084837, -28.625745944719583 }, { 150.449556106129364, -28.646468193452364 }, { 150.492137486056151, -28.654736422747717 }, { 150.62112186108493, -28.65892221378914 }, { 150.664116653061058, -28.654736422747717 }, { 150.752586704812586, -28.63597787877606 }, { 150.793514439239971, -28.635047702789251 }, { 150.834803907973878, -28.647915134276047 }, { 150.87133914578493, -28.670032646989085 }, { 150.890976189799346, -28.678662611490324 }, { 150.933557570625396, -28.687137547260022 }, { 150.948853794866693, -28.69891977312902 }, { 150.963013136646907, -28.712717379703278 }, { 150.979394565606697, -28.723672784171683 }, { 151.000530227288152, -28.727083428857114 }, { 151.02523156058794, -28.728323663206467 }, { 151.045902134276105, -28.73488657015902 }, { 151.054480421933818, -28.754368584542533 }, { 151.053550245947008, -28.788268324923209 }, { 151.055617304395071, -28.810644220054726 }, { 151.062128533604891, -28.828007500945418 }, { 151.07752811063375, -28.836947523809187 }, { 151.10078250490858, -28.840874932432214 }, { 151.140004917892668, -28.84165007878812 }, { 151.160520461050453, -28.846094252247937 }, { 151.181759474620037, -28.856946303029488 }, { 151.219121534731073, -28.883249606783949 }, { 151.287437779429865, -28.920818372469896 }, { 151.301855503628587, -28.984328708503071 }, { 151.309141880093705, -28.999934991106983 }, { 151.302113886047039, -29.010787041888449 }, { 151.302837355559461, -29.018331800771961 }, { 151.306816441025887, -29.024326266943675 }, { 151.309141880093705, -29.030682467421897 }, { 151.309141880093705, -29.06137826869211 }, { 151.315343051840273, -29.099257093639963 }, { 151.318753697425166, -29.105354912599168 }, { 151.335755243109986, -29.115018405874693 }, { 151.342628209324346, -29.122821547176699 }, { 151.344230177980307, -29.137445976950275 }, { 151.343455031624387, -29.153000583610037 }, { 151.350896437720451, -29.165454603946827 }, { 151.376114536756461, -29.170622246919109 }, { 151.384382766051829, -29.168555190269799 }, { 151.405156691628008, -29.159046725725801 }, { 151.422675002149674, -29.154550877221212 }, { 151.42536217732254, -29.148918144456815 }, { 151.426602410772603, -29.142148532828486 }, { 151.430788201814039, -29.136515801862743 }, { 151.45259565706391, -29.126335544649706 }, { 151.461845738290151, -29.120496108108895 }, { 151.467581822043371, -29.107887058141202 }, { 151.48261966386633, -29.085614515797261 }, { 151.492283157141969, -29.078121432857799 }, { 151.514038934649136, -29.066907646870376 }, { 151.520188429552377, -29.06137826869211 }, { 151.520963575908297, -29.05435027374611 }, { 151.520188429552377, -29.027271823635743 }, { 151.526544630929948, -29.008254897245678 }, { 151.549333938110806, -28.970014337091953 }, { 151.554294874608672, -28.955234876788182 }, { 151.55739546093173, -28.954563084119044 }, { 151.564423455877829, -28.950583997753299 }, { 151.572950066692215, -28.948103529953883 }, { 151.580856560781683, -28.946708265973697 }, { 151.587522821421032, -28.9461915020362 }, { 151.593052199599299, -28.944641208425026 }, { 151.610208774915066, -28.933737480800133 }, { 151.616720005024206, -28.931722100994151 }, { 151.623851352757697, -28.930636894477146 }, { 151.637493930600385, -28.930016777752073 }, { 151.643695103246444, -28.928879897089573 }, { 151.654392125296397, -28.925004163511318 }, { 151.664365676035175, -28.91993987422579 }, { 151.700435825852651, -28.896117039170036 }, { 151.715370314888162, -28.888778984962215 }, { 151.720382929128903, -28.88712533856355 }, { 151.725137160051872, -28.886660251469465 }, { 151.729167922361682, -28.888985690537183 }, { 151.762550897006292, -28.947586765117094 }, { 151.766271600953644, -28.951204116276941 }, { 151.770922479089108, -28.954149672069732 }, { 151.776090122960795, -28.956268405562469 }, { 151.782704705857498, -28.957508639911822 }, { 151.796088902181111, -28.957973727905184 }, { 151.802290073927679, -28.958955579836143 }, { 151.806785923331631, -28.961694430953244 }, { 151.81453738779021, -28.968670749955109 }, { 151.819033238093482, -28.971564629803837 }, { 151.824149205121671, -28.973580010509096 }, { 151.829626907355873, -28.971771336278181 }, { 151.833967727128936, -28.965621839576187 }, { 151.840789015600535, -28.938336683890853 }, { 151.847610304971568, -28.925314222773139 }, { 151.852726271999813, -28.919578139019919 }, { 151.858772414115663, -28.916322523965306 }, { 151.864508497868769, -28.914772231253494 }, { 151.870864700145773, -28.914307143260046 }, { 151.876910842261509, -28.914617200723214 }, { 151.897529739106119, -28.918337904670565 }, { 151.920060662969149, -28.9247457819923 }, { 151.924246454010586, -28.925469251504765 }, { 151.928742304313801, -28.925365898717203 }, { 151.933858270442784, -28.924280693998838 }, { 151.964399042082107, -28.910379733737742 }, { 151.975871209588604, -28.906917413108161 }, { 151.982744174903701, -28.906297295483796 }, { 151.99623172401482, -28.906297295483796 }, { 152.000469191899583, -28.905832207490349 }, { 152.004603306097749, -28.904643649984422 }, { 152.008944126769961, -28.902628269279163 }, { 152.013646681748924, -28.899217624593646 }, { 152.017832472790417, -28.894825127977256 }, { 152.021656528625897, -28.888055514550359 }, { 152.024343702899557, -28.882061049277937 }, { 152.025583938148202, -28.875704847900437 }, { 152.025583938148202, -28.850590101651818 }, { 152.026979201229096, -28.845215753104554 }, { 152.038606399265916, -28.820462742061892 }, { 152.042482131045404, -28.80961069128044 }, { 152.044032423757301, -28.795813083806721 }, { 152.043877395025675, -28.771628512645719 }, { 152.046202834093492, -28.746410413609709 }, { 152.04899336205392, -28.735455010940044 }, { 152.051163772390169, -28.73054574948678 }, { 152.054005976294661, -28.725894870451896 }, { 152.063927851089431, -28.713699232533514 }, { 152.066201614213071, -28.70904835349873 }, { 152.06702843561385, -28.703157241013869 }, { 152.064547967814406, -28.695819186806048 }, { 152.058450148855229, -28.686259047217277 }, { 152.030699905176505, -28.657940361858181 }, { 152.007703892420636, -28.639233493830673 }, { 152.003259718960805, -28.63365243880898 }, { 151.998402134350954, -28.625332532670285 }, { 151.99530154802801, -28.613963717951222 }, { 151.993131137691819, -28.598822524240134 }, { 151.985224643602351, -28.585490003860599 }, { 151.958404575910436, -28.560581964086396 }, { 151.959489780628815, -28.549264825311482 }, { 151.961040074240088, -28.544975680583207 }, { 151.963985630932086, -28.54006642002922 }, { 151.967551304349229, -28.536449069768736 }, { 151.973132359370879, -28.533503513076667 }, { 151.98041873583594, -28.531229749953013 }, { 151.991684197767427, -28.530454603597121 }, { 152.000882603049604, -28.528077487685891 }, { 152.010391066694297, -28.524098403118813 }, { 152.035195753681023, -28.507665296416292 }, { 152.040776808702788, -28.501825859875495 }, { 152.050388625134985, -28.489733574744676 }, { 152.163973423134962, -28.437075291291606 }, { 152.172345006117098, -28.43505990968707 }, { 152.187279494253175, -28.434233086487737 }, { 152.21828535388596, -28.437695408016694 }, { 152.225158319201057, -28.437230320023232 }, { 152.232703078084569, -28.434956556899593 }, { 152.24019616102396, -28.431080824220615 }, { 152.24980797835542, -28.423070976444464 }, { 152.267016228715931, -28.405914402028031 }, { 152.29171756381453, -28.38632903395775 }, { 152.300244174628972, -28.383073418903138 }, { 152.31311160701506, -28.380334567786036 }, { 152.357036574977883, -28.376148776744614 }, { 152.386957228992912, -28.365761813956524 }, { 152.403907098733669, -28.355736585475015 }, { 152.408557977768453, -28.351964206482904 }, { 152.412123651185595, -28.348191826591503 }, { 152.414914179145967, -28.343799329975113 }, { 152.429021844982117, -28.308504326513443 }, { 152.432587519298522, -28.304628594733842 }, { 152.447987095428118, -28.297548922944415 }, { 152.478217807805606, -28.269333591272272 }, { 152.487157830669275, -28.263390801943984 }, { 152.492170444910016, -28.261220391607722 }, { 152.500490351048825, -28.261685478701892 }, { 152.510825636993502, -28.265457858593294 }, { 152.528343948414488, -28.278221938191905 }, { 152.534855177624308, -28.287161961055673 }, { 152.537490675953904, -28.295171807932562 }, { 152.536767206441368, -28.307160740275975 }, { 152.537800735215683, -28.312690117554865 }, { 152.539971144652554, -28.31770273179562 }, { 152.543381789338071, -28.321578463575221 }, { 152.547412550748504, -28.324937433215965 }, { 152.552063429783459, -28.327986341796233 }, { 152.56415571491425, -28.332998956036988 }, { 152.574284296183237, -28.333774101493603 }, { 152.583275994991197, -28.331603692056717 }, { 152.594024692985158, -28.324472345222517 }, { 152.598313836814157, -28.318012791057441 }, { 152.600174187888513, -28.311501560048939 }, { 152.600949335143696, -28.305455417933175 }, { 152.603119744580454, -28.300649509267387 }, { 152.606323683691016, -28.296722100644445 }, { 152.610251093213435, -28.293363131902993 }, { 152.616658969635637, -28.293208103171452 }, { 152.622240024657401, -28.293569837477961 }, { 152.647044713442767, -28.316720879864661 }, { 152.655106236263691, -28.321836846892978 }, { 152.75101769411134, -28.358010348598754 }, { 152.757994013113205, -28.358630466223033 }, { 152.766934035077611, -28.358630466223033 }, { 152.781610141694614, -28.355064792805962 }, { 152.798198277128677, -28.353824557557246 }, { 152.825018344820705, -28.343954359606016 }, { 152.830909459104248, -28.339820244508658 }, { 152.84207156824823, -28.329123224257387 }, { 152.84630903523373, -28.32581593146007 }, { 152.854370558954088, -28.32364552202327 }, { 152.865687697729015, -28.322767021980511 }, { 152.887856887285466, -28.324472345222517 }, { 152.908217400812305, -28.328348077002119 }, { 152.934262323047733, -28.339820244508658 }, { 152.944184197842446, -28.341370538119833 }, { 153.000356479667744, -28.344109389236934 }, { 153.004387241977611, -28.345246269899434 }, { 153.010019972943439, -28.346331475517161 }, { 153.066140577925296, -28.34519459395537 }, { 153.075649041569989, -28.346486505148064 }, { 153.081385126222585, -28.348346856222506 }, { 153.091927117742216, -28.353204440832258 }, { 153.098748407113249, -28.354289645550693 }, { 153.10665490120266, -28.35387623529995 }, { 153.116886835259152, -28.350207208196039 }, { 153.131769646551902, -28.338890068521849 }, { 153.153525424958445, -28.307160740275975 }, { 153.162672154296388, -28.303853447478573 }, { 153.166496210132038, -28.301734713985837 }, { 153.170837029904988, -28.296463718225965 }, { 153.175694615414216, -28.288763929711635 }, { 153.180035435187165, -28.276930026999125 }, { 153.192489454624649, -28.259825127627551 }, { 153.217604200873097, -28.258584894177574 }, { 153.232331985232918, -28.260135185990094 }, { 153.312740513264032, -28.242875257886809 }, { 153.324987828025769, -28.241996758743426 }, { 153.354185011628942, -28.2500066056203 }, { 153.38250369698801, -28.237552586182886 }, { 153.472265659932248, -28.175282484499064 }, { 153.506524056145452, -28.149268634823883 }, { 153.531993035000028, -28.177911065999879 }, { 153.562510613000086, -28.174981377999941 }, { 153.570567254000025, -28.1937802059999 }, { 153.581228061000047, -28.246758721999939 }, { 153.591075066000087, -28.268487237999906 }, { 153.590830925000148, -28.318536065999922 }, { 153.563487175000148, -28.460870049999897 }, { 153.562510613000086, -28.504571221999882 }, { 153.576019727000073, -28.589613539999903 }, { 153.584239129000082, -28.608086846999925 }, { 153.620941602000073, -28.644463799999897 }, { 153.630625847000033, -28.661553643999937 }, { 153.629079623000109, -28.667250257999925 }, { 153.619883660000028, -28.686618747999944 }, { 153.61695397200009, -28.695733330999929 }, { 153.617523634000065, -28.705824476999908 }, { 153.619639519000089, -28.717543226999894 }, { 153.619639519000089, -28.729587497999901 }, { 153.601328972000033, -28.76140715899993 }, { 153.600108269000089, -28.78337981599995 }, { 153.610118035000085, -28.826104424999954 }, { 153.605967644000145, -28.867445570999905 }, { 153.582286004000025, -28.896091403999961 }, { 153.521332227000016, -28.943454684999907 }, { 153.475596550000091, -29.000176690999879 }, { 153.453786655000044, -29.035577080999886 }, { 153.438975457000083, -29.073011976999922 }, { 153.436208530000044, -29.085137627999913 }, { 153.435557488000086, -29.093845309999907 }, { 153.44507897200009, -29.140069268999909 }, { 153.445811394000089, -29.151625257999925 }, { 153.441416863000086, -29.155368747999958 }, { 153.422699415000068, -29.161065362999949 }, { 153.418304884000065, -29.164971612999935 }, { 153.415212436000104, -29.175957940999908 }, { 153.370860222000033, -29.241631768999909 }, { 153.350596550000148, -29.281019789999888 }, { 153.340342644000089, -29.322686455999943 }, { 153.349457227000016, -29.36109791499986 }, { 153.366709832000083, -29.38274505 }, { 153.369965040000068, -29.396661065999922 }, { 153.360118035000028, -29.412041924999954 }, { 153.356455925000091, -29.424004815999893 }, { 153.357595248000109, -29.443129164999874 }, { 153.36085045700014, -29.461521091999913 }, { 153.363780144000089, -29.470391533999958 }, { 153.352061394000089, -29.490004164999917 }, { 153.344004754000082, -29.535414320999919 }, { 153.32748457100007, -29.565036716999956 }, { 153.324473504000082, -29.575860283999944 }, { 153.322276238000086, -29.597588799999926 }, { 153.323252800000148, -29.602634372999958 }, { 153.32789147200009, -29.612074476999879 }, { 153.329112175000091, -29.618096612999878 }, { 153.326996290000011, -29.624444268999909 }, { 153.31771894600007, -29.635186455999929 }, { 153.315440300000148, -29.642266533999887 }, { 153.317881707000083, -29.666599216999956 }, { 153.323008660000028, -29.682305596999925 }, { 153.321625196000014, -29.697523695999905 }, { 153.296397332000083, -29.73503997199991 }, { 153.291188998000052, -29.75318775799991 }, { 153.288422071000014, -29.771254164999931 }, { 153.288096550000091, -29.78573984199997 }, { 153.294932488000086, -29.826592705999929 }, { 153.29078209700009, -29.835544528999947 }, { 153.276703321000014, -29.850762627999927 }, { 153.273773634, -29.857354424999912 }, { 153.271494988000143, -29.901625257999868 }, { 153.26734459700009, -29.924248955999929 }, { 153.260101759000065, -29.943291924999926 }, { 153.224457227000016, -29.986911716999927 }, { 153.219899936000104, -30.001397393999881 }, { 153.216563347000033, -30.007256768999923 }, { 153.20240319100003, -30.024672132999896 }, { 153.199229363000143, -30.03582122199991 }, { 153.200043165000068, -30.046563408999916 }, { 153.205577019000089, -30.073663018999952 }, { 153.203786655000101, -30.129164320999905 }, { 153.189626498000109, -30.174981377999899 }, { 153.137217644000089, -30.257989190999893 }, { 153.146494988000086, -30.286065362999892 }, { 153.132090691000087, -30.323825778999947 }, { 153.089366082000083, -30.388929945999891 }, { 153.082530144000089, -30.406426690999936 }, { 153.07545006600003, -30.438409112999935 }, { 153.05054772200009, -30.473321221999953 }, { 153.043142123000109, -30.493829033999916 }, { 153.023070386000143, -30.575506187999935 }, { 153.018077019000089, -30.633070570999891 }, { 153.007985873000109, -30.651625257999896 }, { 153.01099694100003, -30.65536874799993 }, { 152.987796365, -30.734633817999864 }, { 152.999859214000082, -30.751121505 }, { 153.005001433000075, -30.835814295999867 }, { 153.027517123000109, -30.875583591999956 }, { 153.034841342000107, -30.882500908999958 }, { 153.043142123000109, -30.88795338299991 }, { 153.054535352000073, -30.892998955999929 }, { 153.064626498000109, -30.893487237999921 }, { 153.068858269000145, -30.885511976999879 }, { 153.072113477000073, -30.881931247999901 }, { 153.079112175000148, -30.885918877999885 }, { 153.086273634, -30.894707940999936 }, { 153.089366082000083, -30.905694268999895 }, { 153.087901238000143, -30.926690362999935 }, { 153.085703972000033, -30.935153903999975 }, { 153.081879102000016, -30.943942966999941 }, { 153.063327253000068, -30.95959309 }, { 153.046599170000036, -30.992753975999861 }, { 153.039879977000112, -31.029965145999938 }, { 153.045923855000126, -31.046572868999888 }, { 153.057892177000156, -31.05163744799998 }, { 153.060919110000157, -31.06058328099995 }, { 153.05950072100012, -31.077209977999942 }, { 153.041631142000028, -31.0901026559999 }, { 153.008880172000147, -31.122248232999894 }, { 152.980615041000135, -31.16591475599995 }, { 152.97921828900013, -31.199245471999959 }, { 152.959894019000103, -31.24031530499991 }, { 152.970411879000039, -31.255676558999923 }, { 152.976735873000052, -31.320000908999916 }, { 152.93258908100006, -31.366007817999986 }, { 152.917828269000154, -31.395254330999933 }, { 152.916435393000029, -31.420656614999942 }, { 152.934354484000096, -31.438392126999929 }, { 152.93887444500001, -31.454869447999911 }, { 152.940381062000029, -31.46248367099993 }, { 152.934502086000066, -31.482810541999939 }, { 152.906297820000134, -31.505727677999928 }, { 152.876587434000101, -31.532446145999955 }, { 152.845380728000066, -31.569318604999907 }, { 152.849915115000044, -31.599780167999924 }, { 152.836561964, -31.625196178999914 }, { 152.848532646000081, -31.644220246999936 }, { 152.832146959000113, -31.655678984999909 }, { 152.812788211, -31.676031504999898 }, { 152.788948559, -31.704008613999875 }, { 152.803901470000028, -31.719226881999958 }, { 152.800929022000048, -31.733208108999918 }, { 152.77554759700007, -31.754852626999963 }, { 152.744185439000091, -31.793022631999889 }, { 152.736728193000147, -31.827349075999933 }, { 152.747215040000015, -31.842584729999956 }, { 152.715775884000095, -31.859170137999911 }, { 152.69288170700014, -31.88534921699997 }, { 152.664317254000082, -31.903497002999885 }, { 152.609255093, -31.945848262999917 }, { 152.546372674000054, -32.04367920499989 }, { 152.555345725000052, -32.071630892999892 }, { 152.528330925000091, -32.097100518999881 }, { 152.520274285000085, -32.115817966999941 }, { 152.51531009200005, -32.136488539999874 }, { 152.510082932000103, -32.161881366999893 }, { 152.51695268900005, -32.177392201999936 }, { 152.535678945000143, -32.183199517999938 }, { 152.545381547000034, -32.196888175999931 }, { 152.564787202000105, -32.20602140799987 }, { 152.569509311000104, -32.219333591999899 }, { 152.556651238000086, -32.232028903999947 }, { 152.546560092000107, -32.24627044099995 }, { 152.53998826600008, -32.259797076999874 }, { 152.533515488000091, -32.268907929999912 }, { 152.525957109000103, -32.281664572999972 }, { 152.524871412000039, -32.294425623999956 }, { 152.527042902000119, -32.312660829999913 }, { 152.539976734000049, -32.314488747999903 }, { 152.55445397200009, -32.321221612999906 }, { 152.55201256600003, -32.328057549999926 }, { 152.548350457000083, -32.332126559999978 }, { 152.54420006600003, -32.33570728999986 }, { 152.540782097000033, -32.341729424999954 }, { 152.536631707000083, -32.354587497999987 }, { 152.533946160000028, -32.369561455999929 }, { 152.524834943000144, -32.388305282999951 }, { 152.520499171000154, -32.410176412999903 }, { 152.521559969000066, -32.427494067999973 }, { 152.539886296000077, -32.442091940999973 }, { 152.402393537000137, -32.489428571999923 }, { 152.353559882000013, -32.514923347999868 }, { 152.294763900000021, -32.559588894999891 }, { 152.285929613000064, -32.588803960999968 }, { 152.264174174, -32.594256083999895 }, { 152.235861814000089, -32.60699906299989 }, { 152.210669949000078, -32.630738652999909 }, { 152.19198882, -32.652670384999908 }, { 152.187500835000094, -32.669135910999984 }, { 152.2037207300001, -32.686535898999935 }, { 152.219248894000145, -32.697198174999897 }, { 152.205577019000089, -32.697930596999925 }, { 152.202159050000091, -32.695896091999899 }, { 152.194102410000085, -32.687188408999916 }, { 152.190684441000087, -32.684258721999896 }, { 152.186045769000145, -32.683526299999954 }, { 152.17530358200014, -32.685153903999975 }, { 152.170746290000068, -32.684258721999896 }, { 152.145274285000085, -32.66659921699997 }, { 152.136729363000143, -32.663750908999944 }, { 152.135264519000089, -32.666680596999953 }, { 152.116709832000083, -32.680108330999957 }, { 152.109385613000086, -32.684258721999896 }, { 152.060883009, -32.697930596999925 }, { 152.086761915000011, -32.715915622999958 }, { 152.092295769000145, -32.718438408999887 }, { 152.16732832100007, -32.718438408999887 }, { 152.177989129000025, -32.720635674999883 }, { 152.190196160000085, -32.72527434699991 }, { 152.197764519000145, -32.729913018999923 }, { 152.194834832000083, -32.732110283999916 }, { 152.190928582000083, -32.736586195999891 }, { 152.189463738000143, -32.758558851999908 }, { 152.185069207000083, -32.766778252999899 }, { 152.174815300000148, -32.76921965899993 }, { 152.150157097000033, -32.766045830999957 }, { 152.14014733200014, -32.77019622199991 }, { 152.131195509, -32.780857028999932 }, { 152.127614780000044, -32.786553643999923 }, { 152.12256920700014, -32.790134372999901 }, { 152.109385613000086, -32.79412200299997 }, { 152.059428755000056, -32.785253865999934 }, { 151.984926879000056, -32.798745724999904 }, { 151.935188047, -32.815829072999946 }, { 151.875662482000052, -32.842087877999944 }, { 151.856219267000085, -32.855858949999927 }, { 151.834033071000079, -32.864967128999922 }, { 151.799237364000078, -32.893680377999956 }, { 151.803558790000068, -32.919366143999895 }, { 151.787852410000085, -32.931898695999891 }, { 151.772507057000155, -32.94560852899987 }, { 151.748863030000052, -32.957023378999935 }, { 151.737634974000059, -32.972001860999896 }, { 151.736035076, -32.993997022999906 }, { 151.734385613000143, -33.014825127999899 }, { 151.720535107000103, -33.019371191 }, { 151.703800128000012, -33.028521321999904 }, { 151.681488477000016, -33.049981377999956 }, { 151.670583530000044, -33.06113046699997 }, { 151.667002800000148, -33.073337497999944 }, { 151.665688671000055, -33.087343205999986 }, { 151.65291507500001, -33.110432838999955 }, { 151.646739129000025, -33.144707940999936 }, { 151.634938998000052, -33.158623955999914 }, { 151.629567905000044, -33.1742489559999 }, { 151.625987175000148, -33.191582940999893 }, { 151.61226343800007, -33.207550919999917 }, { 151.589994362000141, -33.218937254999943 }, { 151.568952752000087, -33.244224817999878 }, { 151.563181025000063, -33.265009942999953 }, { 151.576019727000016, -33.282484632999953 }, { 151.568957243, -33.292227829999902 }, { 151.53068564400013, -33.319118731999893 }, { 151.515341164000063, -33.327082411999953 }, { 151.515462610000156, -33.316666080999909 }, { 151.532258808000051, -33.302928752999961 }, { 151.540867400000025, -33.277541990999907 }, { 151.516109564000146, -33.261109454 }, { 151.491019552000012, -33.273611379999934 }, { 151.453795174, -33.304198934999903 }, { 151.452726539000139, -33.311514845999923 }, { 151.469737175000091, -33.328220309999963 }, { 151.456392368000024, -33.331088222999938 }, { 151.44270356200002, -33.33421552699987 }, { 151.444021030000044, -33.34563567499994 }, { 151.451228098000058, -33.355460507999894 }, { 151.459956624000085, -33.359611446999892 }, { 151.474545631000069, -33.363001254999872 }, { 151.488356783000143, -33.349290928999949 }, { 151.49529361000009, -33.339586503999911 }, { 151.50499521100005, -33.343743475999958 }, { 151.503829472000064, -33.360010111999927 }, { 151.489999895000096, -33.374534001999933 }, { 151.485846324000022, -33.394024524999921 }, { 151.457227378000141, -33.419805289999971 }, { 151.445300346000124, -33.435971567999985 }, { 151.451997768000069, -33.44498583499994 }, { 151.450910316000147, -33.453114441999972 }, { 151.439065499000094, -33.463584620999953 }, { 151.442760017000069, -33.478269724999876 }, { 151.447521446000053, -33.486453606999959 }, { 151.441595802000052, -33.491283239999888 }, { 151.427875703000097, -33.494413953999924 }, { 151.432465040000011, -33.509535414999903 }, { 151.430023634, -33.515069268999923 }, { 151.428884311000047, -33.521742445999891 }, { 151.424164259000065, -33.527764580999886 }, { 151.414317254000025, -33.532891533999901 }, { 151.406993035000028, -33.534600518999909 }, { 151.38648522200009, -33.533949476999865 }, { 151.380056186000047, -33.536797783999901 }, { 151.362681840000107, -33.532103319999877 }, { 151.353717429000085, -33.541796319999946 }, { 151.343109571000014, -33.548272393999937 }, { 151.320567254000025, -33.551364841999927 }, { 151.308767123000052, -33.547621351999894 }, { 151.28288821700005, -33.562107028999932 }, { 151.266449415000068, -33.561211846999939 }, { 151.25554446700005, -33.546807549999883 }, { 151.245941602000016, -33.521091403999932 }, { 151.230723504000025, -33.534926039999931 }, { 151.226817254000025, -33.554864190999922 }, { 151.23406009200005, -33.573337497999944 }, { 151.252777540000011, -33.582452080999929 }, { 151.248057488000086, -33.590101820999863 }, { 151.241953972000033, -33.595879815999922 }, { 151.234548373000052, -33.599867445999905 }, { 151.225596550000091, -33.602227471999953 }, { 151.225596550000091, -33.609063408999972 }, { 151.249522332000083, -33.606377862999892 }, { 151.28164068000001, -33.572901828999946 }, { 151.299338124000087, -33.570624204999973 }, { 151.309992612000144, -33.578874700999876 }, { 151.298736359000031, -33.606489340999886 }, { 151.291502, -33.636533019999959 }, { 151.295259821000059, -33.648780177999882 }, { 151.30909433000005, -33.637533463999958 }, { 151.317123143, -33.622147940999895 }, { 151.325471543000106, -33.592058408999932 }, { 151.340752909, -33.617465535999898 }, { 151.321341977000088, -33.66781743699994 }, { 151.309178674, -33.692972897999951 }, { 151.305674675000091, -33.720147393999966 }, { 151.304453972000033, -33.726169528999961 }, { 151.311778191000087, -33.736097914999874 }, { 151.31763756600003, -33.74675872199991 }, { 151.317149285000028, -33.757500908999916 }, { 151.308767123000052, -33.781019789999888 }, { 151.304698113000086, -33.825372002999913 }, { 151.291758660000085, -33.829847914999888 }, { 151.279144727000016, -33.827569268999909 }, { 151.266368035000085, -33.828383070999919 }, { 151.252777540000011, -33.842461846999953 }, { 151.246918165000068, -33.856377862999935 }, { 151.247325066000087, -33.867282809999921 }, { 151.254730665000068, -33.874200127999913 }, { 151.269867384000065, -33.876641533999944 }, { 151.280121290000011, -33.870700778999918 }, { 151.28467858200014, -33.860121351999879 }, { 151.287852410000028, -33.856377862999935 }, { 151.294444207000083, -33.870375257999896 }, { 151.29249108200014, -33.891778252999941 }, { 151.273692254000082, -33.937432549999883 }, { 151.281423373000109, -33.952325127999927 }, { 151.267425977000016, -33.981703382999939 }, { 151.260264519000089, -33.992608330999914 }, { 151.249359571000014, -34.003838799999912 }, { 151.241709832000083, -33.998630466999913 }, { 151.213145379000082, -33.966729424999897 }, { 151.201914910000085, -33.95916106599995 }, { 151.182302280000044, -33.963474216999956 }, { 151.177907748000052, -33.973809502999956 }, { 151.176036004000082, -33.987481377999899 }, { 151.164073113000143, -34.000746351999922 }, { 151.145355665000068, -34.00367603999986 }, { 151.12468509200005, -34.0004208309999 }, { 151.106293165000011, -34.000909112999892 }, { 151.095225457000083, -34.014418226999865 }, { 151.125498894000089, -34.020440362999878 }, { 151.132660352000016, -34.024102471999925 }, { 151.143565300000091, -34.032810153999904 }, { 151.149180535000085, -34.031996351999894 }, { 151.160329623000109, -34.01751067499994 }, { 151.221446160000085, -34.024997653999918 }, { 151.232269727000073, -34.024102471999925 }, { 151.231211785000028, -34.040459893999937 }, { 151.22584069100003, -34.047051690999908 }, { 151.179698113000143, -34.047946872999901 }, { 151.17554772200009, -34.046644789999903 }, { 151.172373894000145, -34.047946872999901 }, { 151.164073113000143, -34.054782809999921 }, { 151.158457879000025, -34.062595309999921 }, { 151.155039910000028, -34.070896091999899 }, { 151.149180535000085, -34.078301690999879 }, { 151.136078321000014, -34.082696221999953 }, { 151.146820509000065, -34.086032809999978 }, { 151.170420769000089, -34.086032809999978 }, { 151.17701256600003, -34.089532158999887 }, { 151.177093946000014, -34.100355726999879 }, { 151.168955925000091, -34.110121351999922 }, { 151.150401238000086, -34.124281507999939 }, { 151.112861003000035, -34.149470207999954 }, { 151.096117432000085, -34.162938379999915 }, { 151.068357135000099, -34.175111234999903 }, { 151.027957464, -34.200796095999934 }, { 151.009685907000062, -34.219916955999892 }, { 150.968952516000115, -34.262675193999925 }, { 150.940628388000107, -34.302159102999951 }, { 150.924918127000069, -34.330418880999957 }, { 150.928274759000089, -34.363486780999963 }, { 150.908050376000062, -34.407641400999907 }, { 150.903049563000081, -34.450860842999916 }, { 150.918867505000151, -34.486404115999932 }, { 150.897779177000075, -34.502081173999954 }, { 150.887217644000089, -34.530205987999906 }, { 150.873301629000025, -34.545505466999956 }, { 150.854991082000083, -34.5414364559999 }, { 150.867035352000016, -34.522556247999958 }, { 150.86085045700014, -34.513278903999918 }, { 150.848155144000145, -34.510511976999865 }, { 150.84131920700014, -34.510674737999921 }, { 150.835134311000047, -34.513767184999907 }, { 150.800954623000052, -34.548272393999923 }, { 150.805837436000047, -34.557224216999941 }, { 150.812185092000107, -34.561211846999925 }, { 150.820323113000086, -34.562107028999918 }, { 150.842051629000082, -34.561700127999913 }, { 150.854991082000083, -34.569919528999904 }, { 150.88233483200014, -34.592217705999943 }, { 150.897227410000028, -34.601169528999975 }, { 150.917002800000091, -34.60344817499994 }, { 150.883636915000068, -34.607028903999918 }, { 150.870453321000014, -34.626722914999874 }, { 150.847911004000025, -34.751722914999931 }, { 150.83375084700009, -34.782403252999927 }, { 150.810557488000143, -34.795179945999877 }, { 150.779307488000086, -34.806898695999877 }, { 150.753428582000083, -34.858086846999925 }, { 150.728688998000109, -34.86980559699991 }, { 150.727061394000089, -34.874118747999916 }, { 150.738780144000089, -34.883721612999892 }, { 150.754079623000052, -34.893324476999865 }, { 150.76319420700014, -34.897637627999956 }, { 150.778493686000104, -34.901625257999939 }, { 150.77686608200014, -34.910088799999883 }, { 150.764008009, -34.917413018999895 }, { 150.74577884200005, -34.918145440999922 }, { 150.754161004000025, -34.9281552059999 }, { 150.776133660000028, -34.935804945999934 }, { 150.787364129000025, -34.945489190999893 }, { 150.779795769000089, -34.952894789999888 }, { 150.787364129000025, -34.959730726999894 }, { 150.776215040000011, -34.986993096999896 }, { 150.796153191000087, -35.004001559999949 }, { 150.827647332000083, -35.012627862999949 }, { 150.851573113000086, -35.014906507999925 }, { 150.854991082000083, -35.021661065999965 }, { 150.843597852000016, -35.054131768999952 }, { 150.844737175000148, -35.077243747999901 }, { 150.832855665000011, -35.09091562299993 }, { 150.807139519000145, -35.110528252999899 }, { 150.798838738000086, -35.099379164999888 }, { 150.786143425000091, -35.089125257999953 }, { 150.778086785000085, -35.0785458309999 }, { 150.783539259, -35.066176039999874 }, { 150.792816602000073, -35.050469658999901 }, { 150.781260613000143, -35.028578382999868 }, { 150.787364129000025, -35.014906507999925 }, { 150.767588738000086, -35.007256768999895 }, { 150.748789910000028, -35.01034921699997 }, { 150.731455925000148, -35.017266533999887 }, { 150.695567254000082, -35.026136976999922 }, { 150.68702233200014, -35.038995049999954 }, { 150.677500847000033, -35.075778903999932 }, { 150.69695071700005, -35.079766533999916 }, { 150.701508009, -35.092868747999972 }, { 150.700938347000033, -35.109470309999935 }, { 150.703782730764544, -35.120441501962588 } } \n\tact := Contour{ { 148.848258498231132, -35.750479017992291 }, { 148.853529493990891, -35.749083754012034 }, { 148.857301873882307, -35.74567311022588 }, { 148.862572869642179, -35.736216322525223 }, { 148.865983515226958, -35.73208220742795 }, { 148.870324334999964, -35.728929946060106 }, { 148.876525506746702, -35.727586358023984 }, { 148.883036736855843, -35.727896417285805 }, { 148.887842644622367, -35.733167413045663 }, { 148.891408318938772, -35.742469171115332 }, { 148.892183466193956, -35.762261243861289 }, { 148.901020136270176, -35.818743584948464 }, { 148.907531366379487, -35.839775892943138 }, { 148.922724236933959, -35.867629490308687 }, { 148.92964887909244, -35.875794365917287 }, { 148.933627963659603, -35.879256686546867 }, { 148.93781375470104, -35.882357272869839 }, { 148.948149042444243, -35.887886651048106 }, { 149.006078322556561, -35.903699640126263 }, { 149.030314568762321, -35.917497246700592 }, { 149.035998976571477, -35.919357598674225 }, { 149.042406853893169, -35.919615981092619 }, { 149.04798790891482, -35.917962334693954 }, { 149.052483759218092, -35.914861749270258 }, { 149.055739374272662, -35.910624282284786 }, { 149.058529901333827, -35.905818372719722 }, { 149.065041132342344, -35.890832207740175 }, { 149.07108727355876, -35.881582126513933 }, { 149.074187859881818, -35.877551365103429 }, { 149.078063592560795, -35.873830662055369 }, { 149.082611118808074, -35.870575047000841 }, { 149.092222935240272, -35.864890639191586 }, { 149.096718784644167, -35.861479993606793 }, { 149.09950931170539, -35.856829115471285 }, { 149.101524693309955, -35.851558118812136 }, { 149.104625278733636, -35.839724216099711 }, { 149.106485629807992, -35.82742522629313 }, { 149.105968865870466, -35.815281263419607 }, { 149.096408726281709, -35.776678968959274 }, { 149.095168491932327, -35.765155124609294 }, { 149.095943638288247, -35.759470716800124 }, { 149.104005162008548, -35.731152031441042 }, { 149.104625278733636, -35.715028984899718 }, { 149.099664341336336, -35.684694919734739 }, { 149.087261997842973, -35.63038298898374 }, { 149.086435174643555, -35.610022474557567 }, { 149.090465936054159, -35.599790540501004 }, { 149.09780399026198, -35.591418958418245 }, { 149.126329380296625, -35.581962171616865 }, { 149.131393671380806, -35.571885268090597 }, { 149.130980259331409, -35.566200860281427 }, { 149.133254021555786, -35.557674248567665 }, { 149.14668989472284, -35.52873544648368 }, { 149.150255569039246, -35.518193454963949 }, { 149.151340773757624, -35.509976901612731 }, { 149.147930129072165, -35.498918145256212 }, { 149.146069777997809, -35.494990736633184 }, { 149.141212193388071, -35.488066094474661 }, { 149.137388136653158, -35.476128838974674 }, { 149.137801547803178, -35.473648370276052 }, { 149.139661899776797, -35.468532403247821 }, { 149.147930129072165, -35.456130059754457 }, { 149.146793248409608, -35.450445651945287 }, { 149.144932896436046, -35.445071302498576 }, { 149.141728957325427, -35.439128513170374 }, { 149.142659133312407, -35.434529310978931 }, { 149.14555301316102, -35.430343519937509 }, { 149.149583774571568, -35.427087904882896 }, { 149.154441360080682, -35.424142348190827 }, { 149.160332472565528, -35.418199557963263 }, { 149.166843702674669, -35.410086358298727 }, { 149.182346633390353, -35.386263523243059 }, { 149.186687453163415, -35.380682468221281 }, { 149.194955683357989, -35.374791354837143 }, { 149.200330031905423, -35.37262094450098 }, { 149.2064278508646, -35.371845798145074 }, { 149.212473992980392, -35.372724298187748 }, { 149.227356806071725, -35.380992526583825 }, { 149.23278283056311, -35.382542820194999 }, { 149.240430943133504, -35.380062350597015 }, { 149.244410027700667, -35.377116794804223 }, { 149.249112583578892, -35.366523125541789 }, { 149.263220250314248, -35.352002047656327 }, { 149.269163038743159, -35.350451755843793 }, { 149.277482944882024, -35.349056491863621 }, { 149.349933302879606, -35.359495130595775 }, { 149.359545119311804, -35.359030042602413 }, { 149.367038202251194, -35.357324721158889 }, { 149.381765984812318, -35.3487464326018 }, { 149.393083123587246, -35.340684909780776 }, { 149.404400263261437, -35.330194594205196 }, { 149.404400263261437, -35.327920831081457 }, { 149.403004999281279, -35.324045099301856 }, { 149.398509148978007, -35.321357924128904 }, { 149.349623243617771, -35.299912204984281 }, { 149.326988966967235, -35.292625827619872 }, { 149.318307325622584, -35.29148894605801 }, { 149.308643834145528, -35.289163506990207 }, { 149.258104283286002, -35.269268079658119 }, { 149.249422641941408, -35.263945407954196 }, { 149.244720086962388, -35.258364352932503 }, { 149.244720086962388, -35.252628269179283 }, { 149.245805291680767, -35.24694386226939 }, { 149.245805291680767, -35.241259453560943 }, { 149.242549676626311, -35.233766370621481 }, { 149.237123651235549, -35.230510755566868 }, { 149.229217157146081, -35.229167168430038 }, { 149.220380487069747, -35.228702080436676 }, { 149.2064278508646, -35.224619643082022 }, { 149.199296503131109, -35.220898940034047 }, { 149.194645624096268, -35.216041354524918 }, { 149.192888624910097, -35.211493829176902 }, { 149.192165155397618, -35.206429538992012 }, { 149.192165155397618, -35.203122247094058 }, { 149.193198684171932, -35.192166842625653 }, { 149.192268508185123, -35.185655612516442 }, { 149.189167921862065, -35.178524264782951 }, { 149.184982130820629, -35.174028416278347 }, { 149.180021194322649, -35.170514417906062 }, { 149.127104526652545, -35.139508559172683 }, { 149.102919957290226, -35.145864759650891 }, { 148.939519077943032, -35.248700859656978 }, { 148.82598595588712, -35.313348077252016 }, { 148.817717726591809, -35.320479424985507 }, { 148.809346145408199, -35.330866387773611 }, { 148.804178502435889, -35.339599705062341 }, { 148.801904739312249, -35.346162612014979 }, { 148.801284620788579, -35.352467135649775 }, { 148.802214796775388, -35.358099866615518 }, { 148.803765090386662, -35.363629245693147 }, { 148.805728795147786, -35.368848564609578 }, { 148.805728795147786, -35.376186618817414 }, { 148.803455032024146, -35.386263523243059 }, { 148.790225865331365, -35.414272148440872 }, { 148.7874353382702, -35.422592054579653 }, { 148.783869663953794, -35.447758477671613 }, { 148.770537143574302, -35.493285414290384 }, { 148.769451938855866, -35.506462905039015 }, { 148.772397496447297, -35.549457696115738 }, { 148.78262942870515, -35.581083672473483 }, { 148.782164340711688, -35.591987400098461 }, { 148.780148960905819, -35.606921889133858 }, { 148.773069289116449, -35.63741098392974 }, { 148.772552525178867, -35.651105238615884 }, { 148.774877964246571, -35.659786879061272 }, { 148.788365513357746, -35.669760430699341 }, { 148.791156041318231, -35.674307956946649 }, { 148.791879510830654, -35.679785659180851 }, { 148.790949334843845, -35.6922913545624 }, { 148.791156041318231, -35.699422703195182 }, { 148.792706334030072, -35.707277519541861 }, { 148.795600213878799, -35.712703545832014 }, { 148.799372592870839, -35.717096042448404 }, { 148.832445510052196, -35.744174492558756 }, { 148.837251417818607, -35.747275078881742 }, { 148.842522413578479, -35.749393813273855 }, { 148.848258498231132, -35.750479017992291 } } \n\t\n\t// Look at two contours\n\tcanberra := Point{149.128684300000030000, -35.2819998}\n\tisnsw := nsw.Contains(canberra)\n\tisact := act.Contains(canberra)\n\tif isnsw != true || isact != true {\n\t\tt.Error(\"Canberra should be in NSW and also in the sub-contour ACT state\")\n\t}\t\n\n\t// Using NSW as a multi-contour polygon\n\tnswmulti := Polygon{ Contour{ { 150.703782730764544, -35.120441501962588 }, { 150.673521763018982, -35.124264010875365 }, { 150.636418085326397, -35.14446949567072 }, { 150.613055464931449, -35.187267234778744 }, { 150.61304772200009, -35.187269789999931 }, { 150.585948113000143, -35.196221612999878 }, { 150.55396569100003, -35.213555596999953 }, { 150.548106316000087, -35.221368096999939 }, { 150.543711785000028, -35.237969658999901 }, { 150.539724155000044, -35.247735283999944 }, { 150.534434441000087, -35.254978122999958 }, { 150.52312259200005, -35.26433684699991 }, { 150.49952233200014, -35.289727471999925 }, { 150.489105665000068, -35.305759372999916 }, { 150.484629754000082, -35.324314059999921 }, { 150.485036655000101, -35.350192966999927 }, { 150.488454623000109, -35.364515882999925 }, { 150.491872592000107, -35.369398695999891 }, { 150.492035352000073, -35.373142184999921 }, { 150.485036655000101, -35.384372653999918 }, { 150.455821160000028, -35.403985283999887 }, { 150.45093834700009, -35.408461195999863 }, { 150.445485873000052, -35.425469658999916 }, { 150.43295332100007, -35.440687757999896 }, { 150.41920006600003, -35.454522393999895 }, { 150.40992272200009, -35.466892184999921 }, { 150.406993035000028, -35.487399997999972 }, { 150.409353061000104, -35.538506768999952 }, { 150.406504754000082, -35.548760674999883 }, { 150.389659050000148, -35.557875257999882 }, { 150.372325066000087, -35.578871351999908 }, { 150.332530144000089, -35.639418226999908 }, { 150.306895379000025, -35.700290622999916 }, { 150.291677280000044, -35.722832940999893 }, { 150.273692254000025, -35.730645440999893 }, { 150.253428582000083, -35.726250908999901 }, { 150.231781446000014, -35.7133114559999 }, { 150.221934441000087, -35.717705987999892 }, { 150.19092858200014, -35.726820570999877 }, { 150.21810957100007, -35.751153252999941 }, { 150.225840691000087, -35.778903903999918 }, { 150.228688998000109, -35.785251559999949 }, { 150.238536004000025, -35.799493096999953 }, { 150.240977410000085, -35.809747002999885 }, { 150.238617384, -35.833103122999972 }, { 150.232432488000143, -35.843845309999978 }, { 150.21810957100007, -35.850192966999927 }, { 150.19092858200014, -35.857191664999903 }, { 150.189300977000016, -35.85955169099995 }, { 150.152598504000025, -35.893731377999941 }, { 150.149750196000014, -35.898207289999917 }, { 150.150238477000073, -35.9125302059999 }, { 150.160817905000044, -35.939711195999905 }, { 150.163422071000014, -35.956638278999975 }, { 150.156586134, -36.025079033999944 }, { 150.148692254000025, -36.062595309999963 }, { 150.129649285000028, -36.059502862999892 }, { 150.106781446000014, -36.048597914999903 }, { 150.087738477000016, -36.06267669099995 }, { 150.09115644600007, -36.070245049999897 }, { 150.090179884000065, -36.07529062299993 }, { 150.081553582000083, -36.083754164999874 }, { 150.087657097000033, -36.082777601999894 }, { 150.092539910000028, -36.08269622199991 }, { 150.097015821000014, -36.081312757999939 }, { 150.102061394000089, -36.076348565999893 }, { 150.119151238000086, -36.085056247999958 }, { 150.135752800000091, -36.097751559999935 }, { 150.143321160000085, -36.11443450299997 }, { 150.123057488000143, -36.152601820999934 }, { 150.121104363000086, -36.17376067499994 }, { 150.124196811000104, -36.195245049999969 }, { 150.144786004000025, -36.252862237999935 }, { 150.146494988000143, -36.273532809999949 }, { 150.132823113000086, -36.282403252999899 }, { 150.132823113000086, -36.286797783999887 }, { 150.140391472000033, -36.30974700299997 }, { 150.14234459700009, -36.320000908999901 }, { 150.13819420700014, -36.330010674999883 }, { 150.12842858200014, -36.338311455999957 }, { 150.108246290000011, -36.35133228999986 }, { 150.092295769000089, -36.367852471999925 }, { 150.079274936000104, -36.386000257999925 }, { 150.070485873000052, -36.406345309999921 }, { 150.067393425000148, -36.429294528999904 }, { 150.073008660000028, -36.453057549999912 }, { 150.074229363000143, -36.463311455999929 }, { 150.070974155000101, -36.470147393999952 }, { 150.056813998000109, -36.488946221999896 }, { 150.053558790000068, -36.500909112999935 }, { 150.063649936000104, -36.54314544099995 }, { 150.065765821000014, -36.566582940999936 }, { 150.056976759000065, -36.587172132999868 }, { 150.029063347000033, -36.624281507999882 }, { 149.99537194100003, -36.686455987999892 }, { 149.989105665000068, -36.704685153999961 }, { 149.986094597000033, -36.722914320999863 }, { 149.985362175000148, -36.744805596999896 }, { 149.979502800000091, -36.769952080999957 }, { 149.965098504000025, -36.794528903999975 }, { 149.94703209700009, -36.815687757999882 }, { 149.930023634000065, -36.830498955999957 }, { 149.939952019000145, -36.852959893999952 }, { 149.93482506600003, -36.870700778999947 }, { 149.90967858200014, -36.905531507999896 }, { 149.903819207000083, -36.928399346999896 }, { 149.91138756600003, -36.938571872999944 }, { 149.926524285000028, -36.944105726999865 }, { 149.943695509000065, -36.953383070999919 }, { 149.932139519000145, -36.96550872199991 }, { 149.92310631600003, -36.983493747999944 }, { 149.920176629000025, -37.002618096999925 }, { 149.926768425000091, -37.01824309699991 }, { 149.93482506600003, -37.026625257999868 }, { 149.939952019000145, -37.033868096999896 }, { 149.94288170700014, -37.04216887799997 }, { 149.943695509000065, -37.053399346999882 }, { 149.941579623000052, -37.06218840899993 }, { 149.93685957100007, -37.06894296699997 }, { 149.932302280000101, -37.07097747199991 }, { 149.930023634000065, -37.066338799999883 }, { 149.922536655000044, -37.061781507999925 }, { 149.90577233200014, -37.07097747199991 }, { 149.89031009200005, -37.084079684999963 }, { 149.885508660000028, -37.090508721999882 }, { 149.876149936000104, -37.095879815999936 }, { 149.88209069100003, -37.107598565999922 }, { 149.896657748000052, -37.119317315999922 }, { 149.913096550000148, -37.124688408999972 }, { 149.930186394000089, -37.122816664999903 }, { 149.938975457000083, -37.11980559699991 }, { 149.946055535000028, -37.119235934999935 }, { 149.95875084700009, -37.124688408999972 }, { 149.997569207000083, -37.150485934999907 }, { 150.005869988000086, -37.158868096999953 }, { 150.011403842000107, -37.173435153999989 }, { 150.014414910000028, -37.205336195999905 }, { 150.019541863000086, -37.220879815999908 }, { 150.053558790000068, -37.268731377999941 }, { 150.053558790000068, -37.276136976999922 }, { 150.030039910000085, -37.266045830999957 }, { 150.00733483200014, -37.259372653999904 }, { 149.985362175000148, -37.259047132999882 }, { 149.964366082000083, -37.268731377999941 }, { 149.951019727000073, -37.284274997999944 }, { 149.951345248000109, -37.299737237999963 }, { 149.971690300000091, -37.337579033999901 }, { 149.957286004000025, -37.377862237999892 }, { 149.956797722000033, -37.415459893999881 }, { 149.967133009000065, -37.453708591999927 }, { 149.985362175000148, -37.495863539999874 }, { 149.972097201, -37.51026783599994 }, { 149.972075076275758, -37.510291859955558 }, { 149.761070998227979, -37.425105483031643 }, { 149.544185012228468, -37.33756560546837 }, { 149.32729902622907, -37.249974053759516 }, { 149.110413039330297, -37.16238250115147 }, { 148.89357872927485, -37.074790947644061 }, { 148.676641067331389, -36.987199395036015 }, { 148.459806757275942, -36.899607842427969 }, { 148.242972447220609, -36.812016289819923 }, { 148.216824172197789, -36.801681003875245 }, { 148.160393507953927, -36.798373711977206 }, { 148.134658644980391, -36.792792656955527 }, { 148.123289830261456, -36.788245130708219 }, { 148.122979770999621, -36.784214369297715 }, { 148.195120070634744, -36.691196791298893 }, { 148.20617882699122, -36.672489923271286 }, { 148.21403364513651, -36.65130258564578 }, { 148.217030877772743, -36.628151544158442 }, { 148.214860468335928, -36.616886082226955 }, { 148.197962273639973, -36.585466810544887 }, { 148.185404901415097, -36.581591077865923 }, { 148.171400588366396, -36.57957569806004 }, { 148.161788771934198, -36.576630140468595 }, { 148.154812452932333, -36.569860527940989 }, { 148.150316604427644, -36.562470797789103 }, { 148.147836134829788, -36.554512627755557 }, { 148.146905958842979, -36.545830987310268 }, { 148.148766310816598, -36.504283136157866 }, { 148.146595901379669, -36.499632257122983 }, { 148.141893344602124, -36.494671318826292 }, { 148.13724246556734, -36.487798353511195 }, { 148.13403852825553, -36.46650766399749 }, { 148.13098961787648, -36.458859551427125 }, { 148.120809360663486, -36.446870619083782 }, { 148.085204298839244, -36.424856459158235 }, { 148.067582636429563, -36.409715264547771 }, { 148.05993452385917, -36.388217868559735 }, { 148.06303511018217, -36.377624200196664 }, { 148.076264275975575, -36.360364272093463 }, { 148.079261508611694, -36.354421481865899 }, { 148.077814568687359, -36.341915784685696 }, { 148.074352248057721, -36.332355645096925 }, { 148.065567254824941, -36.316542656918131 }, { 148.043398065268434, -36.258510024018349 }, { 148.042312859650735, -36.247657973236883 }, { 148.031925896862617, -36.237115980817876 }, { 148.034303012773762, -36.213344821706087 }, { 148.045465122817063, -36.172572116909677 }, { 148.035956659172427, -36.151746514490057 }, { 147.999473098204817, -36.130559176864452 }, { 147.991411573585253, -36.114177747904733 }, { 147.995752395156842, -36.087047620950941 }, { 148.001333449279173, -36.070304456785252 }, { 147.996889275819456, -36.059245700428733 }, { 147.970947707270852, -36.049013767271546 }, { 147.949346959394632, -36.045293064223486 }, { 147.94066531804998, -36.042605889949897 }, { 147.929296503330875, -36.035371188529552 }, { 147.921286655554752, -36.025345960947334 }, { 147.915963982951439, -36.014183851803338 }, { 147.909711135260636, -36.005037122465211 }, { 147.898600702060662, -36.001213066629674 }, { 147.871780634368804, -35.998370863624459 }, { 147.741297641672759, -35.945970960791229 }, { 147.731634149296497, -35.944575697710235 }, { 147.713805780412372, -35.939408053838662 }, { 147.703418816724934, -35.939769789044547 }, { 147.694737177178979, -35.94390390414182 }, { 147.677942336169849, -35.95687468751683 }, { 147.672361282047575, -35.959665215477273 }, { 147.556761102442977, -35.996355482919199 }, { 147.538932732659475, -35.990671075110029 }, { 147.533661736899603, -35.972429295075969 }, { 147.520122511844477, -35.958011569977984 }, { 147.502294142960352, -35.948813164695807 }, { 147.48369062682093, -35.945970960791229 }, { 147.475629104, -35.948399753545786 }, { 147.457490675853933, -35.957649834772013 }, { 147.446741977859972, -35.959665215477273 }, { 147.419560174962044, -35.957339775510192 }, { 147.408604771393016, -35.959665215477273 }, { 147.396615839049673, -35.966693210423372 }, { 147.382198113951802, -35.97961231875351 }, { 147.369175652834144, -35.994650159677121 }, { 147.360804070751215, -36.008086032844133 }, { 147.348246697626962, -36.062449639539196 }, { 147.340288527593486, -36.076350599800307 }, { 147.324010451421145, -36.061674493183304 }, { 147.306337112167967, -36.051959323963615 }, { 147.286751744097671, -36.049323825634005 }, { 147.272023960637171, -36.049013767271546 }, { 147.266701288033971, -36.0502540016209 }, { 147.215851678811873, -36.061519463552386 }, { 147.184329055241619, -36.064258314669488 }, { 147.165260451108963, -36.059245700428733 }, { 147.154046666020804, -36.047618504190567 }, { 147.144176467170212, -36.040487155557798 }, { 147.134719680368903, -36.039350273995922 }, { 147.124591099099916, -36.04560312258603 }, { 147.097719353665184, -36.07325001347732 }, { 147.093895297829704, -36.080071302848367 }, { 147.091879918023835, -36.086169121807558 }, { 147.082578159954096, -36.097899671732492 }, { 147.079632603261985, -36.103635755485726 }, { 147.079322544899469, -36.112110691255424 }, { 147.081647983967343, -36.118931979727094 }, { 147.084593540659341, -36.125133151473776 }, { 147.086453891733697, -36.131592705638838 }, { 147.090019566050103, -36.156242363893924 }, { 147.093791945941518, -36.168024590662384 }, { 147.100096469576386, -36.179393406280624 }, { 147.108933139652663, -36.189470309806907 }, { 147.11983686727757, -36.197428480739816 }, { 147.132859328395284, -36.203371270068018 }, { 147.147897170218187, -36.207298678691046 }, { 147.176835972302229, -36.206936943485161 }, { 147.18856652222712, -36.209469089926571 }, { 147.196317986685756, -36.22032113980876 }, { 147.106917758947418, -36.241198419071807 }, { 147.093895297829704, -36.23401539449489 }, { 147.05152062437736, -36.19536142319113 }, { 147.040978631958353, -36.173708997572177 }, { 147.038601516047038, -36.138413995009799 }, { 147.044906040581282, -36.107614840952095 }, { 147.01617394407225, -36.093042088021932 }, { 147.005321894190047, -36.090148207273927 }, { 146.990232374624384, -36.089993177643009 }, { 146.973799269720416, -36.09474740946537 }, { 146.966357863624467, -36.103015638760738 }, { 146.962327102213976, -36.111800631993518 }, { 146.956125929568032, -36.117898450952708 }, { 146.931114537006238, -36.115728040616631 }, { 146.906051466701797, -36.099604994075207 }, { 146.87876631101642, -36.087564385787829 }, { 146.84688195224021, -36.097434583739044 }, { 146.829311964875274, -36.080071302848367 }, { 146.82073367721739, -36.073611748683291 }, { 146.812723830340531, -36.06952931042936 }, { 146.785386997811656, -36.068909193704272 }, { 146.771124302344674, -36.066893812999112 }, { 146.75639651888423, -36.046326592997872 }, { 146.735829298883004, -36.04327768261895 }, { 146.710921259108829, -36.044052829874218 }, { 146.68921715664635, -36.042192477900514 }, { 146.670768671037308, -36.031495456749951 }, { 146.638005813117786, -36.000282891542227 }, { 146.624053176013263, -35.993771660533724 }, { 146.545194939794555, -35.993771660533724 }, { 146.535376417787404, -35.990154311172518 }, { 146.514550816267047, -35.976873467636409 }, { 146.504267206266491, -35.97392791094434 }, { 146.49656741775209, -35.97599496759365 }, { 146.484630162252074, -35.98540007845088 }, { 146.473209669790322, -35.987570488787057 }, { 146.464062942250962, -35.98509002008835 }, { 146.453314244256944, -35.980594170684384 }, { 146.442152134213586, -35.978682142766701 }, { 146.431920201056414, -35.983849785738997 }, { 146.385049677300685, -36.047463473660372 }, { 146.369495070640937, -36.052734469420244 }, { 146.301127150897287, -36.046068210579477 }, { 146.266607293791537, -36.035061131066385 }, { 146.243559605091605, -36.035371188529552 }, { 146.229245232781182, -36.037696628496633 }, { 146.222837356358809, -36.039505303626839 }, { 146.216222771663581, -36.055835055743216 }, { 146.198962843560366, -36.050409031251817 }, { 146.182736444231466, -36.042192477900514 }, { 146.15912031475068, -36.037644951653206 }, { 146.09685021396615, -36.033459160611784 }, { 146.076282993964981, -36.025139256271643 }, { 146.062330356860457, -36.017387790913801 }, { 146.03101443886527, -36.013873792541517 }, { 145.99225711477402, -36.01604420287768 }, { 145.98347212064175, -36.014287204590815 }, { 145.973550245847207, -36.006122328083023 }, { 145.96936445480577, -35.996200453288296 }, { 145.96631554622553, -35.985968520131095 }, { 145.959597609641946, -35.977028497267327 }, { 145.939753860052576, -35.96684824005419 }, { 145.918359816851989, -35.964057712993025 }, { 145.896138951351475, -35.967003268785817 }, { 145.829889765100575, -35.983488050533111 }, { 145.786946649068625, -35.979974053959396 }, { 145.744623650660856, -35.964936212136507 }, { 145.572592807711885, -35.843599948778603 }, { 145.536574334737679, -35.829130547736654 }, { 145.493786249235995, -35.828975519005013 }, { 145.450791457259925, -35.839569186468808 }, { 145.375963983351085, -35.872900486068559 }, { 145.334106072936891, -35.876001071492254 }, { 145.291421340222712, -35.869799899745573 }, { 145.250441928951773, -35.857242526621306 }, { 145.217937452551439, -35.851196383606265 }, { 145.120785761253899, -35.851196383606265 }, { 145.008441196703757, -35.867629490308687 }, { 144.993144973361723, -35.873985690786995 }, { 144.976401809196147, -35.88731821116653 }, { 144.971234166223837, -35.894811293206629 }, { 144.96244917209151, -35.953464043730591 }, { 144.939194777816795, -35.987673841574534 }, { 144.933923782056809, -36.005553888201376 }, { 144.945085891200847, -36.025139256271643 }, { 144.960485468229763, -36.039970391620287 }, { 144.977435337970405, -36.060175876415556 }, { 144.985858595997342, -36.081001478835176 }, { 144.975471633209338, -36.097434583739044 }, { 144.956248000344942, -36.099243258869336 }, { 144.910927769301111, -36.081311537197635 }, { 144.890153842825555, -36.076350599800307 }, { 144.872118768366363, -36.083636977164801 }, { 144.830984328364082, -36.118880303782944 }, { 144.810933873199644, -36.131592705638838 }, { 144.766905552449259, -36.136398614304625 }, { 144.740705600582999, -36.13500335122373 }, { 144.729078404344818, -36.127872002590877 }, { 144.728148228358009, -36.116554863815864 }, { 144.724479201254098, -36.111542249575123 }, { 144.717296176677166, -36.110302016125132 }, { 144.705513950808154, -36.110457044856759 }, { 144.705824009170726, -36.106581313077157 }, { 144.698020867868649, -36.097847995788356 }, { 144.681897821327311, -36.083792005896342 }, { 144.662519158832083, -36.078107598986449 }, { 144.620041131692801, -36.075162042294465 }, { 144.602781202690323, -36.066118665743829 }, { 144.49265872621919, -35.959665215477273 }, { 144.45255781499111, -35.947159519196433 }, { 144.435711298038029, -35.932173354216886 }, { 144.422585484132753, -35.913931573283449 }, { 144.37602501784022, -35.814351087432698 }, { 144.353287388402293, -35.777557468102657 }, { 144.324348586318195, -35.754199721040266 }, { 144.312669713236573, -35.751305841191623 }, { 144.288278435601285, -35.750479017992291 }, { 144.27659956341904, -35.747998549293669 }, { 144.268021274861951, -35.741797376647625 }, { 144.253293492300884, -35.724330742969371 }, { 144.238152296791043, -35.717096042448404 }, { 144.218928663926647, -35.700921319063639 }, { 144.215156284934551, -35.696477145603822 }, { 144.21107384668062, -35.689810885863693 }, { 144.201565383035984, -35.686090182815732 }, { 144.190093214630167, -35.683144627022855 }, { 144.180378046309841, -35.679113864713059 }, { 144.150974156232223, -35.650071709841498 }, { 144.100072870166741, -35.586768080282653 }, { 144.064932896336074, -35.569249769761058 }, { 144.020077753285648, -35.563720391582805 }, { 143.99842532766678, -35.55540048544411 }, { 143.980700310670727, -35.523361097936331 }, { 143.960753209193172, -35.513129163879768 }, { 143.899154901077736, -35.491735120679294 }, { 143.858433873124682, -35.470599460796407 }, { 143.835644565943937, -35.45132415108877 }, { 143.826342807874198, -35.445588066436173 }, { 143.816162550661147, -35.440833835513089 }, { 143.79476850835988, -35.436854750046635 }, { 143.788774042188265, -35.431893812649307 }, { 143.784639927090893, -35.425227552909277 }, { 143.776940138576549, -35.41840626353823 }, { 143.733790317868909, -35.401818129003459 }, { 143.65121137860217, -35.389312432722619 }, { 143.595504184770277, -35.360528660269452 }, { 143.585995722024904, -35.352932223643222 }, { 143.578864374291413, -35.342700290485951 }, { 143.576435582436147, -35.329006035799893 }, { 143.581241490202558, -35.32104786576636 }, { 143.587959425886822, -35.314536634757857 }, { 143.591370070572282, -35.305441583162533 }, { 143.591370070572282, -35.286372979029778 }, { 143.58919966023609, -35.267356051740435 }, { 143.581396518934184, -35.24942433006882 }, { 143.564601678824431, -35.233456313158314 }, { 143.547135045146206, -35.225911554274802 }, { 143.459905226844739, -35.209375094784789 }, { 143.437684361344225, -35.199556572777624 }, { 143.418357374793061, -35.188032728427658 }, { 143.406988560074012, -35.178834324044857 }, { 143.383837517687198, -35.14570973091935 }, { 143.363993768097885, -35.107210789246508 }, { 143.350196160624307, -35.066024671501424 }, { 143.34275475542762, -35.006648450565521 }, { 143.333452997357881, -34.979208266148561 }, { 143.331282587021803, -34.962826837188842 }, { 143.333194614939487, -34.955075371830986 }, { 143.342186313747334, -34.935283298185652 }, { 143.344925164864435, -34.924948012240975 }, { 143.343633253671726, -34.91859181086339 }, { 143.340274285829537, -34.911047051979878 }, { 143.337535434712436, -34.902003675429242 }, { 143.338052198649962, -34.890841567184523 }, { 143.341876255384875, -34.886965833606354 }, { 143.349110955905928, -34.882211602683284 }, { 143.35608727400853, -34.875752047618931 }, { 143.359187860331417, -34.866605320079458 }, { 143.358206008400543, -34.85911223714001 }, { 143.353400099734813, -34.845883070447314 }, { 143.351746454235467, -34.835599460446787 }, { 143.358412713975611, -34.81704762115082 }, { 143.360479770624806, -34.806247247212696 }, { 143.355467157283442, -34.801441338546908 }, { 143.328130323855362, -34.784388116018761 }, { 143.314074334862653, -34.782889500150304 }, { 143.296969436390384, -34.791106051702869 }, { 143.282706740024025, -34.792501315683211 }, { 143.276660597908176, -34.770693862231909 }, { 143.268754103818765, -34.75395069806622 }, { 143.251029086822939, -34.748007907838655 }, { 143.23221886600777, -34.743925469584809 }, { 143.221418492069688, -34.733176771590735 }, { 143.156719599429948, -34.702997735157311 }, { 143.142611932694535, -34.699018649690942 }, { 143.05011111863314, -34.692197361219272 }, { 143.012697381678834, -34.672870374668022 }, { 142.995747511938077, -34.668684583626685 }, { 142.988616164204586, -34.682275485525253 }, { 142.981381463683533, -34.690595391663948 }, { 142.96458662267446, -34.681241956750867 }, { 142.934045851934457, -34.658039238420102 }, { 142.921746861228598, -34.658039238420102 }, { 142.914925571857566, -34.66181161921088 }, { 142.909137811260962, -34.667082614970653 }, { 142.880354038807809, -34.679329928833184 }, { 142.878648715565816, -34.674834079429218 }, { 142.869191928764451, -34.66181161921088 }, { 142.864437697841538, -34.652458185197077 }, { 142.860045201225091, -34.629720553960397 }, { 142.855187615715863, -34.62083220794004 }, { 142.847074416051498, -34.614837741768412 }, { 142.817980585235773, -34.603468927049363 }, { 142.807231887241812, -34.591893405856055 }, { 142.799738804302365, -34.585433851690894 }, { 142.790023635082662, -34.582333266267185 }, { 142.779223261144637, -34.584193616442249 }, { 142.757157424375578, -34.593753756930312 }, { 142.745323520763861, -34.595975844109901 }, { 142.726099887899466, -34.603210544630969 }, { 142.716798129829726, -34.62088388388409 }, { 142.708116490283714, -34.665532322258841 }, { 142.705015903960827, -34.670544935600233 }, { 142.700158319350862, -34.675609225785124 }, { 142.695765822734586, -34.681396987281147 }, { 142.693853794816732, -34.689096774896299 }, { 142.696644321877898, -34.705219821437623 }, { 142.69886640815821, -34.712764581220412 }, { 142.700675084187765, -34.712661227533559 }, { 142.694680617116774, -34.730903008467095 }, { 142.687342563808215, -34.735657241188733 }, { 142.676438837082628, -34.733951917946641 }, { 142.659643996073612, -34.733176771590735 }, { 142.64005862890258, -34.734417005940088 }, { 142.630808546777018, -34.736329033857871 }, { 142.629206578121057, -34.743615411222265 }, { 142.632358840388065, -34.761082044900434 }, { 142.643727655107114, -34.778497002634538 }, { 142.642797479120304, -34.787643731073288 }, { 142.625537551017146, -34.795240166800312 }, { 142.608794386851457, -34.781442560225983 }, { 142.594531692283738, -34.777721856278632 }, { 142.578511997630585, -34.777411797916187 }, { 142.556601189593152, -34.774156182861489 }, { 142.547971225991205, -34.770900566907599 }, { 142.536654087216391, -34.764957777579312 }, { 142.526732212421678, -34.75767140111428 }, { 142.522494745436177, -34.750229994118882 }, { 142.52363162699794, -34.727440687837515 }, { 142.522494745436177, -34.719534193748032 }, { 142.494589472126393, -34.665532322258841 }, { 142.471645136214022, -34.643311455859049 }, { 142.467924433166047, -34.634164727420213 }, { 142.468647902678526, -34.62413949983808 }, { 142.470094842602862, -34.617783297561118 }, { 142.470404900965377, -34.611995537863748 }, { 142.467924433166047, -34.603468927049363 }, { 142.458570998252867, -34.591583346594135 }, { 142.394802280700674, -34.546934910018038 }, { 142.385758905049329, -34.533395684962898 }, { 142.371392856794841, -34.444718926737139 }, { 142.372323032781651, -34.42466847067341 }, { 142.378317498953379, -34.403171074685361 }, { 142.398057895755187, -34.373715508663778 }, { 142.40642947783806, -34.356403903717151 }, { 142.396455927099339, -34.338007094052173 }, { 142.38239993720731, -34.335681654984384 }, { 142.365036656316533, -34.340280857175827 }, { 142.344934524308769, -34.342761325874534 }, { 142.328191360143194, -34.334699802154134 }, { 142.305143671443318, -34.317129814789126 }, { 142.284886508905174, -34.297854505980666 }, { 142.272897576561832, -34.280439548246562 }, { 142.265869581615846, -34.277493991554493 }, { 142.258789910725852, -34.272843112519624 }, { 142.255637649357936, -34.263903089655841 }, { 142.253984002959328, -34.240493665750108 }, { 142.248816359987075, -34.218634534556102 }, { 142.238377720355459, -34.19625863942467 }, { 142.235122105300945, -34.191917819651707 }, { 142.224218377675925, -34.190367526939809 }, { 142.199775424995835, -34.192796318795089 }, { 142.190421990982031, -34.188197116603646 }, { 142.175952589940096, -34.171608982068861 }, { 142.164170364070969, -34.16246225363011 }, { 142.150114374178997, -34.158586520951147 }, { 142.128720330978524, -34.157811374595241 }, { 142.122932571281126, -34.159826756199863 }, { 142.105259231128628, -34.16881845500771 }, { 142.094252150716159, -34.170833835712955 }, { 142.077457309707029, -34.136675713813162 }, { 142.051257358740088, -34.115953464181018 }, { 142.025160760560652, -34.112232761133043 }, { 141.971210565015554, -34.123704928639498 }, { 141.960358515133294, -34.124635104626321 }, { 141.94940311066506, -34.124118340688895 }, { 141.938137648733459, -34.121637871990188 }, { 141.926665481226905, -34.116831964223778 }, { 141.905271438026375, -34.126598810286879 }, { 141.887391392298809, -34.13047454206648 }, { 141.840985955637279, -34.13047454206648 }, { 141.817008090950594, -34.126185398237496 }, { 141.770706007975832, -34.10742685246727 }, { 141.748536819318758, -34.103189385481784 }, { 141.706110468123597, -34.11001067485283 }, { 141.665906203208692, -34.127063896481602 }, { 141.630972934952979, -34.149078058205802 }, { 141.60451460156753, -34.170833835712955 }, { 141.581466912867654, -34.201943048133117 }, { 141.567927687812528, -34.213880303633104 }, { 141.546171910305361, -34.218634534556102 }, { 141.53733524022914, -34.215844007494937 }, { 141.529583774871298, -34.208660983817396 }, { 141.524054396693032, -34.198842461810131 }, { 141.518835076877338, -34.176569919466189 }, { 141.510670201268738, -34.172229098793849 }, { 141.459303827209908, -34.169180190213581 }, { 141.44628136609208, -34.164012547241285 }, { 141.415223829616082, -34.145770766307763 }, { 141.408970981925222, -34.140706476122958 }, { 141.391917759397131, -34.133678481176943 }, { 141.368663365122188, -34.13729583053815 }, { 141.345925734784885, -34.143652031915749 }, { 141.330784540174363, -34.144737236634185 }, { 141.321741163623813, -34.136210625819714 }, { 141.309545525705403, -34.114351494625794 }, { 141.299727003698251, -34.11001067485283 }, { 141.285774366593728, -34.105721531023832 }, { 141.274767287080635, -34.096316420166687 }, { 141.265827265116229, -34.086962986152884 }, { 141.258489210908408, -34.082673841424608 }, { 141.252753127155074, -34.081381931131205 }, { 141.241849400429544, -34.076007581684564 }, { 141.234614699009114, -34.07523243622795 }, { 141.228206821687479, -34.077557875295739 }, { 141.21415083179545, -34.086859632466115 }, { 141.206657749755379, -34.089495130795655 }, { 141.190121291164644, -34.089288425220687 }, { 141.181181268300861, -34.084379163767409 }, { 141.173016391792999, -34.077041110458865 }, { 141.158857050012784, -34.069031263581991 }, { 141.134104038970122, -34.063966974296378 }, { 141.045582310375266, -34.062209975110235 }, { 141.024084914387231, -34.051254570641916 }, { 141.000107049700546, -34.018543389565721 }, { 141.000107049700546, -33.711533704516853 }, { 141.000107049700546, -33.397444349477112 }, { 141.000107049700546, -33.083354993538094 }, { 141.000107049700546, -32.769213962554304 }, { 141.000107049700546, -32.455072930671236 }, { 141.000107049700546, -32.141035251575644 }, { 141.000107049700546, -31.826945895636626 }, { 141.000107049700546, -31.512804863753459 }, { 141.000107049700546, -31.198663831870377 }, { 141.000107049700546, -30.88457447683065 }, { 141.000107049700546, -30.570536797735059 }, { 141.000107049700546, -30.256344089008465 }, { 141.000107049700546, -29.942203058024674 }, { 141.000107049700546, -29.628165378929083 }, { 141.000107049700546, -29.314076022990065 }, { 141.000107049700546, -28.999934991106983 }, { 141.485865513382748, -28.999934991106983 }, { 141.971675653008901, -28.999934991106983 }, { 142.457434116691104, -28.999934991106983 }, { 142.943192580373193, -28.999934991106983 }, { 143.428899367212068, -28.999934991106983 }, { 143.914657830894157, -28.999934991106983 }, { 144.400519647363865, -28.999934991106983 }, { 144.886278111045954, -28.999934991106983 }, { 145.37203657382878, -28.999934991106983 }, { 145.857795038410245, -28.999934991106983 }, { 146.343553502092448, -28.999934991106983 }, { 146.829311964875274, -28.999934991106983 }, { 147.315070428557476, -28.999934991106983 }, { 147.800828892239565, -28.999934991106983 }, { 148.286587355921711, -28.999934991106983 }, { 148.772397496447297, -28.999934991106983 }, { 148.966339145635061, -28.999934991106983 }, { 148.971403435819866, -28.999728284632653 }, { 148.998171827567717, -28.977507420031401 }, { 149.024423456277475, -28.968050631431467 }, { 149.046489293046477, -28.954097996125583 }, { 149.063387485943679, -28.936321303185608 }, { 149.073877802418565, -28.915444023922547 }, { 149.083644646683069, -28.869193616891849 }, { 149.093566522377046, -28.848419692215018 }, { 149.11175662736639, -28.839738050870352 }, { 149.134597609591992, -28.836844171021625 }, { 149.157386915873474, -28.829196058451345 }, { 149.178625930342378, -28.818240654882302 }, { 149.196816034432402, -28.805579928970559 }, { 149.204670851678486, -28.795813083806721 }, { 149.210665317850101, -28.784547620975957 }, { 149.217589960008581, -28.775349215693694 }, { 149.237433709598008, -28.768114516072004 }, { 149.249939406778196, -28.760052991452326 }, { 149.260946487190665, -28.75002776476957 }, { 149.265649042169514, -28.740726006699816 }, { 149.275157504914944, -28.739330742719645 }, { 149.377166782620861, -28.691788424496167 }, { 149.399180943445742, -28.689514662271876 }, { 149.416337518761509, -28.68072966903901 }, { 149.432357213414662, -28.661040948181167 }, { 149.469357538319628, -28.594998467505221 }, { 149.484447056086765, -28.583939711148702 }, { 149.577878046134913, -28.572570895530447 }, { 149.595241327025576, -28.56538787185282 }, { 149.610175816060973, -28.577738538502743 }, { 149.614878371039993, -28.593861585943444 }, { 149.620872838110984, -28.607814223047967 }, { 149.639321323720139, -28.613808689219596 }, { 149.675339796694175, -28.610604750109133 }, { 149.690946080197364, -28.614015394794649 }, { 149.704485305252604, -28.627451267062298 }, { 149.730116815438635, -28.613808689219596 }, { 149.741744012576078, -28.609622898178174 }, { 149.759158970310182, -28.606987399848649 }, { 149.870573357974081, -28.604558607993368 }, { 149.907677036565929, -28.608899427766417 }, { 149.95087853411701, -28.600114434533552 }, { 149.971807489324135, -28.599184258546728 }, { 150.003278436050948, -28.602491549545405 }, { 150.019814894641684, -28.600114434533552 }, { 150.058468865945372, -28.583991387992128 }, { 150.1045642442445, -28.573914482667206 }, { 150.158514438890165, -28.554587497914696 }, { 150.173345575138171, -28.552107029215989 }, { 150.236132439860228, -28.556086113783152 }, { 150.258353306260062, -28.553140557990375 }, { 150.276801792768424, -28.542391859996386 }, { 150.298144159125684, -28.534950453000988 }, { 150.322432082174885, -28.543632093446377 }, { 150.361809523890315, -28.572829277948841 }, { 150.417826776084837, -28.625745944719583 }, { 150.449556106129364, -28.646468193452364 }, { 150.492137486056151, -28.654736422747717 }, { 150.62112186108493, -28.65892221378914 }, { 150.664116653061058, -28.654736422747717 }, { 150.752586704812586, -28.63597787877606 }, { 150.793514439239971, -28.635047702789251 }, { 150.834803907973878, -28.647915134276047 }, { 150.87133914578493, -28.670032646989085 }, { 150.890976189799346, -28.678662611490324 }, { 150.933557570625396, -28.687137547260022 }, { 150.948853794866693, -28.69891977312902 }, { 150.963013136646907, -28.712717379703278 }, { 150.979394565606697, -28.723672784171683 }, { 151.000530227288152, -28.727083428857114 }, { 151.02523156058794, -28.728323663206467 }, { 151.045902134276105, -28.73488657015902 }, { 151.054480421933818, -28.754368584542533 }, { 151.053550245947008, -28.788268324923209 }, { 151.055617304395071, -28.810644220054726 }, { 151.062128533604891, -28.828007500945418 }, { 151.07752811063375, -28.836947523809187 }, { 151.10078250490858, -28.840874932432214 }, { 151.140004917892668, -28.84165007878812 }, { 151.160520461050453, -28.846094252247937 }, { 151.181759474620037, -28.856946303029488 }, { 151.219121534731073, -28.883249606783949 }, { 151.287437779429865, -28.920818372469896 }, { 151.301855503628587, -28.984328708503071 }, { 151.309141880093705, -28.999934991106983 }, { 151.302113886047039, -29.010787041888449 }, { 151.302837355559461, -29.018331800771961 }, { 151.306816441025887, -29.024326266943675 }, { 151.309141880093705, -29.030682467421897 }, { 151.309141880093705, -29.06137826869211 }, { 151.315343051840273, -29.099257093639963 }, { 151.318753697425166, -29.105354912599168 }, { 151.335755243109986, -29.115018405874693 }, { 151.342628209324346, -29.122821547176699 }, { 151.344230177980307, -29.137445976950275 }, { 151.343455031624387, -29.153000583610037 }, { 151.350896437720451, -29.165454603946827 }, { 151.376114536756461, -29.170622246919109 }, { 151.384382766051829, -29.168555190269799 }, { 151.405156691628008, -29.159046725725801 }, { 151.422675002149674, -29.154550877221212 }, { 151.42536217732254, -29.148918144456815 }, { 151.426602410772603, -29.142148532828486 }, { 151.430788201814039, -29.136515801862743 }, { 151.45259565706391, -29.126335544649706 }, { 151.461845738290151, -29.120496108108895 }, { 151.467581822043371, -29.107887058141202 }, { 151.48261966386633, -29.085614515797261 }, { 151.492283157141969, -29.078121432857799 }, { 151.514038934649136, -29.066907646870376 }, { 151.520188429552377, -29.06137826869211 }, { 151.520963575908297, -29.05435027374611 }, { 151.520188429552377, -29.027271823635743 }, { 151.526544630929948, -29.008254897245678 }, { 151.549333938110806, -28.970014337091953 }, { 151.554294874608672, -28.955234876788182 }, { 151.55739546093173, -28.954563084119044 }, { 151.564423455877829, -28.950583997753299 }, { 151.572950066692215, -28.948103529953883 }, { 151.580856560781683, -28.946708265973697 }, { 151.587522821421032, -28.9461915020362 }, { 151.593052199599299, -28.944641208425026 }, { 151.610208774915066, -28.933737480800133 }, { 151.616720005024206, -28.931722100994151 }, { 151.623851352757697, -28.930636894477146 }, { 151.637493930600385, -28.930016777752073 }, { 151.643695103246444, -28.928879897089573 }, { 151.654392125296397, -28.925004163511318 }, { 151.664365676035175, -28.91993987422579 }, { 151.700435825852651, -28.896117039170036 }, { 151.715370314888162, -28.888778984962215 }, { 151.720382929128903, -28.88712533856355 }, { 151.725137160051872, -28.886660251469465 }, { 151.729167922361682, -28.888985690537183 }, { 151.762550897006292, -28.947586765117094 }, { 151.766271600953644, -28.951204116276941 }, { 151.770922479089108, -28.954149672069732 }, { 151.776090122960795, -28.956268405562469 }, { 151.782704705857498, -28.957508639911822 }, { 151.796088902181111, -28.957973727905184 }, { 151.802290073927679, -28.958955579836143 }, { 151.806785923331631, -28.961694430953244 }, { 151.81453738779021, -28.968670749955109 }, { 151.819033238093482, -28.971564629803837 }, { 151.824149205121671, -28.973580010509096 }, { 151.829626907355873, -28.971771336278181 }, { 151.833967727128936, -28.965621839576187 }, { 151.840789015600535, -28.938336683890853 }, { 151.847610304971568, -28.925314222773139 }, { 151.852726271999813, -28.919578139019919 }, { 151.858772414115663, -28.916322523965306 }, { 151.864508497868769, -28.914772231253494 }, { 151.870864700145773, -28.914307143260046 }, { 151.876910842261509, -28.914617200723214 }, { 151.897529739106119, -28.918337904670565 }, { 151.920060662969149, -28.9247457819923 }, { 151.924246454010586, -28.925469251504765 }, { 151.928742304313801, -28.925365898717203 }, { 151.933858270442784, -28.924280693998838 }, { 151.964399042082107, -28.910379733737742 }, { 151.975871209588604, -28.906917413108161 }, { 151.982744174903701, -28.906297295483796 }, { 151.99623172401482, -28.906297295483796 }, { 152.000469191899583, -28.905832207490349 }, { 152.004603306097749, -28.904643649984422 }, { 152.008944126769961, -28.902628269279163 }, { 152.013646681748924, -28.899217624593646 }, { 152.017832472790417, -28.894825127977256 }, { 152.021656528625897, -28.888055514550359 }, { 152.024343702899557, -28.882061049277937 }, { 152.025583938148202, -28.875704847900437 }, { 152.025583938148202, -28.850590101651818 }, { 152.026979201229096, -28.845215753104554 }, { 152.038606399265916, -28.820462742061892 }, { 152.042482131045404, -28.80961069128044 }, { 152.044032423757301, -28.795813083806721 }, { 152.043877395025675, -28.771628512645719 }, { 152.046202834093492, -28.746410413609709 }, { 152.04899336205392, -28.735455010940044 }, { 152.051163772390169, -28.73054574948678 }, { 152.054005976294661, -28.725894870451896 }, { 152.063927851089431, -28.713699232533514 }, { 152.066201614213071, -28.70904835349873 }, { 152.06702843561385, -28.703157241013869 }, { 152.064547967814406, -28.695819186806048 }, { 152.058450148855229, -28.686259047217277 }, { 152.030699905176505, -28.657940361858181 }, { 152.007703892420636, -28.639233493830673 }, { 152.003259718960805, -28.63365243880898 }, { 151.998402134350954, -28.625332532670285 }, { 151.99530154802801, -28.613963717951222 }, { 151.993131137691819, -28.598822524240134 }, { 151.985224643602351, -28.585490003860599 }, { 151.958404575910436, -28.560581964086396 }, { 151.959489780628815, -28.549264825311482 }, { 151.961040074240088, -28.544975680583207 }, { 151.963985630932086, -28.54006642002922 }, { 151.967551304349229, -28.536449069768736 }, { 151.973132359370879, -28.533503513076667 }, { 151.98041873583594, -28.531229749953013 }, { 151.991684197767427, -28.530454603597121 }, { 152.000882603049604, -28.528077487685891 }, { 152.010391066694297, -28.524098403118813 }, { 152.035195753681023, -28.507665296416292 }, { 152.040776808702788, -28.501825859875495 }, { 152.050388625134985, -28.489733574744676 }, { 152.163973423134962, -28.437075291291606 }, { 152.172345006117098, -28.43505990968707 }, { 152.187279494253175, -28.434233086487737 }, { 152.21828535388596, -28.437695408016694 }, { 152.225158319201057, -28.437230320023232 }, { 152.232703078084569, -28.434956556899593 }, { 152.24019616102396, -28.431080824220615 }, { 152.24980797835542, -28.423070976444464 }, { 152.267016228715931, -28.405914402028031 }, { 152.29171756381453, -28.38632903395775 }, { 152.300244174628972, -28.383073418903138 }, { 152.31311160701506, -28.380334567786036 }, { 152.357036574977883, -28.376148776744614 }, { 152.386957228992912, -28.365761813956524 }, { 152.403907098733669, -28.355736585475015 }, { 152.408557977768453, -28.351964206482904 }, { 152.412123651185595, -28.348191826591503 }, { 152.414914179145967, -28.343799329975113 }, { 152.429021844982117, -28.308504326513443 }, { 152.432587519298522, -28.304628594733842 }, { 152.447987095428118, -28.297548922944415 }, { 152.478217807805606, -28.269333591272272 }, { 152.487157830669275, -28.263390801943984 }, { 152.492170444910016, -28.261220391607722 }, { 152.500490351048825, -28.261685478701892 }, { 152.510825636993502, -28.265457858593294 }, { 152.528343948414488, -28.278221938191905 }, { 152.534855177624308, -28.287161961055673 }, { 152.537490675953904, -28.295171807932562 }, { 152.536767206441368, -28.307160740275975 }, { 152.537800735215683, -28.312690117554865 }, { 152.539971144652554, -28.31770273179562 }, { 152.543381789338071, -28.321578463575221 }, { 152.547412550748504, -28.324937433215965 }, { 152.552063429783459, -28.327986341796233 }, { 152.56415571491425, -28.332998956036988 }, { 152.574284296183237, -28.333774101493603 }, { 152.583275994991197, -28.331603692056717 }, { 152.594024692985158, -28.324472345222517 }, { 152.598313836814157, -28.318012791057441 }, { 152.600174187888513, -28.311501560048939 }, { 152.600949335143696, -28.305455417933175 }, { 152.603119744580454, -28.300649509267387 }, { 152.606323683691016, -28.296722100644445 }, { 152.610251093213435, -28.293363131902993 }, { 152.616658969635637, -28.293208103171452 }, { 152.622240024657401, -28.293569837477961 }, { 152.647044713442767, -28.316720879864661 }, { 152.655106236263691, -28.321836846892978 }, { 152.75101769411134, -28.358010348598754 }, { 152.757994013113205, -28.358630466223033 }, { 152.766934035077611, -28.358630466223033 }, { 152.781610141694614, -28.355064792805962 }, { 152.798198277128677, -28.353824557557246 }, { 152.825018344820705, -28.343954359606016 }, { 152.830909459104248, -28.339820244508658 }, { 152.84207156824823, -28.329123224257387 }, { 152.84630903523373, -28.32581593146007 }, { 152.854370558954088, -28.32364552202327 }, { 152.865687697729015, -28.322767021980511 }, { 152.887856887285466, -28.324472345222517 }, { 152.908217400812305, -28.328348077002119 }, { 152.934262323047733, -28.339820244508658 }, { 152.944184197842446, -28.341370538119833 }, { 153.000356479667744, -28.344109389236934 }, { 153.004387241977611, -28.345246269899434 }, { 153.010019972943439, -28.346331475517161 }, { 153.066140577925296, -28.34519459395537 }, { 153.075649041569989, -28.346486505148064 }, { 153.081385126222585, -28.348346856222506 }, { 153.091927117742216, -28.353204440832258 }, { 153.098748407113249, -28.354289645550693 }, { 153.10665490120266, -28.35387623529995 }, { 153.116886835259152, -28.350207208196039 }, { 153.131769646551902, -28.338890068521849 }, { 153.153525424958445, -28.307160740275975 }, { 153.162672154296388, -28.303853447478573 }, { 153.166496210132038, -28.301734713985837 }, { 153.170837029904988, -28.296463718225965 }, { 153.175694615414216, -28.288763929711635 }, { 153.180035435187165, -28.276930026999125 }, { 153.192489454624649, -28.259825127627551 }, { 153.217604200873097, -28.258584894177574 }, { 153.232331985232918, -28.260135185990094 }, { 153.312740513264032, -28.242875257886809 }, { 153.324987828025769, -28.241996758743426 }, { 153.354185011628942, -28.2500066056203 }, { 153.38250369698801, -28.237552586182886 }, { 153.472265659932248, -28.175282484499064 }, { 153.506524056145452, -28.149268634823883 }, { 153.531993035000028, -28.177911065999879 }, { 153.562510613000086, -28.174981377999941 }, { 153.570567254000025, -28.1937802059999 }, { 153.581228061000047, -28.246758721999939 }, { 153.591075066000087, -28.268487237999906 }, { 153.590830925000148, -28.318536065999922 }, { 153.563487175000148, -28.460870049999897 }, { 153.562510613000086, -28.504571221999882 }, { 153.576019727000073, -28.589613539999903 }, { 153.584239129000082, -28.608086846999925 }, { 153.620941602000073, -28.644463799999897 }, { 153.630625847000033, -28.661553643999937 }, { 153.629079623000109, -28.667250257999925 }, { 153.619883660000028, -28.686618747999944 }, { 153.61695397200009, -28.695733330999929 }, { 153.617523634000065, -28.705824476999908 }, { 153.619639519000089, -28.717543226999894 }, { 153.619639519000089, -28.729587497999901 }, { 153.601328972000033, -28.76140715899993 }, { 153.600108269000089, -28.78337981599995 }, { 153.610118035000085, -28.826104424999954 }, { 153.605967644000145, -28.867445570999905 }, { 153.582286004000025, -28.896091403999961 }, { 153.521332227000016, -28.943454684999907 }, { 153.475596550000091, -29.000176690999879 }, { 153.453786655000044, -29.035577080999886 }, { 153.438975457000083, -29.073011976999922 }, { 153.436208530000044, -29.085137627999913 }, { 153.435557488000086, -29.093845309999907 }, { 153.44507897200009, -29.140069268999909 }, { 153.445811394000089, -29.151625257999925 }, { 153.441416863000086, -29.155368747999958 }, { 153.422699415000068, -29.161065362999949 }, { 153.418304884000065, -29.164971612999935 }, { 153.415212436000104, -29.175957940999908 }, { 153.370860222000033, -29.241631768999909 }, { 153.350596550000148, -29.281019789999888 }, { 153.340342644000089, -29.322686455999943 }, { 153.349457227000016, -29.36109791499986 }, { 153.366709832000083, -29.38274505 }, { 153.369965040000068, -29.396661065999922 }, { 153.360118035000028, -29.412041924999954 }, { 153.356455925000091, -29.424004815999893 }, { 153.357595248000109, -29.443129164999874 }, { 153.36085045700014, -29.461521091999913 }, { 153.363780144000089, -29.470391533999958 }, { 153.352061394000089, -29.490004164999917 }, { 153.344004754000082, -29.535414320999919 }, { 153.32748457100007, -29.565036716999956 }, { 153.324473504000082, -29.575860283999944 }, { 153.322276238000086, -29.597588799999926 }, { 153.323252800000148, -29.602634372999958 }, { 153.32789147200009, -29.612074476999879 }, { 153.329112175000091, -29.618096612999878 }, { 153.326996290000011, -29.624444268999909 }, { 153.31771894600007, -29.635186455999929 }, { 153.315440300000148, -29.642266533999887 }, { 153.317881707000083, -29.666599216999956 }, { 153.323008660000028, -29.682305596999925 }, { 153.321625196000014, -29.697523695999905 }, { 153.296397332000083, -29.73503997199991 }, { 153.291188998000052, -29.75318775799991 }, { 153.288422071000014, -29.771254164999931 }, { 153.288096550000091, -29.78573984199997 }, { 153.294932488000086, -29.826592705999929 }, { 153.29078209700009, -29.835544528999947 }, { 153.276703321000014, -29.850762627999927 }, { 153.273773634, -29.857354424999912 }, { 153.271494988000143, -29.901625257999868 }, { 153.26734459700009, -29.924248955999929 }, { 153.260101759000065, -29.943291924999926 }, { 153.224457227000016, -29.986911716999927 }, { 153.219899936000104, -30.001397393999881 }, { 153.216563347000033, -30.007256768999923 }, { 153.20240319100003, -30.024672132999896 }, { 153.199229363000143, -30.03582122199991 }, { 153.200043165000068, -30.046563408999916 }, { 153.205577019000089, -30.073663018999952 }, { 153.203786655000101, -30.129164320999905 }, { 153.189626498000109, -30.174981377999899 }, { 153.137217644000089, -30.257989190999893 }, { 153.146494988000086, -30.286065362999892 }, { 153.132090691000087, -30.323825778999947 }, { 153.089366082000083, -30.388929945999891 }, { 153.082530144000089, -30.406426690999936 }, { 153.07545006600003, -30.438409112999935 }, { 153.05054772200009, -30.473321221999953 }, { 153.043142123000109, -30.493829033999916 }, { 153.023070386000143, -30.575506187999935 }, { 153.018077019000089, -30.633070570999891 }, { 153.007985873000109, -30.651625257999896 }, { 153.01099694100003, -30.65536874799993 }, { 152.987796365, -30.734633817999864 }, { 152.999859214000082, -30.751121505 }, { 153.005001433000075, -30.835814295999867 }, { 153.027517123000109, -30.875583591999956 }, { 153.034841342000107, -30.882500908999958 }, { 153.043142123000109, -30.88795338299991 }, { 153.054535352000073, -30.892998955999929 }, { 153.064626498000109, -30.893487237999921 }, { 153.068858269000145, -30.885511976999879 }, { 153.072113477000073, -30.881931247999901 }, { 153.079112175000148, -30.885918877999885 }, { 153.086273634, -30.894707940999936 }, { 153.089366082000083, -30.905694268999895 }, { 153.087901238000143, -30.926690362999935 }, { 153.085703972000033, -30.935153903999975 }, { 153.081879102000016, -30.943942966999941 }, { 153.063327253000068, -30.95959309 }, { 153.046599170000036, -30.992753975999861 }, { 153.039879977000112, -31.029965145999938 }, { 153.045923855000126, -31.046572868999888 }, { 153.057892177000156, -31.05163744799998 }, { 153.060919110000157, -31.06058328099995 }, { 153.05950072100012, -31.077209977999942 }, { 153.041631142000028, -31.0901026559999 }, { 153.008880172000147, -31.122248232999894 }, { 152.980615041000135, -31.16591475599995 }, { 152.97921828900013, -31.199245471999959 }, { 152.959894019000103, -31.24031530499991 }, { 152.970411879000039, -31.255676558999923 }, { 152.976735873000052, -31.320000908999916 }, { 152.93258908100006, -31.366007817999986 }, { 152.917828269000154, -31.395254330999933 }, { 152.916435393000029, -31.420656614999942 }, { 152.934354484000096, -31.438392126999929 }, { 152.93887444500001, -31.454869447999911 }, { 152.940381062000029, -31.46248367099993 }, { 152.934502086000066, -31.482810541999939 }, { 152.906297820000134, -31.505727677999928 }, { 152.876587434000101, -31.532446145999955 }, { 152.845380728000066, -31.569318604999907 }, { 152.849915115000044, -31.599780167999924 }, { 152.836561964, -31.625196178999914 }, { 152.848532646000081, -31.644220246999936 }, { 152.832146959000113, -31.655678984999909 }, { 152.812788211, -31.676031504999898 }, { 152.788948559, -31.704008613999875 }, { 152.803901470000028, -31.719226881999958 }, { 152.800929022000048, -31.733208108999918 }, { 152.77554759700007, -31.754852626999963 }, { 152.744185439000091, -31.793022631999889 }, { 152.736728193000147, -31.827349075999933 }, { 152.747215040000015, -31.842584729999956 }, { 152.715775884000095, -31.859170137999911 }, { 152.69288170700014, -31.88534921699997 }, { 152.664317254000082, -31.903497002999885 }, { 152.609255093, -31.945848262999917 }, { 152.546372674000054, -32.04367920499989 }, { 152.555345725000052, -32.071630892999892 }, { 152.528330925000091, -32.097100518999881 }, { 152.520274285000085, -32.115817966999941 }, { 152.51531009200005, -32.136488539999874 }, { 152.510082932000103, -32.161881366999893 }, { 152.51695268900005, -32.177392201999936 }, { 152.535678945000143, -32.183199517999938 }, { 152.545381547000034, -32.196888175999931 }, { 152.564787202000105, -32.20602140799987 }, { 152.569509311000104, -32.219333591999899 }, { 152.556651238000086, -32.232028903999947 }, { 152.546560092000107, -32.24627044099995 }, { 152.53998826600008, -32.259797076999874 }, { 152.533515488000091, -32.268907929999912 }, { 152.525957109000103, -32.281664572999972 }, { 152.524871412000039, -32.294425623999956 }, { 152.527042902000119, -32.312660829999913 }, { 152.539976734000049, -32.314488747999903 }, { 152.55445397200009, -32.321221612999906 }, { 152.55201256600003, -32.328057549999926 }, { 152.548350457000083, -32.332126559999978 }, { 152.54420006600003, -32.33570728999986 }, { 152.540782097000033, -32.341729424999954 }, { 152.536631707000083, -32.354587497999987 }, { 152.533946160000028, -32.369561455999929 }, { 152.524834943000144, -32.388305282999951 }, { 152.520499171000154, -32.410176412999903 }, { 152.521559969000066, -32.427494067999973 }, { 152.539886296000077, -32.442091940999973 }, { 152.402393537000137, -32.489428571999923 }, { 152.353559882000013, -32.514923347999868 }, { 152.294763900000021, -32.559588894999891 }, { 152.285929613000064, -32.588803960999968 }, { 152.264174174, -32.594256083999895 }, { 152.235861814000089, -32.60699906299989 }, { 152.210669949000078, -32.630738652999909 }, { 152.19198882, -32.652670384999908 }, { 152.187500835000094, -32.669135910999984 }, { 152.2037207300001, -32.686535898999935 }, { 152.219248894000145, -32.697198174999897 }, { 152.205577019000089, -32.697930596999925 }, { 152.202159050000091, -32.695896091999899 }, { 152.194102410000085, -32.687188408999916 }, { 152.190684441000087, -32.684258721999896 }, { 152.186045769000145, -32.683526299999954 }, { 152.17530358200014, -32.685153903999975 }, { 152.170746290000068, -32.684258721999896 }, { 152.145274285000085, -32.66659921699997 }, { 152.136729363000143, -32.663750908999944 }, { 152.135264519000089, -32.666680596999953 }, { 152.116709832000083, -32.680108330999957 }, { 152.109385613000086, -32.684258721999896 }, { 152.060883009, -32.697930596999925 }, { 152.086761915000011, -32.715915622999958 }, { 152.092295769000145, -32.718438408999887 }, { 152.16732832100007, -32.718438408999887 }, { 152.177989129000025, -32.720635674999883 }, { 152.190196160000085, -32.72527434699991 }, { 152.197764519000145, -32.729913018999923 }, { 152.194834832000083, -32.732110283999916 }, { 152.190928582000083, -32.736586195999891 }, { 152.189463738000143, -32.758558851999908 }, { 152.185069207000083, -32.766778252999899 }, { 152.174815300000148, -32.76921965899993 }, { 152.150157097000033, -32.766045830999957 }, { 152.14014733200014, -32.77019622199991 }, { 152.131195509, -32.780857028999932 }, { 152.127614780000044, -32.786553643999923 }, { 152.12256920700014, -32.790134372999901 }, { 152.109385613000086, -32.79412200299997 }, { 152.059428755000056, -32.785253865999934 }, { 151.984926879000056, -32.798745724999904 }, { 151.935188047, -32.815829072999946 }, { 151.875662482000052, -32.842087877999944 }, { 151.856219267000085, -32.855858949999927 }, { 151.834033071000079, -32.864967128999922 }, { 151.799237364000078, -32.893680377999956 }, { 151.803558790000068, -32.919366143999895 }, { 151.787852410000085, -32.931898695999891 }, { 151.772507057000155, -32.94560852899987 }, { 151.748863030000052, -32.957023378999935 }, { 151.737634974000059, -32.972001860999896 }, { 151.736035076, -32.993997022999906 }, { 151.734385613000143, -33.014825127999899 }, { 151.720535107000103, -33.019371191 }, { 151.703800128000012, -33.028521321999904 }, { 151.681488477000016, -33.049981377999956 }, { 151.670583530000044, -33.06113046699997 }, { 151.667002800000148, -33.073337497999944 }, { 151.665688671000055, -33.087343205999986 }, { 151.65291507500001, -33.110432838999955 }, { 151.646739129000025, -33.144707940999936 }, { 151.634938998000052, -33.158623955999914 }, { 151.629567905000044, -33.1742489559999 }, { 151.625987175000148, -33.191582940999893 }, { 151.61226343800007, -33.207550919999917 }, { 151.589994362000141, -33.218937254999943 }, { 151.568952752000087, -33.244224817999878 }, { 151.563181025000063, -33.265009942999953 }, { 151.576019727000016, -33.282484632999953 }, { 151.568957243, -33.292227829999902 }, { 151.53068564400013, -33.319118731999893 }, { 151.515341164000063, -33.327082411999953 }, { 151.515462610000156, -33.316666080999909 }, { 151.532258808000051, -33.302928752999961 }, { 151.540867400000025, -33.277541990999907 }, { 151.516109564000146, -33.261109454 }, { 151.491019552000012, -33.273611379999934 }, { 151.453795174, -33.304198934999903 }, { 151.452726539000139, -33.311514845999923 }, { 151.469737175000091, -33.328220309999963 }, { 151.456392368000024, -33.331088222999938 }, { 151.44270356200002, -33.33421552699987 }, { 151.444021030000044, -33.34563567499994 }, { 151.451228098000058, -33.355460507999894 }, { 151.459956624000085, -33.359611446999892 }, { 151.474545631000069, -33.363001254999872 }, { 151.488356783000143, -33.349290928999949 }, { 151.49529361000009, -33.339586503999911 }, { 151.50499521100005, -33.343743475999958 }, { 151.503829472000064, -33.360010111999927 }, { 151.489999895000096, -33.374534001999933 }, { 151.485846324000022, -33.394024524999921 }, { 151.457227378000141, -33.419805289999971 }, { 151.445300346000124, -33.435971567999985 }, { 151.451997768000069, -33.44498583499994 }, { 151.450910316000147, -33.453114441999972 }, { 151.439065499000094, -33.463584620999953 }, { 151.442760017000069, -33.478269724999876 }, { 151.447521446000053, -33.486453606999959 }, { 151.441595802000052, -33.491283239999888 }, { 151.427875703000097, -33.494413953999924 }, { 151.432465040000011, -33.509535414999903 }, { 151.430023634, -33.515069268999923 }, { 151.428884311000047, -33.521742445999891 }, { 151.424164259000065, -33.527764580999886 }, { 151.414317254000025, -33.532891533999901 }, { 151.406993035000028, -33.534600518999909 }, { 151.38648522200009, -33.533949476999865 }, { 151.380056186000047, -33.536797783999901 }, { 151.362681840000107, -33.532103319999877 }, { 151.353717429000085, -33.541796319999946 }, { 151.343109571000014, -33.548272393999937 }, { 151.320567254000025, -33.551364841999927 }, { 151.308767123000052, -33.547621351999894 }, { 151.28288821700005, -33.562107028999932 }, { 151.266449415000068, -33.561211846999939 }, { 151.25554446700005, -33.546807549999883 }, { 151.245941602000016, -33.521091403999932 }, { 151.230723504000025, -33.534926039999931 }, { 151.226817254000025, -33.554864190999922 }, { 151.23406009200005, -33.573337497999944 }, { 151.252777540000011, -33.582452080999929 }, { 151.248057488000086, -33.590101820999863 }, { 151.241953972000033, -33.595879815999922 }, { 151.234548373000052, -33.599867445999905 }, { 151.225596550000091, -33.602227471999953 }, { 151.225596550000091, -33.609063408999972 }, { 151.249522332000083, -33.606377862999892 }, { 151.28164068000001, -33.572901828999946 }, { 151.299338124000087, -33.570624204999973 }, { 151.309992612000144, -33.578874700999876 }, { 151.298736359000031, -33.606489340999886 }, { 151.291502, -33.636533019999959 }, { 151.295259821000059, -33.648780177999882 }, { 151.30909433000005, -33.637533463999958 }, { 151.317123143, -33.622147940999895 }, { 151.325471543000106, -33.592058408999932 }, { 151.340752909, -33.617465535999898 }, { 151.321341977000088, -33.66781743699994 }, { 151.309178674, -33.692972897999951 }, { 151.305674675000091, -33.720147393999966 }, { 151.304453972000033, -33.726169528999961 }, { 151.311778191000087, -33.736097914999874 }, { 151.31763756600003, -33.74675872199991 }, { 151.317149285000028, -33.757500908999916 }, { 151.308767123000052, -33.781019789999888 }, { 151.304698113000086, -33.825372002999913 }, { 151.291758660000085, -33.829847914999888 }, { 151.279144727000016, -33.827569268999909 }, { 151.266368035000085, -33.828383070999919 }, { 151.252777540000011, -33.842461846999953 }, { 151.246918165000068, -33.856377862999935 }, { 151.247325066000087, -33.867282809999921 }, { 151.254730665000068, -33.874200127999913 }, { 151.269867384000065, -33.876641533999944 }, { 151.280121290000011, -33.870700778999918 }, { 151.28467858200014, -33.860121351999879 }, { 151.287852410000028, -33.856377862999935 }, { 151.294444207000083, -33.870375257999896 }, { 151.29249108200014, -33.891778252999941 }, { 151.273692254000082, -33.937432549999883 }, { 151.281423373000109, -33.952325127999927 }, { 151.267425977000016, -33.981703382999939 }, { 151.260264519000089, -33.992608330999914 }, { 151.249359571000014, -34.003838799999912 }, { 151.241709832000083, -33.998630466999913 }, { 151.213145379000082, -33.966729424999897 }, { 151.201914910000085, -33.95916106599995 }, { 151.182302280000044, -33.963474216999956 }, { 151.177907748000052, -33.973809502999956 }, { 151.176036004000082, -33.987481377999899 }, { 151.164073113000143, -34.000746351999922 }, { 151.145355665000068, -34.00367603999986 }, { 151.12468509200005, -34.0004208309999 }, { 151.106293165000011, -34.000909112999892 }, { 151.095225457000083, -34.014418226999865 }, { 151.125498894000089, -34.020440362999878 }, { 151.132660352000016, -34.024102471999925 }, { 151.143565300000091, -34.032810153999904 }, { 151.149180535000085, -34.031996351999894 }, { 151.160329623000109, -34.01751067499994 }, { 151.221446160000085, -34.024997653999918 }, { 151.232269727000073, -34.024102471999925 }, { 151.231211785000028, -34.040459893999937 }, { 151.22584069100003, -34.047051690999908 }, { 151.179698113000143, -34.047946872999901 }, { 151.17554772200009, -34.046644789999903 }, { 151.172373894000145, -34.047946872999901 }, { 151.164073113000143, -34.054782809999921 }, { 151.158457879000025, -34.062595309999921 }, { 151.155039910000028, -34.070896091999899 }, { 151.149180535000085, -34.078301690999879 }, { 151.136078321000014, -34.082696221999953 }, { 151.146820509000065, -34.086032809999978 }, { 151.170420769000089, -34.086032809999978 }, { 151.17701256600003, -34.089532158999887 }, { 151.177093946000014, -34.100355726999879 }, { 151.168955925000091, -34.110121351999922 }, { 151.150401238000086, -34.124281507999939 }, { 151.112861003000035, -34.149470207999954 }, { 151.096117432000085, -34.162938379999915 }, { 151.068357135000099, -34.175111234999903 }, { 151.027957464, -34.200796095999934 }, { 151.009685907000062, -34.219916955999892 }, { 150.968952516000115, -34.262675193999925 }, { 150.940628388000107, -34.302159102999951 }, { 150.924918127000069, -34.330418880999957 }, { 150.928274759000089, -34.363486780999963 }, { 150.908050376000062, -34.407641400999907 }, { 150.903049563000081, -34.450860842999916 }, { 150.918867505000151, -34.486404115999932 }, { 150.897779177000075, -34.502081173999954 }, { 150.887217644000089, -34.530205987999906 }, { 150.873301629000025, -34.545505466999956 }, { 150.854991082000083, -34.5414364559999 }, { 150.867035352000016, -34.522556247999958 }, { 150.86085045700014, -34.513278903999918 }, { 150.848155144000145, -34.510511976999865 }, { 150.84131920700014, -34.510674737999921 }, { 150.835134311000047, -34.513767184999907 }, { 150.800954623000052, -34.548272393999923 }, { 150.805837436000047, -34.557224216999941 }, { 150.812185092000107, -34.561211846999925 }, { 150.820323113000086, -34.562107028999918 }, { 150.842051629000082, -34.561700127999913 }, { 150.854991082000083, -34.569919528999904 }, { 150.88233483200014, -34.592217705999943 }, { 150.897227410000028, -34.601169528999975 }, { 150.917002800000091, -34.60344817499994 }, { 150.883636915000068, -34.607028903999918 }, { 150.870453321000014, -34.626722914999874 }, { 150.847911004000025, -34.751722914999931 }, { 150.83375084700009, -34.782403252999927 }, { 150.810557488000143, -34.795179945999877 }, { 150.779307488000086, -34.806898695999877 }, { 150.753428582000083, -34.858086846999925 }, { 150.728688998000109, -34.86980559699991 }, { 150.727061394000089, -34.874118747999916 }, { 150.738780144000089, -34.883721612999892 }, { 150.754079623000052, -34.893324476999865 }, { 150.76319420700014, -34.897637627999956 }, { 150.778493686000104, -34.901625257999939 }, { 150.77686608200014, -34.910088799999883 }, { 150.764008009, -34.917413018999895 }, { 150.74577884200005, -34.918145440999922 }, { 150.754161004000025, -34.9281552059999 }, { 150.776133660000028, -34.935804945999934 }, { 150.787364129000025, -34.945489190999893 }, { 150.779795769000089, -34.952894789999888 }, { 150.787364129000025, -34.959730726999894 }, { 150.776215040000011, -34.986993096999896 }, { 150.796153191000087, -35.004001559999949 }, { 150.827647332000083, -35.012627862999949 }, { 150.851573113000086, -35.014906507999925 }, { 150.854991082000083, -35.021661065999965 }, { 150.843597852000016, -35.054131768999952 }, { 150.844737175000148, -35.077243747999901 }, { 150.832855665000011, -35.09091562299993 }, { 150.807139519000145, -35.110528252999899 }, { 150.798838738000086, -35.099379164999888 }, { 150.786143425000091, -35.089125257999953 }, { 150.778086785000085, -35.0785458309999 }, { 150.783539259, -35.066176039999874 }, { 150.792816602000073, -35.050469658999901 }, { 150.781260613000143, -35.028578382999868 }, { 150.787364129000025, -35.014906507999925 }, { 150.767588738000086, -35.007256768999895 }, { 150.748789910000028, -35.01034921699997 }, { 150.731455925000148, -35.017266533999887 }, { 150.695567254000082, -35.026136976999922 }, { 150.68702233200014, -35.038995049999954 }, { 150.677500847000033, -35.075778903999932 }, { 150.69695071700005, -35.079766533999916 }, { 150.701508009, -35.092868747999972 }, { 150.700938347000033, -35.109470309999935 }, { 150.703782730764544, -35.120441501962588 } }, Contour{ { 148.848258498231132, -35.750479017992291 }, { 148.853529493990891, -35.749083754012034 }, { 148.857301873882307, -35.74567311022588 }, { 148.862572869642179, -35.736216322525223 }, { 148.865983515226958, -35.73208220742795 }, { 148.870324334999964, -35.728929946060106 }, { 148.876525506746702, -35.727586358023984 }, { 148.883036736855843, -35.727896417285805 }, { 148.887842644622367, -35.733167413045663 }, { 148.891408318938772, -35.742469171115332 }, { 148.892183466193956, -35.762261243861289 }, { 148.901020136270176, -35.818743584948464 }, { 148.907531366379487, -35.839775892943138 }, { 148.922724236933959, -35.867629490308687 }, { 148.92964887909244, -35.875794365917287 }, { 148.933627963659603, -35.879256686546867 }, { 148.93781375470104, -35.882357272869839 }, { 148.948149042444243, -35.887886651048106 }, { 149.006078322556561, -35.903699640126263 }, { 149.030314568762321, -35.917497246700592 }, { 149.035998976571477, -35.919357598674225 }, { 149.042406853893169, -35.919615981092619 }, { 149.04798790891482, -35.917962334693954 }, { 149.052483759218092, -35.914861749270258 }, { 149.055739374272662, -35.910624282284786 }, { 149.058529901333827, -35.905818372719722 }, { 149.065041132342344, -35.890832207740175 }, { 149.07108727355876, -35.881582126513933 }, { 149.074187859881818, -35.877551365103429 }, { 149.078063592560795, -35.873830662055369 }, { 149.082611118808074, -35.870575047000841 }, { 149.092222935240272, -35.864890639191586 }, { 149.096718784644167, -35.861479993606793 }, { 149.09950931170539, -35.856829115471285 }, { 149.101524693309955, -35.851558118812136 }, { 149.104625278733636, -35.839724216099711 }, { 149.106485629807992, -35.82742522629313 }, { 149.105968865870466, -35.815281263419607 }, { 149.096408726281709, -35.776678968959274 }, { 149.095168491932327, -35.765155124609294 }, { 149.095943638288247, -35.759470716800124 }, { 149.104005162008548, -35.731152031441042 }, { 149.104625278733636, -35.715028984899718 }, { 149.099664341336336, -35.684694919734739 }, { 149.087261997842973, -35.63038298898374 }, { 149.086435174643555, -35.610022474557567 }, { 149.090465936054159, -35.599790540501004 }, { 149.09780399026198, -35.591418958418245 }, { 149.126329380296625, -35.581962171616865 }, { 149.131393671380806, -35.571885268090597 }, { 149.130980259331409, -35.566200860281427 }, { 149.133254021555786, -35.557674248567665 }, { 149.14668989472284, -35.52873544648368 }, { 149.150255569039246, -35.518193454963949 }, { 149.151340773757624, -35.509976901612731 }, { 149.147930129072165, -35.498918145256212 }, { 149.146069777997809, -35.494990736633184 }, { 149.141212193388071, -35.488066094474661 }, { 149.137388136653158, -35.476128838974674 }, { 149.137801547803178, -35.473648370276052 }, { 149.139661899776797, -35.468532403247821 }, { 149.147930129072165, -35.456130059754457 }, { 149.146793248409608, -35.450445651945287 }, { 149.144932896436046, -35.445071302498576 }, { 149.141728957325427, -35.439128513170374 }, { 149.142659133312407, -35.434529310978931 }, { 149.14555301316102, -35.430343519937509 }, { 149.149583774571568, -35.427087904882896 }, { 149.154441360080682, -35.424142348190827 }, { 149.160332472565528, -35.418199557963263 }, { 149.166843702674669, -35.410086358298727 }, { 149.182346633390353, -35.386263523243059 }, { 149.186687453163415, -35.380682468221281 }, { 149.194955683357989, -35.374791354837143 }, { 149.200330031905423, -35.37262094450098 }, { 149.2064278508646, -35.371845798145074 }, { 149.212473992980392, -35.372724298187748 }, { 149.227356806071725, -35.380992526583825 }, { 149.23278283056311, -35.382542820194999 }, { 149.240430943133504, -35.380062350597015 }, { 149.244410027700667, -35.377116794804223 }, { 149.249112583578892, -35.366523125541789 }, { 149.263220250314248, -35.352002047656327 }, { 149.269163038743159, -35.350451755843793 }, { 149.277482944882024, -35.349056491863621 }, { 149.349933302879606, -35.359495130595775 }, { 149.359545119311804, -35.359030042602413 }, { 149.367038202251194, -35.357324721158889 }, { 149.381765984812318, -35.3487464326018 }, { 149.393083123587246, -35.340684909780776 }, { 149.404400263261437, -35.330194594205196 }, { 149.404400263261437, -35.327920831081457 }, { 149.403004999281279, -35.324045099301856 }, { 149.398509148978007, -35.321357924128904 }, { 149.349623243617771, -35.299912204984281 }, { 149.326988966967235, -35.292625827619872 }, { 149.318307325622584, -35.29148894605801 }, { 149.308643834145528, -35.289163506990207 }, { 149.258104283286002, -35.269268079658119 }, { 149.249422641941408, -35.263945407954196 }, { 149.244720086962388, -35.258364352932503 }, { 149.244720086962388, -35.252628269179283 }, { 149.245805291680767, -35.24694386226939 }, { 149.245805291680767, -35.241259453560943 }, { 149.242549676626311, -35.233766370621481 }, { 149.237123651235549, -35.230510755566868 }, { 149.229217157146081, -35.229167168430038 }, { 149.220380487069747, -35.228702080436676 }, { 149.2064278508646, -35.224619643082022 }, { 149.199296503131109, -35.220898940034047 }, { 149.194645624096268, -35.216041354524918 }, { 149.192888624910097, -35.211493829176902 }, { 149.192165155397618, -35.206429538992012 }, { 149.192165155397618, -35.203122247094058 }, { 149.193198684171932, -35.192166842625653 }, { 149.192268508185123, -35.185655612516442 }, { 149.189167921862065, -35.178524264782951 }, { 149.184982130820629, -35.174028416278347 }, { 149.180021194322649, -35.170514417906062 }, { 149.127104526652545, -35.139508559172683 }, { 149.102919957290226, -35.145864759650891 }, { 148.939519077943032, -35.248700859656978 }, { 148.82598595588712, -35.313348077252016 }, { 148.817717726591809, -35.320479424985507 }, { 148.809346145408199, -35.330866387773611 }, { 148.804178502435889, -35.339599705062341 }, { 148.801904739312249, -35.346162612014979 }, { 148.801284620788579, -35.352467135649775 }, { 148.802214796775388, -35.358099866615518 }, { 148.803765090386662, -35.363629245693147 }, { 148.805728795147786, -35.368848564609578 }, { 148.805728795147786, -35.376186618817414 }, { 148.803455032024146, -35.386263523243059 }, { 148.790225865331365, -35.414272148440872 }, { 148.7874353382702, -35.422592054579653 }, { 148.783869663953794, -35.447758477671613 }, { 148.770537143574302, -35.493285414290384 }, { 148.769451938855866, -35.506462905039015 }, { 148.772397496447297, -35.549457696115738 }, { 148.78262942870515, -35.581083672473483 }, { 148.782164340711688, -35.591987400098461 }, { 148.780148960905819, -35.606921889133858 }, { 148.773069289116449, -35.63741098392974 }, { 148.772552525178867, -35.651105238615884 }, { 148.774877964246571, -35.659786879061272 }, { 148.788365513357746, -35.669760430699341 }, { 148.791156041318231, -35.674307956946649 }, { 148.791879510830654, -35.679785659180851 }, { 148.790949334843845, -35.6922913545624 }, { 148.791156041318231, -35.699422703195182 }, { 148.792706334030072, -35.707277519541861 }, { 148.795600213878799, -35.712703545832014 }, { 148.799372592870839, -35.717096042448404 }, { 148.832445510052196, -35.744174492558756 }, { 148.837251417818607, -35.747275078881742 }, { 148.842522413578479, -35.749393813273855 }, { 148.848258498231132, -35.750479017992291 } } }\n\t\n\tisnsw = nswmulti.Contains(canberra)\n\tif isnsw == true {\n\t\tt.Error(\"Canberra should not be in NSW as it falls in the donut contour of the ACT\")\n\t}\n\n\tsydney := Point{151.209, -33.866}\n\tisnsw = nswmulti.Contains(sydney)\t\n\tif isnsw != true {\n\t\tt.Error(\"Sydney should be in NSW\")\n\t}\n\n\tlosangeles := Point{118.28333, 34.01667}\n\tisnsw = nswmulti.Contains(losangeles)\t\n\tif isnsw == true {\n\t\tt.Error(\"Los Angeles should not be in NSW\")\n\t} \n\n}", "func (me *TxsdPresentationAttributesGraphicsShapeRendering) Set(s string) { (*xsdt.String)(me).Set(s) }", "func (e *Ellipsoid) PolygonInit(polyline bool) Polygon {\n\tvar p Polygon\n\tif polyline {\n\t\tC.geod_polygon_init(&p.p, 1)\n\t} else {\n\t\tC.geod_polygon_init(&p.p, 0)\n\t}\n\tp.e = e\n\treturn p\n}", "func (pat *PatternFilter) Set(value string) {\n\tpat.value = value\n\tpat.pattern = pattern.NewSplitGlobPattern(value, ComponentsOf, pat.fuzzy)\n}", "func (dw *DrawingWand) SetStrokePatternURL(strokeUrl string) {\n\tcsStrokeUrl := C.CString(strokeUrl)\n\tdefer C.free(unsafe.Pointer(csStrokeUrl))\n\tC.MagickDrawSetStrokePatternURL(dw.dw, csStrokeUrl)\n}", "func GetPolygonStipple(mask *uint8) {\n C.glowGetPolygonStipple(gpGetPolygonStipple, (*C.GLubyte)(unsafe.Pointer(mask)))\n}", "func PolygonMode(face uint32, mode uint32) {\n C.glowPolygonMode(gpPolygonMode, (C.GLenum)(face), (C.GLenum)(mode))\n}", "func newPattern(pattern string) *Pattern {\n\treturn &Pattern{*newPath(pattern)}\n\n}", "func (p *PDF) Polygon(pts []gofpdf.PointType, opts ...PDFOption) {\n\n\tfor _, opt := range opts {\n\t\topt(p.fpdf)\n\t}\n\tp.fpdf.Polygon(pts, \"F\")\n}", "func (p thinPoly) Set(x []int32) thinPoly {\n\tfor i := range x {\n\t\tp[i] = x[i]\n\t}\n\treturn p\n}", "func (m *ItemsMutator) Pattern(v string) *ItemsMutator {\n\tm.lock.Lock()\n\tdefer m.lock.Unlock()\n\tm.proxy.pattern = v\n\treturn m\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 (w *Window) Set(v *geom.Vec2, r, g, b byte) {\n\tif v[0] < 0 || v[0] > w.width || v[1] < 0 || v[1] > w.height {\n\t\treturn\n\t}\n\ti := v[1]*3*w.width + v[0]*3\n\tw.tex[i] = r\n\tw.tex[i+1] = g\n\tw.tex[i+2] = b\n}", "func LineStipple(factor int32, pattern uint16) {\n C.glowLineStipple(gpLineStipple, (C.GLint)(factor), (C.GLushort)(pattern))\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 GetPolygonStipple(mask *uint8) {\n\tsyscall.Syscall(gpGetPolygonStipple, 1, uintptr(unsafe.Pointer(mask)), 0, 0)\n}", "func (cv *Canvas) fillPath(path *Path2D, tf mat) {\n\tif len(path.p) < 3 {\n\t\treturn\n\t}\n\n\tvar triBuf [500][2]float64\n\ttris := triBuf[:0]\n\n\trunSubPaths(path.p, true, func(sp []pathPoint) bool {\n\t\ttris = appendSubPathTriangles(tris, tf, sp)\n\t\treturn false\n\t})\n\tif len(tris) == 0 {\n\t\treturn\n\t}\n\n\tcv.drawShadow(tris, nil, false)\n\n\tstl := cv.backendFillStyle(&cv.state.fill, 1)\n\tcv.b.Fill(&stl, tris, false)\n}", "func (shape *Shape) PolyShapeSetVertsRaw(verts []Vect) {\n\tC.cpPolyShapeSetVertsRaw(\n\t\t(*C.cpShape)(unsafe.Pointer(shape)),\n\t\tC.int(len(verts)),\n\t\t(*C.cpVect)(unsafe.Pointer(&verts[0])),\n\t)\n}", "func PolygonOffset(factor float32, units float32) {\n\tsyscall.Syscall(gpPolygonOffset, 2, uintptr(math.Float32bits(factor)), uintptr(math.Float32bits(units)), 0)\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 CreatePolygon(polygon [][][]float64, minp, maxp int) *Poly {\n\twest, south, east, north := 180.0, 90.0, -180.0, -90.0\n\tmaxpmap := map[string]string{}\n\tfor _, cont := range polygon {\n\t\tfor _, pt := range cont {\n\t\t\tx, y := pt[0], pt[1]\n\t\t\t// can only be one condition\n\t\t\t// using else if reduces one comparison\n\t\t\tif x < west {\n\t\t\t\twest = x\n\t\t\t} else if x > east {\n\t\t\t\teast = x\n\t\t\t}\n\n\t\t\tif y < south {\n\t\t\t\tsouth = y\n\t\t\t} else if y > north {\n\t\t\t\tnorth = y\n\t\t\t}\n\t\t\tghash := Geohash(pt, maxp)\n\t\t\tmaxpmap[ghash] = \"\"\n\t\t}\n\t}\n\n\t// logic for creating the smaller maps of each geohash\n\tcurrentmap := maxpmap\n\ttotalmap := map[int]map[string]string{}\n\ttotalmap[maxp] = maxpmap\n\tfor i := maxp - 1; i >= minp; i-- {\n\t\tnewmap := map[string]string{}\n\t\tfor k := range currentmap {\n\t\t\tnewmap[k[:len(k)-1]] = \"\"\n\t\t}\n\t\ttotalmap[i] = newmap\n\t\tcurrentmap = newmap\n\t}\n\n\treturn &Poly{\n\t\tPolygon: polygon,\n\t\tExtrema: Extrema{N: north, S: south, E: east, W: west},\n\t\tMap: totalmap,\n\t\tMin: minp,\n\t\tMax: maxp,\n\t}\n}", "func (w *Way) Polygon() bool {\n\tif len(w.Nodes) <= 3 {\n\t\t// need more than 3 nodes to be a polygon since first/last is repeated.\n\t\treturn false\n\t}\n\n\tif w.Nodes[0].ID != w.Nodes[len(w.Nodes)-1].ID {\n\t\t// must be closed\n\t\treturn false\n\t}\n\n\tif area := w.Tags.Find(\"area\"); area == \"no\" {\n\t\treturn false\n\t} else if area != \"\" {\n\t\treturn true\n\t}\n\n\tfor _, c := range polyConditions {\n\t\tv := w.Tags.Find(c.Key)\n\t\tif v == \"\" || v == \"no\" {\n\t\t\tcontinue\n\t\t}\n\n\t\tif c.Condition == conditionAll {\n\t\t\treturn true\n\t\t} else if c.Condition == conditionWhitelist {\n\t\t\tindex := sort.SearchStrings(c.Values, v)\n\t\t\tif index != len(c.Values) && c.Values[index] == v {\n\t\t\t\treturn true\n\t\t\t}\n\t\t} else if c.Condition == conditionBlacklist {\n\t\t\tindex := sort.SearchStrings(c.Values, v)\n\t\t\tif index == len(c.Values) || c.Values[index] != v {\n\t\t\t\treturn true\n\t\t\t}\n\t\t}\n\t}\n\n\treturn false\n}", "func PolygonOffset(factor, units float32) {\n\tgl.PolygonOffset(factor, units)\n}", "func (w *SVGWriter) PolygonWithClass(p *Polygon, class string) {\n\tvertices := p.getVertices()\n\tx := make([]float64, len(vertices))\n\ty := make([]float64, len(vertices))\n\tfor i, v := range vertices {\n\t\tx[i] = v.X\n\t\ty[i] = v.Y\n\t}\n\tw.appendElement(&poltag{x, y, class})\n}", "func (dst *Polygon) Set(src interface{}) error {\n\tif src == nil {\n\t\tdst.Status = Null\n\t\treturn nil\n\t}\n\terr := fmt.Errorf(\"cannot convert %v to Polygon\", src)\n\tvar p *Polygon\n\tswitch value := src.(type) {\n\tcase string:\n\t\tp, err = stringToPolygon(value)\n\tcase []Vec2:\n\t\tp = &Polygon{Status: Present, P: value}\n\t\terr = nil\n\tcase []float64:\n\t\tp, err = float64ToPolygon(value)\n\tdefault:\n\t\treturn err\n\t}\n\tif err != nil {\n\t\treturn err\n\t}\n\t*dst = *p\n\treturn nil\n}", "func PolygonOffset(factor float32, units float32) {\n C.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func (shape *Shape) SegmentShapeSetRadius(radius float64) {\n\tC.cpSegmentShapeSetRadius(\n\t\t(*C.cpShape)(unsafe.Pointer(shape)),\n\t\tC.cpFloat(radius),\n\t)\n}", "func (p *Polygon) Reverse() {\n\tp.reverse = true\n}", "func buildPatternPath(pattern []quad.Quad, ns *voc.Namespaces) *path.Path {\n\tentities, referenced := groupEntities(pattern, ns)\n\tp := path.StartMorphism()\n\n\tfor entity := range entities {\n\t\t// Apply only on entities which are not referenced as values\n\t\tif _, ok := referenced[entity]; !ok {\n\t\t\tp = p.Follow(entityPropertiesToPath(entity, entities))\n\t\t}\n\t}\n\n\treturn p\n}", "func (this *DtPoly) SetArea(a uint8) {\n\tthis.AreaAndtype = (this.AreaAndtype & 0xc0) | (a & 0x3f)\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 (debugging *debuggingOpenGL) PolygonMode(face uint32, mode uint32) {\n\tdebugging.recordEntry(\"PolygonMode\", face, mode)\n\tdebugging.gl.PolygonMode(face, mode)\n\tdebugging.recordExit(\"PolygonMode\")\n}", "func (c *Canvas) WireSeg(a, b Point, w1, w2 int) {\n\td1 := b.Sub(a).Normalize(float64(w1) / 2)\n\td2 := b.Sub(a).Normalize(float64(w2) / 2)\n\tx1 := a.Add(d1.Rot90())\n\tx2 := b.Add(d2.Rot90())\n\tx3 := b.Add(d2.Rot270())\n\tx4 := a.Add(d1.Rot270())\n\tc.Fill(Poly{x1, x2, x3, x4})\n}", "func (p *HatchPattern) Tile(clip *Path) *Path {\n\tdst := clip.FastBounds()\n\n\t// find extremes along cell axes\n\tinvCell := p.cell.Inv()\n\tpoints := []Point{\n\t\tinvCell.Dot(Point{dst.X - p.Thickness, dst.Y - p.Thickness}),\n\t\tinvCell.Dot(Point{dst.X + dst.W + p.Thickness, dst.Y - p.Thickness}),\n\t\tinvCell.Dot(Point{dst.X + dst.W + p.Thickness, dst.Y + dst.H + p.Thickness}),\n\t\tinvCell.Dot(Point{dst.X - p.Thickness, dst.Y + dst.H + p.Thickness}),\n\t}\n\tx0, x1 := points[0].X, points[0].X\n\ty0, y1 := points[0].Y, points[0].Y\n\tfor _, point := range points[1:] {\n\t\tx0 = math.Min(x0, point.X)\n\t\tx1 = math.Max(x1, point.X)\n\t\ty0 = math.Min(y0, point.Y)\n\t\ty1 = math.Max(y1, point.Y)\n\t}\n\n\thatch := p.hatch(x0, y0, x1, y1)\n\thatch = hatch.Transform(p.cell)\n\thatch = hatch.And(clip)\n\tif p.Thickness != 0.0 {\n\t\thatch = hatch.Stroke(p.Thickness, ButtCap, MiterJoin, 0.01)\n\t}\n\treturn hatch\n}", "func (self *Graphics) SetIsMaskA(member bool) {\n self.Object.Set(\"isMask\", member)\n}", "func NewPolygon(points ...Point) Polygon {\n\tvar poly Polygon\n\tfor _, p := range points {\n\t\tpoly.corners = append(poly.corners, p)\n\t}\n\treturn poly\n}", "func Poly(p *sdf.Polygon, path string) error {\n\n\tvlist := p.Vertices()\n\tif vlist == nil {\n\t\treturn errors.New(\"no vertices\")\n\t}\n\n\tfmt.Printf(\"rendering %s\\n\", path)\n\td := NewDXF(path)\n\n\tfor i := 0; i < len(vlist)-1; i++ {\n\t\tp0 := vlist[i]\n\t\tp1 := vlist[i+1]\n\t\td.Line(p0, p1)\n\t}\n\n\tif p.Closed() {\n\t\tp0 := vlist[len(vlist)-1]\n\t\tp1 := vlist[0]\n\t\tif !p0.Equals(p1, tolerance) {\n\t\t\td.Line(p0, p1)\n\t\t}\n\t}\n\n\treturn d.Save()\n}", "func NewPolygon() *Polygon {\n\tthis := Polygon{}\n\treturn &this\n}", "func (p *Particle) SetRaysDirToPolyVertices(polygons Polygons) {\n\tfor _, polygon := range polygons {\n\t\tfor _, vertex := range polygon.Loop {\n\t\t\trayLeft := NewRay(p.Pos)\n\t\t\trayLeft.SetDir(vertex.X-0.0001, vertex.Y-0.0001)\n\t\t\trayRight := NewRay(p.Pos)\n\t\t\trayRight.SetDir(vertex.X+0.0001, vertex.Y+0.0001)\n\n\t\t\tp.Rays = append(p.Rays, rayLeft, rayRight)\n\t\t}\n\t}\n}", "func StencilMask(mask uint32) {\n C.glowStencilMask(gpStencilMask, (C.GLuint)(mask))\n}", "func StencilMask(mask uint32) {\n\tgl.StencilMask(mask)\n}", "func (node *PolygonExpr) formatFast(buf *TrackedBuffer) {\n\tbuf.WriteString(\"polygon(\")\n\tnode.LinestringParams.formatFast(buf)\n\tbuf.WriteByte(')')\n}", "func (j *Job) patternFill(bp []byte) {\n\tvar up *int64\n\tvar engine func()int64\n\n\tswitch {\n\tcase j.JobParams.Block_Pattern == PatternRand:\n\t\tengine = rand.Int63\n\tcase j.JobParams.Block_Pattern == PatternLCG:\n\t\tengine = j.lcgPattern.Value63\n\t}\n\n\tslice := (*reflect.SliceHeader)(unsafe.Pointer(&bp))\n\tfor offset := 0; offset < len(bp); offset += 8 {\n\t\tup = (*int64)(unsafe.Pointer(uintptr(unsafe.Pointer(slice.Data)) + uintptr(offset)))\n\t\t*up = engine()\n\t}\n}", "func (native *OpenGL) PolygonMode(face uint32, mode uint32) {\n\tgl.PolygonMode(face, mode)\n}", "func (bm Bitmap) Set(i Sym) {\n\tn, r := uint(i)/32, uint(i)%32\n\tbm[n] |= 1 << r\n}", "func (geom Geometry) SetPoint(index int, x, y, z float64) {\n\tC.OGR_G_SetPoint(\n\t\tgeom.cval,\n\t\tC.int(index),\n\t\tC.double(x),\n\t\tC.double(y),\n\t\tC.double(z))\n}", "func StencilMaskSeparate(face uint32, mask uint32) {\n C.glowStencilMaskSeparate(gpStencilMaskSeparate, (C.GLenum)(face), (C.GLuint)(mask))\n}", "func (shape *Shape) SegmentShapeSetEndpoints(a, b Vect) {\n\tC.cpSegmentShapeSetEndpoints(\n\t\t(*C.cpShape)(unsafe.Pointer(shape)),\n\t\ta.c(),\n\t\tb.c(),\n\t)\n}", "func (dw *DrawingWand) SetFillPatternURL(fillUrl string) {\n\tcstr := C.CString(fillUrl)\n\tdefer C.free(unsafe.Pointer(cstr))\n\tC.MagickDrawSetFillPatternURL(dw.dw, cstr)\n}", "func (el *Fill) Set() {}", "func (g *grid) set(v vector, value int8) {\n\tg.bits[v.y][v.x] = value\n}", "func (p *Polygon) createArcs() {\n\tdone := false\n\tfor done == false {\n\t\tdone = true\n\t\tfor i := range p.vlist {\n\t\t\tif p.arcVertex(i) {\n\t\t\t\tdone = false\n\t\t\t}\n\t\t}\n\t}\n}", "func PolygonOffset(factor float32, units float32) {\n\tC.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func PolygonOffset(factor float32, units float32) {\n\tC.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func (c *container) Polygon(pts ...Point) *Polygon {\n\tp := &Polygon{Points: pts}\n\tc.contents = append(c.contents, p)\n\n\treturn p\n}", "func Test_pattern_manager_setpatterns1(t *testing.T) {\n\n\tpolicyPath := \"/tmp/servedpatterntest/\"\n\tservedPatterns := map[string]exchange.ServedPattern{\n\t\t\"myorg1_pattern1\": {\n\t\t\tOrg: \"myorg1\",\n\t\t\tPattern: \"pattern1\",\n\t\t},\n\t}\n\n\tif np := NewPatternManager(); np == nil {\n\t\tt.Errorf(\"Error: pattern manager not created\")\n\t} else if err := np.SetCurrentPatterns(servedPatterns, policyPath); err != nil {\n\t\tt.Errorf(\"Error %v consuming served patterns %v\", err, servedPatterns)\n\t} else if len(np.OrgPatterns) != 1 {\n\t\tt.Errorf(\"Error: should have 1 org in the PatternManager, have %v\", len(np.OrgPatterns))\n\t} else {\n\t\tt.Log(np)\n\t}\n\n}", "func (t *Table) Polygon(colNm string) *Table {\n\tt.columns = append(t.columns, &column{Name: colNm, ColumnType: TypePolygon})\n\treturn t\n}", "func (s *CubicSplineSDF2) Polygonize(n int) *Polygon {\n\tp := NewPolygon()\n\tdt := float64(len(s.spline)) / float64(n-1)\n\tt := 0.0\n\tfor i := 0; i < n; i++ {\n\t\tp.AddV2(s.f0(t))\n\t\tt += dt\n\t}\n\treturn p\n}", "func (it *GridIterator) SetP(p Point) {\n\tq := p.Add(it.rg.Min)\n\tif !q.In(it.rg) {\n\t\treturn\n\t}\n\tit.p = p\n\tit.i = q.Y*it.w + q.X\n}", "func (p *Polygon) Clear() {\n\tC.geod_polygon_clear(&p.p)\n}", "func (self *Graphics) DrawPolygon(path interface{}) *Graphics{\n return &Graphics{self.Object.Call(\"drawPolygon\", path)}\n}", "func (pg *Polygon) Fill(c color.Color) {\n\t// Reset the rgba of the polygon\n\tbounds := pg.r.Bounds()\n\trect := image.Rect(0, 0, bounds.Max.X, bounds.Max.Y)\n\trgba := image.NewRGBA(rect)\n\tminx := pg.Rect2.Min.X()\n\tminy := pg.Rect2.Min.Y()\n\tfor x := 0; x < bounds.Max.X; x++ {\n\t\tfor y := 0; y < bounds.Max.Y; y++ {\n\t\t\tif pg.Contains(float64(x)+minx, float64(y)+miny) {\n\t\t\t\trgba.Set(x, y, c)\n\t\t\t}\n\t\t}\n\t}\n\tpg.r = rgba\n}", "func StencilMask(mask uint32) {\n\tsyscall.Syscall(gpStencilMask, 1, uintptr(mask), 0, 0)\n}", "func GeneratePattern() {\n\tgeneratePattern()\n\n}", "func StencilMask(mask uint) {\n\tC.glStencilMask(C.GLuint(mask))\n}", "func (c *HelpCountryCode) SetPatterns(value []string) {\n\tc.Flags.Set(1)\n\tc.Patterns = value\n}", "func (this *DtNavMesh) SetPolyFlags(ref DtPolyRef, flags uint16) DtStatus {\n\tif ref == 0 {\n\t\treturn DT_FAILURE\n\t}\n\tvar salt, it, ip uint32\n\tthis.DecodePolyId(ref, &salt, &it, &ip)\n\tif it >= (uint32)(this.m_maxTiles) {\n\t\treturn DT_FAILURE | DT_INVALID_PARAM\n\t}\n\tif this.m_tiles[it].Salt != salt || this.m_tiles[it].Header == nil {\n\t\treturn DT_FAILURE | DT_INVALID_PARAM\n\t}\n\ttile := &this.m_tiles[it]\n\tif ip >= (uint32)(tile.Header.PolyCount) {\n\t\treturn DT_FAILURE | DT_INVALID_PARAM\n\t}\n\tpoly := &tile.Polys[ip]\n\n\t// Change flags.\n\tpoly.Flags = flags\n\n\treturn DT_SUCCESS\n}" ]
[ "0.5638292", "0.5576568", "0.5436507", "0.5368226", "0.5366266", "0.5303373", "0.5222189", "0.5166519", "0.5076445", "0.50755554", "0.50195706", "0.5000205", "0.4984429", "0.49822146", "0.49661428", "0.4896016", "0.4879233", "0.48724705", "0.483172", "0.48315576", "0.482566", "0.47606352", "0.4752482", "0.47458965", "0.47422254", "0.46757117", "0.46644747", "0.46187323", "0.46173", "0.4615826", "0.46127748", "0.45973688", "0.45948797", "0.45888305", "0.45780686", "0.45576808", "0.4546441", "0.4503203", "0.4498397", "0.44804925", "0.44637907", "0.4432957", "0.44029164", "0.43925354", "0.43917015", "0.43914133", "0.43786445", "0.4374349", "0.43658927", "0.43637052", "0.436163", "0.43570083", "0.43554825", "0.4343239", "0.43355873", "0.4333189", "0.43304443", "0.43250647", "0.4318597", "0.4313619", "0.43088987", "0.42965573", "0.42937458", "0.4285117", "0.42785758", "0.427716", "0.42667404", "0.42648265", "0.42637092", "0.42624727", "0.42595786", "0.42592973", "0.42506006", "0.42503202", "0.42464763", "0.4245651", "0.42321473", "0.42273846", "0.42230442", "0.42224333", "0.42171997", "0.4215339", "0.42143166", "0.4210204", "0.4207683", "0.42073202", "0.42073202", "0.42047963", "0.4191131", "0.41897324", "0.41837353", "0.41778108", "0.41734394", "0.41709387", "0.4167568", "0.41651708", "0.4163812", "0.41596413", "0.41594556", "0.4157991" ]
0.51751536
7
pop the active debug group
func PopDebugGroup() { C.glowPopDebugGroup(gpPopDebugGroup) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PopDebugGroup() {\n\tsyscall.Syscall(gpPopDebugGroup, 0, 0, 0, 0)\n}", "func PopDebugGroup() {\n C.glowPopDebugGroup(gpPopDebugGroup)\n}", "func RestoreForegroundGroup() {\n\tif group == ForegroundGroup() {\n\t\treturn\n\t}\n\n\tSetForegroundGroup(group)\n}", "func (s *BasePlSqlParserListener) ExitLibrary_debug(ctx *Library_debugContext) {}", "func (s *BasePlSqlParserListener) ExitLog_grp(ctx *Log_grpContext) {}", "func (igb *iterativeGroupBuffers) popFirstCompleteGroup() (timeKey time.Time, nearestCityKey string, cameraModel string, images []*geoindex.GeographicRecord) {\n electedCameraModel := igb.haveAnyCompleteGroups()\n if electedCameraModel == \"\" {\n log.Panicf(\"can not pop a complete group if we do not have one\")\n }\n\n electedBg := igb.groupsByCameraModel[electedCameraModel]\n timeKey = electedBg.firstTimeKey\n\n nearestCityKey, images = electedBg.popCompleteGroup()\n if electedBg.isEmpty() == true {\n delete(igb.groupsByCameraModel, electedCameraModel)\n }\n\n return timeKey, nearestCityKey, electedCameraModel, images\n}", "func pop_level(){\nif text_info[cur_state.repl_field].text_link<max_texts{/* link to a continuation */\ncur_state.repl_field= text_info[cur_state.repl_field].text_link/* stay on the same level */\ncur_state.byte_field= text_info[cur_state.repl_field].token\nreturn\n}\n\nif len(stack)> 0{\ncur_state= stack[len(stack)-1]\nstack= stack[:len(stack)-1]\n}\n}", "func LevelPop() {\n len := len(logLevelStack)\n logLevel, logLevelStack = logLevelStack[len-1], logLevelStack[:len-1] \n}", "func (p *PageStack) StackPopped(o, top model.Component) {\n\to.Stop()\n\tp.StackTop(top)\n}", "func (s *State) Pop() *mesosfile.Group {\n\t// If running task groups synchronously each subsequent group (and task) must reach\n\t// TASK_FINISHED before the next task is available for scheduling.\n\tif s.sync && s.last != mesos.TASK_FINISHED {\n\t\treturn nil\n\t}\n\tselect {\n\tcase group := <-s.pending:\n\t\tif s.sync {\n\t\t\t// Reset last to TASK_STARTING to avoid a race condition\n\t\t\ts.last = mesos.TaskState(0)\n\t\t}\n\t\treturn group\n\tdefault:\n\t}\n\treturn nil\n}", "func (g *Generator) popField() {\n\tg.fieldStack = g.fieldStack[:len(g.fieldStack)-1]\n}", "func (s *state) pop(mark int) {\n\ts.vars = s.vars[0:mark]\n}", "func (cd *circularDependency) pop() {\n\t//log.Println(\"Removing:\", cd.Dependents[len(cd.Dependents)-1])\n\tcd.dependents = cd.dependents[:len(cd.dependents)-1]\n}", "func (tb *TreeBuilder) Pop() {\n if debug.DEBUG {\n fmt.Println(\"<<<<<<<<<<<<<<< START POP NODE <<<<<<<<<<<<<<<\")\n defer fmt.Println(\" <<<<<<<<<<<<<<< DONE POP NODE <<<<<<<<<<<<<<<\")\n }\n if debug.DEBUG {\n fmt.Println(len(tb.stack), tb.node)\n }\n tb.stack, tb.node = tb.stack[:len(tb.stack)-1], tb.stack[len(tb.stack)-1]\n if debug.DEBUG {\n fmt.Println(len(tb.stack))\n }\n}", "func UnsetDebug() {\n\tglobalDebug = false\n}", "func (bg *bufferedGroup) popCompleteGroup() (nearestCityKey string, group []*geoindex.GeographicRecord) {\n if bg.haveCompleteGroup() == false {\n log.Panicf(\"can not return complete group if we do not have one\")\n }\n\n // Iterate through the images at the top of the buffer. Stop when the city\n // or the time-key changes.\n\n group = make([]*geoindex.GeographicRecord, 0)\n firstNearestCityKey := \"\"\n firstTimeKey := time.Time{}\n for _, bi := range bg.images {\n if firstNearestCityKey == \"\" {\n firstNearestCityKey = bi.nearestCityKey\n } else if bi.nearestCityKey != firstNearestCityKey {\n // Break if the current image belongs to a different city than the last.\n\n break\n }\n\n if firstTimeKey.IsZero() == true {\n firstTimeKey = bi.effectiveTimekey\n } else if bi.effectiveTimekey != firstTimeKey {\n // Break if the current image belongs to a different time-key than the last.\n\n break\n }\n\n group = append(group, bi.gr)\n }\n\n len_ := len(group)\n if len_ == 0 {\n log.Panicf(\"the 'first time-key' didn't actually match the first records in the buffer\")\n }\n\n // Prune the front N images.\n bg.images = bg.images[len_:]\n\n if len(bg.images) == 0 {\n // If we get here, the caller should deallocate us.\n bg.firstTimeKey = time.Time{}\n } else {\n bg.firstTimeKey = bg.images[0].effectiveTimekey\n }\n\n bg.updateLocationIndex()\n\n return firstNearestCityKey, group\n}", "func (c *canvasRenderer) Pop() {\n\tc.currentLayer = c.currentLayer.Previous()\n}", "func (r *renderer) pop() reflect.Value {\n\tif len(r.stack) == 0 {\n\t\treturn reflect.Value{}\n\t}\n\tctx := r.stack[len(r.stack)-1]\n\tr.stack = r.stack[:len(r.stack)-1]\n\treturn ctx\n}", "func (vm *VM) framePop() {\n\tf := vm.frames.pop()\n\tvm.global.op = f.op\n\tvm.global.currentEnv = f.env\n}", "func killProcessGroup(pid int) {\n\tif DEBUG {\n\t\tlog.Printf(\"Debug: killProcessGroup( %d )\\n\", pid)\n\t}\n\n\tsyscall.Kill(-pid, syscall.SIGHUP)\n}", "func (s *layoutStack) pop() geom.Layout {\n\ts.assertNotEmpty()\n\tif s.atTopLevel() {\n\t\tpanic(\"top level stack frame should never be popped\")\n\t}\n\tcurTopLayout := s.topLayout()\n\ts.data = s.data[:len(s.data)-1]\n\treturn curTopLayout\n}", "func (s *stack) pop() {\n\ts.items = s.items[:len(s.items)-1]\n}", "func (st *scopeStack) pop() {\n\tl := len(st.stack)\n\tif l == 1 {\n\t\tpanic(\"popped the standard library (pre-main) scope\")\n\t}\n\t// TODO OPT: Optimize for space, this will never free any underlying memory.\n\tst.stack = st.stack[:l-1]\n}", "func (s *callStack) popIfExists(whichFrame int) {\n\tif len(s.stack) == whichFrame {\n\t\tif s.top().cleanEnv {\n\t\t\ts.calls--\n\t\t}\n\t\ts.setCurrentTrace(s.stack[len(s.stack)-1].trace)\n\t\ts.stack = s.stack[:len(s.stack)-1]\n\t}\n}", "func (t *TaskStore) heapPop(group string, id int64) {\n\th, ok := t.heaps[group]\n\tif !ok {\n\t\treturn\n\t}\n\th.PopByKey(id)\n\tif h.Len() == 0 {\n\t\tdelete(t.heaps, group)\n\t}\n}", "func (bg *bufferedGroup) popPartialGroup() (nearestCityKey string, group []*geoindex.GeographicRecord) {\n if bg.haveCompleteGroup() == true {\n log.Panicf(\"can not return partial group if at least one complete group is available\")\n } else if bg.havePartialGroup() == false {\n log.Panicf(\"can not return partial group if we do not have one\")\n }\n\n group = make([]*geoindex.GeographicRecord, 0)\n nearestCityKey = \"\"\n for _, bi := range bg.images {\n gr := bi.gr\n\n if nearestCityKey == \"\" {\n nearestCityKey = bi.nearestCityKey\n }\n\n group = append(group, gr)\n }\n\n // Truncate since we've consumed all contents.\n bg.images = make([]*bufferedImage, 0)\n\n bg.firstTimeKey = time.Time{}\n bg.lastTimeKey = time.Time{}\n\n bg.updateLocationIndex()\n\n return nearestCityKey, group\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 (p *parser) popRecovery() {\n\t// GC that map\n\tp.recoveryStack[len(p.recoveryStack)-1] = nil\n\n\tp.recoveryStack = p.recoveryStack[:len(p.recoveryStack)-1]\n}", "func (p *parser) popRecovery() {\n\t// GC that map\n\tp.recoveryStack[len(p.recoveryStack)-1] = nil\n\n\tp.recoveryStack = p.recoveryStack[:len(p.recoveryStack)-1]\n}", "func (p *parser) popRecovery() {\n\t// GC that map\n\tp.recoveryStack[len(p.recoveryStack)-1] = nil\n\n\tp.recoveryStack = p.recoveryStack[:len(p.recoveryStack)-1]\n}", "func (p *parser) popRecovery() {\n\t// GC that map\n\tp.recoveryStack[len(p.recoveryStack)-1] = nil\n\n\tp.recoveryStack = p.recoveryStack[:len(p.recoveryStack)-1]\n}", "func (stack *savepointStack) popToIdx(idx int) {\n\t*stack = (*stack)[:idx+1]\n}", "func (a *LocalActivations) Pop() {\n\tcount := len(a.activations)\n\tif count < 1 {\n\t\treturn\n\t}\n\ta.activations = a.activations[:count-1]\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 (r *wavefrontSceneReader) popFrame() {\n\tr.errStack = r.errStack[1:]\n}", "func BecomeForegroundGroup() (err error) {\n\tfor group != ForegroundGroup() {\n\t\terr = unix.Kill(-group, unix.SIGTTIN)\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\n\t\tgroup, err = unix.Getpgid(id)\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif id != group {\n\t\terr = unix.Setpgid(id, id)\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\n\t\tgroup = id\n\t}\n\n\tSetForegroundGroup(group)\n\n\treturn\n}", "func (c *Console) Remove(group string) (err error) {\n\t_, err = fmt.Fprintf(c.conn, \"%v\\n\", toJSON([]string{\"remove\", group}))\n\tif err == nil {\n\t\terr = <-c.Waiter\n\t}\n\treturn\n}", "func (t *Tree) cursorStackPop() {\n\tt.cursorStack = t.cursorStack[:len(t.cursorStack)-1]\n}", "func PushDebugGroup(source uint32, id uint32, length int32, message *uint8) {\n\tsyscall.Syscall6(gpPushDebugGroup, 4, uintptr(source), uintptr(id), uintptr(length), uintptr(unsafe.Pointer(message)), 0, 0)\n}", "func (s *BaseSyslParserListener) ExitGroup_stmt(ctx *Group_stmtContext) {}", "func (s *BasePlSqlParserListener) ExitLog_file_group(ctx *Log_file_groupContext) {}", "func (s *BasePlSqlParserListener) ExitSupplemental_log_grp_clause(ctx *Supplemental_log_grp_clauseContext) {\n}", "func (s *BasevhdlListener) ExitGroup_declaration(ctx *Group_declarationContext) {}", "func (c *Action) EndGroup() {\n\tfmt.Fprint(c.w, endGroupFmt)\n}", "func RemoveLastElemFromTop(c *gin.Context) { dequeueTop([]qMessage{}) }", "func DelGroup(name string) (err error) {\n\terr = del(name, &Group{})\n\tif err == nil {\n\t\terr = del(name, &GShadow{})\n\t}\n\treturn\n}", "func (r *YAMLCmpReporter) PopStep() {\n\tr.path = r.path[:len(r.path)-1]\n}", "func (ds *DrawStack) Pop() {\n\tds.toPop++\n}", "func (s *htmlState) pop(tag string) {\n\tn := len(s.openTags)\n\tif n == 0 {\n\t\tif s.ignore&issueStructure == 0 {\n\t\t\ts.err(fmt.Errorf(\"no open tags left to close %s\", tag))\n\t\t}\n\t\treturn\n\t}\n\tpop := s.openTags[n-1]\n\ts.openTags = s.openTags[:n-1]\n\tif s.ignore&issueStructure != 0 {\n\t\treturn\n\t}\n\tif pop != tag && !s.badNesting { // report broken structure just once.\n\t\ts.err(fmt.Errorf(\"tag '%s' closed by '%s'\", pop, tag))\n\t\ts.badNesting = true\n\t}\n}", "func (s *BaseMySqlParserListener) ExitGroupByItem(ctx *GroupByItemContext) {}", "func (gr *Group) Unwrap() *Group {\n\ttx, ok := gr.config.driver.(*txDriver)\n\tif !ok {\n\t\tpanic(\"ent: Group is not a transactional entity\")\n\t}\n\tgr.config.driver = tx.drv\n\treturn gr\n}", "func (syncObj *Sync)ExitRoutineInWaitGroup() {\n syncObj.appWaitGroups.Done()\n}", "func(k *Stack) Pop(){\n\tl := len(k.nums)-1\n\n\tk.nums = k.nums[:l]\n\n\n}", "func (mg *Groups) clear() {\n\n\tmg.group = &Group{}\n}", "func (autoscalingGroup *AutoscalingGroup) popNodes(popNodes []string) {\n\tvar updatedList []string\n\tfor _, node := range autoscalingGroup.Nodes {\n\t\tnodeFound := false\n\t\tfor _, popNode := range popNodes {\n\t\t\tif popNode == node {\n\t\t\t\tnodeFound = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif !nodeFound {\n\t\t\tupdatedList = append(updatedList, node)\n\t\t}\n\t}\n\tautoscalingGroup.Nodes = updatedList\n\treturn\n}", "func (m *BarRecordMutation) ClearGroup() {\n\tm.clearedgroup = true\n}", "func (s *BasePlSqlParserListener) ExitGroup_by_elements(ctx *Group_by_elementsContext) {}", "func (bg *BarGroup) Unwrap() *BarGroup {\n\t_tx, ok := bg.config.driver.(*txDriver)\n\tif !ok {\n\t\tpanic(\"ent: BarGroup is not a transactional entity\")\n\t}\n\tbg.config.driver = _tx.drv\n\treturn bg\n}", "func (pg *ProcessGroup) End() {\n\n\t\t// With every public method calling setup, we avoid the need for a constructor function and it becomes safe\n\t\t// to allow end users to be able to acess the process group itself (ProcessGroup instead of processGroup)\n\t\tpg.setup()\n\n\t\t// Kill our group context - all process contexts are children of that\n\t\tpg.cancel()\n\t}", "func (g *Group) popCloser() (closer func() error) {\n\tg.mutex.Lock()\n\tdefer g.mutex.Unlock()\n\ti := len(g.closers) - 1\n\tif i >= 0 {\n\t\tcloser = g.closers[i]\n\t\tg.closers = g.closers[:i]\n\t}\n\treturn\n}", "func POPQ(mr operand.Op) { ctx.POPQ(mr) }", "func LeaveGroup(selfMember *MemberID, msgQueue *[]GossipMessage) {\n\t// This leave message will later be Gossiped.\n\t*msgQueue = append(*msgQueue, GossipMessage{Member: *selfMember, Status: 2, TTL: 3})\n\n\tfmt.Println(\"Leaving now and sending messages to other members.\")\n\tlogMsg, _ := json.Marshal(*selfMember)\n\tmp2util.WriteLog(\"Leave: Informing other members before leaving:\" + string(logMsg))\n\t/*\n\t\tWait 2 seconds before leave.\n\t\tDuring this period, this node will repy other pings.\n\t\t\tOtherwise, other nodes will think it failed before receive the leaving message.\n\t*/\n\ttime.Sleep(time.Millisecond * 2000)\n\n\tlogMsg, _ = json.Marshal(*selfMember)\n\tmp2util.WriteLog(\"Leave: Terminating the program:\" + string(logMsg))\n\tfmt.Println(\"Thank you. See you!\")\n\n}", "func ExitGroup(t *kernel.Task, sysno uintptr, args arch.SyscallArguments) (uintptr, *kernel.SyscallControl, error) {\n\tstatus := args[0].Int()\n\tt.PrepareGroupExit(linux.WaitStatusExit(status & 0xff))\n\treturn 0, kernel.CtrlDoExit, nil\n}", "func (s *BaseCGListener) ExitAttributegroup(ctx *AttributegroupContext) {}", "func Pop(context *endly.Context) *model.Process {\n\tvar processes = processes(context)\n\tvar process = processes.Pop()\n\tif process != nil && process.Source != nil {\n\t\tcontext.Source = process.Source\n\t}\n\treturn process\n}", "func (el *ExitList) Pop(exitInterface ExitInterface) error {\n\tif el.module == nil {\n\t\treturn errors.New(\"[Smoothly Exit] Pop: plz init ExitList first\")\n\t}\n\n\t// Judge whether it exists or not\n\tmoduleName := exitInterface.GetModuleName()\n\tif _, ok := el.module[moduleName]; ok {\n\t\treturn errors.New(\"[Smoothly Exit] Pop: this module(\" + moduleName + \") name is exist\")\n\t}\n\n\t// Add value\n\telement := el.ll.PushFront(exitInterface)\n\tel.module[moduleName] = element\n\n\treturn nil\n}", "func demo_stack() {\n fmt.Print(\"\\n---STACK Logic---\\n\\n\")\n s := stack.Stack{}\n\n for i := 0; i <= 5; i++ {\n s.Push(i)\n }\n fmt.Print(\"---Stack Before Pop---\\n\")\n s.PrintAll()\n\n popped := s.Pop()\n fmt.Printf(\"\\nPopped Value: %v\\n\", popped)\n fmt.Print(\"---Stack After Pop---\\n\")\n s.PrintAll()\n}", "func (g *Group) Quit() {\n\tg.mu.Lock()\n\tif !g.closed && g.quit != nil {\n\t\tclose(g.quit)\n\t\tg.closed = true\n\t}\n\tg.mu.Unlock()\n}", "func (g *Group) reset() {\n\tg.pattern = \"\"\n\tg.handlers = g.handlers[:0]\n}", "func (gs *LocalConf) Remove(group, repo string) (err error) {\n\tif gs == nil {\n\t\treturn errors.New(\"null.receiver\")\n\t}\n\n\tcd(\"group:%s repo:%s\", group, repo)\n\n\tfor _, g := range gs.Groups {\n\t\tif group == g.Name {\n\t\t\tnrepos := make([]string, 0, len(g.Repos))\n\t\t\tfor _, j := range g.Repos {\n\t\t\t\tif j == repo {\n\t\t\t\t\tcd(\"matched.continue:%s\", j)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tnrepos = append(nrepos, j)\n\t\t\t}\n\t\t\tg.Repos = nrepos\n\t\t\treturn\n\t\t}\n\t}\n\n\treturn\n}", "func PopSub() {\n\toutput.EmitLn(\"SUB (SP)+,D0\")\n}", "func (this popChannel) stack(cmd ...*URLContext) {\n\ttoStack := cmd\n\tfor {\n\t\tselect {\n\t\tcase this <- toStack:\n\t\t\treturn\n\t\tcase old := <-this:\n\t\t\t// Content of the channel got emptied and is now in old, so append whatever\n\t\t\t// is in toStack to it, so that it can either be inserted in the channel,\n\t\t\t// or appended to some other content that got through in the meantime.\n\t\t\ttoStack = append(old, toStack...)\n\t\t}\n\t}\n}", "func (es *eeStack) pop() (v interface{}, t eeType) {\r\n\tt = es.popType()\r\n\tv = t.pop(es)\r\n\treturn\r\n}", "func (p *TimerStack) Pop() {\n\tlastIndex := len(p.stack) - 1\n\tpopped := p.stack[lastIndex]\n\tp.stack = p.stack[:lastIndex]\n\telapsed := time.Since(popped.start)\n\tp.popEventHandler.PopEvent(popped.eventName, elapsed)\n}", "func (igb *iterativeGroupBuffers) popFirstPartialGroup() (timeKey time.Time, nearestCityKey string, cameraModel string, images []*geoindex.GeographicRecord) {\n cameraModelWithComplete := igb.haveAnyCompleteGroups()\n if cameraModelWithComplete != \"\" {\n log.Panicf(\"can not pop a partial group if we still have complete groups: [%s]\", cameraModelWithComplete)\n }\n\n electedCameraModel := igb.haveAnyPartialGroups()\n if electedCameraModel == \"\" {\n log.Panicf(\"can not pop a partial group if we do not have one\")\n }\n\n electedBg := igb.groupsByCameraModel[electedCameraModel]\n timeKey = electedBg.firstTimeKey\n\n nearestCityKey, images = electedBg.popPartialGroup()\n if electedBg.isEmpty() == false {\n log.Panicf(\"we expected buffer to be empty after popping a partial group from it: [%s]\", electedCameraModel)\n }\n\n delete(igb.groupsByCameraModel, electedCameraModel)\n\n return timeKey, nearestCityKey, electedCameraModel, images\n}", "func (canvas *Canvas) Pop() {\n\twriteCommand(canvas.contents, \"Q\")\n}", "func (m *patchGoom) Stop() {\n}", "func (m *BarRecordMutation) ResetGroup() {\n\tm.group = nil\n\tm.clearedgroup = false\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 (g *Github) untrackBuild(build core.Build) {\n\tbuildIndex := -1\n\tfor i, trackedBuild := range g.trackedBuilds {\n\t\tif trackedBuild.Token() == build.Token() {\n\t\t\tbuildIndex = i\n\t\t\tbreak\n\t\t}\n\t}\n\n\tif buildIndex < 0 {\n\t\treturn\n\t}\n\n\tg.trackedBuilds[buildIndex].Unref()\n\tg.trackedBuilds = append(g.trackedBuilds[:buildIndex], g.trackedBuilds[buildIndex+1:]...)\n}", "func (fg *FlowGroup) Unwrap() *FlowGroup {\n\ttx, ok := fg.config.driver.(*txDriver)\n\tif !ok {\n\t\tpanic(\"models: FlowGroup is not a transactional entity\")\n\t}\n\tfg.config.driver = tx.drv\n\treturn fg\n}", "func (s *BaseSelectStatementParserListener) ExitGroupFunction(ctx *GroupFunctionContext) {}", "func (lc *LoggingContext) Pop() (error, bool) {\n\tif lc.curr == \"\" {\n\t\treturn errors.New(fmt.Sprintf(\"Cannot pop context; no loggers have been added\")), false\n\t}\n\tlc.guard.Lock()\n\tdefer lc.guard.Unlock()\n\tif lc.logstack.Len() == 0 {\n\t\treturn errors.New(fmt.Sprintf(\"Cannot pop context; logger stack empty. Still using \\\"%s\\\"\", lc.curr)), true\n\t}\n\tname := lc.logstack.Remove(lc.logstack.Back()).(string)\n\tlc.curr = name\n\tlogger := lc.logmap[name]\n\tl.UseLogger(*logger)\n\treturn nil, true\n}", "func RemoveSubProcessCurrentOrg(c *middleware.Context) Response {\n subprocessId := c.ParamsInt64(\":subProcessId\")\n logger := log.New(\"main\")\n logger.Info(\"Delete Process 1 %s\")\n return removeOrgSubProcessHelper(c.OrgId, subprocessId)\n}", "func (o *ActivityLog) RemoveGroup(ctx context.Context, exec boil.ContextExecutor, related *Group) error {\n\tvar err error\n\n\tqueries.SetScanner(&o.GroupID, nil)\n\tif _, err = o.Update(ctx, exec, boil.Whitelist(\"group_id\")); err != nil {\n\t\treturn errors.Wrap(err, \"failed to update local table\")\n\t}\n\n\to.R.Group = nil\n\tif related == nil || related.R == nil {\n\t\treturn nil\n\t}\n\n\tfor i, ri := range related.R.ActivityLogs {\n\t\tif queries.Equal(o.GroupID, ri.GroupID) {\n\t\t\tcontinue\n\t\t}\n\n\t\tln := len(related.R.ActivityLogs)\n\t\tif ln > 1 && i < ln-1 {\n\t\t\trelated.R.ActivityLogs[i] = related.R.ActivityLogs[ln-1]\n\t\t}\n\t\trelated.R.ActivityLogs = related.R.ActivityLogs[:ln-1]\n\t\tbreak\n\t}\n\treturn nil\n}", "func (t *Timer) Pop() {\n\tif last := len(t.stack) - 1; last >= 0 {\n\t\tt.Intervals[t.stack[last]].End = t.Now()\n\t\tt.stack = t.stack[:last]\n\t}\n}", "func (root *DSSRoot) removeStack(stack *Stack) {\n\tfor i, s := range root.stacks {\n\t\tif s == stack {\n\t\t\troot.stacks[i] = root.stacks[len(root.stacks)-1]\n\t\t\troot.stacks[len(root.stacks)-1] = nil\n\t\t\troot.stacks = root.stacks[:len(root.stacks)-1]\n\t\t}\n\t}\n}", "func (g *Generator) exit() {\n\tg.depth--\n}", "func (w *walk) pop() {\n\tif len(*w) > 0 {\n\t\t*w = (*w)[:len(*w)-1]\n\t}\n}", "func (c *Context) POPQ(mr operand.Op) {\n\tc.addinstruction(x86.POPQ(mr))\n}", "func (lu *LessonplanUpdate) ClearGroupID() *LessonplanUpdate {\n\tlu.mutation.ClearGroupID()\n\treturn lu\n}", "func (luo *LessonplanUpdateOne) ClearGroupID() *LessonplanUpdateOne {\n\tluo.mutation.ClearGroupID()\n\treturn luo\n}", "func (p *Proc) Pop() {\n\tp.stk.load()\n}", "func (p *NoOpNodeGroupListProcessor) CleanUp() {\n}", "func (dw *DrawingWand) PopPattern() {\n\tC.MagickDrawPopPattern(dw.dw)\n}", "func Current() (*Group, error) {\n\treturn currentGroup()\n}", "func (tr *TestRunner) Del(addr *net.UDPAddr) {\n\ttr.mutex.Lock()\n\tdefer tr.mutex.Unlock()\n\t// Find the element\n\tfor i, v := range tr.targets {\n\t\tif v == addr {\n\t\t\t// Delete the element\n\t\t\t// This doesn't preserve order because it shouldn't matter.\n\t\t\t// Also it's WAY more efficient, especially at scale.\n\t\t\ttr.targets[i] = tr.targets[len(tr.targets)-1]\n\t\t\ttr.targets[len(tr.targets)-1] = nil\n\t\t\ttr.targets = tr.targets[:len(tr.targets)-1]\n\t\t}\n\t}\n}", "func (sm *StackedMap) Pop() {\n\t// pop key revision\n\ttop := sm.mapStack.top().(*level)\n\tfor key := range top.kvs {\n\t\trevs := sm.keyRevisionMap[key]\n\t\trevs.pop()\n\t\tif len(*revs) == 0 {\n\t\t\tdelete(sm.keyRevisionMap, key)\n\t\t}\n\t}\n\tsm.mapStack.pop()\n}" ]
[ "0.8235275", "0.7928944", "0.5345466", "0.5344072", "0.52889436", "0.52754337", "0.5265217", "0.5236283", "0.52260923", "0.5212983", "0.52015", "0.5184811", "0.5170799", "0.512836", "0.51194507", "0.5111059", "0.50622296", "0.5037767", "0.5034207", "0.49798647", "0.49658376", "0.4948714", "0.49289095", "0.49225843", "0.4919663", "0.49083173", "0.4887336", "0.48828202", "0.48828202", "0.48828202", "0.48828202", "0.48637113", "0.4862908", "0.485976", "0.485976", "0.48399207", "0.481469", "0.47967523", "0.47836566", "0.4772011", "0.47626257", "0.4757642", "0.47404674", "0.47255978", "0.47154853", "0.47143796", "0.47130218", "0.47106743", "0.4674937", "0.46722147", "0.46710682", "0.46705043", "0.4666081", "0.46642432", "0.4653291", "0.46523118", "0.46380162", "0.4637614", "0.46302953", "0.46294886", "0.4629204", "0.46268633", "0.46258917", "0.4620682", "0.46177176", "0.4616858", "0.46048766", "0.4604027", "0.459786", "0.4585327", "0.45799506", "0.4578456", "0.45780206", "0.45737106", "0.45572826", "0.45536643", "0.45497078", "0.4544492", "0.4522608", "0.45195922", "0.44929934", "0.4489544", "0.44871867", "0.44830498", "0.44702", "0.44523838", "0.44405746", "0.443457", "0.4433905", "0.44327587", "0.4425187", "0.44178462", "0.44110796", "0.44099593", "0.43992102", "0.43967506", "0.43955728", "0.4380655", "0.43734735" ]
0.78050977
3
specify the primitive restart index
func PrimitiveRestartIndex(index uint32) { C.glowPrimitiveRestartIndex(gpPrimitiveRestartIndex, (C.GLuint)(index)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PrimitiveRestartIndex(index uint32) {\n C.glowPrimitiveRestartIndex(gpPrimitiveRestartIndex, (C.GLuint)(index))\n}", "func (proc_status *ProcStatus) IncrRestart() {\n\tproc_status.Restarts++\n}", "func (m *DeviceHealthAttestationState) SetRestartCount(value *int64)() {\n err := m.GetBackingStore().Set(\"restartCount\", value)\n if err != nil {\n panic(err)\n }\n}", "func Restart(args ...string) {\n logger.Log(fmt.Sprintf(\"Restarting %v\\n\", process))\n Stop(args...)\n Start(args...)\n}", "func (r *Subresource) SetRestart(key string) {\n\tlog.Printf(\"[DEBUG] %s: Resource argument %q requires a VM restart\", r, key)\n\tswitch d := r.rdd.(type) {\n\tcase *schema.ResourceData:\n\t\t_ = d.Set(\"reboot_required\", true)\n\tcase *schema.ResourceDiff:\n\t\t_ = d.SetNew(\"reboot_required\", true)\n\tdefault:\n\t\t// This should never happen, but log if it does.\n\t\tlog.Printf(\"[WARN] %s: Could not flag reboot_required: invalid type %T\", r, r.rdd)\n\t}\n}", "func (a API) Restart(cmd *None) (e error) {\n\tRPCHandlers[\"restart\"].Call <-API{a.Ch, cmd, nil}\n\treturn\n}", "func indexResetter(index int, op treeOpType, exactMatch bool) int {\n\tswitch op {\n\tcase treeOpInsert:\n\t\tindex--\n\tcase treeOpSearch, treeOpRemove:\n\t\tif !exactMatch {\n\t\t\tindex--\n\t\t}\n\t}\n\tif index <= 0 {\n\t\tindex = 0\n\t}\n\treturn index\n}", "func (i *Instance) restart(req *route.Request) route.Response {\n\tmsg.Info(\"Instance Restart: %s\", i.Name())\n\tif i.Destroyed() {\n\t\tmsg.Detail(\"Instance does not exist, skipping...\")\n\t\treturn route.OK\n\t}\n\tif resp := i.Derived().PreRestart(req); resp != route.OK {\n\t\treturn resp\n\t}\n\tif resp := i.Derived().Restart(req); resp != route.OK {\n\t\treturn resp\n\t}\n\tif resp := i.Derived().PostRestart(req); resp != route.OK {\n\t\treturn resp\n\t}\n\tmsg.Detail(\"Restarted: %s\", i.Id())\n\taaa.Accounting(\"Instance restarted: %s, %s\", i.Name(), i.Id())\n\treturn route.OK\n}", "func RestartRollout(ctx context.Context, kubeClient client.Client, obj runtime.Object) error {\n\tnowString := time.Now().Format(time.RFC3339)\n\n\tpatchData := fmt.Sprintf(\"{\\\"spec\\\":{\\\"template\\\":{\\\"metadata\\\":{\\\"annotations\\\":{\\\"%s\\\":\\\"%s\\\"}}}}}\", restartAnnotation, nowString)\n\n\terr := kubeClient.Patch(ctx, obj, client.RawPatch(types.MergePatchType, []byte(patchData)))\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to restart workload: %w\", err)\n\t}\n\n\treturn nil\n}", "func (nm *NodeMonitor) Restart(arg string) {\n\tnm.mutex.Lock()\n\tdefer nm.mutex.Unlock()\n\tnm.arg = arg\n\n\tif nm.process == nil {\n\t\treturn\n\t}\n\tif err := nm.process.Kill(); err != nil {\n\t\tlog.WithError(err).WithField(\"pid\", nm.process.Pid).Error(\"process.Kill()\")\n\t}\n\tnm.process = nil\n}", "func (pomo *Pomo) Restart() {\n\tpomo.SetDuration(DEFAULT_DURATION)\n}", "func (c *compiler) regexIndex(r string) int {\n\tif index, ok := c.indexes.regexes[r]; ok {\n\t\treturn index // reuse existing constant\n\t}\n\tindex := len(c.program.Regexes)\n\tc.program.Regexes = append(c.program.Regexes, regexp.MustCompile(AddRegexFlags(r)))\n\tc.indexes.regexes[r] = index\n\treturn index\n}", "func RestartOp(cpNodes []*cke.Node, target *cke.Node, params cke.EtcdParams) cke.Operator {\n\treturn &etcdRestartOp{\n\t\tcpNodes: cpNodes,\n\t\ttarget: target,\n\t\tparams: params,\n\t}\n}", "func Restart(start, pwdn gpio.PinIO) {\n\tif err := pwdn.Out(gpio.Low); err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\ttime.Sleep(500 * time.Millisecond)\n\n\tpwdn.Out(gpio.High)\n\n\tif err := start.Out(gpio.Low); err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\ttime.Sleep(2 * time.Second)\n\n}", "func (o InstanceGroupManagerActionsSummaryResponseOutput) Restarting() pulumi.IntOutput {\n\treturn o.ApplyT(func(v InstanceGroupManagerActionsSummaryResponse) int { return v.Restarting }).(pulumi.IntOutput)\n}", "func (m *UserExperienceAnalyticsDeviceStartupHistory) SetRestartFaultBucket(value *string)() {\n err := m.GetBackingStore().Set(\"restartFaultBucket\", value)\n if err != nil {\n panic(err)\n }\n}", "func (client *VirtualMachineScaleSetsClient) restart(ctx context.Context, resourceGroupName string, vmScaleSetName string, options *VirtualMachineScaleSetsBeginRestartOptions) (*http.Response, error) {\n\treq, err := client.restartCreateRequest(ctx, resourceGroupName, vmScaleSetName, options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tresp, err := client.pl.Do(req)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif !runtime.HasStatusCode(resp, http.StatusOK, http.StatusAccepted) {\n\t\treturn nil, client.restartHandleError(resp)\n\t}\n\treturn resp, nil\n}", "func (m *UserExperienceAnalyticsDeviceStartupHistory) SetRestartStopCode(value *string)() {\n err := m.GetBackingStore().Set(\"restartStopCode\", value)\n if err != nil {\n panic(err)\n }\n}", "func (clus *Cluster) Restart(i int) error {\n\tclus.opLock.Lock()\n\tdefer clus.opLock.Unlock()\n\treturn clus.Members[i].Restart()\n}", "func Restart(resource string, namespace string, args ...string) (err error) {\n\trestart := []string{\"rollout\", \"restart\", resource, \"-n\", namespace}\n\t_, err = kubectl(append(restart, args...)...)\n\treturn\n}", "func (k *Kvs) Incr(key string) (string, error) {\n\tval := k.kv[key]\n\tvalInt, err := strconv.Atoi(val)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\tk.kv[key] = convStr(valInt + 1)\n\treturn k.kv[key], nil\n}", "func (m *DeviceHealthAttestationState) GetRestartCount()(*int64) {\n val, err := m.GetBackingStore().Get(\"restartCount\")\n if err != nil {\n panic(err)\n }\n if val != nil {\n return val.(*int64)\n }\n return nil\n}", "func (c *Controller) tunedRestart(timeoutInitiated bool) (err error) {\n\tif _, err = c.tunedStop(); err != nil {\n\t\treturn err\n\t}\n\tc.tunedCmd = nil // Cmd.Start() cannot be used more than once\n\tc.tunedExit = make(chan bool, 1) // Once tunedStop() terminates, the tunedExit channel is closed!\n\n\tif err = c.tunedReload(timeoutInitiated); err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (cr *ConflictResolver) Restart(baseCtx context.Context) {\n\tcr.startProcessing(baseCtx)\n}", "func (q *CoreClient) Restart() (err error) {\n\t_, err = q.RequestWithoutData(http.MethodPost, \"/safeRestart\", nil, nil, 503)\n\treturn\n}", "func newRestartCommand(client *client.Client) *Command {\n\trestartStrings := docstrings.Get(\"restart\")\n\trestartCmd := BuildCommandKS(nil, runRestart, restartStrings, client, requireSession, requireAppNameAsArg)\n\trestartCmd.Args = cobra.RangeArgs(0, 1)\n\n\treturn restartCmd\n}", "func SchedulerRestartOp(nodes []*cke.Node, cluster string, params cke.ServiceParams) cke.Operator {\n\treturn &schedulerRestartOp{\n\t\tnodes: nodes,\n\t\tcluster: cluster,\n\t\tparams: params,\n\t}\n}", "func Restart(s Restartable) error {\n\treturn s.Restart()\n}", "func (m *RecurrencePattern) SetIndex(value *WeekIndex)() {\n m.index = value\n}", "func (a ClustersAPI) Restart(clusterID string) error {\n\tdata := struct {\n\t\tClusterID string `json:\"cluster_id,omitempty\" url:\"cluster_id,omitempty\"`\n\t}{\n\t\tclusterID,\n\t}\n\t_, err := a.Client.performQuery(http.MethodPost, \"/clusters/restart\", data, nil)\n\treturn err\n}", "func restart() {\n\tfmt.Println(\"Config change detected, restarting\")\n}", "func handleConfigRestart(ctxArg interface{}, restartCounter int) {\n\tctx := ctxArg.(*zedmanagerContext)\n\tlog.Functionf(\"handleConfigRestart(%d)\", restartCounter)\n\tif restartCounter != 0 {\n\t\tctx.pubAppNetworkConfig.SignalRestarted()\n\t}\n}", "func (proc *Proc) AddRestart() {\n\tproc.Status.IncrRestart()\n}", "func (master *ProcMaster) restart(proc ProcContainer) error {\n\terr := master.stop(proc)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn master.start(proc)\n}", "func (m *UserExperienceAnalyticsDeviceStartupHistory) SetRestartCategory(value *UserExperienceAnalyticsOperatingSystemRestartCategory)() {\n err := m.GetBackingStore().Set(\"restartCategory\", value)\n if err != nil {\n panic(err)\n }\n}", "func (c *compiler) numIndex(n float64) int {\n\tif index, ok := c.indexes.nums[n]; ok {\n\t\treturn index // reuse existing constant\n\t}\n\tindex := len(c.program.Nums)\n\tc.program.Nums = append(c.program.Nums, n)\n\tc.indexes.nums[n] = index\n\treturn index\n}", "func (s *Syncthing) Restart(ctx context.Context) error {\n\t_, err := s.APICall(ctx, \"rest/system/restart\", \"POST\", 200, nil, true, nil, false, 3)\n\treturn err\n}", "func SchedulerRestartOp(nodes []*cke.Node, cluster string, params cke.SchedulerParams) cke.Operator {\n\treturn &schedulerRestartOp{\n\t\tnodes: nodes,\n\t\tcluster: cluster,\n\t\tparams: params,\n\t\tfiles: common.NewFilesBuilder(nodes),\n\t}\n}", "func (inst *IndependentInstance) Restart(id string, manager *support.FlowManager) error {\n\tinst.id = id\n\tvar err error\n\tinst.flowDef, err = manager.GetFlow(inst.flowURI)\n\n\tif err != nil {\n\t\treturn err\n\t}\n\tif inst.flowDef == nil {\n\t\treturn errors.New(\"unable to resolve flow: \" + inst.flowURI)\n\t}\n\n\tinst.flowModel = getFlowModel(inst.flowDef)\n\tinst.master = inst\n\tinst.init(inst.Instance)\n\n\treturn nil\n}", "func (sv *SV) IncrPatch() {\n\tsv.patch++\n\tsv.ClearPreRelIDs()\n}", "func (r *RemoteCluster) Restart(i int) error {\n\t_ = r.Kill(i)\n\t// supervisorctl is horrible with exit codes (cockroachdb/cockroach-prod#59).\n\treturn r.execSupervisor(i, \"start cockroach\")\n}", "func restartNano(cmd *cobra.Command, args []string) {\n\tctx := context.Background()\n\tcli, err := client.NewEnvClient()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tnotExistCheck()\n\tfmt.Println(\"Restarting ceph-nano...\")\n\tif err := cli.ContainerRestart(ctx, ContainerName, nil); err != nil {\n\t\tpanic(err)\n\t}\n\techoInfo()\n}", "func updateRunSet(runset []int, index int){\n runset[index] = -1\n //runset = append(runset[:index],runset[index+1:]...)\n}", "func (_SweetToken *SweetTokenTransactor) Restart(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _SweetToken.contract.Transact(opts, \"restart\")\n}", "func (q *CoreClient) RestartDirectly() (err error) {\n\t_, err = q.RequestWithoutData(http.MethodPost, \"/restart\", nil, nil, 503)\n\treturn\n}", "func restartg(gp *g) {\n\ts := readgstatus(gp)\n\tswitch s {\n\tdefault:\n\t\tdumpgstatus(gp)\n\t\tthrow(\"restartg: unexpected status\")\n\n\tcase _Gdead:\n\t// ok\n\n\tcase _Gscanrunnable,\n\t\t_Gscanwaiting,\n\t\t_Gscansyscall:\n\t\tcasfrom_Gscanstatus(gp, s, s&^_Gscan)\n\t}\n}", "func (m *Master) Restart(procSign string, out *StartRsp) error {\n\t// I. find & stop instance\n\t// II. stop instance\n\tif _, err := m.StopInstance(procSign, syscall.SIGINT); err != nil {\n\t\t// ignore \"pid not found\" error\n\t\tif err.Error() != \"no active pid found\" {\n\t\t\treturn err\n\t\t}\n\t}\n\t// III. start instance\n\treturn m.Start(procSign, out)\n}", "func cmdRestart() {\n\tswitch state := status(B2D.VM); state {\n\tcase vmUnregistered:\n\t\tlog.Fatalf(\"%s is not registered.\", B2D.VM)\n\tcase vmRunning:\n\t\tcmdStop()\n\t\ttime.Sleep(1 * time.Second)\n\t\tcmdStart()\n\tdefault:\n\t\tcmdStart()\n\t}\n}", "func ExponentialBackOffRestartStrategy(max int, backoff time.Duration, invoker SupervisionInvoker) *ExponentialBackOffSupervisor {\n\treturn &ExponentialBackOffSupervisor{\n\t\tMax: max,\n\t\tBackoff: backoff,\n\t\tInvoker: invoker,\n\t\tAction: func(err interface{}, targetAddr Addr, target Actor, parent Actor) error {\n\t\t\treturn target.Restart()\n\t\t},\n\t}\n}", "func RequestRestart() {\n\tRestart = true\n\tDebug(\"requesting restart\")\n\tRequest()\n}", "func primaryCrashElectRestart(t *testing.T) {\n\tproxyURL := tutils.RandomProxyURL(t)\n\tkillRestorePrimary(t, proxyURL, false, nil)\n}", "func (el *gameStruct) Restart() {\n\tel.SetLocation(el.start)\n}", "func (td *OsmTestData) RolloutRestartOSMControlPlaneComponent(componentName string) error {\n\tstdout, stderr, err := Td.RunLocal(\"kubectl\", \"rollout\", \"restart\", \"deployment\", componentName, \"-n\", Td.OsmNamespace)\n\tTd.T.Logf(\"stderr:\\n%s\\n\", stderr)\n\tTd.T.Logf(\"stdout:\\n%s\\n\", stdout)\n\treturn err\n}", "func Restart() {\n\tmu.Lock()\n\tdefer mu.Unlock()\n\tinternalPanicHandler.Done()\n\tinternalPanicHandler = NewHandler(internalPanicHandler.handle)\n}", "func (p *RoundRobinPool) nextIndex() int {\n\treturn int(atomic.AddUint64(&p.current, uint64(1)) % uint64(len(p.servers)))\n}", "func (c *KubeTestPlatform) Restart(name string) error {\n\t// To minic the restart behavior, scale to 0 and then scale to the original replicas.\n\tapp := c.AppResources.FindActiveResource(name)\n\tm := app.(*kube.AppManager)\n\toriginalReplicas := m.App().Replicas\n\n\tif err := c.Scale(name, 0); err != nil {\n\t\treturn err\n\t}\n\n\tif err := c.Scale(name, originalReplicas); err != nil {\n\t\treturn err\n\t}\n\n\tm.StreamContainerLogs()\n\n\treturn nil\n}", "func (a *adapter) coreRestarted(ctx context.Context, endPoint string) error {\n\tlogger.Errorw(ctx, \"core-restarted\", log.Fields{\"endpoint\": endPoint})\n\treturn nil\n}", "func (c *CPU) Xorn(n byte) {\n\tc.reg[A] ^= n\n\n\tc.MaybeFlagSetter(c.reg[A] == 0, ZFlag)\n\tc.ResetFlag(NFlag)\n\tc.ResetFlag(HFlag)\n\tc.ResetFlag(CFlag)\n}", "func TestClusterRollingRestart(t *testing.T) {\n\tif testing.Short() {\n\t\tt.Skip(\"skipping cluster test in short mode.\")\n\t}\n\tt.Parallel()\n\n\ttc := newTestCluster(t)\n\tdefer tc.tearDown()\n\n\ttc.addSequinses(3)\n\ttc.makeVersionAvailable(v3)\n\ttc.expectProgression(down, noVersion, v3, down, v3)\n\n\ttc.setup()\n\ttc.startTest()\n\ttime.Sleep(expectTimeout)\n\n\tfor _, s := range tc.sequinses {\n\t\ts.stop()\n\t\ttime.Sleep(expectTimeout)\n\t\ts.start()\n\t\ttime.Sleep(expectTimeout)\n\t}\n\n\ttc.assertProgression()\n}", "func (a API) RestartGetRes() (out *None, e error) {\n\tout, _ = a.Result.(*None)\n\te, _ = a.Result.(error)\n\treturn \n}", "func incrementIndex(index *uint32, length int) {\n\tif !atomic.CompareAndSwapUint32(index, uint32(length), 0) {\n\t\tatomic.AddUint32(index, 1)\n\t}\n\truntime.Gosched()\n}", "func (self *AltaActor) restartAltaCntr() error {\n\tlog.Infof(\"Restarting container %s on host %s\", self.AltaId, self.Model.CurrNode)\n\n\t// First stop the alta\n\tself.stopAltaCntr()\n\n\t// Start the container\n\terr := self.startAltaCntr()\n\tif err != nil {\n\t\tlog.Errorf(\"Error starting container. Err: %v\", err)\n\t\treturn err\n\t}\n\n\t// Trigger the restart event since it was successful\n\tself.AltaEvent(\"restart\")\n\n\treturn nil\n}", "func (v *VersionVector) Incr(actor string) LamportTime {\n\tv.l.Lock()\n\n\tt, exists := v.dots[actor]\n\tif !exists {\n\t\tt = LamportTime(1)\n\t\tv.dots[actor] = t\n\t} else {\n\t\tt++\n\t\tv.dots[actor] = t\n\t}\n\n\tv.l.Unlock()\n\treturn t\n}", "func (adm *AdminClient) ServiceRestart() error {\n\t//\n\treqData := requestData{}\n\treqData.queryValues = make(url.Values)\n\treqData.queryValues.Set(\"service\", \"\")\n\treqData.customHeaders = make(http.Header)\n\treqData.customHeaders.Set(minioAdminOpHeader, \"restart\")\n\n\t// Execute GET on bucket to list objects.\n\tresp, err := adm.executeMethod(\"POST\", reqData)\n\n\tdefer closeResponse(resp)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif resp.StatusCode != http.StatusOK {\n\t\treturn httpRespToErrorResponse(resp)\n\t}\n\treturn nil\n}", "func (vt *perfSchemaTable) IndexPrefix() kv.Key {\n\treturn nil\n}", "func (e *Exec) IncrRetriesCount() {\n\te.RetriesCount++\n}", "func getRoundRobinInstIdx(instances []*Instance, idx int) (int, error) {\r\n\ttryCount := 1\r\n\tinstCount := len(instances)\r\n\tlastNonNil := -1\r\n\tfor {\r\n\t\tinst := instances[idx]\r\n\t\tif inst != nil {\r\n\t\t\tif inst.isRoundRobinPicked() {\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t\tlastNonNil = idx\r\n\t\t}\r\n\t\tidx++\r\n\t\ttryCount++\r\n\t\tif tryCount > instCount {\r\n\t\t\tif lastNonNil != -1 {\r\n\t\t\t\treturn lastNonNil, nil\r\n\t\t\t}\r\n\t\t\treturn -1, ErrFailedRoundRobin\r\n\t\t}\r\n\t\tif idx >= instCount {\r\n\t\t\tidx = 0\r\n\t\t}\r\n\t}\r\n\treturn idx, nil\r\n}", "func ExampleVirtualMachineScaleSetsClient_BeginRestart_virtualMachineScaleSetRestartMaximumSetGen() {\n\tcred, err := azidentity.NewDefaultAzureCredential(nil)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to obtain a credential: %v\", err)\n\t}\n\tctx := context.Background()\n\tclientFactory, err := armcompute.NewClientFactory(\"<subscription-id>\", cred, nil)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to create client: %v\", err)\n\t}\n\tpoller, err := clientFactory.NewVirtualMachineScaleSetsClient().BeginRestart(ctx, \"rgcompute\", \"aaaaaaaaaaaaaaaaaaa\", &armcompute.VirtualMachineScaleSetsClientBeginRestartOptions{VMInstanceIDs: &armcompute.VirtualMachineScaleSetVMInstanceIDs{\n\t\tInstanceIDs: []*string{\n\t\t\tto.Ptr(\"aaaaaaaaaaaaaaaaa\")},\n\t},\n\t})\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to finish the request: %v\", err)\n\t}\n\t_, err = poller.PollUntilDone(ctx, nil)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to pull the result: %v\", err)\n\t}\n}", "func (client *VirtualMachineScaleSetsClient) BeginRestart(ctx context.Context, resourceGroupName string, vmScaleSetName string, options *VirtualMachineScaleSetsBeginRestartOptions) (VirtualMachineScaleSetsRestartPollerResponse, error) {\n\tresp, err := client.restart(ctx, resourceGroupName, vmScaleSetName, options)\n\tif err != nil {\n\t\treturn VirtualMachineScaleSetsRestartPollerResponse{}, err\n\t}\n\tresult := VirtualMachineScaleSetsRestartPollerResponse{\n\t\tRawResponse: resp,\n\t}\n\tpt, err := armruntime.NewPoller(\"VirtualMachineScaleSetsClient.Restart\", \"\", resp, client.pl, client.restartHandleError)\n\tif err != nil {\n\t\treturn VirtualMachineScaleSetsRestartPollerResponse{}, err\n\t}\n\tresult.Poller = &VirtualMachineScaleSetsRestartPoller{\n\t\tpt: pt,\n\t}\n\treturn result, nil\n}", "func (o InstanceGroupManagerActionsSummaryResponsePtrOutput) Restarting() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v *InstanceGroupManagerActionsSummaryResponse) *int {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn &v.Restarting\n\t}).(pulumi.IntPtrOutput)\n}", "func (a API) RestartChk() (isNew bool) {\n\tselect {\n\tcase o := <-a.Ch.(chan RestartRes):\n\t\tif o.Err != nil {\n\t\t\ta.Result = o.Err\n\t\t} else {\n\t\t\ta.Result = o.Res\n\t\t}\n\t\tisNew = true\n\tdefault:\n\t}\n\treturn\n}", "func (n Noop) Index() int {\n\treturn 0\n}", "func (sv *StubbedValidator) StubRestartResult(voucherResult datatransfer.ValidationResult) {\n\tsv.revalidationResult = voucherResult\n}", "func ExampleVirtualMachineScaleSetsClient_BeginRestart_virtualMachineScaleSetRestartMinimumSetGen() {\n\tcred, err := azidentity.NewDefaultAzureCredential(nil)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to obtain a credential: %v\", err)\n\t}\n\tctx := context.Background()\n\tclientFactory, err := armcompute.NewClientFactory(\"<subscription-id>\", cred, nil)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to create client: %v\", err)\n\t}\n\tpoller, err := clientFactory.NewVirtualMachineScaleSetsClient().BeginRestart(ctx, \"rgcompute\", \"aaaa\", &armcompute.VirtualMachineScaleSetsClientBeginRestartOptions{VMInstanceIDs: nil})\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to finish the request: %v\", err)\n\t}\n\t_, err = poller.PollUntilDone(ctx, nil)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to pull the result: %v\", err)\n\t}\n}", "func (me XAttrRestartTxsdAnimTimingAttrsRestartAlways) RestartDefault() TxsdAnimTimingAttrsRestart {\n\treturn TxsdAnimTimingAttrsRestart(\"always\")\n}", "func wrapPlaneExtension(index, limit int) int { return index % limit }", "func (h *Hero) Restart() {\n\th.mu.Lock()\n\tdefer h.mu.Unlock()\n\tpos := h.world.RandomizePos(h.ID, heroW, heroH)\n\th.setDefaults(pos.X, pos.Y, pos.W, pos.H, h.world)\n}", "func (a *App) posRestart(w io.Writer) error {\n\tif err := a.loadHooks(); err != nil {\n\t\treturn err\n\t}\n\treturn a.runHook(w, a.hooks.PosRestart, \"pos-restart\")\n}", "func nextIndex(ctx context.Context) int {\n\treturn int(strconv.MustParseInt(ctx.Value(\"item.index\")))\n}", "func nextIndex(ctx context.Context) int {\n\treturn int(strconv.MustParseInt(ctx.Value(\"item.index\")))\n}", "func nextIndex(ctx context.Context) int {\n\treturn int(strconv.MustParseInt(ctx.Value(\"item.index\")))\n}", "func (actor *Actor) start(idx, n int) {\n\tif idx == n {\n\t\treturn\n\t}\n\n\t// worker number starts from 1\n\tgo actor.work(idx + 1)\n\tactor.start(idx+1, n)\n}", "func TestDvLIRClient_Restart(t *testing.T) {\n\tip := viper.GetString(\"IPAddress\")\n\tpw := viper.GetString(\"Password\")\n\n\tdvlirClient, err := NewDvLIRClient(ip, pw)\n\tif !assert.NoError(t, err, \"Error while creating Api client\") {\n\t\treturn\n\t}\n\n\terr = dvlirClient.Login()\n\tif !assert.NoError(t, err, \"Error during Login\") {\n\t\treturn\n\t}\n\n\t_, err = dvlirClient.AllowResetWithPwd(\"Yes\")\n\tif !assert.NoError(t, err, \"Error during AllowResetWithPwd request\") {\n\t\treturn\n\t}\n\n\tres, err := dvlirClient.Restart()\n\tif !assert.NoError(t, err, \"Error during Restart request\") {\n\t\treturn\n\t}\n\n\tfmt.Println(res)\n\tdefer func() {\n\t\terr = dvlirClient.Logout()\n\t\tif !assert.NoError(t, err, \"Error during Logout\") {\n\t\t\treturn\n\t\t}\n\t}()\n}", "func (tg *TradesGroup) restart() {\n\ttime.Sleep(5 * time.Second)\n\tif err := tg.wsClient.Exit(); err != nil {\n\t\tlog.Println(\"[BITFINEX] Error destroying connection: \", err)\n\t}\n\ttg.Start(tg.bus.outChannel)\n}", "func (q *CoreClient) Restart() (err error) {\n\tapi := fmt.Sprintf(\"%s/safeRestart\", q.URL)\n\tvar (\n\t\treq *http.Request\n\t\tresponse *http.Response\n\t)\n\n\treq, err = http.NewRequest(\"POST\", api, nil)\n\tif err == nil {\n\t\tq.AuthHandle(req)\n\t} else {\n\t\treturn\n\t}\n\n\tclient := q.GetClient()\n\tif response, err = client.Do(req); err == nil {\n\t\tcode := response.StatusCode\n\t\tvar data []byte\n\t\tdata, err = ioutil.ReadAll(response.Body)\n\t\tif code == 503 { // Jenkins could be behind of a proxy\n\t\t\tfmt.Println(\"Please wait while Jenkins is restarting\")\n\t\t} else if code != 200 || err != nil {\n\t\t\tlog.Fatalf(\"Error code: %d, response: %s, errror: %v\", code, string(data), err)\n\t\t} else {\n\t\t\tfmt.Println(\"restart successfully\")\n\t\t}\n\t} else {\n\t\tlog.Fatal(err)\n\t}\n\treturn\n}", "func (client *CloudServiceRoleInstancesClient) restartCreateRequest(ctx context.Context, roleInstanceName string, resourceGroupName string, cloudServiceName string, options *CloudServiceRoleInstancesBeginRestartOptions) (*azcore.Request, error) {\n\turlPath := \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/cloudServices/{cloudServiceName}/roleInstances/{roleInstanceName}/restart\"\n\tif roleInstanceName == \"\" {\n\t\treturn nil, errors.New(\"parameter roleInstanceName cannot be empty\")\n\t}\n\turlPath = strings.ReplaceAll(urlPath, \"{roleInstanceName}\", url.PathEscape(roleInstanceName))\n\tif resourceGroupName == \"\" {\n\t\treturn nil, errors.New(\"parameter resourceGroupName cannot be empty\")\n\t}\n\turlPath = strings.ReplaceAll(urlPath, \"{resourceGroupName}\", url.PathEscape(resourceGroupName))\n\tif cloudServiceName == \"\" {\n\t\treturn nil, errors.New(\"parameter cloudServiceName cannot be empty\")\n\t}\n\turlPath = strings.ReplaceAll(urlPath, \"{cloudServiceName}\", url.PathEscape(cloudServiceName))\n\tif client.subscriptionID == \"\" {\n\t\treturn nil, errors.New(\"parameter client.subscriptionID cannot be empty\")\n\t}\n\turlPath = strings.ReplaceAll(urlPath, \"{subscriptionId}\", url.PathEscape(client.subscriptionID))\n\treq, err := azcore.NewRequest(ctx, http.MethodPost, azcore.JoinPaths(client.con.Endpoint(), urlPath))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treq.Telemetry(telemetryInfo)\n\treqQP := req.URL.Query()\n\treqQP.Set(\"api-version\", \"2021-03-01\")\n\treq.URL.RawQuery = reqQP.Encode()\n\treq.Header.Set(\"Accept\", \"application/json\")\n\treturn req, nil\n}", "func init() {\n\tupdateIndex()\n}", "func (Tests) Restart(ctx context.Context) {\n\tmg.SerialCtxDeps(ctx,\n\t\tTests.Stop,\n\t\tTests.Start,\n\t)\n}", "func (dk *DynaKube) FeatureAgentInitialConnectRetry() int {\n\traw := dk.getFeatureFlagRaw(AnnotationFeatureOneAgentInitialConnectRetry)\n\tif raw == \"\" {\n\t\treturn -1\n\t}\n\n\tval, err := strconv.Atoi(raw)\n\tif err != nil {\n\t\tlog.Error(err, \"failed to parse agentInitialConnectRetry feature-flag\")\n\t\treturn -1\n\t}\n\n\treturn val\n}", "func (p *progress) reset(nodeIndex NodeIndex, nextIndex LogEntryIndex) {\n\tp.MatchIndex[nodeIndex] = 0\n\tp.NextIndex[nodeIndex] = nextIndex\n}", "func INT(i operand.Op) { ctx.INT(i) }", "func (app *appContext) Restart() error {\n\tif TRAY {\n\t\tTRAYRESTART <- true\n\t} else {\n\t\tRESTART <- true\n\t}\n\treturn nil\n}", "func (client *CloudServiceRoleInstancesClient) ResumeRestart(ctx context.Context, token string) (HTTPPollerResponse, error) {\n\tpt, err := armcore.NewLROPollerFromResumeToken(\"CloudServiceRoleInstancesClient.Restart\", token, client.con.Pipeline(), client.restartHandleError)\n\tif err != nil {\n\t\treturn HTTPPollerResponse{}, err\n\t}\n\tpoller := &httpPoller{\n\t\tpt: pt,\n\t}\n\tresp, err := poller.Poll(ctx)\n\tif err != nil {\n\t\treturn HTTPPollerResponse{}, err\n\t}\n\tresult := HTTPPollerResponse{\n\t\tRawResponse: resp,\n\t}\n\tresult.Poller = poller\n\tresult.PollUntilDone = func(ctx context.Context, frequency time.Duration) (*http.Response, error) {\n\t\treturn poller.pollUntilDone(ctx, frequency)\n\t}\n\treturn result, nil\n}", "func (irs *InstanceRuntimeSelect) IntX(ctx context.Context) int {\n\tv, err := irs.Int(ctx)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn v\n}", "func (s *FluentdService) Restart(ctx context.Context, r *pb.FluentdRestartRequest) (*pb.FluentdRestartResponse, error) {\n\treturn &pb.FluentdRestartResponse{Status: pb.FluentdRestartResponse_RESTART_SUCCESS}, nil\n}", "func (s *VectorClock) Increment(nodeId string) {\n\tpanic(\"todo\")\n}", "func TestIngesterRestart(t *testing.T) {\n\tconfig := defaultIngesterTestConfig()\n\tclientConfig := defaultClientTestConfig()\n\tlimits := defaultLimitsTestConfig()\n\tconfig.LifecyclerConfig.UnregisterOnShutdown = false\n\n\t{\n\t\t_, ingester := newTestStore(t, config, clientConfig, limits, nil)\n\t\ttime.Sleep(100 * time.Millisecond)\n\t\t// Doesn't actually unregister due to UnregisterFromRing: false.\n\t\trequire.NoError(t, services.StopAndAwaitTerminated(context.Background(), ingester))\n\t}\n\n\ttest.Poll(t, 100*time.Millisecond, 1, func() interface{} {\n\t\treturn testutils.NumTokens(config.LifecyclerConfig.RingConfig.KVStore.Mock, \"localhost\", ring.IngesterRingKey)\n\t})\n\n\t{\n\t\t_, ingester := newTestStore(t, config, clientConfig, limits, nil)\n\t\ttime.Sleep(100 * time.Millisecond)\n\t\t// Doesn't actually unregister due to UnregisterFromRing: false.\n\t\trequire.NoError(t, services.StopAndAwaitTerminated(context.Background(), ingester))\n\t}\n\n\ttime.Sleep(200 * time.Millisecond)\n\n\ttest.Poll(t, 100*time.Millisecond, 1, func() interface{} {\n\t\treturn testutils.NumTokens(config.LifecyclerConfig.RingConfig.KVStore.Mock, \"localhost\", ring.IngesterRingKey)\n\t})\n}", "func _iload(frame *runtime.Frame, index uint) {\n\tval := frame.GetInt(index)\n\tframe.PushInt(val)\n}", "func TestClusteringRestart(t *testing.T) {\n\tcleanupDatastore(t)\n\tdefer cleanupDatastore(t)\n\tcleanupRaftLog(t)\n\tdefer cleanupRaftLog(t)\n\n\t// For this test, use a central NATS server.\n\tns := natsdTest.RunDefaultServer()\n\tdefer ns.Shutdown()\n\n\t// Configure the server in non-clustered mode.\n\ts1sOpts := getTestDefaultOptsForClustering(\"a\", false)\n\ts1sOpts.Clustering.Clustered = false\n\ts1 := runServerWithOpts(t, s1sOpts, nil)\n\n\t// Restart in clustered mode. This should fail.\n\ts1.Shutdown()\n\ts1sOpts.Clustering.Clustered = true\n\t_, err := RunServerWithOpts(s1sOpts, nil)\n\tif err == nil {\n\t\tt.Fatal(\"Expected error on server start\")\n\t}\n\tif err != ErrClusteredRestart {\n\t\tt.Fatalf(\"Incorrect error, expected: ErrClusteredRaftRestart, got: %v\", err)\n\t}\n}" ]
[ "0.75042564", "0.6513786", "0.6151376", "0.5413822", "0.5402964", "0.53925467", "0.5354168", "0.51798", "0.51774615", "0.5160603", "0.51575506", "0.51270556", "0.509853", "0.5096893", "0.50675863", "0.50572634", "0.505711", "0.5055703", "0.5042089", "0.5008453", "0.4996636", "0.49831387", "0.49772277", "0.4963043", "0.4957029", "0.4946498", "0.49294966", "0.49109003", "0.49026823", "0.4895564", "0.4889539", "0.48873264", "0.4885524", "0.48638272", "0.48529485", "0.48498243", "0.48454234", "0.48372167", "0.4832441", "0.4818549", "0.4817147", "0.48093793", "0.4788052", "0.47832403", "0.47733244", "0.47707245", "0.47695273", "0.47641566", "0.47212547", "0.4708073", "0.47050053", "0.46967214", "0.46963152", "0.46725267", "0.46685073", "0.46667972", "0.46643484", "0.46630824", "0.4660375", "0.46601477", "0.46511254", "0.4640608", "0.4640141", "0.46399912", "0.46347642", "0.46121994", "0.46080858", "0.46012804", "0.4596847", "0.45959455", "0.45907214", "0.45872602", "0.4586757", "0.45719543", "0.45674083", "0.4547849", "0.4543527", "0.4541936", "0.45331445", "0.45331445", "0.45331445", "0.4521189", "0.45068762", "0.45027298", "0.44952327", "0.44938818", "0.44796073", "0.44742525", "0.4469156", "0.4467289", "0.44640756", "0.44609118", "0.445832", "0.44524235", "0.44513544", "0.4450181", "0.44468507", "0.4442714", "0.44423673" ]
0.72193307
2
set texture residence priority
func PrioritizeTextures(n int32, textures *uint32, priorities *float32) { C.glowPrioritizeTextures(gpPrioritizeTextures, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(textures)), (*C.GLfloat)(unsafe.Pointer(priorities))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func PrioritizeTextures(n int32, textures *uint32, priorities *float32) {\n C.glowPrioritizeTextures(gpPrioritizeTextures, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(textures)), (*C.GLfloat)(unsafe.Pointer(priorities)))\n}", "func PrioritizeTextures(n int32, textures *uint32, priorities *float32) {\n\tsyscall.Syscall(gpPrioritizeTextures, 3, uintptr(n), uintptr(unsafe.Pointer(textures)), uintptr(unsafe.Pointer(priorities)))\n}", "func (self *TileSprite) SetTintedTextureA(member *Canvas) {\n self.Object.Set(\"tintedTexture\", member)\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, destroy)\n}", "func (self *TileSprite) SetTexture(texture *Texture) {\n self.Object.Call(\"setTexture\", texture)\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\n}", "func TestSpritePriority(t *testing.T) {\n\t// Takes about 10 frames to render the sprite priority image\n\tconst maxPPUIterations = 10\n\n\t// Override the palette with the colours in the expected image\n\tPalettes[CurrentPalette] = [][]byte{\n\t\t{3, 3, 3},\n\t\t{2, 2, 3},\n\t\t{1, 1, 1}, // not used in expected image\n\t\t{0, 0, 0},\n\t}\n\n\t// Map of colours in the image to color in the palette\n\tvar imageMap = map[color.Color]byte{\n\t\tcolor.Gray{Y: 255}: 3,\n\t\tcolor.Gray{Y: 111}: 2,\n\t\tcolor.Gray{Y: 0}: 0,\n\t}\n\n\t// Load the test ROM and iterate a few frames to load the image\n\tgb, err := NewGameboy(\"./../../roms/mooneye/runnable/sprite_priority.gb\")\n\trequire.NoError(t, err, \"error in init gb %v\", err)\n\tfor i := 0; i < maxPPUIterations; i++ {\n\t\tgb.Update()\n\t}\n\n\t// Load the expected output image\n\timg, err := loadImage(\"../../roms/mooneye/runnable/sprite_priority-expected.png\")\n\tif err != nil {\n\t\tt.Fatalf(\"Could not open expected image: %v\", err)\n\t}\n\n\t// Iterate over the image and assert each pixel matches the expected image\n\tfor x := 0; x < ScreenWidth; x++ {\n\t\tfor y := 0; y < ScreenHeight; y++ {\n\t\t\tactual := gb.PreparedData[x][y]\n\t\t\texpected, ok := imageMap[img.At(x, y)]\n\t\t\trequire.True(t, ok, \"unexpected colour in expected image: %v\", img.At(x, y))\n\t\t\trequire.Equal(t, expected, actual[0], \"incorrect pixel at X:%v Y:%x\", x, y)\n\t\t}\n\t}\n}", "func AreTexturesResident(n int32, textures *uint32, residences *bool) bool {\n ret := C.glowAreTexturesResident(gpAreTexturesResident, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(textures)), (*C.GLboolean)(unsafe.Pointer(residences)))\n return ret == TRUE\n}", "func (self *TileSprite) SetTilingTextureA(member *PIXITexture) {\n self.Object.Set(\"tilingTexture\", member)\n}", "func (self *TileSprite) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func TextureBarrier() {\n\tsyscall.Syscall(gpTextureBarrier, 0, 0, 0, 0)\n}", "func (*myScene) Preload() {\n engo.Files.Load(\"textures/cumulus.png\")\n}", "func (ren *RenderComponent) preloadTexture() {\n\tif ren.drawable == nil || headless {\n\t\treturn\n\t}\n\n\tren.bufferContent = ren.generateBufferContent()\n\n\tren.buffer = Gl.CreateBuffer()\n\tGl.BindBuffer(Gl.ARRAY_BUFFER, ren.buffer)\n\tGl.BufferData(Gl.ARRAY_BUFFER, ren.bufferContent, Gl.STATIC_DRAW)\n}", "func TextureBarrier() {\n\tC.glowTextureBarrier(gpTextureBarrier)\n}", "func TextureBarrier() {\n\tC.glowTextureBarrier(gpTextureBarrier)\n}", "func (self *TileSprite) TintedTexture() *Canvas{\n return &Canvas{self.Object.Get(\"tintedTexture\")}\n}", "func (self *PhysicsP2) SetRestitutionA(member int) {\n self.Object.Set(\"restitution\", member)\n}", "func (self *TileSprite) SetBlendModeA(member int) {\n self.Object.Set(\"blendMode\", member)\n}", "func (self *TileSprite) SetTextureDebugA(member bool) {\n self.Object.Set(\"textureDebug\", member)\n}", "func (self *TileSprite) SetTextureI(args ...interface{}) {\n self.Object.Call(\"setTexture\", args)\n}", "func TranslationPriority(locales ...string) {\n\tallResources.SetTranslationPriority(locales)\n}", "func ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func (*GameScene) Preload() {\n\tengo.Files.Load(\"textures/city.png\")\n}", "func GenerateTextureMipmap(texture uint32) {\n\tsyscall.Syscall(gpGenerateTextureMipmap, 1, uintptr(texture), 0, 0)\n}", "func (self *TileSprite) SetRefreshTextureA(member bool) {\n self.Object.Set(\"refreshTexture\", member)\n}", "func (m *AuthenticationListener) SetPriority(value *int32)() {\n err := m.GetBackingStore().Set(\"priority\", value)\n if err != nil {\n panic(err)\n }\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func (self *TileSprite) TilingTexture() *PIXITexture{\n return &PIXITexture{self.Object.Get(\"tilingTexture\")}\n}", "func (this *RectangleShape) SetTexture(texture *Texture, resetRect bool) {\n\tC.sfRectangleShape_setTexture(this.cptr, texture.cptr, goBool2C(resetRect))\n\tthis.texture = texture\n}", "func AreTexturesResident(n int32, textures *uint32, residences *bool) bool {\n\tret, _, _ := syscall.Syscall(gpAreTexturesResident, 3, uintptr(n), uintptr(unsafe.Pointer(textures)), uintptr(unsafe.Pointer(residences)))\n\treturn ret != 0\n}", "func (self *TileSprite) SetTintA(member int) {\n self.Object.Set(\"tint\", member)\n}", "func (p *EventProber) SetTargetResource(targetGVR schema.GroupVersionResource, targetName string) {\n\tp.targetMu.Lock()\n\tdefer p.targetMu.Unlock()\n\n\tp.target = target{\n\t\tgvr: targetGVR,\n\t\tname: targetName,\n\t}\n}", "func SetPriority(level int) {\n\tmu.Lock()\n\tdefer mu.Unlock()\n\tpriority = level\n}", "func (spriteBatch *SpriteBatch) SetTexture(newtexture ITexture) {\n\tspriteBatch.texture = newtexture\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 (s *cpuSource) Priority() int { return 0 }", "func TexParameteriv(target, pname Enum, params []int32) {\n\tgl.TexParameteriv(uint32(target), uint32(pname), &params[0])\n}", "func (m *DirectoryAudit) SetTargetResources(value []TargetResourceable)() {\n m.targetResources = value\n}", "func srcsetToPreloadData(srcset string, e *Context) {\n\ttype imageWithTargetSize struct {\n\t\timgURL *url.URL\n\t\tsize int\n\t}\n\n\tsrcSets := strings.FieldsFunc(strings.TrimSpace(srcset), func(c rune) bool { return c == ',' })\n\tsrcSetsSize := len(srcSets)\n\timgSet := []imageWithTargetSize{}\n\n\tfor _, src := range srcSets {\n\t\timgComponents := strings.Fields(src)\n\t\tif len(imgComponents) != 2 {\n\t\t\te.Preloads = nil\n\t\t\treturn\n\t\t}\n\t\timgTargetSize, err := strconv.Atoi(strings.TrimSuffix(imgComponents[1], \"w\"))\n\n\t\tif err != nil {\n\t\t\te.Preloads = nil\n\t\t\treturn\n\t\t}\n\n\t\turlObj, err := url.Parse(imgComponents[0])\n\n\t\tif err != nil {\n\t\t\te.Preloads = nil\n\t\t\treturn\n\t\t}\n\n\t\timgSet = append(imgSet, imageWithTargetSize{urlObj, imgTargetSize})\n\t}\n\n\t// Sort the images based on their target sizes in asc order.\n\tsort.Slice(imgSet, func(i, j int) bool { return imgSet[i].size < imgSet[j].size })\n\n\tfor i, ci := range imgSet {\n\t\tvar mediaQuery string\n\t\t// srcset images should be sorted by width.\n\t\tif i == 0 {\n\t\t\tmediaQuery = fmt.Sprintf(\"(max-width: %d)\", ci.size)\n\t\t\t// Largest image has only min width limit of second largest image.\n\t\t} else if i == srcSetsSize-1 {\n\t\t\tmediaQuery = fmt.Sprintf(\"(min-width: %d)\", imgSet[i-1].size+1)\n\t\t} else {\n\t\t\tmediaQuery = fmt.Sprintf(\"(min-width: %d) and (max-width: %d)\", imgSet[i-1].size+1, ci.size)\n\t\t}\n\n\t\te.Preloads = append(e.Preloads, PreloadData{URL: ci.imgURL, As: \"image\", Media: mediaQuery})\n\t}\n}", "func GenerateTextureMipmap(texture uint32) {\n\tC.glowGenerateTextureMipmap(gpGenerateTextureMipmap, (C.GLuint)(texture))\n}", "func GenerateTextureMipmap(texture uint32) {\n\tC.glowGenerateTextureMipmap(gpGenerateTextureMipmap, (C.GLuint)(texture))\n}", "func (bm Blendmap) Texture() *gl.Texture {\n\treturn bm.Map.id\n}", "func AreTexturesResident(n int32, textures *uint32, residences *bool) bool {\n\tret := C.glowAreTexturesResident(gpAreTexturesResident, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(textures)), (*C.GLboolean)(unsafe.Pointer(residences)))\n\treturn ret == TRUE\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func (m *SecureScoreControlProfile) SetRemediationImpact(value *string)() {\n m.remediationImpact = value\n}", "func SetSampler(fixedTarget uint32, fallbackRate float64) {\n\tsegment.SetSampler(utils.NewSampler(fixedTarget, fallbackRate))\n}", "func (p antiAffinityLabel) priority() priority {\n\treturn lowPriority\n}", "func (self *Graphics) GenerateTexture2O(resolution int, scaleMode int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode)}\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) Shader() *AbstractFilter{\n return &AbstractFilter{self.Object.Get(\"shader\")}\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 setResource(alloc types.ResourceList, res map[string]int64, grpres map[string]int64) {\n\t// set resource\n\tfor key, val := range res {\n\t\tsetRes(alloc, key, val)\n\t}\n\t// set group resource\n\tfor key, val := range grpres {\n\t\tsetGrpRes(alloc, key, val)\n\t}\n}", "func BindTexture(target uint32, texture uint32) {\n C.glowBindTexture(gpBindTexture, (C.GLenum)(target), (C.GLuint)(texture))\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 (ps *prioritySampler) apply(spn *span) {\n\trate := ps.getRate(spn)\n\tif sampledByRate(spn.TraceID, rate) {\n\t\tspn.setSamplingPriority(ext.PriorityAutoKeep, samplernames.AgentRate, rate)\n\t} else {\n\t\tspn.setSamplingPriority(ext.PriorityAutoReject, samplernames.AgentRate, rate)\n\t}\n\tspn.SetTag(keySamplingPriorityRate, rate)\n}", "func (arg1 *UConverter) SetFallback(arg2 UBool)", "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 (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func (s *Layer) UsePriority(phase string, priority Priority, handler ...interface{}) {\n\ts.register(phase, priority, handler...)\n}", "func (this *RectangleShape) SetTextureRect(rect IntRect) {\n\tC.sfRectangleShape_setTextureRect(this.cptr, rect.toC())\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 (ship *Ship) revThrustersOn() {\n\tif !ship.revThrusters {\n\t\tship.revThrusters = true\n\t\tstartRcsSound()\n\t}\n}", "func (m *Vulnerability) SetPriorityScore(value *int32)() {\n err := m.GetBackingStore().Set(\"priorityScore\", value)\n if err != nil {\n panic(err)\n }\n}", "func (o *V0037Node) SetTresWeighted(v float64) {\n\to.TresWeighted = &v\n}", "func (self *TileSprite) LoadTexture(key interface{}) {\n self.Object.Call(\"loadTexture\", key)\n}", "func ClientActiveTexture(texture uint32) {\n C.glowClientActiveTexture(gpClientActiveTexture, (C.GLenum)(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 TexParam(wrap TextureWrap, filter TextureFilter) TextureParameters {\n\treturn TextureParameters{wrap, wrap, filter, filter}\n}", "func SetActiveTexture(texture Enum) {\n\tctexture, _ := (C.GLenum)(texture), cgoAllocsUnknown\n\tC.glActiveTexture(ctexture)\n}", "func SetFilePriority(t *torrent.Client, db *storm.DB) {\n\tstoredTorrents := Storage.FetchAllStoredTorrents(db)\n\tfor _, singleTorrent := range t.Torrents() {\n\t\tfor _, storedTorrent := range storedTorrents {\n\t\t\tif storedTorrent.Hash == singleTorrent.InfoHash().String() {\n\t\t\t\tfor _, file := range singleTorrent.Files() {\n\t\t\t\t\tfor _, storedFile := range storedTorrent.TorrentFilePriority {\n\t\t\t\t\t\tif storedFile.TorrentFilePath == file.DisplayPath() {\n\t\t\t\t\t\t\tswitch storedFile.TorrentFilePriority {\n\t\t\t\t\t\t\tcase \"High\":\n\t\t\t\t\t\t\t\tfile.SetPriority(torrent.PiecePriorityHigh)\n\t\t\t\t\t\t\tcase \"Normal\":\n\t\t\t\t\t\t\t\tfile.SetPriority(torrent.PiecePriorityNormal)\n\t\t\t\t\t\t\tcase \"Cancel\":\n\t\t\t\t\t\t\t\tfile.SetPriority(torrent.PiecePriorityNone)\n\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\tfile.SetPriority(torrent.PiecePriorityNormal)\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\t}\n}", "func ActiveTexture(texture uint32) {\n\tsyscall.Syscall(gpActiveTexture, 1, uintptr(texture), 0, 0)\n}", "func FixedUnigramCandidateSamplerDistortion(value float32) FixedUnigramCandidateSamplerAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"distortion\"] = value\n\t}\n}", "func (m *ManagementTemplateStep) SetPriority(value *int32)() {\n err := m.GetBackingStore().Set(\"priority\", value)\n if err != nil {\n panic(err)\n }\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) LoadTexture2O(key interface{}, frame interface{}, stopAnimation bool) {\n self.Object.Call(\"loadTexture\", key, frame, stopAnimation)\n}", "func (me piecePriority) BitmapPriority() int {\n\treturn -int(me)\n}", "func (self *TileSprite) LoadTexture1O(key interface{}, frame interface{}) {\n self.Object.Call(\"loadTexture\", key, frame)\n}", "func (tx *TextureBase) Init(sc *Scene) error {\n\tif tx.Tex != nil {\n\t\ttx.Tex.SetBotZero(tx.Bot0)\n\t\ttx.Tex.Activate(0)\n\t}\n\treturn nil\n}", "func (v *Video) AttrSet(attr int32, bit uint) {\n\tv.Attribute = v.Attribute&(^(1 << bit)) | (attr << bit)\n}", "func (iface *Interface) SetDefaultVrrpPriority(subifname string, vrid uint8) {\n\tiface.lock.Lock()\n\tdefer iface.lock.Unlock()\n\n\tsubiface, ret := iface.Subinterfaces[subifname]\n\tif ret {\n\t\tsubiface.SetDefaultVrrpPriority(vrid)\n\t}\n}", "func (self *TileSprite) Texture() *Texture{\n return &Texture{self.Object.Get(\"texture\")}\n}", "func (m *SecureScoreControlProfile) SetRemediationImpact(value *string)() {\n err := m.GetBackingStore().Set(\"remediationImpact\", value)\n if err != nil {\n panic(err)\n }\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func SetResident() ConfigOption {\n\treturn setCitizenship(PermanentResident)\n}", "func (g *Grip) SetThreshold(l interface{}) error {\n\tg.mu.RLock()\n\tdefer g.mu.RUnlock()\n\n\tlv := g.impl.Level()\n\tlv.Threshold = convertPriority(l, lv.Threshold)\n\treturn g.impl.SetLevel(lv)\n}", "func (self *Graphics) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func BindTexture(target uint32, texture uint32) {\n\tsyscall.Syscall(gpBindTexture, 2, uintptr(target), uintptr(texture), 0)\n}", "func (s *Swarm32) SetConstriction(\n\tnumofparticles int,\n\tdims int,\n\tcognative float32,\n\tsocial float32,\n\tvmax float32,\n\tminpositionstart float32,\n\tmaxpositionstart float32,\n) {\n\ts.setswarm(s.mode.Constriction(), numofparticles, dims, cognative, social, vmax, minpositionstart, maxpositionstart, .5, .5)\n}", "func (self *GameObjectCreator) RenderTexture3O(width int, height int, key string) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height, key)}\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 (m *EducationAssignment) SetResources(value []EducationAssignmentResourceable)() {\n m.resources = value\n}", "func (r *RoleV2) SetResource(kind string, actions []string) {\n\tif r.Spec.Resources == nil {\n\t\tr.Spec.Resources = make(map[string][]string)\n\t}\n\tr.Spec.Resources[kind] = actions\n}", "func (self *Graphics) SetTintA(member int) {\n self.Object.Set(\"tint\", member)\n}", "func (self *Graphics) SetBlendModeA(member int) {\n self.Object.Set(\"blendMode\", member)\n}", "func BindTexture(target Enum, t Texture) {\n\tgl.BindTexture(uint32(target), t.Value)\n}", "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func VBLENDPS(i, mxy, xy, xy1 operand.Op) { ctx.VBLENDPS(i, mxy, xy, xy1) }", "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 (u *mutableResource[GA, Alpha, Beta]) Set(src *GA) error {\n\tc := newCopier(u.copierOptions...)\n\tif err := c.do(reflect.ValueOf(&u.ga), reflect.ValueOf(src)); err != nil {\n\t\treturn err\n\t}\n\treturn u.postAccess(meta.VersionGA, postAccessSkipValidation)\n}", "func (self *TileSprite) OnTextureUpdate(event interface{}) {\n self.Object.Call(\"onTextureUpdate\", event)\n}" ]
[ "0.596955", "0.59046215", "0.52260256", "0.51892644", "0.50928843", "0.48873568", "0.48292565", "0.48202685", "0.47728", "0.4742732", "0.47071686", "0.47068322", "0.46641707", "0.46532208", "0.46532208", "0.46457013", "0.46139172", "0.45878053", "0.4560443", "0.45182702", "0.45176926", "0.45053273", "0.448779", "0.44661647", "0.44634953", "0.44329718", "0.44189107", "0.4400992", "0.43969312", "0.4395989", "0.43936262", "0.4379267", "0.43458837", "0.43340635", "0.43322524", "0.43122384", "0.43033868", "0.4302694", "0.42990255", "0.4297855", "0.4297855", "0.42975125", "0.4291519", "0.42825004", "0.42781168", "0.42779264", "0.4274455", "0.42620352", "0.42559186", "0.42506406", "0.42458352", "0.4236419", "0.42353186", "0.4234957", "0.42347234", "0.42307907", "0.42284894", "0.4220357", "0.41917345", "0.4190141", "0.41899678", "0.41798028", "0.41774258", "0.41769287", "0.41616154", "0.415581", "0.4151851", "0.41450772", "0.41420496", "0.41420147", "0.41387603", "0.4133096", "0.41305575", "0.41300052", "0.4126523", "0.4116448", "0.41164303", "0.4112297", "0.41047716", "0.4099968", "0.40957606", "0.40908784", "0.40907788", "0.40861392", "0.40856645", "0.40761754", "0.407161", "0.40671036", "0.4059117", "0.40555707", "0.4053101", "0.40523896", "0.40354773", "0.40341127", "0.40312925", "0.40242136", "0.40237972", "0.4022502", "0.4015798", "0.4014893" ]
0.5674935
2
load a program object with a program binary
func ProgramBinary(program uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) { C.glowProgramBinary(gpProgramBinary, (C.GLuint)(program), (C.GLenum)(binaryFormat), binary, (C.GLsizei)(length)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (c *Chip8) LoadProgram(prog string) {\n\tprogFile, err := os.Open(prog)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\t_, err = progFile.Read(c.memory[progStart:])\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func (ip *Interpreter) Load(prog []byte) {\n\tcopy(ip.memory[memoryOffsetProgram:], prog)\n}", "func loadExecutable(filename string, data []byte) (*Exec, error) {\n\t// Use initMutex to synchronize file operations by this process\n\tinitMutex.Lock()\n\tdefer initMutex.Unlock()\n\n\tvar err error\n\tif !filepath.IsAbs(filename) {\n\t\tfilename, err = inStandardDir(filename)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\tfilename = renameExecutable(filename)\n\n\tif data != nil {\n\t\tlog.Tracef(\"Placing executable in %s\", filename)\n\t\tif err := filepersist.Save(filename, data, NewFileMode); err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tlog.Trace(\"File saved, returning new Exec\")\n\t} else {\n\t\tlog.Tracef(\"Loading executable from %s\", filename)\n\t}\n\treturn newExec(filename)\n}", "func (vm *C8VM) LoadProgram(filename string) error {\n\tdata, err := ioutil.ReadFile(filename)\n\n\tif err != nil {\n\t\treturn fmt.Errorf(\"Error loading program: %v\", err)\n\t}\n\tsize := len(data)\n\tif size > maxProgramSize {\n\t\treturn errors.New(\"Program size exceeds the maximum size\")\n\t}\n\tif copy(vm.memory[pcStartAddr:], data) != size {\n\t\treturn errors.New(\"Error copying program data into VM's memory\")\n\t}\n\treturn nil\n}", "func (c *Chip8) LoadProgram(data []uint8) {\n\t// MEM from 0x000 to 0x1FF is reserved for the interpreter\n\t// Loaded roms start from 0x200\n\tc.LoadData(data, 0x200)\n}", "func loadELF(ctx context.Context, args LoadArgs) (loadedELF, *arch.Context64, error) {\n\tbin, ac, err := loadInitialELF(ctx, args.MemoryManager, args.Features, args.File)\n\tif err != nil {\n\t\tctx.Infof(\"Error loading binary: %v\", err)\n\t\treturn loadedELF{}, nil, err\n\t}\n\n\tvar interp loadedELF\n\tif bin.interpreter != \"\" {\n\t\t// Even if we do not allow the final link of the script to be\n\t\t// resolved, the interpreter should still be resolved if it is\n\t\t// a symlink.\n\t\targs.ResolveFinal = true\n\t\t// Refresh the traversal limit.\n\t\t*args.RemainingTraversals = linux.MaxSymlinkTraversals\n\t\targs.Filename = bin.interpreter\n\t\tintFile, err := openPath(ctx, args)\n\t\tif err != nil {\n\t\t\tctx.Infof(\"Error opening interpreter %s: %v\", bin.interpreter, err)\n\t\t\treturn loadedELF{}, nil, err\n\t\t}\n\t\tdefer intFile.DecRef(ctx)\n\n\t\tinterp, err = loadInterpreterELF(ctx, args.MemoryManager, intFile, bin)\n\t\tif err != nil {\n\t\t\tctx.Infof(\"Error loading interpreter: %v\", err)\n\t\t\treturn loadedELF{}, nil, err\n\t\t}\n\n\t\tif interp.interpreter != \"\" {\n\t\t\t// No recursive interpreters!\n\t\t\tctx.Infof(\"Interpreter requires an interpreter\")\n\t\t\treturn loadedELF{}, nil, linuxerr.ENOEXEC\n\t\t}\n\t}\n\n\t// ELF-specific auxv entries.\n\tbin.auxv = arch.Auxv{\n\t\tarch.AuxEntry{linux.AT_PHDR, bin.phdrAddr},\n\t\tarch.AuxEntry{linux.AT_PHENT, hostarch.Addr(bin.phdrSize)},\n\t\tarch.AuxEntry{linux.AT_PHNUM, hostarch.Addr(bin.phdrNum)},\n\t\tarch.AuxEntry{linux.AT_ENTRY, bin.entry},\n\t}\n\tif bin.interpreter != \"\" {\n\t\tbin.auxv = append(bin.auxv, arch.AuxEntry{linux.AT_BASE, interp.start})\n\n\t\t// Start in the interpreter.\n\t\t// N.B. AT_ENTRY above contains the *original* entry point.\n\t\tbin.entry = interp.entry\n\t} else {\n\t\t// Always add AT_BASE even if there is no interpreter.\n\t\tbin.auxv = append(bin.auxv, arch.AuxEntry{linux.AT_BASE, 0})\n\t}\n\n\treturn bin, ac, nil\n}", "func loadBinary(provider fsProviderFn, c Config) string {\n\tlog.Printf(\"Encoding project: %s\", c.Project)\n\tfs, err := provider(c)\n\tif err != nil {\n\t\tlog.Printf(\"Failed creating filesystem %q: %s\", c.Project, err)\n\t\treturn \"\"\n\t}\n\tb, err := encode(fs)\n\tif err != nil {\n\t\tlog.Printf(\"Failed encoding filesystem %q: %s\", c.Project, err)\n\t\treturn \"\"\n\t}\n\treturn string(b)\n}", "func ProgramBinary(program uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) {\n\tsyscall.Syscall6(gpProgramBinary, 4, uintptr(program), uintptr(binaryFormat), uintptr(binary), uintptr(length), 0, 0)\n}", "func Program(importPath string) (*loader.Program, error) {\n\tcacheLock.Lock()\n\tdefer cacheLock.Unlock()\n\tif p := importCache[importPath]; p != nil {\n\t\treturn p, nil\n\t}\n\tloadConfig.Import(importPath)\n\tp, err := loadConfig.Load()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\timportCache[importPath] = p\n\treturn p, err\n}", "func ProgramBinary(program uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) {\n C.glowProgramBinary(gpProgramBinary, (C.GLuint)(program), (C.GLenum)(binaryFormat), binary, (C.GLsizei)(length))\n}", "func Load(fn func(r io.Reader) error) error {\n\tvar (\n\t\targs []string\n\t\tstdin io.Reader\n\t)\n\tif *binary != \"\" {\n\t\targs = append(args, *binary)\n\t} else if Reader != nil {\n\t\tstdin = Reader\n\t} else {\n\t\t// We have no input stream or binary.\n\t\treturn fmt.Errorf(\"no binary or reader provided\")\n\t}\n\n\t// Construct our command.\n\tcmd := exec.Command(*objdumpTool, args...)\n\tcmd.Stdin = stdin\n\tcmd.Stderr = os.Stderr\n\tout, err := cmd.StdoutPipe()\n\tif err != nil {\n\t\treturn err\n\t}\n\tif err := cmd.Start(); err != nil {\n\t\treturn err\n\t}\n\n\t// Call the user hook.\n\tuserErr := fn(out)\n\n\t// Wait for the dump to finish.\n\tif err := cmd.Wait(); userErr == nil && err != nil {\n\t\treturn err\n\t}\n\n\treturn userErr\n}", "func (a *Applet) Load(filename string, src []byte, loader ModuleLoader) (err error) {\n\tdefer func() {\n\t\tif r := recover(); r != nil {\n\t\t\terr = fmt.Errorf(\"panic while executing %s: %v\", a.Filename, r)\n\t\t}\n\t}()\n\n\ta.Filename = filename\n\ta.loader = loader\n\n\ta.src = src\n\n\ta.Id = fmt.Sprintf(\"%s/%x\", filename, md5.Sum(src))\n\n\ta.predeclared = starlark.StringDict{\n\t\t\"struct\": starlark.NewBuiltin(\"struct\", starlarkstruct.Make),\n\t}\n\n\tglobals, err := starlark.ExecFile(a.thread(), a.Filename, a.src, a.predeclared)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"starlark.ExecFile: %v\", err)\n\t}\n\ta.Globals = globals\n\n\tmainFun, found := globals[\"main\"]\n\tif !found {\n\t\treturn fmt.Errorf(\"%s didn't export a main() function\", filename)\n\t}\n\tmain, ok := mainFun.(*starlark.Function)\n\tif !ok {\n\t\treturn fmt.Errorf(\"%s exported a main() that is not function\", filename)\n\t}\n\ta.main = main\n\n\treturn nil\n}", "func loadBinaryInfoElf(bi *BinaryInfo, image *Image, path string, addr uint64, wg *sync.WaitGroup) error {\n\texe, err := os.OpenFile(path, 0, os.ModePerm)\n\tif err != nil {\n\t\treturn err\n\t}\n\timage.closer = exe\n\telfFile, err := elf.NewFile(exe)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif !supportedLinuxArch[elfFile.Machine] {\n\t\treturn &ErrUnsupportedArch{os: \"linux\", cpuArch: elfFile.Machine}\n\t}\n\n\tif image.index == 0 {\n\t\t// adding executable file:\n\t\t// - addr is entryPoint therefore staticBase needs to be calculated by\n\t\t// subtracting the entry point specified in the executable file from addr.\n\t\t// - memory address of the .dynamic section needs to be recorded in\n\t\t// BinaryInfo so that we can find loaded libraries.\n\t\tif addr != 0 {\n\t\t\timage.StaticBase = addr - elfFile.Entry\n\t\t} else if elfFile.Type == elf.ET_DYN {\n\t\t\treturn ErrCouldNotDetermineRelocation\n\t\t}\n\t\tif dynsec := elfFile.Section(\".dynamic\"); dynsec != nil {\n\t\t\tbi.ElfDynamicSection.Addr = dynsec.Addr + image.StaticBase\n\t\t\tbi.ElfDynamicSection.Size = dynsec.Size\n\t\t}\n\t} else {\n\t\timage.StaticBase = addr\n\t}\n\n\tdwarfFile := elfFile\n\n\tbi.loadBuildID(image, elfFile)\n\tvar debugInfoBytes []byte\n\tvar dwerr error\n\timage.dwarf, dwerr = elfFile.DWARF()\n\tif dwerr != nil {\n\t\tvar sepFile *os.File\n\t\tvar serr error\n\t\tsepFile, dwarfFile, serr = bi.openSeparateDebugInfo(image, elfFile, bi.DebugInfoDirectories)\n\t\tif serr != nil {\n\t\t\tif len(bi.Images) <= 1 {\n\t\t\t\tfmt.Fprintln(os.Stderr, \"Warning: no debug info found, some functionality will be missing such as stack traces and variable evaluation.\")\n\t\t\t}\n\t\t\tsymTable, err := readPcLnTableElf(elfFile, path)\n\t\t\tif err != nil {\n\t\t\t\treturn fmt.Errorf(\"could not read debug info (%v) and could not read go symbol table (%v)\", dwerr, err)\n\t\t\t}\n\t\t\timage.symTable = symTable\n\t\t\tfor _, f := range image.symTable.Funcs {\n\t\t\t\tcu := &compileUnit{}\n\t\t\t\tcu.image = image\n\t\t\t\tfn := Function{Name: f.Name, Entry: f.Entry + image.StaticBase, End: f.End + image.StaticBase, cu: cu}\n\t\t\t\tbi.Functions = append(bi.Functions, fn)\n\t\t\t}\n\t\t\tfor f := range image.symTable.Files {\n\t\t\t\tbi.Sources = append(bi.Sources, f)\n\t\t\t}\n\t\t\treturn nil\n\t\t}\n\t\timage.sepDebugCloser = sepFile\n\t\timage.dwarf, err = dwarfFile.DWARF()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\tdebugInfoBytes, err = godwarf.GetDebugSectionElf(dwarfFile, \"info\")\n\tif err != nil {\n\t\treturn err\n\t}\n\n\timage.dwarfReader = image.dwarf.Reader()\n\n\tdebugLineBytes, err := godwarf.GetDebugSectionElf(dwarfFile, \"line\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tdebugLocBytes, _ := godwarf.GetDebugSectionElf(dwarfFile, \"loc\")\n\timage.loclist2 = loclist.NewDwarf2Reader(debugLocBytes, bi.Arch.PtrSize())\n\tdebugLoclistBytes, _ := godwarf.GetDebugSectionElf(dwarfFile, \"loclists\")\n\timage.loclist5 = loclist.NewDwarf5Reader(debugLoclistBytes)\n\tdebugAddrBytes, _ := godwarf.GetDebugSectionElf(dwarfFile, \"addr\")\n\timage.debugAddr = godwarf.ParseAddr(debugAddrBytes)\n\tdebugLineStrBytes, _ := godwarf.GetDebugSectionElf(dwarfFile, \"line_str\")\n\timage.debugLineStr = debugLineStrBytes\n\n\twg.Add(3)\n\tgo bi.parseDebugFrameElf(image, dwarfFile, elfFile, debugInfoBytes, wg)\n\tgo bi.loadDebugInfoMaps(image, debugInfoBytes, debugLineBytes, wg, nil)\n\tgo bi.loadSymbolName(image, elfFile, wg)\n\tif image.index == 0 {\n\t\t// determine g struct offset only when loading the executable file\n\t\twg.Add(1)\n\t\tgo bi.setGStructOffsetElf(image, dwarfFile, wg)\n\t}\n\treturn nil\n}", "func (l *Loader) Preload(syms *sym.Symbols, f *bio.Reader, lib *sym.Library, unit *sym.CompilationUnit, length int64, flags int) {\n\troObject, readonly, err := f.Slice(uint64(length))\n\tif err != nil {\n\t\tlog.Fatal(\"cannot read object file:\", err)\n\t}\n\tr := goobj2.NewReaderFromBytes(roObject, readonly)\n\tif r == nil {\n\t\tif len(roObject) >= 8 && bytes.Equal(roObject[:8], []byte(\"\\x00go114ld\")) {\n\t\t\tlog.Fatalf(\"found object file %s in old format, but -go115newobj is true\\nset -go115newobj consistently in all -gcflags, -asmflags, and -ldflags\", f.File().Name())\n\t\t}\n\t\tpanic(\"cannot read object file\")\n\t}\n\tlocalSymVersion := syms.IncVersion()\n\tpkgprefix := objabi.PathToPrefix(lib.Pkg) + \".\"\n\tndef := r.NSym()\n\tnnonpkgdef := r.NNonpkgdef()\n\tor := &oReader{r, unit, localSymVersion, r.Flags(), pkgprefix, make([]Sym, ndef+nnonpkgdef+r.NNonpkgref()), ndef, uint32(len(l.objs))}\n\n\t// Autolib\n\tlib.ImportStrings = append(lib.ImportStrings, r.Autolib()...)\n\n\t// DWARF file table\n\tnfile := r.NDwarfFile()\n\tunit.DWARFFileTable = make([]string, nfile)\n\tfor i := range unit.DWARFFileTable {\n\t\tunit.DWARFFileTable[i] = r.DwarfFile(i)\n\t}\n\n\tl.addObj(lib.Pkg, or)\n\tl.preloadSyms(or, pkgDef)\n\n\t// The caller expects us consuming all the data\n\tf.MustSeek(length, os.SEEK_CUR)\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 loadBinaryInfoMacho(bi *BinaryInfo, image *Image, path string, entryPoint uint64, wg *sync.WaitGroup) error {\n\texe, err := macho.Open(path)\n\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif entryPoint != 0 {\n\t\tmachoOff := uint64(0x100000000)\n\t\tfor _, ld := range exe.Loads {\n\t\t\tif seg, _ := ld.(*macho.Segment); seg != nil {\n\t\t\t\tif seg.Name == \"__TEXT\" {\n\t\t\t\t\tmachoOff = seg.Addr\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tlogflags.DebuggerLogger().Debugf(\"entryPoint %#x machoOff %#x\", entryPoint, machoOff)\n\t\timage.StaticBase = entryPoint - machoOff\n\t}\n\n\timage.closer = exe\n\tif !supportedDarwinArch[exe.Cpu] {\n\t\treturn &ErrUnsupportedArch{os: \"darwin\", cpuArch: exe.Cpu}\n\t}\n\timage.dwarf, err = exe.DWARF()\n\tif err != nil {\n\t\treturn err\n\t}\n\tdebugInfoBytes, err := godwarf.GetDebugSectionMacho(exe, \"info\")\n\tif err != nil {\n\t\treturn err\n\t}\n\n\timage.dwarfReader = image.dwarf.Reader()\n\n\tdebugLineBytes, err := godwarf.GetDebugSectionMacho(exe, \"line\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tdebugLocBytes, _ := godwarf.GetDebugSectionMacho(exe, \"loc\")\n\timage.loclist2 = loclist.NewDwarf2Reader(debugLocBytes, bi.Arch.PtrSize())\n\tdebugLoclistBytes, _ := godwarf.GetDebugSectionMacho(exe, \"loclists\")\n\timage.loclist5 = loclist.NewDwarf5Reader(debugLoclistBytes)\n\tdebugAddrBytes, _ := godwarf.GetDebugSectionMacho(exe, \"addr\")\n\timage.debugAddr = godwarf.ParseAddr(debugAddrBytes)\n\tdebugLineStrBytes, _ := godwarf.GetDebugSectionMacho(exe, \"line_str\")\n\timage.debugLineStr = debugLineStrBytes\n\n\twg.Add(2)\n\tgo bi.parseDebugFrameMacho(image, exe, debugInfoBytes, wg)\n\tgo bi.loadDebugInfoMaps(image, debugInfoBytes, debugLineBytes, wg, bi.setGStructOffsetMacho)\n\treturn nil\n}", "func GetProgramBinary(program uint32, bufSize int32, length *int32, binaryFormat *uint32, binary unsafe.Pointer) {\n C.glowGetProgramBinary(gpGetProgramBinary, (C.GLuint)(program), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLenum)(unsafe.Pointer(binaryFormat)), binary)\n}", "func LoadELF(file *elf.File, emulator interfaces.Emulator) {\n\tuc := emulator.GetUnicorn()\n\tbrk := uint64(0)\n\tfor _, programSection := range file.Progs {\n\t\tif programSection.Type == elf.PT_LOAD {\n\t\t\tdata := make([]byte, programSection.Filesz)\n\n\t\t\tprogramSection.Open().Read(data)\n\n\t\t\talignedStart := helpers.PageStart(programSection.Vaddr)\n\t\t\talignedSize := helpers.PageEnd((programSection.Vaddr - alignedStart) + programSection.Memsz)\n\n\t\t\tfmt.Printf(\"Map 0x%x with length 0x%x\\n\", alignedStart, alignedSize)\n\n\t\t\tuc.MemMap(alignedStart, alignedSize)\n\t\t\tuc.MemWrite(programSection.Vaddr, data)\n\t\t}\n\t\tif programSection.Flags&elf.PF_W != 0 {\n\t\t\taddr := programSection.Vaddr + programSection.Memsz\n\t\t\tif addr > emulator.GetBRK() {\n\t\t\t\tbrk = addr\n\t\t\t}\n\t\t}\n\t}\n\tif brk > 0 {\n\t\temulator.SetBRK(helpers.PageEnd(brk))\n\t}\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 GetProgramBinary(program uint32, bufSize int32, length *int32, binaryFormat *uint32, binary unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetProgramBinary, 5, uintptr(program), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(binaryFormat)), uintptr(binary), 0)\n}", "func loadScript(filename string) (*goja.Program, error) {\n\tb, err := ioutil.ReadFile(filename)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn goja.Compile(filename, string(b), true)\n}", "func Load(path string, object interface{}) error {\n\tfile, err := os.Open(path)\n\tdefer file.Close()\n\tif err != nil {\n\t\tlog.Error(\"Was not able to open file\", \"path\", path, \"error\", err)\n\t\treturn err\n\t}\n\tdecoder := gob.NewDecoder(file)\n\terr = decoder.Decode(object)\n\tif err != nil {\n\t\tlog.Error(\"Was not able to decode file.\", \"path\", path, \"error\", err)\n\t}\n\treturn err\n}", "func (m *Machine) loadObject(i Word) *object {\n\to := new(object)\n\tif m.Version() <= 3 {\n\t\tbase := m.objectTableAddress() + (31 * 2) + Address((i-1)*9)\n\t\tcopy(o.Attributes[:4], m.memory[base:])\n\t\to.Parent = Word(m.loadByte(base + 4))\n\t\to.Sibling = Word(m.loadByte(base + 5))\n\t\to.Child = Word(m.loadByte(base + 6))\n\t\to.PropertyBase = Address(m.loadWord(base + 7))\n\t} else {\n\t\tbase := m.objectTableAddress() + (63 * 2) + Address((i-1)*14)\n\t\tcopy(o.Attributes[:6], m.memory[base:])\n\t\to.Parent = m.loadWord(base + 6)\n\t\to.Sibling = m.loadWord(base + 8)\n\t\to.Child = m.loadWord(base + 10)\n\t\to.PropertyBase = Address(m.loadWord(base + 12))\n\t}\n\treturn o\n}", "func LoadProgram(glctx gl.Context, vertexAsset, fragmentAsset string) (program gl.Program, err error) {\n\tlog.Println(\"LoadProgram:\", vertexAsset, fragmentAsset)\n\n\tprogram = glctx.CreateProgram()\n\tif program.Value == 0 {\n\t\treturn gl.Program{}, fmt.Errorf(\"glutil: no programs available\")\n\t}\n\n\terr = LoadShaders(glctx, program, vertexAsset, fragmentAsset)\n\treturn\n}", "func ReadProgram(filePath string) (interface{}, error) {\n\text := strings.ToLower(path.Ext(filePath))\n\n\t// ZIP archive\n\tif ext == \".zip\" {\n\t\treturn readZIP(filePath)\n\t}\n\n\tdata, err := ioutil.ReadFile(filePath)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tvar format *FormatInfo\n\tformat, err = detectFormat(filePath, ENCAPSULATION_NONE, false)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tif format.Format == FORMAT_TAP {\n\t\treturn NewTAP(data)\n\t}\n\n\treturn SnapshotData(data).Decode(format.Format)\n}", "func Example_loadWholeProgram() {\n\t// Load, parse, and type-check the whole program.\n\tcfg := packages.Config{Mode: packages.LoadAllSyntax}\n\tinitial, err := packages.Load(&cfg, \"fmt\", \"net/http\")\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\t// Create SSA packages for well-typed packages and their dependencies.\n\tprog, pkgs := ssautil.AllPackages(initial, ssa.PrintPackages|ssa.InstantiateGenerics)\n\t_ = pkgs\n\n\t// Build SSA code for the whole program.\n\tprog.Build()\n}", "func New(data []byte, filename string) (*Exec, error) {\n\tlog.Tracef(\"Creating new at %v\", filename)\n\treturn loadExecutable(filename, data)\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 load(thread *starlark.Thread, module string) (starlark.StringDict, error) {\n\tif module == \"assert.star\" {\n\t\treturn starlarktest.LoadAssertModule()\n\t}\n\tif module == \"json.star\" {\n\t\treturn starlark.StringDict{\"json\": json.Module}, nil\n\t}\n\tif module == \"time.star\" {\n\t\treturn starlark.StringDict{\"time\": time.Module}, nil\n\t}\n\tif module == \"math.star\" {\n\t\treturn starlark.StringDict{\"math\": starlarkmath.Module}, nil\n\t}\n\tif module == \"proto.star\" {\n\t\treturn starlark.StringDict{\"proto\": proto.Module}, nil\n\t}\n\n\t// TODO(adonovan): test load() using this execution path.\n\tfilename := filepath.Join(filepath.Dir(thread.CallFrame(0).Pos.Filename()), module)\n\treturn starlark.ExecFile(thread, filename, nil, nil)\n}", "func (r *Runtime) Load(wasmBytes []byte) (*Module, error) {\n\tresult := C.m3Err_none\n\tbytes := C.CBytes(wasmBytes)\n\tlength := len(wasmBytes)\n\tvar module C.IM3Module\n\tresult = C.m3_ParseModule(\n\t\tr.cfg.Environment.Ptr(),\n\t\t&module,\n\t\t(*C.uchar)(bytes),\n\t\tC.uint(length),\n\t)\n\tif result != nil {\n\t\treturn nil, errParseModule\n\t}\n\tif module.memoryImported {\n\t\tmodule.memoryImported = false\n\t}\n\tresult = C.m3_LoadModule(\n\t\tr.Ptr(),\n\t\tmodule,\n\t)\n\tif result != nil {\n\t\treturn nil, errLoadModule\n\t}\n\tresult = C.m3_LinkSpecTest(r.Ptr().modules)\n\tif result != nil {\n\t\treturn nil, errors.New(\"LinkSpecTest failed\")\n\t}\n\t// if r.cfg.EnableWASI {\n\t// \tC.m3_LinkWASI(r.Ptr().modules)\n\t// }\n\tm := NewModule((ModuleT)(module))\n\treturn m, nil\n}", "func (bi *BinaryInfo) LoadBinaryInfo(path string, entryPoint uint64, debugInfoDirs []string) error {\n\tfi, err := os.Stat(path)\n\tif err == nil {\n\t\tbi.lastModified = fi.ModTime()\n\t}\n\n\tbi.DebugInfoDirectories = debugInfoDirs\n\n\treturn bi.AddImage(path, entryPoint)\n}", "func GetProgramBinary(program uint32, bufSize int32, length *int32, binaryFormat *uint32, binary unsafe.Pointer) {\n\tC.glowGetProgramBinary(gpGetProgramBinary, (C.GLuint)(program), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLenum)(unsafe.Pointer(binaryFormat)), binary)\n}", "func GetProgramBinary(program uint32, bufSize int32, length *int32, binaryFormat *uint32, binary unsafe.Pointer) {\n\tC.glowGetProgramBinary(gpGetProgramBinary, (C.GLuint)(program), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLenum)(unsafe.Pointer(binaryFormat)), binary)\n}", "func OpenExecutable(path string) (*Executable, error) {\n\tif path == \"\" {\n\t\treturn nil, fmt.Errorf(\"path cannot be empty\")\n\t}\n\n\tf, err := os.Open(path)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"open file '%s': %w\", path, err)\n\t}\n\tdefer f.Close()\n\n\tse, err := internal.NewSafeELFFile(f)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"parse ELF file: %w\", err)\n\t}\n\n\tif se.Type != elf.ET_EXEC && se.Type != elf.ET_DYN {\n\t\t// ELF is not an executable or a shared object.\n\t\treturn nil, errors.New(\"the given file is not an executable or a shared object\")\n\t}\n\n\tex := Executable{\n\t\tpath: path,\n\t\taddresses: make(map[string]uint64),\n\t}\n\n\tif err := ex.load(se); err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn &ex, nil\n}", "func Load(prog *Prog) (ProgID, error) {\n\tlogBuf := make([]byte, 1024)\n\t//\tvar progidptr uintptr\n\tattr := ProgLoadAttr{\n\t\tunix.BPF_PROG_TYPE_SOCKET_FILTER,\n\t\tuint32(len(prog.Insts)),\n\t\tprog.Insts,\n\t\t[]byte(\"GPL\"),\n\t\t1,\n\t\t1024,\n\t\tlogBuf,\n\t}\n\tprogidptr, _, errno := unix.Syscall(\n\t\tunix.SYS_BPF, unix.BPF_PROG_LOAD,\n\t\tuintptr(unsafe.Pointer(&attr)),\n\t\tuintptr(unsafe.Sizeof(attr)))\n\tif errno < 0 {\n\t\treturn 0, fmt.Errorf(\"Failed on calling bpf: %s\", errno.Error())\n\t}\n\treturn progidptr, nil\n}", "func Load (content []byte, commands *map[string]Command) {\n // decode json\n var command_descriptor descriptor\n if err := json.Unmarshal(content, &command_descriptor); err != nil {\n log.Println(err)\n os.Exit(1)\n }\n\n // build command\n var new_command *Command = Build_command(command_descriptor)\n if (new_command == nil) {\n log.Printf(\"Command %s: not loaded!\", command_descriptor.Command_name)\n } else {\n (*commands)[command_descriptor.Command_name] = *new_command\n }\n}", "func Load(path string) (*OBJFile, error) {\n\tin, err := os.Open(path)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdefer in.Close()\n\treturn Decode(in)\n}", "func (env *Environment) Load(source, code string) error {\n\treturn nil\n}", "func (env *Environment) Load(source, code string) error {\n\treturn nil\n}", "func loadInterpreterELF(ctx context.Context, m *mm.MemoryManager, fd *vfs.FileDescription, initial loadedELF) (loadedELF, error) {\n\tinfo, err := parseHeader(ctx, fd)\n\tif err != nil {\n\t\tif linuxerr.Equals(linuxerr.ENOEXEC, err) {\n\t\t\t// Bad interpreter.\n\t\t\terr = linuxerr.ELIBBAD\n\t\t}\n\t\treturn loadedELF{}, err\n\t}\n\n\tif info.os != initial.os {\n\t\tctx.Infof(\"Initial ELF OS %v and interpreter ELF OS %v differ\", initial.os, info.os)\n\t\treturn loadedELF{}, linuxerr.ELIBBAD\n\t}\n\tif info.arch != initial.arch {\n\t\tctx.Infof(\"Initial ELF arch %v and interpreter ELF arch %v differ\", initial.arch, info.arch)\n\t\treturn loadedELF{}, linuxerr.ELIBBAD\n\t}\n\n\t// The interpreter is not given a load offset, as its location does not\n\t// affect brk.\n\treturn loadParsedELF(ctx, m, fd, info, 0)\n}", "func loadBinaryInfoPE(bi *BinaryInfo, image *Image, path string, entryPoint uint64, wg *sync.WaitGroup) error {\n\tpeFile, closer, err := openExecutablePathPE(path)\n\tif err != nil {\n\t\treturn err\n\t}\n\timage.closer = closer\n\tcpuArch := _PEMachine(peFile.Machine)\n\tif !supportedWindowsArch[cpuArch] {\n\t\treturn &ErrUnsupportedArch{os: \"windows\", cpuArch: cpuArch}\n\t}\n\timage.dwarf, err = peFile.DWARF()\n\tif err != nil {\n\t\treturn err\n\t}\n\tdebugInfoBytes, err := godwarf.GetDebugSectionPE(peFile, \"info\")\n\tif err != nil {\n\t\treturn err\n\t}\n\topth := peFile.OptionalHeader.(*pe.OptionalHeader64)\n\tif entryPoint != 0 {\n\t\timage.StaticBase = entryPoint - opth.ImageBase\n\t} else {\n\t\tif opth.DllCharacteristics&_IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE != 0 {\n\t\t\treturn ErrCouldNotDetermineRelocation\n\t\t}\n\t}\n\n\timage.dwarfReader = image.dwarf.Reader()\n\n\tdebugLineBytes, err := godwarf.GetDebugSectionPE(peFile, \"line\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tdebugLocBytes, _ := godwarf.GetDebugSectionPE(peFile, \"loc\")\n\timage.loclist2 = loclist.NewDwarf2Reader(debugLocBytes, bi.Arch.PtrSize())\n\tdebugLoclistBytes, _ := godwarf.GetDebugSectionPE(peFile, \"loclists\")\n\timage.loclist5 = loclist.NewDwarf5Reader(debugLoclistBytes)\n\tdebugAddrBytes, _ := godwarf.GetDebugSectionPE(peFile, \"addr\")\n\timage.debugAddr = godwarf.ParseAddr(debugAddrBytes)\n\tdebugLineStrBytes, _ := godwarf.GetDebugSectionPE(peFile, \"line_str\")\n\timage.debugLineStr = debugLineStrBytes\n\n\twg.Add(2)\n\tgo bi.parseDebugFramePE(image, peFile, debugInfoBytes, wg)\n\tgo bi.loadDebugInfoMaps(image, debugInfoBytes, debugLineBytes, wg, func() {\n\t\t// setGStructOffsetPE requires the image compile units to be loaded,\n\t\t// so it can't be called concurrently with loadDebugInfoMaps.\n\t\tif image.index == 0 {\n\t\t\t// determine g struct offset only when loading the executable file.\n\t\t\tbi.setGStructOffsetPE(entryPoint, peFile)\n\t\t}\n\t})\n\treturn nil\n}", "func Load(entryfile string) error {\n\tpkgs := starlark.StringDict{\n\t\t\"git_repository\": NewGitRepoBuiltin(),\n\t}\n\tthread := &starlark.Thread{\n\t\tLoad: loader.NewModulesLoaderWithPredeclaredPkgs(filepath.Dir(entryfile), pkgs).Load,\n\t}\n\n\tabsPath, err := filepath.Abs(entryfile)\n\tif err != nil {\n\t\treturn err\n\t}\n\tbytes, err := ioutil.ReadFile(absPath)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t_, err = starlark.ExecFile(thread, entryfile, bytes, pkgs)\n\treturn err\n}", "func objcopy(infile, outfile string) error {\n\tf, err := os.OpenFile(outfile, os.O_RDWR|os.O_CREATE|os.O_TRUNC, 0666)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer f.Close()\n\n\t// Read the .text segment.\n\taddr, data, err := extractROM(infile)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// Write to the file, in the correct format.\n\tswitch filepath.Ext(outfile) {\n\tcase \".gba\":\n\t\t// The address is not stored in a .gba file.\n\t\t_, err := f.Write(data)\n\t\treturn err\n\tcase \".bin\":\n\t\t// The address is not stored in a .bin file (therefore you\n\t\t// should use .hex files in most cases).\n\t\t_, err := f.Write(data)\n\t\treturn err\n\tcase \".hex\":\n\t\tmem := gohex.NewMemory()\n\t\terr := mem.AddBinary(uint32(addr), data)\n\t\tif err != nil {\n\t\t\treturn objcopyError{\"failed to create .hex file\", err}\n\t\t}\n\t\tmem.DumpIntelHex(f, 16) // TODO: handle error\n\t\treturn nil\n\tdefault:\n\t\tpanic(\"unreachable\")\n\t}\n}", "func (vm *BFVM) LoadFromString(source string) error {\n\treturn vm.LoadFromStream(strings.NewReader(source))\n}", "func(r *Runtime) Load(wasmBytes []byte) (*Module, error) {\n\tresult := C.m3Err_none\n\tbytes := C.CBytes(wasmBytes)\n\tlength := len(wasmBytes)\n\tvar module C.IM3Module\n\tresult = C.m3_ParseModule(\n\t\tr.cfg.Environment.Ptr(),\n\t\t&module,\n\t\t(*C.uchar)(bytes),\n\t\tC.uint(length),\n\t)\n\tif result != nil {\n\t\treturn nil, errParseModule\n\t}\n\tresult = C.m3_LoadModule(\n\t\tr.Ptr(),\n\t\tmodule,\n\t)\n\tif result != nil {\n\t\treturn nil, errLoadModule\n\t}\n\tresult = C.m3_LinkSpecTest(r.Ptr().modules)\n\tif result != nil {\n\t\treturn nil, errors.New(\"LinkSpecTest failed\")\n\t}\n\tif r.cfg.EnableWASI {\n\t\tC.m3_LinkWASI(r.Ptr().modules)\n\t}\n\tm := NewModule((ModuleT)(module))\n\treturn m, nil\n}", "func Deserialize(b []byte) (prgrm *CXProgram) {\n\tprgrm = &CXProgram{}\n\tvar s SerializedCXProgram\n\n\thelper.DeserializeRaw(b, &s)\n\tinitDeserialization(prgrm, &s)\n\n\treturn prgrm\n}", "func (u *Update) LaunchAppBinary() error {\n\tcmd := exec.Command(*u.oldMollyBinaryPath)\n\terr := cmd.Start()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to execute run command for Molly Wallet: %v\", err)\n\t}\n\treturn nil\n}", "func (self *Build) load(ctx core.Context, moduleLabel core.Label) (starlark.StringDict, error) {\n\t// Only .bzl files can ever be loaded.\n\tif filepath.Ext(string(moduleLabel.Target)) != \".bzl\" {\n\t\treturn nil, fmt.Errorf(\"%v: load not allowed: %v is not a .bzl file\", ctx.Label(),\n\t\t\tmoduleLabel)\n\t}\n\tmoduleLabelString := moduleLabel.String()\n\n\te, ok := self.loadCache[moduleLabelString]\n\tif ok {\n\t\tif e == nil {\n\t\t\treturn nil, fmt.Errorf(\"%v: load of %v failed: cycle in load graph\",\n\t\t\t\tctx.Label(), moduleLabel)\n\t\t}\n\t\treturn e.globals, e.err\n\t}\n\n\tsourceData, err := self.sourceFileReader(moduleLabel)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"%v: load of %v failed: read failed: %v\", ctx.Label(),\n\t\t\tmoduleLabel, err)\n\t}\n\n\tself.loadCache[moduleLabelString] = nil\n\n\tthread := createThread(self, moduleLabel, core.FileTypeBzl)\n\tglobals, err := starlark.ExecFile(thread, moduleLabelString, sourceData,\n\t\tbuiltins.InitialGlobals(core.FileTypeBzl))\n\tself.loadCache[moduleLabelString] = &loadCacheEntry{globals, err}\n\treturn globals, err\n}", "func LoadFromString(source string) (*BFVM, error) {\n\tmachine, err := New()\n\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\terr = machine.LoadFromString(source)\n\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn machine, nil\n}", "func New(b []byte) *LazyExe {\n\tle := &LazyExe{\n\t\tbytes: b,\n\t}\n\treturn le\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 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 (e *elf_t) elf_load(p *proc.Proc_t, f *fd.Fd_t) (int, int, int, defs.Err_t) {\n\tPT_LOAD := 1\n\tPT_TLS := 7\n\tistls := false\n\ttlssize := 0\n\tvar tlsaddr int\n\tvar tlscopylen int\n\n\tgimme := bounds.Bounds(bounds.B_ELF_T_ELF_LOAD)\n\tentry := e.entry()\n\t// load each elf segment directly into process memory\n\tfor _, hdr := range e.headers() {\n\t\t// XXX get rid of worthless user program segments\n\t\tif !res.Resadd_noblock(gimme) {\n\t\t\treturn 0, 0, 0, -defs.ENOHEAP\n\t\t}\n\t\tif hdr.etype == PT_TLS {\n\t\t\tistls = true\n\t\t\ttlsaddr = hdr.vaddr\n\t\t\ttlssize = util.Roundup(hdr.memsz, 8)\n\t\t\ttlscopylen = hdr.filesz\n\t\t} else if hdr.etype == PT_LOAD && hdr.vaddr >= mem.USERMIN {\n\t\t\terr := segload(p, entry, &hdr, f.Fops)\n\t\t\tif err != 0 {\n\t\t\t\treturn 0, 0, 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\tfreshtls := 0\n\tt0tls := 0\n\tif istls {\n\t\t// create fresh TLS image and map it COW for thread 0\n\t\tl := util.Roundup(tlsaddr+tlssize, mem.PGSIZE)\n\t\tl -= util.Rounddown(tlsaddr, mem.PGSIZE)\n\n\t\tfreshtls = p.Vm.Unusedva_inner(0, 2*l)\n\t\tt0tls = freshtls + l\n\t\tp.Vm.Vmadd_anon(freshtls, l, vm.PTE_U)\n\t\tp.Vm.Vmadd_anon(t0tls, l, vm.PTE_U|vm.PTE_W)\n\t\tperms := vm.PTE_U\n\n\t\tfor i := 0; i < l; i += mem.PGSIZE {\n\t\t\t// allocator zeros objects, so tbss is already\n\t\t\t// initialized.\n\t\t\t_, p_pg, ok := physmem.Refpg_new()\n\t\t\tif !ok {\n\t\t\t\treturn 0, 0, 0, -defs.ENOMEM\n\t\t\t}\n\t\t\t_, ok = p.Vm.Page_insert(freshtls+i, p_pg, perms,\n\t\t\t\ttrue, nil)\n\t\t\tif !ok {\n\t\t\t\tphysmem.Refdown(p_pg)\n\t\t\t\treturn 0, 0, 0, -defs.ENOMEM\n\t\t\t}\n\t\t\t// map fresh TLS for thread 0\n\t\t\tnperms := perms | vm.PTE_COW\n\t\t\t_, ok = p.Vm.Page_insert(t0tls+i, p_pg, nperms, true, nil)\n\t\t\tif !ok {\n\t\t\t\tphysmem.Refdown(p_pg)\n\t\t\t\treturn 0, 0, 0, -defs.ENOMEM\n\t\t\t}\n\t\t}\n\t\t// copy TLS data to freshtls\n\t\ttlsvmi, ok := p.Vm.Vmregion.Lookup(uintptr(tlsaddr))\n\t\tif !ok {\n\t\t\tpanic(\"must succeed\")\n\t\t}\n\t\tfor i := 0; i < tlscopylen; {\n\t\t\tif !res.Resadd_noblock(gimme) {\n\t\t\t\treturn 0, 0, 0, -defs.ENOHEAP\n\t\t\t}\n\n\t\t\t_src, p_pg, err := tlsvmi.Filepage(uintptr(tlsaddr + i))\n\t\t\tif err != 0 {\n\t\t\t\treturn 0, 0, 0, err\n\t\t\t}\n\t\t\toff := (tlsaddr + i) & int(vm.PGOFFSET)\n\t\t\tsrc := mem.Pg2bytes(_src)[off:]\n\t\t\tbpg, err := p.Vm.Userdmap8_inner(freshtls+i, true)\n\t\t\tif err != 0 {\n\t\t\t\tphysmem.Refdown(p_pg)\n\t\t\t\treturn 0, 0, 0, err\n\t\t\t}\n\t\t\tleft := tlscopylen - i\n\t\t\tif len(src) > left {\n\t\t\t\tsrc = src[0:left]\n\t\t\t}\n\t\t\tcopy(bpg, src)\n\t\t\ti += len(src)\n\t\t\tphysmem.Refdown(p_pg)\n\t\t}\n\n\t\t// amd64 sys 5 abi specifies that the tls pointer references to\n\t\t// the first invalid word past the end of the tls\n\t\tt0tls += tlssize\n\t}\n\treturn freshtls, t0tls, tlssize, 0\n}", "func Load(path string, v interface{}) error {\n\tlock.Lock()\n\tdefer lock.Unlock()\n\tf, err := os.Open(path)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer f.Close()\n\treturn Unmarshal(f, v)\n}", "func (p *Puck) Load(name ...string) error {\n\tcmd := []byte(\"load();\\n\")\n\terr := p.command(name, cmd)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (d *Dump) Load() error {\n\td.mutex.Lock()\n\tdefer d.mutex.Unlock()\n\n\tvar (\n\t\tdata []byte\n\t\terr error\n\t)\n\n\tif data, err = ioutil.ReadFile(d.filename); err != nil {\n\t\treturn err\n\t}\n\n\treturn d.decodeGob(data)\n}", "func Load(path string, v interface{}) error {\n\tlock.Lock()\n\tdefer lock.Unlock()\n\tf, err := os.Open(path)\n\tif err != nil {\n\t\tif os.IsNotExist(err) {\n\t\t\treturn err\n\t\t}\n\t}\n\tdefer f.Close()\n\treturn Unmarshal(f, v)\n}", "func execModule(module string, load loadFunc) (starlark.StringDict, error) {\n\treturn load(&starlark.Thread{Name: module, Load: load}, module)\n}", "func Load(fname string) (r *Recipe, err error) {\n\tb, err := ioutil.ReadFile(fname)\n\tif err != nil {\n\t\treturn\n\t}\n\tr = new(Recipe)\n\terr = json.Unmarshal(b, r)\n\treturn\n}", "func initSerialization(prgrm *CXProgram, s *SerializedCXProgram, includeMemory bool) {\n\ts.PackagesMap = make(map[string]int64)\n\ts.StructsMap = make(map[string]int64)\n\ts.FunctionsMap = make(map[string]int64)\n\ts.StringsMap = make(map[string]int64)\n\n\ts.Calls = make([]serializedCall, prgrm.CallCounter)\n\ts.Packages = make([]serializedPackage, len(prgrm.Packages))\n\n\tif includeMemory {\n\t\t// s.Memory = prgrm.Memory[:PROGRAM.HeapStartsAt+PROGRAM.HeapPointer]\n\t\ts.Memory = prgrm.Memory\n\t}\n\n\tvar numStrcts int\n\tvar numFns int\n\n\tfor _, pkg := range prgrm.Packages {\n\t\tnumStrcts += len(pkg.Structs)\n\t\tnumFns += len(pkg.Functions)\n\t}\n\n\ts.Structs = make([]serializedStruct, numStrcts)\n\ts.Functions = make([]serializedFunction, numFns)\n\t// args and exprs need to be appended as they are found\n}", "func (c *Chip8) LoadROM(rompath string) {\n\tdata, err := ioutil.ReadFile(rompath)\n\tif err != nil {\n\t\tdie(\"Could not read ROM file at path:\", rompath)\n\t}\n\tc.LoadProgram(data)\n}", "func (d *cephobject) load() error {\n\t// Register the patches.\n\td.patches = map[string]func() error{\n\t\t\"storage_lvm_skipactivation\": nil,\n\t\t\"storage_missing_snapshot_records\": nil,\n\t\t\"storage_delete_old_snapshot_records\": nil,\n\t\t\"storage_zfs_drop_block_volume_filesystem_extension\": nil,\n\t\t\"storage_prefix_bucket_names_with_project\": nil,\n\t}\n\n\t// Done if previously loaded.\n\tif cephobjectLoaded {\n\t\treturn nil\n\t}\n\n\t// Validate the required binaries.\n\tfor _, tool := range []string{\"radosgw-admin\"} {\n\t\t_, err := exec.LookPath(tool)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"Required tool %q is missing\", tool)\n\t\t}\n\t}\n\n\t// Detect and record the version.\n\tif cephobjectVersion == \"\" {\n\t\tout, err := shared.RunCommand(\"radosgw-admin\", \"--version\")\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tout = strings.TrimSpace(out)\n\n\t\tfields := strings.Split(out, \" \")\n\t\tif strings.HasPrefix(out, \"ceph version \") && len(fields) > 2 {\n\t\t\tcephobjectVersion = fields[2]\n\t\t} else {\n\t\t\tcephobjectVersion = out\n\t\t}\n\t}\n\n\tcephobjectLoaded = true\n\n\treturn nil\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() {\n\tRun(&LoadgenService{})\n}", "func (s *ScriptReal) Load(c Scripter) StringCmd {\n\treturn &StringCmdReal{stringCmd: s.script.Load(c)}\n}", "func Load(modelArchive string, framework Framework, flags ModelFlags) (*Model, error) {\n\tf, _ := os.Open(modelArchive)\n\tdefer f.Close()\n\tvar outDir string\n\tif fi, err := f.Stat(); err == nil && fi.IsDir() {\n\t\toutDir = modelArchive\n\t} else if err == nil && !fi.IsDir() {\n\t\ttmpDir := os.TempDir()\n\t\toutDir = filepath.Join(tmpDir, utils.PseudoUuid())\n\t\tif err := utils.Unzip(modelArchive, outDir); err != nil {\n\t\t\treturn nil, fmt.Errorf(\"Failed to extract model archive: %v\", err)\n\t\t}\n\t} else {\n\t\treturn nil, fmt.Errorf(\"%s does not exist\", modelArchive)\n\t}\n\n\tmodelFilename := filepath.Join(outDir, \"saved_model.pb\")\n\tif _, err := os.Stat(modelFilename); err != nil {\n\t\t// This if is here for when we can read pbtxt files\n\t\tif _, err2 := os.Stat(modelFilename + \"txt\"); err2 == nil {\n\t\t\tmodelFilename = modelFilename + \"txt\"\n\t\t\treturn nil, errors.New(\"Currently loading saved_model.pbtxt is not supported\")\n\t\t\t//comment the return when we can read pbtxt\n\t\t} else {\n\t\t\treturn nil, errors.New(\"saved_model.pb does not exist\")\n\t\t}\n\t}\n\n\tflags.ModelPath = outDir\n\tflags.ModelFile = modelFilename\n\tvar model Model\n\terr := framework.Load(&model, flags)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn &model, nil\n}", "func Load(filePath string, struc interface{}) error{\n\n\t//Build OS reader\n\treader := new(ReaderOS)\n\t\n\t//Reading File\n\tcontentBytes, err := reader.Read(filePath)\n\tif err != nil{\n\t\tlog.Println(TAG, err)\n\t\treturn err\n\t}\n\n\t//Get Parser\n\tparser := GetParser()\n\n\t//Parsing\n\tif err := parser.Parse(contentBytes, struc); err != nil {\n\t\tlog.Println(TAG, err)\n\t\treturn ErrParserFile\n\t}\n\n\treturn nil\n}", "func (am *AssetManager) LoadRenderProgram(vertexShader, fragmentShader, iname string) {\n\t//program, err := LoadProgram(am.shadersDir+\"standard.vert\", am.shadersDir+\"standard.frag\")\n\t//if err != nil {\n\t//\tlog.Fatal(err)\n\t//}\n\t//am.Programs[iname] = program\n}", "func LoadLabFromString(text string, lab *Lab) error {\n\treturn proto.UnmarshalText(text, lab)\n}", "func (init *FuseInitIn) ParseBinary(bcontent []byte) error {\n\terr := common.ParseBinary(bcontent, init)\n\n\treturn err\n}", "func (m *MMU) Load(rom string) error {\n\tf, err := os.Open(rom)\n\tdefer f.Close()\n\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif e := m.LoadFrom(f); e != nil {\n\t\treturn e\n\t}\n\n\treturn nil\n}", "func (self *Build) exec(moduleLabel core.Label, fileType core.FileType) error {\n\tthread := createThread(self, moduleLabel, fileType)\n\n\tsourceData, err := self.sourceFileReader(moduleLabel)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to execute %v: read failed: %v\", moduleLabel, err)\n\t}\n\n\t_, err = starlark.ExecFile(thread, moduleLabel.String(), sourceData,\n\t\tbuiltins.InitialGlobals(fileType))\n\treturn err\n}", "func (o *MempoolBin) Reload(ctx context.Context, exec boil.ContextExecutor) error {\n\tret, err := FindMempoolBin(ctx, exec, o.Time, o.Bin)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t*o = *ret\n\treturn nil\n}", "func ReadText(text string) (*il.Program, error) {\n\tp := il.NewProgram()\n\tif err := MergeText(text, p); err != nil {\n\t\treturn nil, err\n\t}\n\treturn p, nil\n}", "func initDeserialization(prgrm *CXProgram, s *SerializedCXProgram) {\n\tprgrm.Memory = s.Memory\n\tprgrm.Packages = make([]*CXPackage, len(s.Packages))\n\tprgrm.CallStack = make([]CXCall, constants.CALLSTACK_SIZE)\n\tprgrm.HeapStartsAt = int(s.Program.HeapStartsAt)\n\tprgrm.HeapPointer = int(s.Program.HeapPointer)\n\tprgrm.StackSize = int(s.Program.StackSize)\n\tprgrm.DataSegmentSize = int(s.Program.DataSegmentSize)\n\tprgrm.DataSegmentStartsAt = int(s.Program.DataSegmentStartsAt)\n\tprgrm.HeapSize = int(s.Program.HeapSize)\n\tprgrm.Version = deserializeString(s.Program.VersionOffset, s.Program.VersionSize, s)\n\n\tdeserializePackages(s, prgrm)\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 (e *Emulator) Load(rom []byte) error {\n\te.mmu.Load(rom)\n\treturn nil\n}", "func Load(fileName string, src interface{}) error {\n\tfile, err := os.Open(fileName)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer file.Close()\n\tif err == nil {\n\t\tdecoder := gob.NewDecoder(file)\n\t\tif err = decoder.Decode(src); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\t// Restore parameters\n\tswitch src.(type) {\n\tcase Model:\n\t\tmodel := src.(Model)\n\t\tmodel.SetParams(model.GetParams())\n\tdefault:\n\t\treturn errors.New(\"the file is not a model dump\")\n\t}\n\treturn nil\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 newLoad() *cobra.Command {\n\tvar cluster []string\n\tvar dbName string\n\tvar fileName string\n\tvar batch, verbose bool\n\n\tcmd := &cobra.Command{\n\t\tUse: \"load\",\n\t\tShort: \"Execute the statements in the given file.\",\n\t\tRunE: func(cmd *cobra.Command, args []string) error {\n\t\t\tif fileName == \"\" {\n\t\t\t\tlog.Fatal(\"no filename specified\")\n\t\t\t}\n\t\t\tctx := context.Background()\n\t\t\tdbFile(ctx, &globalKeys, fileName, dbName, batch, verbose, cluster)\n\t\t\treturn nil\n\t\t},\n\t}\n\n\tflags := cmd.Flags()\n\tflags.StringSliceVarP(&cluster, \"cluster\", \"c\", clusterList(), \"addresses of existing cluster nodes\")\n\tflags.StringVarP(&dbName, \"database\", \"d\", envy.StringDefault(\"DQLITED_DB\", defaultDatabase), \"name of database to use\")\n\tflags.StringVarP(&fileName, \"file\", \"f\", \"\", \"name of file to load\")\n\tflags.BoolVarP(&batch, \"batch\", \"b\", false, \"run all statements as a single transaction\")\n\tflags.BoolVarP(&verbose, \"verbose\", \"v\", false, \"be chatty about activities\")\n\n\treturn cmd\n}", "func Load(path string, object interface{}) error {\n\tfile, err := os.Open(path)\n\tif err == nil {\n\t\tdecoder := json.NewDecoder(file)\n\t\terr = decoder.Decode(object)\n\t}\n\tfile.Close()\n\treturn err\n}", "func (self *LSHforest) Load(path string) error {\n\tb, err := ioutil.ReadFile(path)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn msgpack.Unmarshal(b, self)\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 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 readELFInterpreter(f *elf.File) string {\n\tconst pathMax = 4096\n\tfor _, p := range f.Progs {\n\t\tif p.Type == elf.PT_INTERP {\n\t\t\tr := p.Open()\n\t\t\tm := p.Filesz\n\t\t\tif m > pathMax {\n\t\t\t\tm = pathMax\n\t\t\t}\n\t\t\tb := make([]byte, m)\n\t\t\tr.Read(b)\n\t\t\treturn strings.TrimRight(string(b), \"\\x00\")\n\t\t}\n\t}\n\treturn \"\"\n}", "func loadParsedELF(ctx context.Context, m *mm.MemoryManager, fd *vfs.FileDescription, info elfInfo, sharedLoadOffset hostarch.Addr) (loadedELF, error) {\n\tfirst := true\n\tvar start, end hostarch.Addr\n\tvar interpreter string\n\tfor _, phdr := range info.phdrs {\n\t\tswitch phdr.Type {\n\t\tcase elf.PT_LOAD:\n\t\t\tvaddr := hostarch.Addr(phdr.Vaddr)\n\t\t\tif first {\n\t\t\t\tfirst = false\n\t\t\t\tstart = vaddr\n\t\t\t}\n\t\t\tif vaddr < end {\n\t\t\t\t// NOTE(b/37474556): Linux allows out-of-order\n\t\t\t\t// segments, in violation of the spec.\n\t\t\t\tctx.Infof(\"PT_LOAD headers out-of-order. %#x < %#x\", vaddr, end)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\t\t\tvar ok bool\n\t\t\tend, ok = vaddr.AddLength(phdr.Memsz)\n\t\t\tif !ok {\n\t\t\t\tctx.Infof(\"PT_LOAD header size overflows. %#x + %#x\", vaddr, phdr.Memsz)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\n\t\tcase elf.PT_INTERP:\n\t\t\tif phdr.Filesz < 2 {\n\t\t\t\tctx.Infof(\"PT_INTERP path too small: %v\", phdr.Filesz)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\t\t\tif phdr.Filesz > linux.PATH_MAX {\n\t\t\t\tctx.Infof(\"PT_INTERP path too big: %v\", phdr.Filesz)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\t\t\tif int64(phdr.Off) < 0 || int64(phdr.Off+phdr.Filesz) < 0 {\n\t\t\t\tctx.Infof(\"Unsupported PT_INTERP offset %d\", phdr.Off)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\n\t\t\tpath := make([]byte, phdr.Filesz)\n\t\t\t_, err := fd.ReadFull(ctx, usermem.BytesIOSequence(path), int64(phdr.Off))\n\t\t\tif err != nil {\n\t\t\t\t// If an interpreter was specified, it should exist.\n\t\t\t\tctx.Infof(\"Error reading PT_INTERP path: %v\", err)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\n\t\t\tif path[len(path)-1] != 0 {\n\t\t\t\tctx.Infof(\"PT_INTERP path not NUL-terminated: %v\", path)\n\t\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t\t}\n\n\t\t\t// Strip NUL-terminator and everything beyond from\n\t\t\t// string. Note that there may be a NUL-terminator\n\t\t\t// before len(path)-1.\n\t\t\tinterpreter = string(path[:bytes.IndexByte(path, '\\x00')])\n\t\t\tif interpreter == \"\" {\n\t\t\t\t// Linux actually attempts to open_exec(\"\\0\").\n\t\t\t\t// open_exec -> do_open_execat fails to check\n\t\t\t\t// that name != '\\0' before calling\n\t\t\t\t// do_filp_open, which thus opens the working\n\t\t\t\t// directory. do_open_execat returns EACCES\n\t\t\t\t// because the directory is not a regular file.\n\t\t\t\t//\n\t\t\t\t// We bypass that nonsense and simply\n\t\t\t\t// short-circuit with EACCES. Those this does\n\t\t\t\t// mean that there may be some edge cases where\n\t\t\t\t// the open path would return a different\n\t\t\t\t// error.\n\t\t\t\tctx.Infof(\"PT_INTERP path is empty: %v\", path)\n\t\t\t\treturn loadedELF{}, linuxerr.EACCES\n\t\t\t}\n\t\t}\n\t}\n\n\t// Shared objects don't have fixed load addresses. We need to pick a\n\t// base address big enough to fit all segments, so we first create a\n\t// mapping for the total size just to find a region that is big enough.\n\t//\n\t// It is safe to unmap it immediately without racing with another mapping\n\t// because we are the only one in control of the MemoryManager.\n\t//\n\t// Note that the vaddr of the first PT_LOAD segment is ignored when\n\t// choosing the load address (even if it is non-zero). The vaddr does\n\t// become an offset from that load address.\n\tvar offset hostarch.Addr\n\tif info.sharedObject {\n\t\ttotalSize := end - start\n\t\ttotalSize, ok := totalSize.RoundUp()\n\t\tif !ok {\n\t\t\tctx.Infof(\"ELF PT_LOAD segments too big\")\n\t\t\treturn loadedELF{}, linuxerr.ENOEXEC\n\t\t}\n\n\t\tvar err error\n\t\toffset, err = m.MMap(ctx, memmap.MMapOpts{\n\t\t\tLength: uint64(totalSize),\n\t\t\tAddr: sharedLoadOffset,\n\t\t\tPrivate: true,\n\t\t})\n\t\tif err != nil {\n\t\t\tctx.Infof(\"Error allocating address space for shared object: %v\", err)\n\t\t\treturn loadedELF{}, err\n\t\t}\n\t\tif err := m.MUnmap(ctx, offset, uint64(totalSize)); err != nil {\n\t\t\tpanic(fmt.Sprintf(\"Failed to unmap base address: %v\", err))\n\t\t}\n\n\t\tstart, ok = start.AddLength(uint64(offset))\n\t\tif !ok {\n\t\t\tctx.Infof(fmt.Sprintf(\"Start %#x + offset %#x overflows?\", start, offset))\n\t\t\treturn loadedELF{}, linuxerr.EINVAL\n\t\t}\n\n\t\tend, ok = end.AddLength(uint64(offset))\n\t\tif !ok {\n\t\t\tctx.Infof(fmt.Sprintf(\"End %#x + offset %#x overflows?\", end, offset))\n\t\t\treturn loadedELF{}, linuxerr.EINVAL\n\t\t}\n\n\t\tinfo.entry, ok = info.entry.AddLength(uint64(offset))\n\t\tif !ok {\n\t\t\tctx.Infof(\"Entrypoint %#x + offset %#x overflows? Is the entrypoint within a segment?\", info.entry, offset)\n\t\t\treturn loadedELF{}, err\n\t\t}\n\t}\n\n\t// Map PT_LOAD segments.\n\tfor _, phdr := range info.phdrs {\n\t\tswitch phdr.Type {\n\t\tcase elf.PT_LOAD:\n\t\t\tif phdr.Memsz == 0 {\n\t\t\t\t// No need to load segments with size 0, but\n\t\t\t\t// they exist in some binaries.\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tif err := mapSegment(ctx, m, fd, &phdr, offset); err != nil {\n\t\t\t\tctx.Infof(\"Failed to map PT_LOAD segment: %+v\", phdr)\n\t\t\t\treturn loadedELF{}, err\n\t\t\t}\n\t\t}\n\t}\n\n\t// This assumes that the first segment contains the ELF headers. This\n\t// may not be true in a malformed ELF, but Linux makes the same\n\t// assumption.\n\tphdrAddr, ok := start.AddLength(info.phdrOff)\n\tif !ok {\n\t\tctx.Warningf(\"ELF start address %#x + phdr offset %#x overflows\", start, info.phdrOff)\n\t\tphdrAddr = 0\n\t}\n\n\treturn loadedELF{\n\t\tos: info.os,\n\t\tarch: info.arch,\n\t\tentry: info.entry,\n\t\tstart: start,\n\t\tend: end,\n\t\tinterpreter: interpreter,\n\t\tphdrAddr: phdrAddr,\n\t\tphdrSize: info.phdrSize,\n\t\tphdrNum: len(info.phdrs),\n\t}, nil\n}", "func (b *BrBuilder) Load() error {\n\tfpath := filepath.Join(b.StorePath, adminDir, branchBin)\n\tfd, err := os.OpenFile(fpath, os.O_RDONLY, 666)\n\tif err != nil {\n\t\t//log.Error(2, \"[Branch] Load branch %s failed: %v.\", b.Name(), err)\n\t\treturn err\n\t}\n\n\tdefer fd.Close()\n\treturn gob.NewDecoder(fd).Decode(&b.Branch)\n}", "func (l *loaderImpl) Load(location string) ([]byte, error) {\n\tscheme, err := l.getSchemeLoader(location)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tfullLocation, err := scheme.FullLocation(l.root, location)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn scheme.Load(fullLocation)\n}", "func (ee *EncryptionEngine) Load(data EncryptedData) {\n\tif err := ioutil.WriteFile(ee.wDekPathName, []byte(data.Wdek), 0644); err != nil {\n\t\terr := errors.Wrapf(err, \"cannot create file for loading: %s\", ee.wDekPathName)\n\t\tee.logger.Fatalf(\"%+v\", err)\n\t}\n\n\tee.ReadWdek()\n}", "func (w *Worker) Load(scriptName string, code string) error {\n\treturn w.LoadWithOptions(&ScriptOrigin{ScriptName: scriptName}, code)\n}", "func (p *Config) NewProcessorFromBinary(vmtype string, binaryCode []byte) (isc.VMProcessor, error) {\n\tconstructor, ok := p.vmConstructors[vmtype]\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"unknown VM type '%s'\", vmtype)\n\t}\n\treturn constructor(binaryCode)\n}", "func Load(ioreader io.Reader) (*Rom, error) {\n\treader := bufio.NewReader(ioreader)\n\tr := new(Rom)\n\n\t// read the header\n\tbuf := make([]byte, 16)\n\t_, err := io.ReadAtLeast(reader, buf, 16)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif string(buf[0:4]) != \"NES\\x1a\" {\n\t\treturn nil, errors.New(\"Invalid ROM file\")\n\t}\n\tprgBankCount := int(buf[4])\n\tchrBankCount := int(buf[5])\n\tflags6 := buf[6]\n\tflags7 := buf[7]\n\tif buf[8] != 0 && buf[8] != 1 {\n\t\treturn nil, errors.New(\"Only 8KB program RAM supported\")\n\t}\n\tflags9 := buf[9]\n\tflags10 := buf[10]\n\n\tr.Mapper = (flags6 >> 4) | (flags7 & 0xf0)\n\tif flags6&0x8 != 0 {\n\t\tr.Mirroring = FourScreenVRamMirroring\n\t} else if flags6&0x1 != 0 {\n\t\tr.Mirroring = HorizontalMirroring\n\t} else {\n\t\tr.Mirroring = VerticalMirroring\n\t}\n\tif flags6&0x2 != 0 {\n\t\tr.BatteryBacked = true\n\t}\n\tif flags6&0x4 != 0 {\n\t\treturn nil, errors.New(\"Trainer unsupported\")\n\t}\n\tif flags7&0x1 != 0 {\n\t\treturn nil, errors.New(\"VS Unisystem unsupported\")\n\t}\n\tif flags7&0x2 != 0 {\n\t\treturn nil, errors.New(\"PlayChoice-10 unsupported\")\n\t}\n\tif (flags7>>2)&0x2 != 0 {\n\t\treturn nil, errors.New(\"NES 2.0 format unsupported\")\n\t}\n\tif flags9&0x1 != 0 {\n\t\treturn nil, errors.New(\"PAL unsupported\")\n\t}\n\tswitch flags10 & 0x2 {\n\tcase 0:\n\t\tr.TvSystem = NtscTv\n\tcase 2:\n\t\tr.TvSystem = PalTv\n\tdefault:\n\t\tr.TvSystem = DualCompatTv\n\t}\n\tr.SRamPresent = flags10&0x10 == 0\n\tif flags10&0x20 != 0 {\n\t\treturn nil, errors.New(\"bus conflicts unsupported\")\n\t}\n\n\tr.PrgRom = make([][]byte, prgBankCount)\n\tfor i := 0; i < prgBankCount; i++ {\n\t\tbank := make([]byte, 0x4000)\n\t\t_, err := io.ReadAtLeast(reader, bank, len(bank))\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tr.PrgRom[i] = bank\n\t}\n\n\tr.ChrRom = make([][]byte, chrBankCount)\n\tfor i := 0; i < chrBankCount; i++ {\n\t\tbank := make([]byte, 0x2000)\n\t\t_, err := io.ReadAtLeast(reader, bank, len(bank))\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tr.ChrRom[i] = bank\n\t}\n\n\treturn r, nil\n}", "func Load(b common.RawBytes) (*Topology, error) {\n\trt := &Topology{}\n\tif err := json.Unmarshal(b, rt); err != nil {\n\t\treturn nil, serrors.WrapStr(\"unable to parse topology from JSON\", err)\n\t}\n\treturn rt, nil\n}", "func NewExecBinary(name FileName) ExecBinary {\n\treturn ExecBinary{\n\t\tName: name,\n\t}\n}", "func BinaryFromFile(path string) *Binary {\n\tif bf, ok := BinaryFromFile2(path); ok {\n\t\treturn bf\n\t}\n\tpanic(px.Error(px.FileNotFound, issue.H{`path`: path}))\n}", "func (c *CPU) LoadGame(file string) error {\n\tf, err := os.Open(file)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer f.Close()\n\n\t//Load rom in buffer\n\tvar rom []byte\n\trom, err = ioutil.ReadAll(f)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t//Write rom to memory from the buffer\n\tfor i := 0; i < len(rom); i++ {\n\t\tc.memory[i+512] = rom[i]\n\t}\n\treturn nil\n}", "func (*Program) Descriptor() ([]byte, []int) {\n\treturn file_data_proto_rawDescGZIP(), []int{2}\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 (this *Manager) load() error{\n bytes, err := ioutil.ReadFile(this.filename())\n if err != nil {\n return err\n }\n mp := dynmap.NewDynMap()\n err = mp.UnmarshalJSON(bytes)\n if err != nil {\n return err\n }\n table,err := ToRouterTable(mp)\n if err != nil {\n return err\n }\n this.SetRouterTable(table) \n return nil\n}" ]
[ "0.70892036", "0.69508004", "0.66458416", "0.65731376", "0.6112255", "0.59849906", "0.59597445", "0.5928969", "0.59015036", "0.5862646", "0.5851017", "0.5848486", "0.5829028", "0.5814285", "0.57555217", "0.573734", "0.56857157", "0.56596124", "0.5624457", "0.5588231", "0.55813104", "0.5555636", "0.5531976", "0.54897076", "0.5462848", "0.5454867", "0.54520345", "0.54439366", "0.5405641", "0.53777313", "0.534452", "0.5330424", "0.5330424", "0.5320591", "0.53098017", "0.53076535", "0.52922165", "0.5277415", "0.5277415", "0.52516973", "0.5243102", "0.5219929", "0.5204695", "0.51898134", "0.5183915", "0.51784563", "0.5156693", "0.51455545", "0.5118772", "0.51120424", "0.5074089", "0.5064671", "0.50625044", "0.5061848", "0.5053452", "0.5041097", "0.503792", "0.503391", "0.50260967", "0.50157577", "0.5013627", "0.5006759", "0.50005776", "0.49973977", "0.49905822", "0.49836224", "0.49799967", "0.49698988", "0.4969217", "0.49665952", "0.49627414", "0.49592268", "0.49574643", "0.49513146", "0.4947582", "0.4934587", "0.4928875", "0.49268597", "0.4917841", "0.49095738", "0.4902725", "0.49022374", "0.48999563", "0.48924196", "0.48766053", "0.48764563", "0.48683208", "0.48603952", "0.48536476", "0.48530316", "0.48527128", "0.48459357", "0.48450086", "0.4841109", "0.48374763", "0.4832965", "0.48314062", "0.48262244", "0.48113465" ]
0.5603798
20
specify a parameter for a program object
func ProgramParameteri(program uint32, pname uint32, value int32) { C.glowProgramParameteri(gpProgramParameteri, (C.GLuint)(program), (C.GLenum)(pname), (C.GLint)(value)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ProgramParameteri(program uint32, pname uint32, value int32) {\n\tsyscall.Syscall(gpProgramParameteri, 3, uintptr(program), uintptr(pname), uintptr(value))\n}", "func (m *ProgramControl) SetProgram(value Programable)() {\n err := m.GetBackingStore().Set(\"program\", value)\n if err != nil {\n panic(err)\n }\n}", "func RequireParam(rt runtime.Runtime, predicate bool, msg string, args ...interface{}) {\n\tRequirePredicate(rt, predicate, exitcode.ErrIllegalArgument, msg, args...)\n}", "func (s *Script) Param(name string, value interface{}) *Script {\n\tif s.params == nil {\n\t\ts.params = make(map[string]interface{})\n\t}\n\ts.params[name] = value\n\treturn s\n}", "func execNewParam(_ int, p *gop.Context) {\n\targs := p.GetArgs(4)\n\tret := types.NewParam(token.Pos(args[0].(int)), args[1].(*types.Package), args[2].(string), args[3].(types.Type))\n\tp.Ret(4, ret)\n}", "func UseProgram(p Program) {\n\tgl.UseProgram(p.Value)\n}", "func (p *Program) getParameter(param uint32) int {\n\tvar v int32\n\tgl.GetProgramiv(uint32(p.glHandle), param, &v)\n\treturn int(v)\n}", "func init() {\n\tport = flag.Int(\"port\", 3000, \"an int\")\n}", "func (s *BaselimboListener) EnterProgram(ctx *ProgramContext) {}", "func (node *Node) Param(config *ValidationConfig, keys ...string) *Node {\n\n\tif len(keys) == 0 { panic(\"NO KEYS SUPPLIED FOR NEW PARAMETER\") }\n\n\tn := node.new(\":\" + keys[0])\n\n\tconfig.keys = keys\n\n\tn.Lock()\n\t\tn.validation = config\n\t\tn.validations = append(n.validations, config)\n\tn.Unlock()\n\n\tnode.param = n\n\n\treturn n\n}", "func (s *BaseEvent) AddParamStr( name, value string ) error {\n if s.execParams==nil { s.execParams=make(map[string]string,10) }\n s.execParams[name] = value\n return 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 (s *BaseAspidaListener) EnterProgram(ctx *ProgramContext) {}", "func (modes Modes) Param(position int) Mode {\n\tdigit := digitAt(int(modes), position)\n\treturn Mode(digit)\n}", "func (g *Generator) CommandLineParameters(parameter string) {\n\tg.Param = make(map[string]string)\n\tfor _, p := range strings.Split(parameter, \",\") {\n\t\tif i := strings.Index(p, \"=\"); i < 0 {\n\t\t\tg.Param[p] = \"\"\n\t\t} else {\n\t\t\tg.Param[p[0:i]] = p[i+1:]\n\t\t}\n\t}\n\n\tfor k, v := range g.Param {\n\t\tswitch k {\n\t\tcase \"vopkg\":\n\t\t\tg.ValueObjectPackage = paramToJavaPackage(v)\n\t\tcase \"cvtpkg\":\n\t\t\tg.ConverterPackage = paramToJavaPackage(v)\n\t\t}\n\t}\n\n\tif g.ValueObjectPackage == \"\" {\n\t\tg.Fail(\"invalid vo package, use --bean_out=vopkg=[package.of.vo], to set\")\n\t}\n\tif g.ConverterPackage == \"\" {\n\t\tg.ConverterPackage = fmt.Sprintf(\"%s.%s\", g.ValueObjectPackage, \"converter\")\n\t}\n}", "func UseProgram(program uint32) {\n\tsyscall.Syscall(gpUseProgram, 1, uintptr(program), 0, 0)\n}", "func (s *BasevhdlListener) EnterParameter_specification(ctx *Parameter_specificationContext) {}", "func (s *BaseednListener) EnterProgram(ctx *ProgramContext) {}", "func (r *ClusterHibernateRequest) Parameter(name string, value interface{}) *ClusterHibernateRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\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 (r *ClusterResumeRequest) Parameter(name string, value interface{}) *ClusterResumeRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\n}", "func (b *ProgramControlRequestBuilder) Program() *ProgramRequestBuilder {\n\tbb := &ProgramRequestBuilder{BaseRequestBuilder: b.BaseRequestBuilder}\n\tbb.baseURL += \"/program\"\n\treturn bb\n}", "func Param(ctx context.Context, name string) string {\n\treturn Params(ctx).ByName(name)\n}", "func (m *ProgramControl) SetProgramId(value *string)() {\n err := m.GetBackingStore().Set(\"programId\", value)\n if err != nil {\n panic(err)\n }\n}", "func (c *command) addParam(key, value string) {\n\tif c.Parameters == nil {\n\t\tc.Parameters = map[string]string{}\n\t}\n\tc.Parameters[key] = value\n}", "func (s *BasecluListener) EnterParam(ctx *ParamContext) {}", "func main() {\n\tdefer contracts.ShowHelp(help)\n\tnProd, nCons, bufferSize := parseArguments()\n\n\tprogram(nProd, nCons, bufferSize)\n}", "func main() {\n\tflag.Parse() // should be executed into \"main\" method\n\tfmt.Println(stringParam)\n\tfmt.Println(intParam)\n\tfmt.Printf(\"%#v\\n\", listParam)\n}", "func (s *BaselimboListener) EnterFormal_arg(ctx *Formal_argContext) {}", "func (b *TriggerTemplateBuilder) Param(name, description string) {\n\tb.TriggerTemplate.Spec.Params = append(b.TriggerTemplate.Spec.Params, v1alpha1.ParamSpec{\n\t\tName: name,\n\t\tDescription: description,\n\t})\n}", "func main() {\n\tvar name string\n\t// flag.StringVar() melakukan penyimpanan dgn metode referensi, dimana variabel yg digunakan adalah \"name\"\n\tflag.StringVar(&name,\"name\",\"any\",\"type your name\")\n\tvar age = flag.Int64(\"age\",25,\"type your age\")\n\n\tflag.Parse()\n\n\t// Pengaksesan nilai asli tdk perlu di-deference lagi\n\tfmt.Printf(\"Name\\t: %s\\n\",name)\n\n\tfmt.Printf(\"Age\\t: %d\\n\",*age)\n\n\t// Cara eksekusinya : go run flagnya.go -name=\"Alex Hendra\" -age=28\n}", "func main (a int ) {\r\n\r\n}", "func (node *Node) Param(vc *validation.Config, keys ...string) *Node {\n\n\tif len(keys) == 0 { panic(\"NO KEYS SUPPLIED FOR NEW PARAMETER\") }\n\n\tnode.RLock()\n\t\tp := node.Parameter\n\tnode.RUnlock()\n\tif p != nil {\n\t\treturn p\n\t}\n\n\tn := node.new(\"{\" + keys[0] + \"}\")\n\n\tvc.Keys = keys\n\n\tn.Lock()\n\t\tn.Validation = vc\n\t\tn.Validations = append(n.Validations, vc)\n\tn.Unlock()\n\n\tnode.Lock()\n\t\tnode.Parameter = n\n\tnode.Unlock()\n\n\treturn n\n}", "func (s *BaseSyslParserListener) EnterParam(ctx *ParamContext) {}", "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 (s *BasemumpsListener) EnterParam(ctx *ParamContext) {}", "func (s *BaseBrainfuckListener) EnterProgram(ctx *ProgramContext) {}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func SetParam(params ParamT, pname string, value string) int32 {\n\tcpname := C.CString(pname)\n\tdefer C.free(unsafe.Pointer(cpname))\n\tcvalue := C.CString(value)\n\tdefer C.free(unsafe.Pointer(cvalue))\n\treturn int32(C.yices_set_param(yparam(params), cpname, cvalue))\n}", "func (r *MachinePoolsAddRequest) Parameter(name string, value interface{}) *MachinePoolsAddRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\n}", "func Param(props *ParamProps, children ...Element) *ParamElem {\n\trProps := &_ParamProps{\n\t\tBasicHTMLElement: newBasicHTMLElement(),\n\t}\n\n\tif props != nil {\n\t\tprops.assign(rProps)\n\t}\n\n\treturn &ParamElem{\n\t\tElement: createElement(\"param\", rProps, children...),\n\t}\n}", "func Param(c context.Context, key string) string {\n\treturn C(c).Param(key)\n}", "func main() {\n\tfoo := \"\"\n\tshowCommand := flag.NewFlagSet(\"show\", flag.ExitOnError)\n\tshowCommand.StringVar(&foo, \"foo\", \"DEFAULT\", \"foo param\")\n\n\tif len(os.Args) == 1 {\n\t\tfmt.Println(\"go run flag-practice.go <COMMAND> [--foo=<FOO>]\")\n\t\treturn\n\t}\n\n\tswitch os.Args[1] {\n\tcase \"show\":\n\t\tshowCommand.Parse(os.Args[2:])\n\t\tfmt.Println(foo)\n\tdefault:\n\t\tfmt.Printf(\"%q is not valid command.\\n\", os.Args[1])\n\t\tos.Exit(2)\n\t}\n}", "func (r *ClusterPollRequest) Parameter(name string, value interface{}) *ClusterPollRequest {\n\tr.request.Parameter(name, value)\n\treturn r\n}", "func (r *ClusterUpdateRequest) Parameter(name string, value interface{}) *ClusterUpdateRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\n}", "func (d *KfDef) SetApplicationParameter(appName string, paramName string, value string) error {\n\t// First we check applications for an application with the specified name.\n\tif d.Spec.Applications != nil {\n\t\tappIndex := -1\n\t\tfor i, a := range d.Spec.Applications {\n\t\t\tif a.Name == appName {\n\t\t\t\tappIndex = i\n\t\t\t}\n\t\t}\n\n\t\tif appIndex >= 0 {\n\n\t\t\tif d.Spec.Applications[appIndex].KustomizeConfig == nil {\n\t\t\t\treturn errors.WithStack(fmt.Errorf(\"Application %v doesn't have KustomizeConfig\", appName))\n\t\t\t}\n\n\t\t\td.Spec.Applications[appIndex].KustomizeConfig.Parameters = setParameter(\n\t\t\t\td.Spec.Applications[appIndex].KustomizeConfig.Parameters, paramName, value)\n\n\t\t\treturn nil\n\t\t}\n\t}\n\n\t// Since an application with the specified name wasn't found check the deprecated componentParams\n\tif _, ok := d.Spec.ComponentParams[appName]; ok {\n\t\td.Spec.ComponentParams[appName] = setParameter(d.Spec.ComponentParams[appName], paramName, value)\n\t\treturn nil\n\t}\n\n\treturn &AppNotFound{Name: appName}\n}", "func (broadcast *Broadcast) ChangeDeveloperParam(ctx context.Context, creator string,\n\tparameter model.DeveloperParam, reason string, privKeyHex string, seq int64) (*model.BroadcastResponse, error) {\n\tmsg := model.ChangeDeveloperParamMsg{\n\t\tCreator: creator,\n\t\tParameter: parameter,\n\t\tReason: reason,\n\t}\n\treturn broadcast.broadcastTransaction(ctx, msg, privKeyHex, seq, \"\", false)\n}", "func OptParticipant() parameter.Parameter {\n\treturn Other(\"OPT-PARTICIPANT\")\n}", "func Parameter(key, value string) ReqOption {\n\treturn func(v url.Values) {\n\t\tv.Set(key, value)\n\t}\n}", "func (s *BaseLittleDuckListener) EnterPrograma(ctx *ProgramaContext) {}", "func ParamEx(paramData ParamData) *CXArgument {\n\tvar arg *CXArgument\n\tswitch paramData.paramType {\n\tcase PARAM_DEFAULT:\n\t\targ = Param(paramData.typCode)\n\tcase PARAM_SLICE:\n\t\targ = Slice(paramData.typCode)\n\tcase PARAM_STRUCT:\n\t\targ = Struct(paramData.pkg.Name, paramData.strctName, \"\")\n\t}\n\targ.Inputs = paramData.inputs\n\targ.Outputs = paramData.outputs\n\targ.Package = paramData.pkg\n\treturn arg\n}", "func (am *Manager) AddProgram(set ShaderSet, prog uint32) error {\n\tif _, ok := am.GetProgram(set); ok {\n\t\treturn fmt.Errorf(\"asset.Manager.AddProgram error: Program '%v' already exists\", set)\n\t}\n\n\tLogger.Printf(\"Manager: adding Program '%v'\\n\", set)\n\tam.Programs[set] = prog\n\n\treturn nil\n}", "func (args *Arguments) define() {\n\n\tflag.BoolVar(\n\t\t&args.Version,\n\t\t\"Version\",\n\t\tfalse,\n\t\t\"Prints the version number of this utility and exits.\",\n\t)\n\n\tflag.BoolVar(\n\t\t&args.Licence,\n\t\t\"Licence\",\n\t\tfalse,\n\t\t\"Prints the copyright licence this software is released under.\",\n\t)\n\n\tflag.BoolVar(\n\t\t&args.AllProblems,\n\t\t\"AllProblems\",\n\t\tfalse,\n\t\t\"Answer all problems for which there is code.\",\n\t)\n\n\tflag.UintVar(\n\t\t&args.Problem,\n\t\t\"Problem\",\n\t\t0,\n\t\t\"Numeric Id of problem as per Projecteuler.net\",\n\t)\n\n\tflag.BoolVar(\n\t\t&args.Concurrent,\n\t\t\"Concurrent\",\n\t\tfalse,\n\t\t\"Solves problems concurrently (may be faster)\",\n\t)\n\n\tflag.Usage = usageMessage\n\n\tflag.Parse()\n}", "func (s *BasePlSqlParserListener) EnterParameter_spec(ctx *Parameter_specContext) {}", "func TexParameteri(target, pname Enum, param int) {\n\tgl.TexParameteri(uint32(target), uint32(pname), int32(param))\n}", "func SetProcess(proc string) {\n process = proc\n}", "func (t Texture3D) SetParameter(paramName uint32, param int32) {\n\tt.Bind()\n\tgl.TexParameteri(gl.TEXTURE_3D, paramName, param)\n\tt.Unbind()\n}", "func (r *ManagedServicePollRequest) Parameter(name string, value interface{}) *ManagedServicePollRequest {\n\tr.request.Parameter(name, value)\n\treturn r\n}", "func (s *BasecluListener) ExitParam(ctx *ParamContext) {}", "func (s *BasemumpsListener) EnterProgram(ctx *ProgramContext) {}", "func UseProgram(program uint32) {\n\tC.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func UseProgram(program uint32) {\n\tC.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func parseProgramArgs() {\n\tLocalFolderPath = flag.String(\"l\", \".\", \"Path to local directory to open, default is '.'\")\n\tdpRestURL = flag.String(\"r\", \"\", \"DataPower REST URL\")\n\tdpSomaURL = flag.String(\"s\", \"\", \"DataPower SOMA URL\")\n\tdpUsername = flag.String(\"u\", \"\", \"DataPower user username\")\n\tpassword := flag.String(\"p\", \"\", \"DataPower user password\")\n\tdpDomain = flag.String(\"d\", \"\", \"DataPower domain name\")\n\tproxy = flag.String(\"x\", \"\", \"URL of proxy server for DataPower connection\")\n\tdpConfigName = flag.String(\"c\", \"\", \"Name of DataPower connection configuration to save with given configuration params\")\n\tDebugLogFile = flag.Bool(\"debug\", false, \"Write debug dpcmder.log file in current dir\")\n\tTraceLogFile = flag.Bool(\"trace\", false, \"Write trace dpcmder.log file in current dir\")\n\thelpUsage = flag.Bool(\"h\", false, \"Show dpcmder usage with examples\")\n\thelpFull = flag.Bool(\"help\", false, \"Show dpcmder in-program help on console\")\n\tversion = flag.Bool(\"v\", false, \"Show dpcmder version\")\n\n\tflag.Parse()\n\tsetDpPasswordPlain(*password)\n}", "func (s *BasevhdlListener) EnterActual_parameter_part(ctx *Actual_parameter_partContext) {}", "func (p *Parser)program() {\n\tp.declarations()\n\tp.begin()\n}", "func (r *ClusterGetRequest) Parameter(name string, value interface{}) *ClusterGetRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\n}", "func PrefabParameterFor(name string, description string) Parameter {\n\treturn ParameterFor(Prefab, name, description)\n}", "func (debugging *debuggingOpenGL) UseProgram(program uint32) {\n\tdebugging.recordEntry(\"UseProgram\", program)\n\tdebugging.gl.UseProgram(program)\n\tdebugging.recordExit(\"UseProgram\")\n}", "func (gl *WebGL) UseProgram(shaderProgram WebGLShaderProgram) {\n\tgl.context.Call(\"useProgram\", shaderProgram)\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 (p Parameter) viewParameter(viewrule bool) {\n\tfmt.Println(\"Parameter-----\")\n\tfmt.Println(\"Delay:\", p.Delay, \"Arity:\", p.Arity)\n\n\tfmt.Print(\"Transcript=\")\n\tfmt.Print(p.Transcript.Arr)\n\tfmt.Println(\"\")\n\n\tif viewrule {\n\t\tfmt.Println(\"Ruleset={\")\n\t\tfor b1 := 1; b1 <= 132; b1++ {\n\t\t\tr2s, ok := p.Rule.rule[strconv.Itoa(b1)]\n\t\t\tif ok {\n\t\t\t\tsort.Strings(r2s)\n\t\t\t\tfor _, r2 := range r2s {\n\t\t\t\t\tb2, ok2 := strconv.Atoi(r2)\n\t\t\t\t\tif ok2 == nil && b1 <= b2 {\n\t\t\t\t\t\tfmt.Println(\"(\" + strconv.Itoa(b1) + \",\" + strconv.Itoa(b2) + \"),\")\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tfmt.Println(\"}----end\")\n\t\t/*\n\t\t\tfmt.Println(\"Ruleset={\")\n\t\t\tfor b1, v := range p.Rule.rule {\n\t\t\t\tfor _, b2 := range v {\n\t\t\t\t\tfmt.Println(\" -(\", b1, b2, \")\")\n\t\t\t\t}\n\t\t\t}\n\t\t\tfmt.Println(\"}----end\")\n\t\t*/\n\t}\n}", "func (c *C) Param(name string) string {\n\treturn c.params.ByName(name)\n}", "func (r *ManagedServiceUpdateRequest) Parameter(name string, value interface{}) *ManagedServiceUpdateRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\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 inputParameter(parameter string) string {\n\treturn fmt.Sprintf(\"{{inputs.parameters.%s}}\", parameter)\n}", "func (c *Context) Param(name string) string {\n\treturn c.Params.Get(name)\n}", "func (r *ManagedServiceGetRequest) Parameter(name string, value interface{}) *ManagedServiceGetRequest {\n\thelpers.AddValue(&r.query, name, value)\n\treturn r\n}", "func main() {\n\tfmt.Println(\"Hello, World\")\n\t// Modify name, with argument:\n\tif len(os.Args) > 1 {\n\t\tfmt.Println(\"Hello \" + os.Args[1])\n\t} else {\n\t\tlog.Println(\"No argument has been given!\")\n\t}\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 init() {\n\tflag.StringVar(&name, \"name\", \"everyone\", \"The greeting object.\")\n}", "func (p *ctx) Param(key string) string {\n\tval, _ := p.ParamOk(key)\n\treturn val\n}", "func main() {\n\tobj := Constructor()\n\tparam := obj.Book(3, 5)\n\tparam = obj.Book(1, 4)\n\tfmt.Println(param)\n}", "func (p *ByName) processParam(loc *location.L, paramParts []string) {\n\tif p.AttrIsSet(SetOnlyOnce) && p.HasBeenSet() {\n\t\tp.ps.AddErr(p.name,\n\t\t\tloc.Error(fmt.Sprintf(\n\t\t\t\t\"This may only be set once but has already been set at %s\",\n\t\t\t\tp.whereIsParamSet[0])))\n\t\treturn\n\t}\n\n\tif p.AttrIsSet(IsTerminalParam) {\n\t\tp.ps.terminalParamSeen = true\n\t}\n\n\tvar err error\n\n\tswitch len(paramParts) {\n\tcase 1:\n\t\terr = p.setter.Set(paramParts[0])\n\tcase 2:\n\t\terr = p.setter.SetWithVal(paramParts[0], paramParts[1])\n\tdefault:\n\t\terr = fmt.Errorf(\"bad parameter: %q\", paramParts)\n\t}\n\n\tif err != nil {\n\t\tp.ps.AddErr(p.name, loc.Error(err.Error()))\n\t\treturn\n\t}\n\n\tp.whereIsParamSet = append(p.whereIsParamSet, loc.String())\n\n\tfor _, action := range p.postAction {\n\t\terr = action(*loc, p, paramParts)\n\n\t\tif err != nil {\n\t\t\tp.ps.AddErr(p.name, loc.Error(err.Error()))\n\t\t}\n\t}\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 (c *Context) Param(name string) string {\n\tfor i, n := range c.pnames {\n\t\tif n == name {\n\t\t\treturn c.pvalues[i]\n\t\t}\n\t}\n\treturn \"\"\n}", "func (debugging *debuggingOpenGL) GetProgramParameter(program uint32, param uint32) int32 {\n\tdebugging.recordEntry(\"GetProgramParameter\", program, param)\n\tresult := debugging.gl.GetProgramParameter(program, param)\n\tdebugging.recordExit(\"GetProgramParameter\", result)\n\treturn result\n}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n\tsyscall.Syscall(gpActiveShaderProgram, 2, uintptr(pipeline), uintptr(program), 0)\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 setParameterOverrides(app *argoappv1.Application, parameters []string) {\n\tif len(parameters) == 0 {\n\t\treturn\n\t}\n\tvar newParams []argoappv1.ComponentParameter\n\tif len(app.Spec.Source.ComponentParameterOverrides) > 0 {\n\t\tnewParams = app.Spec.Source.ComponentParameterOverrides\n\t} else {\n\t\tnewParams = make([]argoappv1.ComponentParameter, 0)\n\t}\n\tfor _, paramStr := range parameters {\n\t\tparts := strings.SplitN(paramStr, \"=\", 3)\n\t\tif len(parts) != 3 {\n\t\t\tlog.Fatalf(\"Expected parameter of the form: component=param=value. Received: %s\", paramStr)\n\t\t}\n\t\tnewParam := argoappv1.ComponentParameter{\n\t\t\tComponent: parts[0],\n\t\t\tName: parts[1],\n\t\t\tValue: parts[2],\n\t\t}\n\t\tindex := -1\n\t\tfor i, cp := range newParams {\n\t\t\tif cp.Component == newParam.Component && cp.Name == newParam.Name {\n\t\t\t\tindex = i\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif index == -1 {\n\t\t\tnewParams = append(newParams, newParam)\n\t\t} else {\n\t\t\tnewParams[index] = newParam\n\t\t}\n\t}\n\tapp.Spec.Source.ComponentParameterOverrides = newParams\n}", "func (native *OpenGL) GetProgramParameter(program uint32, param uint32) int32 {\n\tresult := int32(0)\n\tgl.GetProgramiv(program, param, &result)\n\treturn result\n}", "func (native *OpenGL) UseProgram(program uint32) {\n\tgl.UseProgram(program)\n}", "func (p *Porter) EditParameter(ctx context.Context, opts ParameterEditOptions) error {\n\tparamSet, err := p.Parameters.GetParameterSet(ctx, opts.Namespace, opts.Name)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tcontents, err := encoding.MarshalYaml(paramSet)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to load parameter set: %w\", err)\n\t}\n\n\teditor := editor.New(p.Context, fmt.Sprintf(\"porter-%s.yaml\", paramSet.Name), contents)\n\toutput, err := editor.Run(ctx)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to open editor to edit parameter set: %w\", err)\n\t}\n\n\terr = encoding.UnmarshalYaml(output, &paramSet)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to process parameter set: %w\", err)\n\t}\n\n\terr = p.Parameters.Validate(ctx, paramSet)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"parameter set is invalid: %w\", err)\n\t}\n\n\tparamSet.Status.Modified = time.Now()\n\terr = p.Parameters.UpdateParameterSet(ctx, paramSet)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to save parameter set: %w\", err)\n\t}\n\n\treturn nil\n}", "func (program Program) Use() {\n\tgl.UseProgram(uint32(program))\n}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func ParameterFor(source Source, name string, description string) Parameter {\n\treturn Parameter{\n\t\tSource: source,\n\t\tName: name,\n\t\tDescription: description,\n\t}\n}", "func (s *BaseCymbolListener) EnterFormalParameter(ctx *FormalParameterContext) {}", "func (s *BasemumpsListener) ExitParam(ctx *ParamContext) {}", "func (s *BaseEvent) ExistsParam( name string ) (bool) {\n _,ok:=s.execParams[name]\n return ok\n}", "func TexParameteri(target, pname GLEnum, param int32) {\n\tgl.TexParameteri(uint32(target), uint32(pname), param)\n}" ]
[ "0.62678206", "0.5989248", "0.56628054", "0.55927986", "0.5564994", "0.55450314", "0.53872466", "0.53594196", "0.5359206", "0.5330904", "0.5302828", "0.52861834", "0.52337784", "0.52323073", "0.52216554", "0.51981676", "0.51938117", "0.5186575", "0.5183584", "0.5181039", "0.51749694", "0.5168035", "0.5155057", "0.51510465", "0.51479506", "0.5146064", "0.5137623", "0.5098104", "0.5049507", "0.5040681", "0.5032442", "0.503004", "0.502734", "0.5018224", "0.50135773", "0.50118476", "0.5010649", "0.5002352", "0.4969727", "0.4965567", "0.49647352", "0.49629286", "0.49624792", "0.49619508", "0.49559122", "0.49542037", "0.49352348", "0.4916987", "0.49153754", "0.49105725", "0.49079755", "0.49027827", "0.49011412", "0.4898537", "0.48891866", "0.48768702", "0.4875866", "0.4868263", "0.48655018", "0.48595455", "0.48554265", "0.48554265", "0.48495692", "0.48407125", "0.48362714", "0.48344943", "0.48296976", "0.4827267", "0.48179492", "0.4817201", "0.48147035", "0.48081055", "0.47945702", "0.47919223", "0.4786908", "0.4773808", "0.4769169", "0.47676477", "0.47669318", "0.47555828", "0.47342312", "0.47311887", "0.47280762", "0.47253996", "0.4721574", "0.47201708", "0.47180706", "0.47180465", "0.47178644", "0.47177646", "0.47158656", "0.47062275", "0.47003192", "0.47000343", "0.46906075", "0.4689532", "0.4677398", "0.46757045", "0.46639115" ]
0.5767469
3
Specify the value of a uniform variable for a specified program object
func ProgramUniform1f(program uint32, location int32, v0 float32) { C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596244", "0.65417147", "0.6461359", "0.644842", "0.64406013", "0.6411922", "0.63519603", "0.6340269", "0.6338394", "0.631641", "0.630704", "0.6295751", "0.6286016", "0.6283217", "0.6257883", "0.6256306", "0.6242154", "0.61727124", "0.6163814", "0.61348826", "0.6133831", "0.6062144", "0.6036356", "0.60238934", "0.6019526", "0.5999546", "0.5993949", "0.5993949", "0.59912443", "0.59912443", "0.5970015", "0.59668493", "0.59668493", "0.59601575", "0.5951523", "0.5941418", "0.5941418", "0.5934123", "0.59340847", "0.59272635", "0.59272635", "0.5925408", "0.59216744", "0.5901728", "0.58857214", "0.58857214", "0.5883279", "0.5883279", "0.5883212", "0.5875172", "0.586362", "0.582998", "0.5828949", "0.58207005", "0.5807014", "0.58062696", "0.580162", "0.5798558", "0.5795985", "0.57942384", "0.57870764", "0.57870764", "0.5786004", "0.57720304", "0.5771651", "0.5768039", "0.5768039", "0.5767777", "0.5767777", "0.57662076", "0.57505685", "0.5745927", "0.5745927", "0.5737881", "0.57237256", "0.572228", "0.572188", "0.572188", "0.57115656", "0.57115656", "0.57029104", "0.5694383", "0.5694383", "0.56921077", "0.56837326", "0.56837326", "0.56562597", "0.56517005", "0.5643553", "0.5623654", "0.5623654", "0.56175387", "0.56167626", "0.56103224", "0.5587195", "0.55844986", "0.5583507", "0.55771756", "0.556309", "0.55570835", "0.55538654" ]
0.0
-1
Specify the value of a uniform variable for a specified program object
func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) { C.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.574635
72
Specify the value of a uniform variable for a specified program object
func ProgramUniform1i(program uint32, location int32, v0 int32) { C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.56845397
85
Specify the value of a uniform variable for a specified program object
func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) { C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.5787795
61
Specify the value of a uniform variable for a specified program object
func ProgramUniform1ui(program uint32, location int32, v0 uint32) { C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596244", "0.65417147", "0.6461359", "0.644842", "0.64406013", "0.6411922", "0.63519603", "0.6340269", "0.6338394", "0.631641", "0.630704", "0.6295751", "0.6286016", "0.6283217", "0.6257883", "0.6256306", "0.6242154", "0.61727124", "0.6163814", "0.61348826", "0.6133831", "0.6062144", "0.6036356", "0.60238934", "0.6019526", "0.5999546", "0.5993949", "0.5993949", "0.59912443", "0.59912443", "0.5970015", "0.59668493", "0.59668493", "0.59601575", "0.5951523", "0.5941418", "0.5941418", "0.5934123", "0.59340847", "0.5925408", "0.59216744", "0.5901728", "0.58857214", "0.58857214", "0.5883279", "0.5883279", "0.5883212", "0.5875172", "0.586362", "0.582998", "0.5828949", "0.58207005", "0.5807014", "0.58062696", "0.580162", "0.5798558", "0.5795985", "0.57942384", "0.57870764", "0.57870764", "0.5786004", "0.57720304", "0.5771651", "0.5768039", "0.5768039", "0.5767777", "0.5767777", "0.57662076", "0.57505685", "0.5745927", "0.5745927", "0.5737881", "0.57237256", "0.572228", "0.572188", "0.572188", "0.57115656", "0.57115656", "0.57029104", "0.5694383", "0.5694383", "0.56921077", "0.56837326", "0.56837326", "0.56562597", "0.56517005", "0.5643553", "0.5623654", "0.5623654", "0.56175387", "0.56167626", "0.56103224", "0.5587195", "0.55844986", "0.5583507", "0.55771756", "0.556309", "0.55570835", "0.55538654" ]
0.59272635
40
Specify the value of a uniform variable for a specified program object
func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) { C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.5994685
27
Specify the value of a uniform variable for a specified program object
func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) { C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.0
-1
Specify the value of a uniform variable for a specified program object
func ProgramUniform2fv(program uint32, location int32, count int32, value *float32) { C.glowProgramUniform2fv(gpProgramUniform2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.0
-1
Specify the value of a uniform variable for a specified program object
func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) { C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596244", "0.65417147", "0.6461359", "0.644842", "0.64406013", "0.6411922", "0.63519603", "0.6340269", "0.6338394", "0.631641", "0.630704", "0.6295751", "0.6286016", "0.6283217", "0.6257883", "0.6256306", "0.6242154", "0.61727124", "0.6163814", "0.61348826", "0.6133831", "0.6062144", "0.6036356", "0.60238934", "0.6019526", "0.5999546", "0.5993949", "0.5993949", "0.59912443", "0.59912443", "0.5970015", "0.59668493", "0.59668493", "0.59601575", "0.5951523", "0.5941418", "0.5941418", "0.5934123", "0.59340847", "0.59272635", "0.59272635", "0.5925408", "0.59216744", "0.5901728", "0.58857214", "0.58857214", "0.5883279", "0.5883279", "0.5883212", "0.5875172", "0.586362", "0.582998", "0.5828949", "0.58207005", "0.5807014", "0.58062696", "0.580162", "0.5798558", "0.5795985", "0.57942384", "0.57870764", "0.57870764", "0.5786004", "0.57720304", "0.5771651", "0.5768039", "0.5768039", "0.5767777", "0.5767777", "0.57662076", "0.57505685", "0.5745927", "0.5745927", "0.5737881", "0.57237256", "0.572228", "0.572188", "0.572188", "0.57115656", "0.57115656", "0.57029104", "0.5694383", "0.5694383", "0.56921077", "0.56837326", "0.56837326", "0.56562597", "0.56517005", "0.5643553", "0.5623654", "0.5623654", "0.56175387", "0.56167626", "0.56103224", "0.5587195", "0.55844986", "0.5583507", "0.55771756", "0.556309", "0.55570835", "0.55538654" ]
0.0
-1
Specify the value of a uniform variable for a specified program object
func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) { C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.0
-1
Specify the value of a uniform variable for a specified program object
func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) { C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.5941445
36
Specify the value of a uniform variable for a specified program object
func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) { C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.5885659", "0.5885659", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.58831745
47
Specify the value of a uniform variable for a specified program object
func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) { C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596244", "0.65417147", "0.6461359", "0.644842", "0.64406013", "0.6411922", "0.63519603", "0.6340269", "0.6338394", "0.631641", "0.630704", "0.6295751", "0.6286016", "0.6283217", "0.6257883", "0.6256306", "0.6242154", "0.61727124", "0.6163814", "0.61348826", "0.6133831", "0.6062144", "0.6036356", "0.60238934", "0.6019526", "0.5999546", "0.5993949", "0.5993949", "0.59912443", "0.59912443", "0.5970015", "0.59668493", "0.59668493", "0.59601575", "0.5951523", "0.5941418", "0.5941418", "0.5934123", "0.59340847", "0.59272635", "0.59272635", "0.5925408", "0.59216744", "0.5901728", "0.58857214", "0.58857214", "0.5883279", "0.5883279", "0.5883212", "0.5875172", "0.586362", "0.582998", "0.5828949", "0.58207005", "0.5807014", "0.58062696", "0.580162", "0.5798558", "0.5795985", "0.57942384", "0.57870764", "0.57870764", "0.5786004", "0.57720304", "0.5771651", "0.5768039", "0.5768039", "0.5767777", "0.5767777", "0.57662076", "0.57505685", "0.5745927", "0.5745927", "0.5737881", "0.57237256", "0.572228", "0.572188", "0.572188", "0.57029104", "0.5694383", "0.5694383", "0.56921077", "0.56837326", "0.56837326", "0.56562597", "0.56517005", "0.5643553", "0.5623654", "0.5623654", "0.56175387", "0.56167626", "0.56103224", "0.5587195", "0.55844986", "0.5583507", "0.55771756", "0.556309", "0.55570835", "0.55538654" ]
0.57115656
79
Specify the value of a uniform variable for a specified program object
func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) { C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *Shader) setUniform(name string, value int32) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n gl.Uniform1i(location, value)\n }\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n C.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n C.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n C.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n C.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform3fv(gpProgramUniform3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n C.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (u *Uniform) Bind() {\n\tif u.id < 0 {\n\t\tu.id = gl.GetUniformLocation(u.program, glString(u.name))\n\t\tif u.id < 0 {\n\t\t\tpanic(fmt.Errorf(\"glGetUniformLocation for \\\"%s\\\" (program %d) returned -1, GL error: %d\", u.name, u.program, gl.GetError()))\n\t\t}\n\t}\n\tswitch value := u.value.(type) {\n\tcase uint32:\n\t\tgl.Uniform1ui(u.id, value)\n\tcase []uint32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1uiv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2uiv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3uiv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4uiv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase int32:\n\t\tgl.Uniform1i(u.id, value)\n\tcase []int32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1iv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2iv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3iv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4iv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float32:\n\t\tgl.Uniform1f(u.id, value)\n\tcase []float32:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1fv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2fv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3fv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4fv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase float64:\n\t\tgl.Uniform1d(u.id, value)\n\tcase []float64:\n\t\tswitch len(value) {\n\t\tcase 1:\n\t\t\tgl.Uniform1dv(u.id, 1, &value[0])\n\t\tcase 2:\n\t\t\tgl.Uniform2dv(u.id, 2, &value[0])\n\t\tcase 3:\n\t\t\tgl.Uniform3dv(u.id, 3, &value[0])\n\t\tcase 4:\n\t\t\tgl.Uniform4dv(u.id, 4, &value[0])\n\t\tdefault:\n\t\t\tpanic(ErrUniformInvalidType)\n\t\t}\n\tcase mgl32.Mat2:\n\t\tgl.UniformMatrix2fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat3:\n\t\tgl.UniformMatrix3fv(u.id, 1, false, &value[0])\n\tcase mgl32.Mat4:\n\t\tgl.UniformMatrix4fv(u.id, 1, false, &value[0])\n\tcase *Texture:\n\t\tvalue.Bind(0) //TODO support multiple textures per-shader\n\t\terr := value.SetUniform(u.id)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase color.Color:\n\t\tr, g, b, a := toGLColor(value)\n\t\tgl.Uniform4f(u.id, r, g, b, a)\n\tdefault:\n\t\tpanic(ErrUniformInvalidType)\n\t}\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 Uniform1ui(location int32, v0 uint32) {\n C.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n C.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n C.glowProgramUniform1f(gpProgramUniform1f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform4i(program uint32, location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowProgramUniform4i(gpProgramUniform4i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n C.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform3uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform1uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform3fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform3fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform1uiv(gpProgramUniform1uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowProgramUniform3ui(gpProgramUniform3ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform4fv(gpProgramUniform4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform3uiv(gpProgramUniform3uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2i(program uint32, location int32, v0 int32, v1 int32) {\n C.glowProgramUniform2i(gpProgramUniform2i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform2uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tC.glowProgramUniform2ui(gpProgramUniform2ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform1fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\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 ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tC.glowProgramUniform1ui(gpProgramUniform1ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tsyscall.Syscall6(gpProgramUniform3ui, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\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 Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform2uiv(gpProgramUniform2uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform4ui(location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n C.glowUniform4ui(gpUniform4ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform1ui(program uint32, location int32, v0 uint32) {\n\tsyscall.Syscall(gpProgramUniform1ui, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n C.glowUniform3i(gpUniform3i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func Uniform2ui(location int32, v0 uint32, v1 uint32) {\n C.glowUniform2ui(gpUniform2ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1))\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 ProgramUniform2ui(program uint32, location int32, v0 uint32, v1 uint32) {\n\tsyscall.Syscall6(gpProgramUniform2ui, 4, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), 0, 0)\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpProgramUniform3i, 5, uintptr(program), uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0)\n}", "func ProgramUniform4iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform4iv(gpProgramUniform4iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform1iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tsyscall.Syscall(gpProgramUniform1i, 3, uintptr(program), uintptr(location), uintptr(v0))\n}", "func GetUniformfv(program uint32, location int32, params *float32) {\n C.glowGetUniformfv(gpGetUniformfv, (C.GLuint)(program), (C.GLint)(location), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tsyscall.Syscall6(gpUniform3i, 4, uintptr(location), uintptr(v0), uintptr(v1), uintptr(v2), 0, 0)\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform1iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform1iv(gpProgramUniform1iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tsyscall.Syscall6(gpProgramUniform3iv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func ProgramUniformMatrix3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3fv(gpProgramUniformMatrix3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func Uniform1ui(location int32, v0 uint32) {\n\tC.glowUniform1ui(gpUniform1ui, (C.GLint)(location), (C.GLuint)(v0))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform3i(program uint32, location int32, v0 int32, v1 int32, v2 int32) {\n\tC.glowProgramUniform3i(gpProgramUniform3i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2))\n}", "func ProgramUniform2iv(program uint32, location int32, count int32, value *int32) {\n C.glowProgramUniform2iv(gpProgramUniform2iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\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 ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n\tC.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tsyscall.Syscall6(gpProgramUniform4uiv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tsyscall.Syscall6(gpProgramUniform3f, 5, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)), uintptr(math.Float32bits(v1)), uintptr(math.Float32bits(v2)), 0)\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func Uniform3ui(location int32, v0 uint32, v1 uint32, v2 uint32) {\n\tC.glowUniform3ui(gpUniform3ui, (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func ProgramUniform3f(program uint32, location int32, v0 float32, v1 float32, v2 float32) {\n\tC.glowProgramUniform3f(gpProgramUniform3f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func Uniform1i(location int32, v0 int32) {\n\tsyscall.Syscall(gpUniform1i, 2, uintptr(location), uintptr(v0), 0)\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform3iv(program uint32, location int32, count int32, value *int32) {\n\tC.glowProgramUniform3iv(gpProgramUniform3iv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func ProgramUniform2f(program uint32, location int32, v0 float32, v1 float32) {\n C.glowProgramUniform2f(gpProgramUniform2f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func ProgramUniform1i(program uint32, location int32, v0 int32) {\n\tC.glowProgramUniform1i(gpProgramUniform1i, (C.GLuint)(program), (C.GLint)(location), (C.GLint)(v0))\n}", "func (debugging *debuggingOpenGL) Uniform1i(location int32, value int32) {\n\tdebugging.recordEntry(\"Uniform1i\", location, value)\n\tdebugging.gl.Uniform1i(location, value)\n\tdebugging.recordExit(\"Uniform1i\")\n}", "func ProgramUniform4fv(program uint32, location int32, count int32, value *float32) {\n\tsyscall.Syscall6(gpProgramUniform4fv, 4, uintptr(program), uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)), 0, 0)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func ProgramUniform4ui(program uint32, location int32, v0 uint32, v1 uint32, v2 uint32, v3 uint32) {\n\tC.glowProgramUniform4ui(gpProgramUniform4ui, (C.GLuint)(program), (C.GLint)(location), (C.GLuint)(v0), (C.GLuint)(v1), (C.GLuint)(v2), (C.GLuint)(v3))\n}", "func UintVar(p *uint, name string, value uint, usage string) {\n\tCommandLine.VarP(newUintValue(value, p), name, \"\", usage)\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 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 Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\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 Uniform3Int(location UniformLocation, v0, v1, v2 int32) {\n\tgl.Uniform3i(int32(location), v0, v1, v2)\n}", "func (native *OpenGL) Uniform3i(location int32, v0 int32, v1 int32, v2 int32) {\n\tgl.Uniform3i(location, v0, v1, v2)\n}", "func ProgramUniform1f(program uint32, location int32, v0 float32) {\n\tsyscall.Syscall(gpProgramUniform1f, 3, uintptr(program), uintptr(location), uintptr(math.Float32bits(v0)))\n}", "func (native *OpenGL) Uniform1i(location int32, value int32) {\n\tgl.Uniform1i(location, value)\n}", "func ProgramUniform4uiv(program uint32, location int32, count int32, value *uint32) {\n\tC.glowProgramUniform4uiv(gpProgramUniform4uiv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}" ]
[ "0.74596703", "0.6542257", "0.6461325", "0.64492404", "0.64413136", "0.64122504", "0.63523656", "0.6340831", "0.63384855", "0.6316857", "0.6307855", "0.6295642", "0.6285599", "0.6283731", "0.62582535", "0.6256287", "0.6242904", "0.61734796", "0.61641574", "0.61352617", "0.6134187", "0.6062273", "0.60368806", "0.6024162", "0.6019799", "0.5999256", "0.5994685", "0.5994685", "0.59918094", "0.59918094", "0.59701234", "0.59670734", "0.59670734", "0.59603465", "0.595128", "0.5941445", "0.5941445", "0.5934152", "0.59340155", "0.5928211", "0.5928211", "0.5925792", "0.59216046", "0.5901995", "0.58831745", "0.58831745", "0.5883113", "0.58758867", "0.586351", "0.58294696", "0.5828137", "0.5820565", "0.5807289", "0.5806582", "0.5802101", "0.5799118", "0.57952845", "0.57937264", "0.5787795", "0.5787795", "0.57860744", "0.57716167", "0.5771515", "0.57684743", "0.57684743", "0.5768209", "0.5768209", "0.5766295", "0.5750447", "0.574635", "0.574635", "0.57380235", "0.57239854", "0.57222235", "0.5721812", "0.5721812", "0.5711823", "0.5711823", "0.5702769", "0.5694582", "0.5694582", "0.569243", "0.56845397", "0.56845397", "0.56564677", "0.5651431", "0.5644162", "0.56241274", "0.56241274", "0.56176555", "0.5616514", "0.5610137", "0.558673", "0.5584317", "0.5583056", "0.557683", "0.5563395", "0.5557459", "0.55541074" ]
0.5885659
45