You are here

the rescale bug

Hi there,
I'm using Ubuntu 16.04 64bit with Qtractor 0.7.1, editing MIDI notes, so the "rescale bug" I've found might be already known.
If so, sorry for having posting this and wasting your time. Please delete this Post.

Rescale bug: The rescale functionality (Midi Tools) just works in relation to the first note of a selection.
So, if you shorten the notes of four bars 50% with the first note at the very first position of the first bar, the tool works well and you'll get two bars with halved notes. But if you shorten another four bar selection with the first note at the very first position of the second bar, only the last three bars are halved, while the first bar stays 100%. - This obviously can desynchronize a whole song. The rescale function should work in relation to the complete selected sector, not just in relation to the first note of the selection.

And: Copy your four bars and paste them a few bars later into the same track. If you now select the copied bars for rescaling, the whole track is rescaled, not just the selection. And furthermore you cannot use the undo button then. It takes back the last step, but doesn't show the old state. If you still click undo, it works normal and as expected. If you then click the redo button, qtractor completely crashes.

regards,
borla

Forums: 
rncbc's picture

i'm having some difficulty to reproduce this bug as you report, even while using older v0.7.1 as you say.

please give some more details, most importantly what your MIDI clip editor > Tools > Rescale... settings are (Time, Duration and/or Value?).

assuming you're trying to Rescale > Time, i shall say that it indeed applies relative to the earliest or first note-on time of the selection. and yes, there's a bug on there, that manifests if you, for instance, just unselect some early notes and apply rescale to the remaining selection--it seems that the earlier unselected notes are still anchored there. the bug doesn't manifest if you redo the selection from scratch. is that it?

byee

