New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move context creation/query functions to gltools #1299
Conversation
// COMMON CONTEXT PARAMETERS | ||
// Attempt to allocate WebGL2 context | ||
webgl2: true, // Attempt to create a WebGL2 context (false to force webgl1) | ||
webgl1: true, // Attempt to create a WebGL1 context (false to fail if webgl2 not available) | ||
throwOnFailure: true, | ||
throwOnError: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there documentation that needs to be updated?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Never mentioned anywhere, never used anywhere. Just a ghost prop leftover from a prior refactor I'm guessing.
modules/webgl/src/index.js
Outdated
withParameters, | ||
isWebGL, | ||
isWebGL2 | ||
} from '@luma.gl/gltools'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the atom modules should avoid re-exporting APIs from their dependencies. Whoever importing these from the webgl module should switch to importing from gltools, so that we are perfectly clear where things live.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good to me.
createGLContext
,resizeGLContext
,instrumentGLContext
,getContextDebugInfo
,cssToDeviceRatio
,cssToDevicePixels
,isWebGL
,isWebGL2
isBrowser
,isBrowserMainThread
,isNode
,isElectron
,global
,window
,self
WebGL2RenderingContext
andImage
(are these used anywhere? luma.gl and deck.gl tests pass without them)throwOnError