User:D1-1/GSoC Progress

General Information
See User:D1-1/GSoC_Information for an overview of the project.

Progress Charts
This page has the latest charts and status reports: External Progress Page

In particular, see the Gantt chart for the approximate order in which I propose to tackle things.

Week 12 Status
'Pencils down'. Finished previous bugs & committed a fix for 'edit menu enabling' P2. Added documentation, effect testing script, and several new commands.

Mailing-list post: Gmane archive

Commit messages: 1 2 3 4 5 6 7 8 9 10

Week 11 Status
Mostly work on two P2 bugs - some progress towards proper fixes for each. Lots of discussion about 'white space' and how it should be treated by effects.

Mailing-list post: Gmane archive

Commit messages: 1 2 3 4 5 6 7

Week 10 Status
Further work on scripting before moving on to bug fixing.

Mailing-list post: Gmane archive

Commit messages: 1

Week 9 Status
Mostly work on scripting. Improved the way commands are built; added a command for calling menu commands; added a command for getting a list of available menu commands. Mod-script-pipe: fixed bug with long reponses. Numerous miscellaneous other changes to command system. Added module version check. Fixed playback indicator drawing bug.

Mailing-list post: Gmane archive

Commit messages: 1 2 3 4 5 6

Week 8 Status
Tried unsuccessfully to fix the Linux 'label undo crash' problem. Worked on getting EQ curve to be set properly in Batch chains. Proposed TrackArtist refactoring to facilitate work on 'find notes' - consensus is that we are too close to stable release to be comfortable with changing internals significantly, so a change of plan is required.

Mailing-list post: Gmane archive

Commit messages: 1 2 3 4 5

Week 7 Status
This week I continued to help track down and fix bugs. Also began planning for 'Find Notes' stage. Improved batch chains undo behaviour and solved P1 clipboard bug (with help from Michael)

Mailing-list post: Gmane archive

Commit messages: 1 2 3 4 5

Week 6 Status
I spent the first half of this week working on providing more structure for the command object system, and using it to create a screenshot command. The rest of the week has been spent working on fixing bugs.

For details see the mailing-list post:

Sourceforge archive

Gmane archive

Commit messages: 1 2 3 4 5 6 7 8 9

Next I will finish working on the bugs I've started, then move on to tackling further items from the release checklist.

Week 5 Status
Finished exams and now free to work full-time on Audacity. Changed the way command responses are delimited, (was discussed on list). Each set of response lines is now separated by a blank line, which makes things a bit easier for script-writers to handle. This also prevents a compiler warning.

Mailing-list post:

Gmane archive

Commit messages:

(The sourceforge archive seems to be behind, so here are GMane links.)

1 2 3

I'm currently looking at adding a command for taking screenshots, and after that I think I'll be moving on to mostly fixing bugs for a while.

Weeks 3 & 4 Status
A bit of a lull due to exams. Discovered reason for an exit crash in windows (due to my configuration) and fixed an assert problem with the batch chains GUI. Some planning/design regarding how to proceed with fitting scripting into the system for menu commands.

Mailing-list post:

Sourceforge archive

Gmane archive

Week 2 Status
Now the main thread can send responses back to the script thread via a new ResponseQueue class. This also prevents crashing if new commands are received whilst the previous one is still executing, since now the next commands are not read until the response has been returned.

Mailing-list post:

Sourceforge archive

Gmane archive

Commit messages: 1 2 3 4 5 6 7 8

Week 1 Status
This week I've been working on allowing commands coming from a script to be executed in the main thread, to avoid crashes when accessing the GUI. I've also tried to introduce some abstraction which leaves open the possibility of some refactoring of the BatchCommands system.

The relevant mailing-list post is here:

Sourceforge archive

Gmane archive

Commit messages are here: 1 23 4

See the mailing list post for further information.

Details of Planned Work
Here is a summary of the work I intend to carry out (not necessarily in chronological order).

Scripting Module
Completed
 * Provide a way for the script thread to delegate certain GUI actions (including display of error and progress dialogs) to the main thread

Completed
 * Provide a way for error messages to be returned to the script when necessary.

 JC: Mentors have confirmed that if this project goes ahead they do want this and by the mid term deliverables date.

Additional tasks, replacing 'Find Notes': Completed
 * Allow menu commands to be triggered by a script

Completed Completed Completed Completed
 * Provide commands for:
 * Getting a list of available menu commands
 * Setting the selection
 * Setting preferences
 * Getting start/end positions of a track

 DH: Yes - I've started such a page on this (main) wiki - but I'll be sure to expand, update and tidy it and put it in the manual. Completed.
 * And:
 * One page documenting how to use scripting on Audacity Manual Wiki ?

