MCPcopy Create free account
hub / github.com/cogentcore/core / Init

Method Init

vgpu/memory.go:78–86  ·  view source on GitHub ↗

Init configures the Memory for use with given gpu, device, and associated queueindex

(gp *GPU, device *Device)

Source from the content-addressed store, hash-verified

76
77// Init configures the Memory for use with given gpu, device, and associated queueindex
78func (mm *Memory) Init(gp *GPU, device *Device) {
79 mm.GPU = gp
80 mm.Device = *device
81 mm.CmdPool.ConfigTransient(device)
82 for bt := VtxIndexBuff; bt < BuffTypesN; bt++ {
83 mm.Buffs[bt] = &MemBuff{Type: bt, GPU: mm.GPU}
84 }
85 mm.Vars.Mem = mm
86}
87
88// Destroy destroys all vulkan allocations, using given dev
89func (mm *Memory) Destroy(dev vk.Device) {

Callers

nothing calls this directly

Calls 1

ConfigTransientMethod · 0.80

Tested by

no test coverage detected