This repository has been archived by the owner on Oct 10, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
843d3e2
commit a5e82b6
Showing
17 changed files
with
196 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
*.yml | ||
*.sh | ||
package-lock.json | ||
.vscode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
// See https://go.microsoft.com/fwlink/?LinkId=733558 | ||
// for the documentation about the tasks.json format | ||
"version": "2.0.0", | ||
"tasks": [ | ||
{ | ||
"label": "Build GitBook", | ||
"type": "shell", | ||
"command": "./node_modules/gitbook-cli/bin/gitbook.js build", | ||
"group": { | ||
"kind": "build", | ||
"isDefault": true | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,22 @@ | ||
# Summary | ||
|
||
* [Introduction](README.md) | ||
* [Basic concepts](chapter1.md) | ||
* [Elements](chapter1/concepts.md) | ||
* [First pipeline](chapter1/pipeline.md) | ||
* [First element](chapter1/element.md) | ||
* [Advanced](chapter2.md) | ||
* [Logger](chapter2/logger.md) | ||
* [NIFs](chapter2/nifs.md) | ||
* [Demands](chapter2/demands.md) | ||
* [Element lifecycle](chapter2/lifecycle.md) | ||
* [Testing](chapter2/testing.md) | ||
|
||
## Concepts | ||
|
||
* [Elements](concepts/elements.md) | ||
* [Pads](concepts/pads.md) | ||
* [Lifecycle](concepts/lifecycle.md) | ||
* [Pipelines](concepts/pipelines.md) | ||
|
||
## Building application | ||
|
||
* [Writing pipeline](creating_app/pipeline.md) | ||
* [Logger](creating_app/logger.md) | ||
|
||
## Creating new elements | ||
|
||
* [Tutorial](creating_element/tutorial.md) | ||
* [Testing](creating_element/testing.md) | ||
* [Native code integration](creating_element/natives.md) | ||
* [Demands](creating_element/demands.md) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Elements | ||
|
||
Elements in Membrane Framework are the most basic entities | ||
responsible for processing multimedia. | ||
Each instance of an element is an Erlang process, that has internal state and communicates by message passing. | ||
|
||
Every element is created to solve one problem. The examples of elements are | ||
audio encoder (converting raw audio to encoded format like MP3), | ||
file source (reading data from a file and passing it to other elements) or | ||
UDP sink (sending data from an application via UDP socket). | ||
|
||
There are three basic types of elements: `sink`, `source`, and `filters`: | ||
|
||
* `Source` - responsible for getting (or generating) data delivering it to other elements | ||
* `Sink` - defines an endpoint for data flowing through an application. | ||
* `Filter` - an element that receives data from other elements, processes it and sends it further to the next elements | ||
|
||
Every element may be in one of three states: | ||
|
||
* `:stopped` - element has been created | ||
* `:prepared` - element should be ready for processing data. All necessary resources should be allocated and initialized. | ||
* `:playing` - element is actually processing data | ||
|
||
Elements define their own `options` that parametrize their work. For example, some audio decoder may have an option named `bitrate` that represents bitrate of the output data. |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
## Pads and capabilities | ||
|
||
To create the flow of data between elements in the application, they have to communicate with each other. For that purpose, the concept of `pads` and `capabilities` is used. `Pads` are basically inputs and outputs of the elements and because of that, there are two types of pads: `input` and `output`. It is worth mentioning that `Source` elements may only contain `output` pads, `Sinks` contain only `input` pads, and `Filters` can have both of them. | ||
|
||
Every pad has some capabilities, which defines a type of data that it is expecting. This format can be, for example, raw audio with a specific sample rate or encoded audio in a given format. | ||
|
||
Two elements that should send data between each other, should have linked pads. One pad can be linked with only one other pad of a different element. Only links between `output` and `input` pads are allowed. Furthermore, to link two pads, their capabilities have to be compatible. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
## Pipelines | ||
|
||
A pipeline is a container that consists of many elements and links between them. Like an Element, every Pipeline also has a playback state and on its basis, it manages the state of the contained elements. | ||
|
||
During the application execution, elements may want to signal some events. For that purpose, they send the `notification` to their supervisor, which in most cases is a pipeline. A programmer can handle those notifications by defining the appropriate method in the pipeline module. |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.