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

Method AddValidationLayer

vgpu/gpu.go:187–194  ·  view source on GitHub ↗

AddValidationLayer adds given validation layer, only if not already set returns true if added.

(ext string)

Source from the content-addressed store, hash-verified

185// AddValidationLayer adds given validation layer, only if not already set
186// returns true if added.
187func (gp *GPU) AddValidationLayer(ext string) bool {
188 i := FindString(ext, gp.ValidationLayers)
189 if i >= 0 {
190 return false
191 }
192 gp.ValidationLayers = append(gp.ValidationLayers, ext)
193 return true
194}
195
196// Config configures the GPU given the extensions set in InstanceExts,
197// DeviceExts, and ValidationLayers, and the given GPUOpts options.

Callers 1

ConfigMethod · 0.95

Calls 1

FindStringFunction · 0.85

Tested by

no test coverage detected