Hi rncbc,
I just updatet to 0.7.9 without change. - You can reproduce this way:
1. Define two new Midi busses
2. Make two new Tracks (Midi)
3. Track1: Make a new clip. 4 bars. A quarter note at the beginning of every bar.
4. Track2: Make a new clip. 4 bars. A quarter note at the beginning of bar 3 and 4.
5. Press Ctrl + A to select all.
6. Use > Midi Tools > Rescale > Time 50% Duration 50% Value 100% (no change; or also 50% doesn't matter).
7. Track1 shrinks to two bars with eights notes, while Track2 just shrinks to three bars with eights notes. Bar 1 of Track2 stayed 100% and the notes are desynced (in relation to the proper shrinked Track1).
8. Undo.
9. Ctrl + A and Ctrl + C and Ctrl + V the selection to the right, some bars later.
10. Mark the copied new clip and again try a 50% rescale.
11. Now not just the marked area is rescaled, but the whole track. And you now can not undo.

Cheers,
borla

rncbc's picture

aha. you're doing it all from the main tracks view (main menu Clip > Tools > Rescale...). i was trying instead on individual clips to their MIDI clip editor alone (menu Tools > Rescale...).

and yes, i can confirm that on the second clip, the one that first note isnn't at beginning of the clip, gets it somewhat mistaken on the anchor time reference. let me tell this is not a bug in it's own sense, in fact, it's all working as signed: although, on the main view you actually see a course selection, which spans over the a clip region, for the MID tools it actually means about the events are selected directly as it would happen on each MIDI clip editor on it's own, so that on each clip, the earliest event that get's inside the selection range, is indeed the anchor reference for Time rescaling... the issue you're observing is that this starting event most probably isn't on the very same on-set time and so, time rescaling might get skewed across several tracks.

the other issue, that goes for the copy/paste, is still under investigation, but the thing you shall be acquainted is about when copy-pasting whole MIDI clips, the copies are said linked or, in other words, they represent the very same MIDi file track/channel contents. You can unlink those copies via, you guess, menu Clip > Unlink. With v0.7.9+ you can also get some visual evidence that two or more clips are linked: you click on one and the linked others are shown with a dashed light-blue outline.

and yes, just confirmed the loss of undo. investigation's still an on going process... thanks for all the details.

byee

Hi Rui,
I appreciate all your q-works very much and I am glad that I can help.
Well, to be precise, the first note of the second track originally matches with the third note of the first track.
After rescaling, it should not be at the clip's beginning, but it should match with the third note of track1 again.
Rescaling doesn't work because the empty area (track 2, bar 1 and 2) stays at 100% instead of also being shortened 50%.
Rescaling bar 1 and 2 of track2 to 0% (to get the first note at the beginning of the clip) would also be a fault.

Yes, I saw the linking lines. But have they been in version 0.7.1 too? I can't remember...

Anyway, I'm shure you'll fix all that.

All the best,
borla

rncbc's picture

Yes, I saw the linking lines. But have they been in version 0.7.1 too? I can't remember...

no, the lines weren't on previous versions than last v0.7.9, but the linking were already there for ages :)

cheers

I can confirm the following:
8...
9. Ctrl + A and Ctrl + C and Ctrl + V the selection to the right, some bars later.
10. Ctrl + A and > Clip > Split. - Allthough all clips are selected, this doesn't split all clips. I had to repeat this to split all clips reliable.
11. Select (range) just the copied clips and rescale time and duration 50%. - Now correct: Just the selection is rescaled and undo works.

Small issue:
1. > View > Options > General. Mark new session template. Define a template and restart qtractor. Now try to delete your definition - You can't confirm, because the OK button is greyed out.

rncbc's picture

10. Ctrl + A and > Clip > Split. - Allthough all clips are selected, this doesn't split all clips. I had to repeat this to split all clips reliable.

Clip > Split is meant to work on sub-clip selections or regions; it doesn't do anything on whole clips selection as from Ctrl+A (Select All) or when Edit > Select Mode > Clip is on; Clip > Split is most effective when either Edit > Select Mode > Range or Rectangle are on and you do sub-clip selections.

Small issue: 1. > View > Options > General. Mark new session template. Define a template and restart qtractor. Now try to delete your definition - You can't confirm, because the OK button is greyed out.

what you mean by "delete your definition" ? isn't it enough to turn off/uncheck "New session template" ?

seeya

Split just for sub-clip sections: I didn't knew that... - But wouldn't it be a useful feature to have the possibility to unlink a whole song, all tracks, all clips at once? (Imagining a situation where a composer has an old complex project, lost overview about the linkings and now wants to rearrange the complete composition)

Yes, that has been unclear - "Delete your definition" does not mean deleting the qtr file, but deleting just the written line in the new session template field.
And yes, you're right: uncheck it, is best to disable a template. It's a matter of habit that you can click an OK button, as soon as you change something in a field. Even though it might be nonsense like leaving a field blank. - My first thought was "Oops! I can not completely delete what I wrote! But leaving a field blank used to be a normal state that one can confirm. I did it a hundred times when filling out forms at the internet. The programmer don't want me to be enabled to do that."
I like to be free to do nonsense ;-)

(from a programmers point of view: Isn't it easier to define "all allowed conditions" for an OK button, then "all allowed conditions except a blank field"?
Or in other words: Isn't a blank field an allowed condition for an OK button?
It might be nonsense to allow the user to delete his writings complete, but if it's a worldwide habit, shouldn't it be enabled?
Moreover: Don't you waste hours of lifetime answering enerverating "My OK button isn't working!" comments?)

live long and prosper :-)

PS: I should do a song entitled "The world loves working OK buttons" :-))

rncbc's picture

Isn't a blank field an allowed condition for an OK button?

it is not just about a blank field: the field in question is actually a file ptah/name and it *must exist* on the file-system to be a valid entry and thus the Ok button to be enabled.

cheers

rncbc's picture

hi, maybe you'd like to know that latest git head (master branch), now being v0.7.9.135+, may address some, if not all, your original questions

please lend some time to test, no hurry, no worry, chicken curry ;)~

seeya

Hi Rui, that's good...
I'm glad that I could help to make qtractor a little bit better...
I hope you don't mind about my humorous style in my last posting.
I was just trying to be funny. I didn't want to upset you.

all the best

Add new comment