Click here to Skip to main content
15,508,890 members

Comments by stephen.hazel (Top 8 by date)

stephen.hazel 30-Sep-10 0:39am View    
shared memory = memory mapped file - an actual file (uses sys paging file).
I've got a test program and storing the threadids in a memory mapped file (minus file:) and PostThreadMessage()ing works great. and is about as fast as you can possibly get.

and i'm pretty sure than any equivalent solution will use these things underneath (like pipes, dll shared mem block, etc)
stephen.hazel 29-Sep-10 18:11pm View    
How come I can't #Quote#accept#Quote# my own answer ??
stephen.hazel 29-Sep-10 18:08pm View    
Wow Steve, that works pretty darn good!
I can't imagine a better way to share memory across processes than windows shared memory.
And I can't imagine any faster way to message than PostThreadMessage (it does work across processes, BTW).

So I think I'm set, Steve - thanks again for your help!

(ok, sorry for annoyin' everyone, but when things WORK, it's a good day!!)
stephen.hazel 29-Sep-10 12:57pm View    
I think this uses mem mapped files per Jeff Richter's book.
But it does send a message and I need some way for this
to be message based. I wonder if there's some way to wait on a mem mapped file change.
I know there's a way to wait on regular os file changes..
well, time to go hit ole msdn again :/
stephen.hazel 29-Sep-10 12:54pm View    
well, the sequencer and synth are guaranteed to be on the same box.
so i'd =think= there'd be a more direct way than sockets, eh?