MCPcopy
hub / github.com/EngoEngine/engo / updateScale

Method updateScale

common/render_shaders_blendmap.go:288–293  ·  view source on GitHub ↗
(bm Blendmap)

Source from the content-addressed store, hash-verified

286}
287
288func (s *blendmapShader) updateScale(bm Blendmap) {
289 engo.Gl.Uniform2f(s.uf_scaleFB, bm.Width()/bm.Fallback.Width(), bm.Height()/bm.Fallback.Height())
290 engo.Gl.Uniform2f(s.uf_scaleR, bm.Width()/bm.RChannel.Width(), bm.Height()/bm.RChannel.Height())
291 engo.Gl.Uniform2f(s.uf_scaleG, bm.Width()/bm.GChannel.Width(), bm.Height()/bm.GChannel.Height())
292 engo.Gl.Uniform2f(s.uf_scaleB, bm.Width()/bm.BChannel.Width(), bm.Height()/bm.BChannel.Height())
293}
294
295func (s *blendmapShader) Draw(ren *RenderComponent, space *SpaceComponent) {
296 bm, ok := ren.Drawable.(Blendmap)

Callers 1

DrawMethod · 0.95

Calls 2

WidthMethod · 0.65
HeightMethod · 0.65

Tested by

no test coverage detected