I think i need to create some input level adjust editor etc. Maybe envelope detector treats noise as a signal from instrument - try to decrease signal volume or try different asio input. If this will not work, maybe it's a problem with thread locking
edit:
Hmm i tested layering stuff... and i think that all the code is weird
