Giter VIP home page Giter VIP logo

Comments (6)

davepagurek avatar davepagurek commented on June 30, 2024 1

Right, I guess the rule would be, set the camera before you draw the content?

Also, we have this PR basically ready to start testing as soon as we're done making quick docs releases for the website release: #6761 I think after this change, since the camera and model transform matrices will not be merged into a single variable, we actually might not need to reset at all, since we'll be able to discern what part came from transforms vs what part came from the camera. So maybe the thing to do is to wait until we can merge and test to see if that refactor fixes this for us? (The reason for the wait is that it's a pretty big change to a core part of the rendering algorithm, which I think warrants a beta testing period before release, which we've been skipping for our expedited docs releases.)

from p5.js.

nickmcintyre avatar nickmcintyre commented on June 30, 2024

@davepagurek would this approach also affect/reset transformations applied elsewhere in code?

from p5.js.

davepagurek avatar davepagurek commented on June 30, 2024

I think it would only affect transforms if you're calling setCamera in the middle of draw rather than in setup or in an event handler. But if you were previously calling setCamera mid-draw, arguably the resulting things you draw wouldn't have been in the correct spot anyway since they wouldn't be using the camera's transform yet?

from p5.js.

nickmcintyre avatar nickmcintyre commented on June 30, 2024

As long as the reference is clear about where/when to call setCamera() I think we're good. This test case is a little contrived but it surprised me.

from p5.js.

nickmcintyre avatar nickmcintyre commented on June 30, 2024

Agreed that beta testing for this kind of change is a good call.

from p5.js.

davepagurek avatar davepagurek commented on June 30, 2024

Just put up #7067 with something that augments #6761 so that only the view matrix updates when you change cameras. We can play around with that and see if there are any situations that would cause issues

from p5.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.