From 057c804e636c93b5e9f3fc989770ece355c2e235 Mon Sep 17 00:00:00 2001 From: "N.N." Date: Thu, 1 Nov 2012 11:00:32 +0000 Subject: updating help file svn path=/trunk/externals/share_mem/; revision=16504 --- shmem-help.pd | 70 ++++++++++++++++++++++++++++++++++------------------------- 1 file changed, 40 insertions(+), 30 deletions(-) diff --git a/shmem-help.pd b/shmem-help.pd index 6e72876..34f2101 100644 --- a/shmem-help.pd +++ b/shmem-help.pd @@ -1,4 +1,4 @@ -#N canvas 271 434 821 482 10; +#N canvas 122 50 1009 468 10; #N canvas 1 89 450 300 (subpatch) 0; #X array array2 100 float 3; #A 0 0.257142 0.285713 0.314285 0.357142 0.371428 0.385714 0.4 0.414285 @@ -16,14 +16,11 @@ -0.571435 -0.600007 -0.614292 -0.628578 -0.628578 -0.628578 -0.642864 -0.642864; #X coords 0 1 99 -1 200 140 1; -#X restore 580 194 graph; -#X floatatom 62 382 5 0 0 0 - - -; -#X msg 93 128 memset 0 1 1 1 1 1; -#X text 225 122 write a list (or a float) to the shared memory : 1st +#X restore 680 26 graph; +#X msg 53 288 memset 0 1 1 1 1 1; +#X text 185 282 write a list (or a float) to the shared memory : 1st value is index \, other are data to store; -#X msg 147 288 memdump \$1; -#X floatatom 147 269 5 0 0 0 - - -; -#X msg 62 63 memset 0 array1; +#X msg 22 223 memset 0 array1; #N canvas 0 22 450 300 (subpatch) 0; #X array array1 100 float 3; #A 0 -0.87857 -0.864284 -0.849998 -0.835713 -0.835713 -0.807141 -0.792856 @@ -41,27 +38,40 @@ value is index \, other are data to store; 0.749998 0.77857 0.807141 0.821427 0.849998 0.878569 0.878569 0.907141 0.907141 0.921427 0.964284; #X coords 0 1 99 -1 200 140 1; -#X restore 579 31 graph; -#X msg 114 159 memset 100 5 5 5 1 1 0.1 0.2 0.3 0.4 0.5 0.6 0.7; -#X text 176 63 set shared memory from index 0 with array1; -#X msg 78 93 memset 0 array1 50; -#X text 206 93 set shared memory from index 0 with array1 from index +#X restore 475 26 graph; +#X msg 74 319 memset 100 5 5 5 1 1 0.1 0.2 0.3 0.4 0.5 0.6 0.7; +#X text 136 223 set shared memory from index 0 with array1; +#X msg 38 253 memset 0 array1 50; +#X text 166 253 set shared memory from index 0 with array1 from index 50; -#X obj 62 355 shmem 1214 250; -#X text 218 288 read one float of the table send value to the outlet +#X obj 22 375 shmem 1214 250; +#X text 132 375 1st argument : Identifiant of the memory segment; +#X text 21 15 shmem - shared memory manipulation; +#X text 22 37 The shmem object allow to use shared memory in Pd. It +is useful for example to exchange array between two instances of Pd. +Every shmem object can read and write to a shared memory segment that +is identified by its Id.; +#X text 21 95 When you create a shmem object \, it checks its Id. If +the id is not used \, it allows a new segment \, otherwise it address +the exisiting segment.; +#X msg 584 343 memdump \$1; +#X floatatom 584 318 5 0 0 0 - - -; +#X obj 568 371 shmem 1214 250; +#X text 655 343 read one float of the table send value to the outlet ; -#X text 61 421 You can read / write in the same share memory using -diferent pd instances; -#X text 61 15 shmem allow share memory manipulation; -#X text 172 355 1st argument : Identifiant of the memory segment; -#X text 172 371 2nd argument : size of the segment; -#X msg 131 237 memdump 0 array2; -#X text 251 237 write share memory (index 0) to a table; -#X connect 2 0 12 0; -#X connect 4 0 12 0; -#X connect 5 0 4 0; -#X connect 6 0 12 0; -#X connect 8 0 12 0; -#X connect 10 0 12 0; -#X connect 12 0 1 0; -#X connect 18 0 12 0; +#X msg 568 292 memdump 0 array2; +#X text 21 192 WRINTING INTO MEMORY; +#X text 563 201 READING MEMORY; +#X floatatom 568 395 5 0 0 0 - - -; +#X text 688 292 dump shared memory from index 0 to array2; +#X text 21 146 Work only on Linux / and Unix.; +#X text 132 391 2nd argument : size of the segment (number of float) +; +#X connect 1 0 9 0; +#X connect 3 0 9 0; +#X connect 5 0 9 0; +#X connect 7 0 9 0; +#X connect 14 0 16 0; +#X connect 15 0 14 0; +#X connect 16 0 21 0; +#X connect 18 0 16 0; -- cgit v1.2.1