MCPcopy Index your code
hub / github.com/gre/gl-react / nodeWidthHeight

Function nodeWidthHeight

packages/gl-react/src/Node.tsx:107–114  ·  view source on GitHub ↗
(
  { width, height }: Props,
  { glSizable }: SurfaceContext
)

Source from the content-addressed store, hash-verified

105 obj && typeof obj === "object" && obj.type === "TextureSize";
106
107const nodeWidthHeight = (
108 { width, height }: Props,
109 { glSizable }: SurfaceContext
110): [number, number] => {
111 if (width && height) return [width, height];
112 const [cw, ch] = glSizable.getGLSize();
113 return [width || cw, height || ch];
114};
115
116const mapBlendFunc = (
117 gl: WebGLRenderingContext,

Callers 2

_syncNextDrawPropsMethod · 0.85
getGLSizeMethod · 0.85

Calls 1

getGLSizeMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…