-
Notifications
You must be signed in to change notification settings - Fork 232
Project Structure
An Audiveris project gathers all OMR information related to a given Book, including the contained Sheet instances.
This project can be stored to disk as a project file and reloaded later. The project file is merely the result of the XML marshalling of a book and its sheets, hence there is no logical difference in the project structure in memory and on disk.
A project structure is specific to Audiveris software, but it is not opaque and is meant for public access, either via Audiveris API or by direct extraction of project XML fragments. Hence, project structure will be further described below, based on the concrete structure of a project file.
An Audiveris project file (a file with a ".omr" extension, dedicated to one Book
),
is nothing more than a Zip archive whose content can be easily browsed (and even modified at your
own risk...) via any Zip editor.
Its structure is merely a sequence of 3 kinds of XML files as follows:
File Name | Content |
---|---|
book.xml | Skeleton of book hierarchy. See book-xml |
book.xml | Skeleton of book hierarchy. See book-xml |
sheet#N/ | Specific folder for sheet #N |
sheet#N/ BINARY.xml | Run table of binarized image of sheet #N. See binary-xml |
sheet#N/ sheet#N.xml | OMR details of sheet #N. See sheet#N-xml |
To be able to handle books with more than a few sheets, we keep book-related top data in memory, while sheet "details" are loaded into memory only when they are really needed. In terms of Audiveris project file, this means that just the book.xml part is kept in memory, while the various sheet#N.xml are loaded on demand.
So, the physical and logical containments presented above are implemented as follows:
- A
Book
does not directly containSheet
's but only a sequence of SheetStub instances (or Stub for short) with a one-to-one relationship betweenSheetStub
andSheet
. - In a similar manner, a
Score
actually containsPageRef
's which refer toPage
's.
In the following class diagram, physical entities are displayed in blue, and logical entities in yellow.
On the left side, the "book.xml" artifact represents the content of the book.xml part within an
Audiveris project file, and is kept in memory.
Note that the Score
and PageRef
instances can exist only when GRID step has been reached on
(some sheets of) the book.
On the right side, the "sheet#N.xml" artifact represents one sheet (perhaps among others), pointed to from book.xml, and is not necessarily in memory.
[Just to avoid endless clashes with Java predefined System
class, we have chosen SystemInfo
as the class name to represent a music system]
Software licensed under the GNU Affero General Public License (AGPL) Version 3
© 2000-2023 Audiveris. Logo designed by Katka.