my own personal requests for the editor

Send us your feedback or ask for features.
joebataz
Regular
Posts:154
Joined:28 Feb 2012 16:50
Location:Anthem, AZ USA
Contact:
Re: my own personal requests for the editor

Post by joebataz » 19 Nov 2012 15:48

analog604,

Hmmm, I remember trying that and never getting anything but red script. But if that does work it would sure as heck cut down on script size and let me go larger with amount of steps. I've had to drop to 32 steps JUST because of script limits so this would get me up to where I really want to be.
----------DISCLAIMER!!! DON'T TRY THIS UNLESS YOU'RE COMFORTABLE WITH .jzml STRUCTURES IN LEMUR----------
Because of the size of my app I do very little in the Lemur script editor. With all due respect it just isn't powerful enough for me to do the kind of scripting my app requires so I use a text editor to edit the .jzml file itself. I'm on a Mac so I use BBEdit which also gives me the power of editing with GREP. It can get a little tedious flipping back and forth because Lemur definitely DOESN'T LIKE when you're editing a file it has open. So I have to quit Lemur, do my big edits, close the file in the editor and then open it in Lemur. Searching works fine though. As long as you don't edit you can open the .jzml file that you're working on in Lemur. Find what you're looking for, and then close the file. Then you can go edit in Lemur. Working like this has proven to be a Godsend and I have saved literally months of time working like this. Plus since I use lots of arrays I can easily flip between whole array sets just by keeping copies of the app preloaded with different array sets.
A word to the wise! BACKUP, BACKUP, BACKUP!!!!

Thanks again for the tip about the references. I didn't seem to be able to get it to work but am going to give it another CLOSE look.

joeb

analog604
Regular
Posts:262
Joined:29 Dec 2011 15:40
Location:north east, usa

Re: my own personal requests for the editor

Post by analog604 » 19 Nov 2012 16:33

Yeah there are a few tricks to learn there with the indirect object ref's.
It will be best to edit those right in Lemur because you can see right away what it will accept.

You can even access elements of an array on the other side of an object.

so... you can pass a ref to an object and operate upon it's array elements with a single script instead of rewriting/copying loads of times.

but using something like:

myObjArray[ELEMENT].Text1

Won't work properly until you build a single obj ref variable:

decl finalRef=myObjArray[ELEMENT];
finalRef=finalRef.Text1;
//so now this works:
setattribute(finalRef,'content','Text Update')
//where this wouldn't have (grrrrrr!!!!)
//setattribute(myObjArray[ELEMENT].Text1,'content','Text Update')
And thus can be used in a loop

Same rules for getattribute.

You can also work on a target array, either by getting a copy of it using getexpression or simply by using the reference.

Here I operate on a multibyte synthesizer patch in Lemur denoted by variable 'p'.
Its controls are contained within array object tloc={knob1,knob2,knob3,fader1,fader2}
and its scaling is set in array object isc={127,127,1,1,127,..whatever max MIDI is for that control}

srcObj is the object reference to the currently focused control set (like an Oscillator or Envelope section). Each target object contains a 'p', 'tloc', 'isc' established prior to calling this:

//Update all controls of synth section from p[] patch array and scale (array isc[]) for proper knobs/fader display:
decl sz=sizeof(srcObj.p),x;
for(x=0;x<sz;x++) setexpression(srcObj.tloc[x],'x',srcObj.p[x]*srcObj.isc[x]);

so that one idea with some planning basically allowed me to remove about a hundred
messy lines of If..then..else from my older templates

At first it's a bit of a pain to figure out how to properly implement but once you know the rules you'll do fine!

cheers~
J
joebataz wrote:analog604,

Hmmm, I remember trying that and never getting anything but red script. But if that does work it would sure as heck cut down on script size and let me go larger with amount of steps. I've had to drop to 32 steps JUST because of script limits so this would get me up to where I really want to be.
----------DISCLAIMER!!! DON'T TRY THIS UNLESS YOU'RE COMFORTABLE WITH .jzml STRUCTURES IN LEMUR----------
Because of the size of my app I do very little in the Lemur script editor. With all due respect it just isn't powerful enough for me to do the kind of scripting my app requires so I use a text editor to edit the .jzml file itself. I'm on a Mac so I use BBEdit which also gives me the power of editing with GREP. It can get a little tedious flipping back and forth because Lemur definitely DOESN'T LIKE when you're editing a file it has open. So I have to quit Lemur, do my big edits, close the file in the editor and then open it in Lemur. Searching works fine though. As long as you don't edit you can open the .jzml file that you're working on in Lemur. Find what you're looking for, and then close the file. Then you can go edit in Lemur. Working like this has proven to be a Godsend and I have saved literally months of time working like this. Plus since I use lots of arrays I can easily flip between whole array sets just by keeping copies of the app preloaded with different array sets.
A word to the wise! BACKUP, BACKUP, BACKUP!!!!

Thanks again for the tip about the references. I didn't seem to be able to get it to work but am going to give it another CLOSE look.

joeb
Dashboard gear control templates: User 112 Idx :: LModIt Lite :: SVG image converter for Lemur Canvas

joebataz
Regular
Posts:154
Joined:28 Feb 2012 16:50
Location:Anthem, AZ USA
Contact:

Re: my own personal requests for the editor

Post by joebataz » 21 Nov 2012 03:46

Nope! Still can't get it to work. Here's how I'm setup:

