Stuff in Max4Live you wish you'd worked out ages ago….

Learn about building and using Max for Live devices.
S4racen
Posts: 5834
Joined: Fri Aug 24, 2007 4:08 pm
Location: Dunstable
Contact:

Stuff in Max4Live you wish you'd worked out ages ago….

Post by S4racen » Sat Nov 02, 2013 8:40 pm

When you open the information on an object (CMD + I) you can click on the colours and drag them to another object and choose what to change…

So many hours copying colour schemes saved!

Cheers
D

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Sat Nov 02, 2013 10:08 pm

In some situations, use a combination of 'uzi N' and live.object instead of N live.objects.
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

S4racen
Posts: 5834
Joined: Fri Aug 24, 2007 4:08 pm
Location: Dunstable
Contact:

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by S4racen » Sun Nov 03, 2013 8:32 am

chapelier fou wrote:In some situations, use a combination of 'uzi N' and live.object instead of N live.objects.
Interesting, when would you do this?

Cheers
D

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Sun Nov 03, 2013 10:03 am

i am sure this must be obvious to you. But for instance when you want to get a series of properties.

<pre><code>
----------begin_max5_patcher----------
565.3ocwV9sjaBBEF+Z8ofgoW5lQLI9mdWeN5zwAUZBaMnifot6N66dgCZ2M
oF0scp4hDBGN.e7yCewWbcvYUcLIF8YzWQNNu353.gLAb566fOQ6xKoRHMrf
8yprGwd1gTrNEDVgxP7gn0TU9Qt3PZCKWYW7cga78PD+XnYefoIveiO5a8yo
pUUxTpmpY1IfynhCXODlKzKwPVh1SbgNOPKj2BZmMDMnOJu.DlVrOP1NnruW
ITB5IXOveogSKe+HR9yvHDs7LQe0007k2BQyIlTROv9C1nwwQTI+LKUxTHUC
M+GRzmHSPKRTBvocDnYqOzDOEttAiBFkQjQXTvpvnaT9XnyFCmV.T1CM62Oe
Ijo7A97Qpe1NBa7uq0OGzUM0kzmL3PVVoR4hBV27W15qdBR9+W8jbOKdd.M4
cIsYydOTL37rE98zUM21vYw3H5dhi1m4HR3DDwBjPqoBIY4VwyaIGrzqTau6
tM5ALDY1aQw1lH+E327OV17WXA2GVROyJRsGoTpR0vyZU1+X242rwAmVyZjb
ohIxsq.DGf5.ZgiflPhqes.fPl3WxaYUaS9..5sBPuwnBlTwETEuR7tbBtHm
i7hBFL7vwofKoYkLfLi+beopIZApw75AqjbL6TvLxIZ0TyUG7wkSx5JGxbOr
VuZmq1panG+0SO9KfOAWjyxki8dOst9rwhvtjfRzNpOV0X5F5Ac4BaWv.C2v
NyGxeGDg1ncRUZin1FqAVWbH10rOu59KUWt26C
-----------end_max5_patcher-----------
</code></pre>
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

Myralfur
Posts: 114
Joined: Wed Feb 18, 2009 4:53 am
Location: London, England
Contact:

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by Myralfur » Mon Nov 04, 2013 4:06 am

once you've set a property for a [live.observer] to observe, every time you send an id to its right inlet it will start observing the property in the new id. you don't need to send the new id and then property each time, this actually makes it send out the value twice, making loads of things later in the programming happen twice.

if you are using a [live.observer] to observe one property, which will always be the same even if the id you're focused on is different, it is worth writing the property into the object. i.e. [live.observer value] and then just send an id to the right inlet to start it observing and change what id it is focused on.

Myralfur
Posts: 114
Joined: Wed Feb 18, 2009 4:53 am
Location: London, England
Contact:

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by Myralfur » Mon Nov 04, 2013 4:11 am

@S4racen

also, check this out if you get a chance :), think it might be of use to you... if i can explain what it does usefully anyway.

----------- quick copy paste from another thread below --------------

i've been working on a max for live device to simplify and centralise communication with the live api within a live set. you might be interested in it.

basically it's a device that on initialisation gets all of the ids and properties of objects within the live object model. it stores all the ids and values of properties in a master dictionary named "m4lc-hub" which you can access from other m4l devices. the ids and values are all stored in a dictionary hierarchy exactly the same as the live object model hierarchy.

for example, if you want to get the id of a clip slot in m4l you send a [live.path] the message "path live_set tracks 0 clip_slots 0". to do the same with the "m4lc-hub" dictionary you send the message "get live_set::tracks::0::clip_slots::0::id". so quite similar. it has "id" on the end as "m4lc-hub" dictionary stores more than just ids and you might want to get the value of a property, such as "get live_set::tracks::0::mute" to get if the track is muted.

it observes as many of the properties as it can without using up to many resources... it would be possible to build a device that observes every clip slot for clips, and every device parameter value in the entire set, but would it be practical, i'm not so sure.

it's currently going through a refresh to use the awesome new dictionaries in max 6, instead of lots of coll and var objects, as it did before. but i previously used it to make clip launchers and other max for live devices that do a lot of api stuff much simpler and quicker to build.

have a look around if you like, let me know what you think or if you have any questions. i'm interested to see if other m4l programmers would be interested in it, and if i should make a brief tutorial video and documentation.

Download for the device, the current version and a tester version with comments and examples in the user interface:

