Skip to content
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

Performance issues #24

Closed
Schroedingers-Cat opened this issue Oct 9, 2017 · 1 comment
Closed

Performance issues #24

Schroedingers-Cat opened this issue Oct 9, 2017 · 1 comment

Comments

@Schroedingers-Cat
Copy link
Contributor

Schroedingers-Cat commented Oct 9, 2017

I'm using Unity 2017.1.1 with the latest version of UnityOSC from github. The profiler reports 1,4ms execution time and 72KB GC allocation on my script, which I can trace back to the OSCHandler.Instance.SendMessageToClient() call. The function is being called three times per frame as I'm sending three parameter values out via OSC. See the screenshot for profiler details:
grafik

Unfortunately, having two instances of the script running in a scene doubles both, execution time and GC alloc, so this doesn't scale well. What can be done about this? Is this the expected behaviour or am I doing something wrong?

System is Win10x64 with an i5-3380M.

@jorgegarcia
Copy link
Owner

Hi @Schroedingers-Cat ,

To be honest, I haven't done any profiling on UnityOSC recently with latest Unity version, so I can't tell what should be ok numbers.

The library has some optimisations, but it hasn't been maintained since a while ago, so please feel free to carry out any optimisations you may need for your project and then do a pull request if you consider it.

I'm sorry I can't be of more help at the moment.

All the best,
Jorge

jorgegarcia added a commit that referenced this issue Nov 24, 2018
Improve performance of SendMessageToClient() calls (#24)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants