-
Notifications
You must be signed in to change notification settings - Fork 356
Promote sprite depth examples from experimental to main #2434
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
Conversation
* Stop trying to set the window's read-only clock value * Fix annoying indent on list at top of comments
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.
The window has a depth buffer by default, and spritelists innately support depth testing so this should be moved to examples
* Make the example subclass view * Use the same style found in other examples * Grab the context locally
Seems like this line is wrong:
You moved
Anyway I don't understand why you moved that attribute to the window. Just leave it in the view...no? |
I think this is what's wrong:
|
* Convert to View style * Make bg / clear color a Color defined at the top of the file * Use WINDOW_TITLE, WINDOW_WIDTH, and WINDOW_HEIGHT constants
* Add a screenshot for the example page and example gallery * Add an .rst file to reference the code and example * Add the .rst file to the examples gallery
* Add a screenshot for the page and gallery * Add an example .rst file for it * Add an entry in the examples page
@alejcas fixed |
The reason it wasn't moved into examples was a lingering issue related to the depth range. As far as I know the depth range set in the ortho projection is We could possibly change to to Including a new reasonable depth range would make things a bit more cleaner? |
It seems @DragonMoffon changed the range to The default depth range in arcade is -100 (near plane) / 100 (far plane). Higher value is further away from the camera. |
Can we add default near and far constants to make this more legible? |
For now I think it's enough to just mention the default range. |
I didn't actually choose this range myself. There was definitely a code snippet in Arcade that I based it on. I feel like it was the internal matrix gen, but it might have been one of the gl tutorials. In any case, in the depth example, it should probably be mentioned since it's directly settable in Camer2D's init |
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.
One last, very pedantic, change. Im otherwise happy for it to be merged.
|
|
View
example style