GraphEditor.DrawGrid fix performance

NodeCanvas Forums General Discussion GraphEditor.DrawGrid fix performance

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #12660
    psykaw
    Participant

    Hello,

    I have huge perfomance issues cause by GraphEditor.DrawGrid so I rewrited the DrawGrid function which have execution time divided by 10:
    Replace in GraphEditor.cs DrawGrid function by this piece of code:

    Of course @Gavalakis you can use it for next update if you want!

    #12666
    Gavalakis
    Keymaster

    Hello,

    Indeed the grid function was way too slow because of many lines drawn and being part of the zoom group.
    I have already changed the way it works to be faster, but of course also using GL directly is probably going to be further better as well, so thank you for that!
    What version of unity is this code on? I am asking because it seems that the method “s_applyWireMaterialMethod” can not be found.

    Thank you!

    Join us on Discord: https://discord.gg/97q2Rjh

    #12671
    psykaw
    Participant

    Oh :(. So try something like that:

    It should works!

    #12676
    Gavalakis
    Keymaster

    Thanks for the follow up!

    Join us on Discord: https://discord.gg/97q2Rjh

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.