2016-06-04 16:14:27 +00:00
|
|
|
# Introduction
|
|
|
|
|
|
|
|
This is a collection of design documents, formerly maintained in various
|
|
|
|
different locations and formats, now grouped together and converted
|
|
|
|
to commonmark.
|
|
|
|
|
|
|
|
# Contributing
|
|
|
|
|
|
|
|
## Style
|
|
|
|
|
|
|
|
We will follow the commonmark specification.
|
|
|
|
|
|
|
|
We *should* try to follow this
|
|
|
|
[style guide](http://www.cirosantilli.com/markdown-style-guide/#about),
|
|
|
|
but are still [evaluating solutions](https://github.com/jgm/cmark/issues/131)
|
|
|
|
for *stable* automatic formatting.
|
|
|
|
|
|
|
|
80 columns line width is thus not yet enforced, but strongly suggested.
|
|
|
|
|
2019-04-24 22:45:37 +00:00
|
|
|
# Build the documentation
|
2016-06-04 16:14:27 +00:00
|
|
|
|
|
|
|
## Install dependencies
|
|
|
|
|
2019-04-24 22:45:37 +00:00
|
|
|
* Follow [hotdoc's installation guide](https://hotdoc.github.io/installing.html),
|
2016-06-04 16:14:27 +00:00
|
|
|
preferably in a virtualenv.
|
|
|
|
|
2016-06-04 16:19:38 +00:00
|
|
|
* We *experimentally* use the hotdoc C extension to include functions by
|
|
|
|
name, follow the steps outlined [here](https://github.com/hotdoc/hotdoc_c_extension)
|
|
|
|
|
2019-04-24 22:45:37 +00:00
|
|
|
## Build the portal without the API documentation
|
2016-06-04 16:14:27 +00:00
|
|
|
|
|
|
|
```
|
2019-04-24 22:45:37 +00:00
|
|
|
meson build
|
|
|
|
ninja -C build/ GStreamer-doc
|
2016-06-04 16:14:27 +00:00
|
|
|
```
|
|
|
|
|
2019-04-24 22:45:37 +00:00
|
|
|
And browse it:
|
2016-06-04 16:14:27 +00:00
|
|
|
|
|
|
|
```
|
2019-04-24 22:45:37 +00:00
|
|
|
gio open build/GStreamer-doc/html/index.html
|
2016-06-04 16:14:27 +00:00
|
|
|
```
|
2018-05-31 17:31:06 +00:00
|
|
|
|
2019-04-24 22:45:37 +00:00
|
|
|
## API documentation
|
|
|
|
|
2021-10-05 12:26:52 +00:00
|
|
|
Building the API documentation in the portal implies using the full multi-repo
|
|
|
|
[gstreamer](https://gitlab.freedesktop.org/gstreamer/gstreamer/) build which
|
|
|
|
allows us to aggregate the documentation from all GStreamer modules using the
|
|
|
|
hotdoc subproject feature.
|
2019-04-24 22:45:37 +00:00
|
|
|
|
2021-10-05 12:26:52 +00:00
|
|
|
From `gstreamer`:
|
2019-04-24 22:45:37 +00:00
|
|
|
|
|
|
|
```
|
|
|
|
meson build/
|
2022-03-29 07:24:55 +00:00
|
|
|
./gst-env ninja -C build subprojects/gst-docs/GStreamer-doc
|
2019-04-24 22:45:37 +00:00
|
|
|
```
|
|
|
|
|
|
|
|
And browse the doc:
|
|
|
|
|
|
|
|
```
|
|
|
|
gio open build/subprojects/gst-docs/GStreamer-doc/html/index.html
|
|
|
|
```
|
|
|
|
|
|
|
|
You can also generate a release tarball of the portal with:
|
|
|
|
|
|
|
|
```
|
2020-06-12 15:24:49 +00:00
|
|
|
ninja -C build gst-docs@@release
|
2019-04-24 22:45:37 +00:00
|
|
|
```
|
|
|
|
|
|
|
|
### Adding a newly written plugin to the documentation
|
|
|
|
|
|
|
|
To add a plugin to the documentation you need to add the given
|
|
|
|
meson target to the `plugins` list present in each GStreamer module for
|
|
|
|
example:
|
|
|
|
|
|
|
|
``` meson
|
|
|
|
gst_elements = library('gstcoreelements',
|
|
|
|
gst_elements_sources,
|
|
|
|
c_args : gst_c_args,
|
|
|
|
include_directories : [configinc],
|
2022-03-25 19:00:20 +00:00
|
|
|
dependencies : [gst_dep, gst_base_dep],
|
2019-04-24 22:45:37 +00:00
|
|
|
install : true,
|
|
|
|
install_dir : plugins_install_dir,
|
|
|
|
)
|
|
|
|
plugins += [gst_elements]
|
|
|
|
```
|
|
|
|
|
2019-05-16 17:57:05 +00:00
|
|
|
Then you need to regenerate the `gst_plugins_cache.json` file by running
|
|
|
|
the target manually, if building from the module itself:
|
2019-04-24 22:45:37 +00:00
|
|
|
|
2019-05-16 17:57:05 +00:00
|
|
|
```
|
|
|
|
ninja -C <build-dir> docs/gst_plugins_cache.json
|
|
|
|
```
|
|
|
|
|
2021-10-05 12:26:52 +00:00
|
|
|
if you use the mono repo build there's also a target that will rebuild all
|
|
|
|
the cache files in the various GStreamer subprojects:
|
2019-05-16 17:57:05 +00:00
|
|
|
|
|
|
|
```
|
|
|
|
ninja -C <build-dir> plugins_doc_caches`
|
|
|
|
```
|
|
|
|
|
|
|
|
NOTE: the newly generated cache should be commited to the git repos.
|
|
|
|
|
|
|
|
The plugins documentation is generated based on that file to
|
2019-04-24 22:45:37 +00:00
|
|
|
avoid needing to have built all plugins to get the documentation generated.
|
|
|
|
|
|
|
|
NOTE: When moving plugins from one module to another, the `gst_plugins_cache.json`
|
|
|
|
from the module where the plugin has been removed should be manually edited
|
|
|
|
to reflect the removal.
|
|
|
|
|
2018-05-31 17:31:06 +00:00
|
|
|
## Licensing
|
|
|
|
|
|
|
|
The content of this module comes from a number of different sources and is
|
|
|
|
licensed in different ways:
|
|
|
|
|
|
|
|
### Tutorial source code
|
|
|
|
|
|
|
|
All tutorial code is licensed under any of the following licenses (your choice):
|
|
|
|
|
|
|
|
- 2-clause BSD license ("simplified BSD license") (`LICENSE.BSD`)
|
|
|
|
- MIT license (`LICENSE.MIT`)
|
2020-09-03 20:53:47 +00:00
|
|
|
- LGPL v2.1 (`LICENSE.LGPL-2.1`), or (at your option) any later version
|
2018-05-31 17:31:06 +00:00
|
|
|
|
|
|
|
This means developers have maximum flexibility and can pick the right license
|
|
|
|
for any derivative work.
|
|
|
|
|
|
|
|
### Application Developer Manual and Plugin Writer's Guide
|
|
|
|
|
|
|
|
These are licensed under the [Open Publication License v1.0][op-license]
|
|
|
|
(`LICENSE.OPL`), for historical reasons.
|
|
|
|
|
|
|
|
[op-license]: http://www.opencontent.org/openpub/
|
|
|
|
|
|
|
|
### Documentation
|
|
|
|
|
2020-09-03 20:53:47 +00:00
|
|
|
#### Tutorials
|
|
|
|
|
|
|
|
The tutorials are licensed under the [Creative Commons CC-BY-SA-4.0 license][cc-by-sa-4.0]
|
|
|
|
(`LICENSE.CC-BY-SA-4.0`).
|
2018-05-31 17:31:06 +00:00
|
|
|
|
|
|
|
[cc-by-sa-4.0]: https://creativecommons.org/licenses/by-sa/4.0/
|
2020-09-03 20:53:47 +00:00
|
|
|
|
|
|
|
#### API Reference and Design Documentation
|
|
|
|
|
|
|
|
The remaining documentation, including the API reference and Design Documentation,
|
|
|
|
is licensed under the LGPL v2.1 (`LICENSE.LGPL-2.1`), or (at your option) any later
|
|
|
|
version.
|