MCPcopy
hub / github.com/visgl/deck.gl / draw

Method draw

modules/layers/src/line-layer/line-layer.ts:171–189  ·  view source on GitHub ↗
({uniforms})

Source from the content-addressed store, hash-verified

169 }
170
171 draw({uniforms}): void {
172 const {widthUnits, widthScale, widthMinPixels, widthMaxPixels, wrapLongitude} = this.props;
173 const model = this.state.model!;
174 const lineProps: LineProps = {
175 widthUnits: UNIT[widthUnits],
176 widthScale,
177 widthMinPixels,
178 widthMaxPixels,
179 useShortestPath: wrapLongitude ? 1 : 0
180 };
181 model.shaderInputs.setProps({line: lineProps});
182 model.draw(this.context.renderPass);
183
184 if (wrapLongitude) {
185 // Render a second copy for the clipped lines at the 180th meridian
186 model.shaderInputs.setProps({line: {...lineProps, useShortestPath: -1}});
187 model.draw(this.context.renderPass);
188 }
189 }
190
191 protected _getModel(): Model {
192 /*

Callers

nothing calls this directly

Calls 2

setPropsMethod · 0.65
drawMethod · 0.65

Tested by

no test coverage detected