3 global vars txBank, txPre, txTime.
txBank = ['LB0','LB1',...'LB31']
txPre and txTime are set up in the same way.

I want to set the color of the LB0 text field. A_CurFrame is a global that holds the current step in the sequence.
So I tried
setattribute(txBank[0],'color',12886);

NOPE, tried

decl k,pt = txBank[0];
pt = pt.color;
k=12886;
setattribute(pt,'color',k);

NOPE. The scripts show no error (no red). So either I missing something in the translation or ???????????? I am honestly baffled by how it works for you but not for me. Maybe it only works with content? I also don't understand what Text1 is or what ELEMENT is.

TIA,

joeb

joebataz
Regular
Posts:154
Joined:28 Feb 2012 16:50
Location:Anthem, AZ USA
Contact:

Re: my own personal requests for the editor

Post by joebataz » 21 Nov 2012 04:40

HOLD THE PHONE there sparky! "Check the scope you moron!" he said looking in the mirror.......

THIS works:
setattribute(findobject(txBank[A_CurFrame]),'color',12886);

thanks analog604, especially for all the code I NOW HAVE TO RIP OUT!!!!

just KIDDING.....
but seriously I think I can now go the full 128 steps that I originally wanted.

And THANKS analog604, REALLY!

BR

joeb

Macciza
Regular
Posts:1325
Joined:07 Dec 2011 04:57
Location:Sydney, Australia.

Re: my own personal requests for the editor

Post by Macciza » 21 Nov 2012 11:55

Hi
I was actually going to mention 'scope' as a possible issue . .
Oh and [ELEMENT] is 'index' into the array most likely . . .
Might have to look at doing up some 'Lemur Recipes' . . .

Cheers
MM
iMac 2.8G i7 12G 10.6.8/10.7.2, Legacy Dexter/Lemur, Liine Lemur/iPad2, KMI SoftStep, 12Step & QuNeo , B-Controls, Mackie C4 etc
MaxMSP, Live Suite, Native Instrument stuff, etc Modified Virtual Guitar System etc All Projects/Modules © CC-BY-NC-SA[*][/b]

joebataz
Regular
Posts:154
Joined:28 Feb 2012 16:50
Location:Anthem, AZ USA
Contact:

Re: my own personal requests for the editor

Post by joebataz » 21 Nov 2012 12:50

Macciza,

Now that's a heck of a good idea! I know starting out with Lemur I felt so clueless sometimes (actually I still do) especially when getting the concept of frames and time through my thick skull. There is SO much good code laying around in so many different places that we need a centralized repository, NO DISCUSSIONS, JUST CODE with comments on what it does. This last little exchange with analog604 has been enormously valuable and I'm sure would be of just as much value to a lot of others. But that's just IMNSHO.
BTW, nice talking to y'all again. With the holidays here in the US it's been a little busy for me but I need to make more time to spend on the forum. Lemur has just been such a huge help to my business that quite honestly I don't know what I would have done over the past few months without it and picking up ideas like this last one is going to save me lots of time and code.

best regards to all!

joeb

lewisedwards
Regular
Posts:72
Joined:26 Dec 2011 22:11

Re: my own personal requests for the editor

Post by lewisedwards » 07 Dec 2012 11:46

here are 2, one of which i had no idea about.

• to allow create alias on containers, which would obviously contain objects that all need to be aliased at the same time.

this one is a bit much though, but worth asking. but if not, i completely understand ;)
• to have a video feedback window. feeding from max/jitter or whatever environment. would not be amazing quality, but just something to give an indication of what is happening in certain patches.
lewis edwards
------
smokingbunny.co.uk

lewisedwards
Regular
Posts:72
Joined:26 Dec 2011 22:11

Re: my own personal requests for the editor

Post by lewisedwards » 07 Dec 2012 11:58

• making alias' of monitor and text has made it practically unreadable. using monitor with max to read in tempo, it completely mucks with it in the worst possible way. so other pages make it hard to read, but the original is fine
lewis edwards
------
smokingbunny.co.uk

Macciza
Regular
Posts:1325
Joined:07 Dec 2011 04:57
Location:Sydney, Australia.

Re: my own personal requests for the editor

Post by Macciza » 07 Dec 2012 14:14

Hi Lewis

Container aliasing is certainly in the future somewhere, the video later still,
Not sure exactly what you mean about the monitor/text alias but if you have something reproducable send it to support
iMac 2.8G i7 12G 10.6.8/10.7.2, Legacy Dexter/Lemur, Liine Lemur/iPad2, KMI SoftStep, 12Step & QuNeo , B-Controls, Mackie C4 etc
MaxMSP, Live Suite, Native Instrument stuff, etc Modified Virtual Guitar System etc All Projects/Modules © CC-BY-NC-SA[*][/b]

joebataz
Regular
Posts:154
Joined:28 Feb 2012 16:50
Location:Anthem, AZ USA
Contact:

Re: my own personal requests for the editor

Post by joebataz » 07 Dec 2012 14:39

I'm also confused about what monitor aliasing is. My biggest issue is still bigger fonts on pads. Gets difficult to read text under changing lights and 64 pads. Number 2 is still a better editor, where cut/copy/paste works between external editors and Lemur. But all in all my Lemur app is totally irreplaceable now in my system with the sequencer functioning. I have added another iPad and my iPhone now runs the lasers.

joeb

Post Reply