Version 11:
https://www.dropbox.com/s/ynfuejqa6j2bs ... 20v11.amxd

Tester Example:
https://www.dropbox.com/s/66pgm4fiv2a0e ... %20v1.amxd

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Mon Nov 04, 2013 7:56 am

Myralfur wrote:once you've set a property for a [live.observer] to observe, every time you send an id to its right inlet it will start observing the property in the new id. you don't need to send the new id and then property each time, this actually makes it send out the value twice, making loads of things later in the programming happen twice.

if you are using a [live.observer] to observe one property, which will always be the same even if the id you're focused on is different, it is worth writing the property into the object. i.e. [live.observer value] and then just send an id to the right inlet to start it observing and change what id it is focused on.
That's really helpful, and actually explains a weirdness that i couldn't figure out !
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Mon Nov 04, 2013 6:33 pm

Myralfur wrote: if you are using a [live.observer] to observe one property, which will always be the same even if the id you're focused on is different, it is worth writing the property into the object. i.e. [live.observer value] and then just send an id to the right inlet to start it observing and change what id it is focused on.
Well, i gave it a try without any luck. This doesn't work for instance :
<pre><code>
----------begin_max5_patcher----------
488.3oc2T1riaBCD.9L7TX4yzHL4mR5s1WipUHC3l3sDaj8.MaWsu60dLjca
JEQhT2C8hMdlwyOeLieNNhVpOKrTxmHekDE8bbTDJxKHZ3bD8D+bUC2hlQOI
rV9AAMInCDmATdqQ2JLvSDE+zEssbn5nTcnvHpfPT9X5pzjg0bbksaUJ4gga
HqQuoKe7CYYit4aZEft0q5yFIug7EcS8nZU2IopQ.XBl8l6Xk+DuCyGmK1p6
fQiYCRChfmZEgjjRIO307RbreIYgrQI9gKw+CzzH6EqzkVgoWXVFeXoaBaLb
KeZBwx+mSnr+JgRPJMn1x6E0EtbxUGEb.LxxNHzXEcAVQzBWKhUZAgpJDVTN
R4ak0N+CZ0LfjscqmcaPBlkNtNEG2OImX2VKSIWc39ZatZjZhZY8drMX8N+1
1YmZ17+zPiCEGI9uJrBf.Fd02sjzY+om4gyt7.ule54dHE6VH05YGdRtlXXR
5Jb00uHiEpW9uiQqtyTM5xwWLIuVq0BKHUbP5lSd0H+iFuwnix5ZAperFpkV
dYi.AU5j+PWZ9bUnlNebMrD16S5rT579jN6WR5bm+qBsR711d+CtAWhIha16
QswebWBdTpBGwFapQzKGseCJgabyXfa.qyDFPNmuiF6iyKw+B3avrGJ
-----------end_max5_patcher-----------
</code></pre>
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

Myralfur
Posts: 114
Joined: Wed Feb 18, 2009 4:53 am
Location: London, England
Contact:

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by Myralfur » Mon Nov 04, 2013 7:14 pm

just tried a quick test, this is working fine for me:

<pre><code>
----------begin_max5_patcher----------
803.3oc6XlraaCCDF9r7SAgPO5XvEs1a44nnv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5_patcher-----------
</code></pre>

also if you have a look through "M4LC Hub" you'll see all of the live.observers in there are used in this way.

Because789
Posts: 440
Joined: Thu Apr 28, 2011 1:26 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by Because789 » Mon Nov 04, 2013 7:26 pm

Hmm, your patch doesn't work here Myralfur. I get the appropriate id of the tracks, but the observers rest silent.

Just made some tests with chapeliers patch and it looks like I have to send "property name" once to the observer and only then it spits out the names when the id changes...
Live 9.5 (64bit), Max 7.0.6, Windows 10, Push 2, Korg electribe2, Bass Station II, Launch Control XL, Faderfox DJ3

M4L

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Mon Nov 04, 2013 7:30 pm

That's weird...
i got plenty of things like this happening these days : i doesn't work in edit mode, but if i save the device it's working perfectly.
Is it the same for you ? That's really annoying to have to save and close the patch to have it working...
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Mon Nov 04, 2013 7:32 pm

Yep, exact same thing here, Because789.
Can you try saving it and see ?
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

Because789
Posts: 440
Joined: Thu Apr 28, 2011 1:26 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by Because789 » Mon Nov 04, 2013 7:42 pm

Works as expected when I save it...
Live 9.5 (64bit), Max 7.0.6, Windows 10, Push 2, Korg electribe2, Bass Station II, Launch Control XL, Faderfox DJ3

M4L

chapelier fou
Posts: 6021
Joined: Mon May 15, 2006 12:15 pm

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by chapelier fou » Mon Nov 04, 2013 7:47 pm

@S4racen :
So sorry to mess up this topic as soon as it started... Great idea btw !
MacBook Pro 13" Retina i7 2.8 GHz OS 10.13, L10.0.1, M4L.
MacStudio M1Max 32Go OS 12.3.1

Myralfur
Posts: 114
Joined: Wed Feb 18, 2009 4:53 am
Location: London, England
Contact:

Re: Stuff in Max4Live you wish you'd worked out ages ago….

Post by Myralfur » Mon Nov 04, 2013 8:27 pm

ah you're right, very weird.

the code i pasted above worked fine when i wrote it, but if i paste it back in it no longer works, then if i save the device it starts working again...

i think we may have found a bug...

Post Reply