-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Using 32 index buffer for large Graphics #6417
Conversation
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.
OK, in this case, I think HAS_UINT32_INDEX is good to modify.
Co-Authored-By: Matt Karl <matt@mattkarl.com>
Co-Authored-By: Matt Karl <matt@mattkarl.com>
Codecov Report
@@ Coverage Diff @@
## dev #6417 +/- ##
=======================================
Coverage 78.33% 78.33%
=======================================
Files 57 57
Lines 2820 2820
=======================================
Hits 2209 2209
Misses 611 611 Continue to review full report at Codecov.
|
Totally agree, That’s a nice idea!
On Mon, 17 Feb 2020 at 23:25, Matt Karl ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In packages/core/src/context/ContextSystem.ts
<#6417 (comment)>:
> + const hasuint32
+ = (gl instanceof WebGL2RenderingContext)
+ || !!(gl as WebGLRenderingContext).getExtension('OES_element_index_uint');
+
+ if (!hasuint32 && settings.HAS_UINT32_INDEX)
+ {
+ /* eslint-disable max-len */
+
+ /* eslint-disable no-console */
+ console.warn('Provided WebGL context does not support 32 index buffer, large graphics may not render correctly');
+ /* eslint-enable no-console */
+
+ /* eslint-enable max-len */
+ }
+
+ settings.HAS_UINT32_INDEX = settings.HAS_UINT32_INDEX && hasuint32;
I think we should add an env state object either to core (or a new
package, or something in settings), that will be a collection of readonly
properties for users that can be set from within Pixi. This would contain
things like webgl/webgl2, has_uint32_index, max_textures, etc.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#6417>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAXX34RI67TEVR3XHC3CTPTRDMMFDANCNFSM4KWQFYDA>
.
--
Sent from Gmail Mobile
|
Much better! One small thing: Can you make the doc |
@eXponenta the reason to document |
Verification: https://jsfiddle.net/bigtimebuddy/wnqe2y7p/ |
I'd like to say a big thank you to everyone who worked on this (especially @eXponenta) and contributed their thoughts about how to improve the user experience here. o7 |
Follow up #6047, #6104, #6107
Implementing of https://github.com/pixijs/pixi.js/wiki/v5-Hacks#pixigraphics internally.
Upd:
Introducing
ContextSystem#supports
to store context parameters. Could be used for store MAX_TEXTURE_UNIT and other context specific parameters.npm run lint
)npm run test
)