embedding images into jitter?

Dec 7, 2013 at 2:33pm

embedding images into jitter?

Hello,

I’m very new to max and I have been trying to solve this problem…

I’ve made a patch which is set up to crossfade between 2 images using jit.xfade. (The fade is controlled by audio input.) I figured out how to embed the sound I want into the patch so that I don’t have to open the sound file every time I use the patch (with the embed 1 message), but I can’t seem to figure out how to do the same with the images. I know that it is possible to send a {read videoname.mov} message to embed a video file but I am using a JPG image file, rather than a video. Any suggestions?

Sorry if I am not explaining this clearly –I’m still working on learning the language around programming too!

Thanks for any help!

#275056
Dec 7, 2013 at 6:56pm

I don’t know about “embedding images” (other than using fpic and ticking embed in the inspector, but that won’t work here).

So I set up what I usually use for loading images into matrices. Basically, the “read” command will “read” in the last directory it read in (normally the same folder as the Max patch).

So just put your two images in the same folder as my max patch. Then, replace “read” and “read” messages with “read example1.jpg” and “read example2.jpg”. Other image formats will work too, just use the proper file type.

#275064
Dec 7, 2013 at 6:58pm

Note that I use a “loadbang” object to load the images every time the patch is opened. :) good luck with your project!

#275066
Dec 15, 2013 at 12:11pm

Hi, Thanks so much for your help!

#275788

You must be logged in to reply to this topic.