// Package glib was automatically generated by github.com/bnema/puregotk DO NOT EDIT package glib import ( "github.com/ebitengine/purego" "github.com/bnema/puregotk/pkg/core" ) var xSpacedPrimesClosest func(uint) uint // Gets the smallest prime number from a built-in array of primes which // is larger than @num. This is used within GLib to calculate the optimum // size of a #GHashTable. // // The built-in array of primes ranges from 11 to 13845163 such that // each prime is approximately 1.5-2 times the previous prime. func SpacedPrimesClosest(NumVar uint) uint { cret := xSpacedPrimesClosest(NumVar) return cret } func init() { core.SetPackageName("GLIB", "glib-2.0") core.SetSharedLibraries("GLIB", []string{"libgobject-2.0.so.0", "libglib-2.0.so.0"}) var libs []uintptr for _, libPath := range core.GetPaths("GLIB") { lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) if err != nil { panic(err) } libs = append(libs, lib) } core.PuregoSafeRegister(&xSpacedPrimesClosest, libs, "g_spaced_primes_closest") }