groimp-platform:gs-project
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
groimp-platform:gs-project [2024/12/16 14:29] – [Project design and main files] gaetan | groimp-platform:gs-project [2025/01/22 15:54] (current) – Tim | ||
---|---|---|---|
Line 7: | Line 7: | ||
To simplify: | To simplify: | ||
* a Project is the set of resources that enables to open an entity that can be processed by GroIMP. | * a Project is the set of resources that enables to open an entity that can be processed by GroIMP. | ||
- | * a Workbench is the set of windows that enables the user to use the project. A workbench is created around a project. Even in [[: | + | * a Workbench is the set of windows that enables the user to interact with the project. A workbench is created around a project. Even in [[: |
Note for developers, a GroIMP project is slightly different from the code implementation of a [[https:// | Note for developers, a GroIMP project is slightly different from the code implementation of a [[https:// | ||
Line 15: | Line 15: | ||
A project requires three files to be openable in GroIMP: | A project requires three files to be openable in GroIMP: | ||
- The **project registry**: Named // | - The **project registry**: Named // | ||
- | - The **Graph**: Named // | + | - The **Graph**: Named // |
- | - The | + | - The **Java resources file**: Named // |
+ | |||
+ | Note that: | ||
+ | - the **project registry** and the **graph** can be renamed as long as their references are also renamed. | ||
+ | - The project can be compressed into a .gsz file. In that case, the three files (and all other resources) are contained in the .gsz file. | ||
==== Project registry (GS) ==== | ==== Project registry (GS) ==== | ||
+ | |||
+ | The project registry is a XML file. It hold the mapping between the project resources and the GroIMP way to load them (Which java classes, which parameters, ...). | ||
+ | |||
+ | It's minimal content is: | ||
+ | |||
+ | <code xml> | ||
+ | <?xml version=" | ||
+ | <project xmlns=" | ||
+ | </ | ||
+ | |||
+ | The first line describe the xml format. Then the second line is the main tag of the file: ''< | ||
+ | |||
+ | An actual registry project look like: | ||
+ | |||
+ | <code xml> | ||
+ | <?xml version=" | ||
+ | <project xmlns=" | ||
+ | <!-- The list of required groimp plugin for running the project --> | ||
+ | < | ||
+ | < | ||
+ | |||
+ | <!-- All the registry items required to be loaded --> | ||
+ | < | ||
+ | <!-- List of the projects objects (Here we only have one file, but shaders, images, ... would be listed here as well) --> | ||
+ | < | ||
+ | < | ||
+ | <ref name=" | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | ... | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | </ | ||
+ | |||
+ | </ | ||
+ | </ | ||
==== Project graph ==== | ==== Project graph ==== | ||
- | ==== Compressed project | + | The current state of the project graph. It is a XML file as well. It is a slightly more complete version of the graph you can see in the 2d graph panel (panels> |
+ | - The **main graph**: it is the graph build by the queries, rules, and objects insertions. This is the graph manipulated by the user. | ||
+ | - The **meta graph**: A graph containing additional meta information. For instance it includes the resources nodes (e.g. shaders). | ||
+ | |||
+ | Note that despite being called both //graph//, they are more // | ||
+ | |||
+ | The minimal content of the **graph** is: | ||
+ | |||
+ | <code xml> | ||
+ | <?xml version=" | ||
+ | <graph xmlns=" | ||
+ | </ | ||
+ | |||
+ | The first line is the required xml description. The second contains the main tag of the file: ''< | ||
+ | |||
+ | An actual **graph** | ||
+ | |||
+ | <code xml> | ||
+ | <?xml version=" | ||
+ | |||
+ | <!-- The first root: the meta graph --> | ||
+ | < | ||
+ | <data gx: | ||
+ | <node id=" | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | <!-- The second root --> | ||
+ | < | ||
+ | <data gx: | ||
+ | <node id=" | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | Notice that, with this representation, | ||
==== Java resources file ==== | ==== Java resources file ==== | ||
+ | The third required file to open a project. It follow the same definition as the java [[https:// | ||
+ | |||
+ | It cannot be renamed or moved. It needs to be '' | ||
+ | |||
+ | This is a simple text file that list the files used in the project including the **project registry** and **graph** file. | ||
+ | |||
+ | A simple example of its content is: | ||
+ | < | ||
+ | Name: project.gs | ||
+ | Content-Type: | ||
+ | |||
+ | Name: Model.rgg | ||
+ | Content-Type: | ||
+ | |||
+ | Name: graph.xml | ||
+ | Content-Type: | ||
+ | </ | ||
+ | |||
+ | Each file is mapped with its name and a MimeType (i.e. the explicit type of the file. Several files could have the same extension but be processed differently). | ||
+ | |||
+ | |||
+ | |||
+ | ==== Compressed project (GSZ) ==== | ||
+ | |||
+ | A project can be compressed into an archive. The standard GroIMP extension is .gsz, but is is a simple archive. Any .zip, 7z, or other archive format would work (as long as you rename the extension .gsz). | ||
+ | |||
+ | The archive contains all the content of the project. It can be viewed, modified, or extracted with any archive tools on you computer. | ||
+ | |||
+ | Note that: | ||
+ | * GroIMP requires the archive extension to be .gsz. | ||
+ | * The archive need to follow the same compression order as a java package. Thus, if you want to compress the project manually you need to include first the META-INF directory. | ||
+ | |||
+ | For instance to compress a project in the current folder you can use the command: | ||
- | ===== Create a project ===== | + | '' |
groimp-platform/gs-project.1734355778.txt.gz · Last modified: 2024/12/16 14:29 by gaetan