matrix to clipboard?
this is either impossible or i am not seeing the most obvious things.
when i implement a copy-and-paste function within the max runtime, i can use global places for data storage - and in many cases (named jit.matrix, buffer~, or coll objects) even just refer to the source or read it out from there.
max also can copy selected canvas content or selected text into the OS clipbard.
but is there a way how to copy from a jitter matrix to the OS clipboard? to copy-and-paste still images to photoshop?
i have reasons to avoid using the SSD/HDD and, unlike some other graphics apps, photoshop also wont support OSC networking or audio input or whatever could be abused to send data around.
Hi Roman,
AFAIK there's no built-in copy-and-paste function for jitter matrices.
If you need something similar, while staying in the Max domain, you can try with the object [grab]:
If wrapped around some scripting, it works pretty well:
the grab example is a fun idea, i like that.
for images smaller than my monitor i thought could maybe print it in a pwindow and then copy the pwindow object into the clipboard. this usually works for GUI externals and including they content (pictures, lcd...)
but it does not work for pcontrol, because you have to unlock the patch to copy and then the matrix ends up black (or did i do something wrong? yes, i know that in older jitter versions onscreen and no buffering was default.)
right now i am experimenting with making screenshots of the pwindow using jit.desktop. it can of course only write files. but this would be the right object to have it write to the OS clipboard...
and then there is the good old problem that you can not so easily produce "Command-C" programmatically.
otoh i came to the conclusion that using the clipboard for picture data has disadvantages i couldnt live with anyway: it would crop qualities higher than 8 bit and it eventually also applies compression.
a "send to" or "edit in" like present in many major applications would be great to have. of course i know that using max does _not mean working with image or text douments.
ah, i see.
Maybe you can experiment with the [shell] object and some terminal wizardry to programmatically take a snapshot of the portion of the screen you care about (retrieving the position and size of the object on screen) and copy it to the clipboard.
Or, if you want to copy the content of a jit.matrix, you can save the image and copy its content to the clipboard from the saved file.
Here there are some ways to do it:
https://superuser.com/questions/199285/how-to-copy-image-to-clipboard-to-paste-to-another-application
ok, i put using OSX services via shell on my todo list.
making sure that the pwindow always has the same location on the screen is no problem.
manually copying a pwindow ends up with a pasted picture which has 1 line too much at the bottom and one on top and therefore is 5 clicks alltogether (unlock max patch & 2 PS actions to remove the whites lines), while shell could be controlled programatically...
though even selecting an applescript or automator script from the applemenu will be fine.