GA: I've now moved it to Scripting in the Manual and updated it so the links work.

It should apply each effect to a chirp and compare the result to a reference sample, and then display information about how long it took, whether it was successful, and whether the result contained noise/glitches. Completed (but doesn't check for glitches at the moment)
 * Produce a script for testing effects:

Completed (basic import/export commands, anyway) '' JC: Write script to collect all screenshots in the manual automatically surely would need to come first? Are scripted screenshots of menus, parameter entry in effects and preferences possible yet? I would see the upload as lying outside GSoC since the aforementioned would need to be done first.''
 * Other scripting features for which there is a demand.
 * For example it may be possible to use a script to investigate dropouts.
 * It might also be useful for scripts to have more control over import/export of audio (limited control already possible via the batch system)
 * Uploading collected screenshots to the manual wiki?

'' DH: Yes, fair point, that does need doing first - I was including the necessary scripting improvements under that general heading. Screenshots of the actual menus are not currently possible and neither are preferences tabs. Effect windows might work with a little tweaking.''

Track Views/Find Notes

 * Refactor TrackArtist so that different WaveTrack views are drawn by separate classes, and provide a composite view which allows alternative views of the same track to be shown alongside one another.


 * Optimise track drawing methods - for example, ensuring that buffered drawing is used and that analysis data is cached where it is beneficial - with the aim of making the more computationally intensive track views usable on less powerful machines.


 * Improve the Find Notes algorithm to make it useful for the purpose of musical transcription. It should work well enough to be able to identify notes and chords in a solo piano recording with reasonable accuracy, and to display this to the user clearly. Amongst other things, it will need to be able to vary the number of notes detected adaptively.


 * Fix the related bugs on the release checklist (e.g. P4 - Minimum and Maximum frequency settings don't work for Spectrum log(f) view)

Bugs
* P3 Jack problems I will investigate these once I've bought a new audio interface. It may or may not be practical to solve these problems, but I'll at least try to work out why they happen. * P3 Opening a second file while the first is playing causes hang This seems to only happen with particular ALSA playback devices which don't allow mixing

Did P2s instead (clip-joining/white-space, edit-menu-enabling, and EQ-batch-chains ones.)


 * P4 Linux build fails with EXPERIMENTAL_SCOREALIGN defined Not high priority and seems to be non-trivial


 * P3 Preferences dialog - clicking OK can sometimes cause a crash Crash was resolved by Leland (the other 'preferences OK' bug is still outstanding, but I can't reproduce that one)


 * Some failed assertions I encountered, including
 * Track.cpp(209) when deleting a label track (I think this must have been an instance of the general linux 'label-undo/delete' crash)
 * A wxWidgets problem in BatchProcessDialog (Solved)


 * P3 Desynchronisation problem when pasting with audio and a label track Solved by André (?)


 * P2 Labels should move appropriately when timeline-changing effects are applied Solved by André.


 * P3 Ensure tooltips are updated when language is changed in preferences


 * (Solved: many bugs that took priority over the planned ones; see progress reports for details)


 * Additional high-priority bugs from the checklist

'' JC: One of the GSoC requirements is (at the end) to submit a 'tarball' of code written. Please keep a folder with all your patches somewhere to make this step easy.''

 JC: If bugs on this list are solved by someone else, please note and add a bug of similar difficulty to the end of the list.

Optional Extras

 * Solve more of the issues from the release checklist or the 'not aiming' list.

(Screenshots - completed)
 * Further extend the capabilities of the scripting module, for example to allow automatic taking of screenshots.


 * Refactor or optimise other areas of the code, if it becomes apparent that this would be useful.


 * Allow transfer of detected notes to a MIDI track, export of note names, or of a MIDI file.


 * Provide a general way of allowing alternative colourings to be used in spectrum view and other places.

Midterm Status
Due to the time constraints imposed by my exams, the bulk of the work would necessarily be completed in the period after the midterm evaluation. My main deliverable for the midterm period would be enhancements to the scripting module. I would provide code for a module which works on at least the windows platform and allows a perl script to control import and export of wav files as well as application of effects, and returns an error message to the script if a command was not recognised. In addition I would provide fixes for at least three items from the release checklist.

Preliminary Work
The two main patches I submitted were:
 * A modification to TimeTextCtrl to ensure that the first non-zero digit is focused initially, rather than the first digit
 * A larger patch which refactored the generator effects and resolved a problem when the duration was zero

Additional Comments
My primary development platform is Arch Linux, but I can also test/develop on Windows XP if necessary. I have no way of tackling any Mac-only bugs, or other issues which I cannot reproduce for whatever reason.