Wickedlasers / Laser_OS_TouchDesigner

32 stars 1 forks source link

Severe lags, crashes, frame drops. #10

Open Nullifier opened 3 years ago

Nullifier commented 3 years ago

Hello. I'm continuously getting crashes or 3-10 fps in viewport when enabling Laser output inside LaserOS CHOP, even if there is no incoming signal and nothing is drawn. When Laser output is disabled everything is smooth.

Sometimes it was working fine in 60 fps, fully functional. Then it could decide to drop fps to 30 and keep it like that. Sometimes it could get back to 60 fps when OP create dialog was open (TAB). This all is really weird behavior. I just worked on a project which was tracing a finger with a Leap Motion controller. But suddenly it became unusable and I can't even start the project, TD freezes on 100% loading. I can only open Backups that have Laser output disabled.

Plugin version 0.0.3 TD version 2020.41040 Windows 10 i7 4930k RTX 2070 Super 32GB Ram

Please let me know if there is a solution. Thanks.

tgreiser commented 3 years ago

Disable laser output and view 'Info' for the CHOP you are feeding in. For 0.0.3 should should be sending 500 samples/frame at 30,000 samples/sec.

Start/End - ... (500i) Sample Rate - 30000 samples/sec

Some CHOPs can change the number of samples in your signal chain, like Merge CHOP for example if you don't change the parameters. Sending too many samples is the most likely culprit. I couldn't say for sure without looking at a .toe example.

Nullifier commented 3 years ago

These are my stats. On input, there are 2 constants for x and y set to 0. After I turn on the laser, TD freezes. 20k and 30k samples.

TouchDesigner_2020-11-28_22-15-24 TouchDesigner_2020-11-28_22-15-38

tgreiser commented 3 years ago

Your CHOP network is sending 2 frames worth of samples every frame (2f). Send half as many points per frame as you currently are.

Nullifier commented 3 years ago

I tried different approaches, disabling Realtime option in TD seems to fix it. But the image out of the laser is not stable anyway and framerate too. Maybe you can check the project? Thank you. https://we.tl/t-p6VnanICwE

Nullifier commented 3 years ago

Hello. I think I solved the problem, I switched my monitor to the second GPU, and (2f) problem disappeared. Not sure why it mattered but anyway that works. Thank you for your prompt response and help with the problem!