part-messages.txt 4.27 KB
Newer Older
Wim Taymans's avatar
Wim Taymans committed
1 2 3 4 5 6
Messages
--------

Messages are refcounted lightweight objects to signal the application
of pipeline events. 

7
Messages are implemented as a subclass of GstMiniObject with a generic 
Wim Taymans's avatar
Wim Taymans committed
8 9 10 11 12
GstStructure as the content. This allows for writing custom messages without
requiring an API change while allowing a wide range of different types
of messages.

Messages are posted by objects in the pipeline and are passed to the 
13
application using the GstBus (See also part-gstbus.txt and part-gstpipeline.txt). 
Wim Taymans's avatar
Wim Taymans committed
14 15 16


Message types
17
~~~~~~~~~~~~~
Wim Taymans's avatar
Wim Taymans committed
18

19
GST_MESSAGE_EOS:
Wim Taymans's avatar
Wim Taymans committed
20

21 22 23
  Posted by sink elements. This message is posted to the application when
  all the sinks in a pipeline posted an EOS message. When performing a seek,
  the EOS state of the pipeline and sinks is undone.
Wim Taymans's avatar
Wim Taymans committed
24

25
GST_MESSAGE_ERROR:
Wim Taymans's avatar
Wim Taymans committed
26

27 28 29
  An element in the pipeline got into an error state. The message carries
  a GError and a debug string describing the error. This usually means that
  part of the pipeline is not streaming anymore.
Wim Taymans's avatar
Wim Taymans committed
30

31 32 33 34 35 36 37
GST_MESSAGE_WARNING:

  An element in the pipeline encountered a condition that made it produce a
  warning. This could be a recoverable decoding error or some other non fatal
  event. The pipeline continues streaming after a warning.

GST_MESSAGE_INFO:
38

39
  An element produced an informational message.
Wim Taymans's avatar
Wim Taymans committed
40

41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
GST_MESSAGE_TAG:

  An element decoded metadata about the stream. The message carries a GstTagList
  with the tag information.

GST_MESSAGE_BUFFERING:

  An element is buffering data and that could potentially take some time. This
  message is typically emited by elements that perform some sort of network
  buffering. While the pipeline is buffering it should remain in the PAUSED
  state. When the buffering is finished, it can resume PLAYING.

GST_MESSAGE_STATE_CHANGED:

  An element changed state in the pipeline. The message carries the old, new
  and pending state of the element.

GST_MESSAGE_STATE_DIRTY:
Wim Taymans's avatar
Wim Taymans committed
59
  
60 61 62
  An internal message used to instruct a pipeline hierarchy that a state
  recalculation must be performed because of an ASYNC state change completed.
  This message is not used anymore.
Wim Taymans's avatar
Wim Taymans committed
63

64
GST_MESSAGE_STEP_DONE:
Wim Taymans's avatar
Wim Taymans committed
65

66
  An element stepping frames has finished. This is currently not used.
Wim Taymans's avatar
Wim Taymans committed
67

68
GST_MESSAGE_CLOCK_PROVIDE:
Wim Taymans's avatar
Wim Taymans committed
69

70
  An element notifies it capability of providing a clock for the pipeline.
Wim Taymans's avatar
Wim Taymans committed
71

72
GST_MESSAGE_CLOCK_LOST:
Wim Taymans's avatar
Wim Taymans committed
73

74 75
  The current clock as selected by the pipeline became unusable. The pipeline 
  will select a new clock on the next PLAYING state change.
Wim Taymans's avatar
Wim Taymans committed
76

77
GST_MESSAGE_NEW_CLOCK:
Wim Taymans's avatar
Wim Taymans committed
78

79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94
  A new clock was selected for the pipeline.

GST_MESSAGE_STRUCTURE_CHANGE:

  The pipeline changed of structure, This means elements were added or removed or
  pads were linked or unlinked. This messages is not yet used.

GST_MESSAGE_STREAM_STATUS:

  Posted by an element when it start/stop/pauses a streaming task. It
  contains information about the reason why the stream state changed along
  with the thread id. The application can use this information to detect
  failures in streaming threads. It can also be used to adjust streaming
  thread priorities by the application.
  
GST_MESSAGE_APPLICATION:
Wim Taymans's avatar
Wim Taymans committed
95

96 97
  The application posted a message. This message must be used when the
  application posts a message on the bus.
Wim Taymans's avatar
Wim Taymans committed
98

99
GST_MESSAGE_ELEMENT:
Wim Taymans's avatar
Wim Taymans committed
100

101
  Element-specific message, see the specific element's documentation
Wim Taymans's avatar
Wim Taymans committed
102

103
GST_MESSAGE_SEGMENT_START:
Wim Taymans's avatar
Wim Taymans committed
104

105
  An element started playback of a new segment. This message is not forwarded
Piotr Fusik's avatar
Piotr Fusik committed
106
  the application but is used internally to schedule SEGMENT_DONE messages.
Wim Taymans's avatar
Wim Taymans committed
107

108
GST_MESSAGE_SEGMENT_DONE:
Wim Taymans's avatar
Wim Taymans committed
109

110 111
  An element or bin completed playback of a segment. This message is only posted
  on the bus if a SEGMENT seek is performed on a pipeline.
Wim Taymans's avatar
Wim Taymans committed
112

113
GST_MESSAGE_DURATION:
Wim Taymans's avatar
Wim Taymans committed
114

115
  An element posts this message when it has detected or updated the stream duration.
116

117
GST_MESSAGE_ASYNC_START:
118

119
  Posted by sinks when they start an asynchronous state change.
120

121
GST_MESSAGE_ASYNC_DONE:
122

123 124
  Posted by sinks when they receive the first data buffer and complete the
  asynchronous state change.
125

126
GST_MESSAGE_LATENCY:
127

128 129
  Posted by elements when the latency in a pipeline changed and a new global
  latency should be calculated by the pipeline or application.
130

131
GST_MESSAGE_REQUEST_STATE:
132

133 134 135
  Posted by elements when they want to change the state of the pipeline they
  are in. A typical use case would be an audio sink that requests the pipeline
  to pause in order to play a higher priority stream.
Wim Taymans's avatar
Wim Taymans committed
136