├── docs
├── plugins
│ ├── index.md
│ ├── sitemap.txt
│ └── nle.md
├── base-classes.md
├── version.entities.in
├── deprecated.md
├── images
│ └── layer_track_overview.png
├── low_level.md
├── libs
│ ├── GESAudioUriSource-children-props.md
│ ├── GESTransitionClip-children-props.md
│ ├── GESAudioTestSource-children-props.md
│ ├── GESVideoUriSource-children-props.md
│ └── GESVideoTestSource-children-props.md
├── random
│ └── lifecycle
├── sitemap.txt
├── design
│ └── gstencodebin.h
└── index.md
├── tests
├── check
│ ├── python
│ │ ├── __init__.py
│ │ └── overrides_hack.py
│ ├── ges
│ │ ├── wrong_test.xptv
│ │ └── negative.c
│ ├── nose2-junit-xml.cfg.in
│ ├── assets
│ │ ├── png.png
│ │ ├── image.png
│ │ ├── audio_only.ogg
│ │ ├── audio_video.ogg
│ │ ├── test-properties.xges
│ │ ├── test-project.xges
│ │ └── test-auto-transition.xges
│ └── scenarios
│ │ ├── set-layer-on-command-line.validatetest
│ │ ├── check-clip-positioning.validatetest
│ │ ├── check_edit_in_frames_with_framerate_mismatch.scenario
│ │ ├── complex_effect_bin_desc
│ │ └── flow-expectations
│ │ │ └── log-videosink-sink-expected
│ │ ├── check_layer_activness_gaps.scenario
│ │ ├── complex_effect_bin_desc.validatetest
│ │ ├── seek_with_stop.check_clock_sync
│ │ └── flow-expectations
│ │ │ └── log-videosink-sink-expected
│ │ ├── seek_with_stop.check_clock_sync.validatetest
│ │ ├── check_edit_in_frames.scenario
│ │ ├── seek_with_stop.validatetest
│ │ ├── check_video_track_restriction_scale_with_keyframes.scenario
│ │ ├── edit_while_seeked_with_stop.validatetest
│ │ └── check_video_track_restriction_scale.scenario
├── meson.build
├── validate
│ ├── scenarios
│ │ ├── meson.build
│ │ └── ges-edit-clip-while-paused.scenario
│ └── meson.build
└── benchmarks
│ └── meson.build
├── examples
├── meson.build
├── c
│ ├── meson.build
│ ├── play_timeline_with_one_clip.c
│ ├── assets.c
│ └── multifilesrc.c
└── python
│ ├── gst-player.py
│ └── simple.py
├── plugins
├── nle
│ ├── gnlmarshal.list
│ ├── meson.build
│ ├── nle.h
│ ├── nletypes.h
│ ├── nleghostpad.h
│ ├── nleurisource.h
│ ├── gstnle.c
│ ├── nlecomposition.h
│ ├── nlesource.h
│ └── nleoperation.h
├── meson.build
└── ges
│ ├── meson.build
│ ├── gesbasebin.h
│ └── gesplugin.c
├── ges
├── gesmarshal.list
├── ges.resource
├── ges-time-overlay-clip.h
├── ges-version.h.in
├── ges-screenshot.h
├── ges-utils.h
├── ges-prelude.h
├── ges-xml-formatter.h
├── ges-time-overlay-clip.c
├── ges-transition.c
├── parse.l
├── ges-effect-asset.h
├── ges-group.h
├── ges-uri-source.h
├── ges-source-clip-asset.h
├── ges-operation.c
├── ges-video-track.h
├── ges-audio-track.h
├── ges-image-source.h
├── ges-base-effect-clip.h
├── ges-base-transition-clip.c
├── ges-operation-clip.c
├── ges-overlay-clip.h
├── ges-audio-transition.h
├── ges-source-clip.h
├── ges-effect-clip.h
├── ges-command-line-formatter.h
├── ges-multi-file-source.h
├── ges-operation.h
├── ges-source-clip-asset.c
├── ges-base-transition-clip.h
├── ges-screenshot.c
├── ges-operation-clip.h
├── ges-audio-uri-source.h
├── ges-pitivi-formatter.h
├── ges-transition.h
├── ges-effect.h
├── ges-video-uri-source.h
├── ges-base-xml-formatter.h
├── ges-overlay-clip.c
├── ges-marker-list.h
├── ges-uri-clip.h
├── ges-video-test-source.h
├── ges-audio-source.h
├── ges-transition-clip.h
├── ges-audio-test-source.h
├── ges-auto-transition.h
├── ges-smart-adder.h
├── ges-smart-video-mixer.h
├── ges-clip-asset.h
├── ges-track-element-asset.h
├── ges-gerror.h
├── ges-structure-parser.h
├── ges-source.h
├── ges-test-clip.h
├── ges-video-source.h
├── ges-video-transition.h
├── ges-base-effect-clip.c
├── ges-track-element-deprecated.h
└── ges-pipeline.h
├── .gitignore
├── bindings
└── python
│ ├── meson.build
│ ├── gi
│ └── overrides
│ │ └── __init__.py
│ └── examples
│ └── simple.py
├── AUTHORS
├── .gitlab-ci.yml
├── .arcconfig
├── README
├── meson_options.txt
├── tools
├── ges-launch.c
├── ges-launcher-kb.h
├── ges-launch-1.0.1
├── ges-validate.h
├── ges-launcher.h
├── meson.build
└── utils.h
└── scripts
└── extract-release-date-from-doap-file.py
/docs/plugins/index.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/docs/plugins/sitemap.txt:
--------------------------------------------------------------------------------
1 | gst-index
--------------------------------------------------------------------------------
/tests/check/python/__init__.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/meson.build:
--------------------------------------------------------------------------------
1 | subdir('c')
2 |
--------------------------------------------------------------------------------
/docs/base-classes.md:
--------------------------------------------------------------------------------
1 | # Base classes
2 |
--------------------------------------------------------------------------------
/tests/check/ges/wrong_test.xptv:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/plugins/nle/gnlmarshal.list:
--------------------------------------------------------------------------------
1 | VOID:OBJECT,UINT
2 |
3 |
--------------------------------------------------------------------------------
/ges/gesmarshal.list:
--------------------------------------------------------------------------------
1 | VOID:OBJECT
2 | VOID:OBJECT,INT,INT
3 |
--------------------------------------------------------------------------------
/plugins/meson.build:
--------------------------------------------------------------------------------
1 | plugins = []
2 | subdir('nle')
3 | subdir('ges')
--------------------------------------------------------------------------------
/tests/check/nose2-junit-xml.cfg.in:
--------------------------------------------------------------------------------
1 | [junit-xml]
2 | always-on = True
3 | path = @path@
4 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /build/
2 | /b/
3 | /_build/
4 | *~
5 | core.*
6 |
7 | core
8 | log
9 |
10 |
--------------------------------------------------------------------------------
/bindings/python/meson.build:
--------------------------------------------------------------------------------
1 | install_data(['gi/overrides/GES.py'], install_dir: pygi_override_dir)
--------------------------------------------------------------------------------
/AUTHORS:
--------------------------------------------------------------------------------
1 | Edward Hervey
2 | Brandon Lewis
3 |
--------------------------------------------------------------------------------
/.gitlab-ci.yml:
--------------------------------------------------------------------------------
1 | include: "https://gitlab.freedesktop.org/gstreamer/gst-ci/raw/master/gitlab/ci_template.yml"
2 |
--------------------------------------------------------------------------------
/docs/version.entities.in:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/tests/check/assets/png.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GStreamer/gst-editing-services/HEAD/tests/check/assets/png.png
--------------------------------------------------------------------------------
/docs/deprecated.md:
--------------------------------------------------------------------------------
1 | # Deprecated APIS
2 |
3 | Those APIs have been deprecated and shouldn't be used in newly written code.
--------------------------------------------------------------------------------
/tests/check/assets/image.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GStreamer/gst-editing-services/HEAD/tests/check/assets/image.png
--------------------------------------------------------------------------------
/tests/check/assets/audio_only.ogg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GStreamer/gst-editing-services/HEAD/tests/check/assets/audio_only.ogg
--------------------------------------------------------------------------------
/docs/images/layer_track_overview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GStreamer/gst-editing-services/HEAD/docs/images/layer_track_overview.png
--------------------------------------------------------------------------------
/tests/check/assets/audio_video.ogg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GStreamer/gst-editing-services/HEAD/tests/check/assets/audio_video.ogg
--------------------------------------------------------------------------------
/docs/plugins/nle.md:
--------------------------------------------------------------------------------
1 | ---
2 | short-description: Non Linear Engine
3 | ...
4 |
5 | # Non Linear Engine
6 |
7 | NLE is a set of elements to implement Non Linear multimedia editing.
8 |
--------------------------------------------------------------------------------
/ges/ges.resource:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | python/gesotioformatter.py
5 |
6 |
7 |
--------------------------------------------------------------------------------
/tests/meson.build:
--------------------------------------------------------------------------------
1 | # FIXME: make check work on windows
2 | if host_machine.system() != 'windows' and gstcheck_dep.found()
3 | subdir('check')
4 | endif
5 |
6 | subdir('validate')
7 | subdir('benchmarks')
--------------------------------------------------------------------------------
/tests/validate/scenarios/meson.build:
--------------------------------------------------------------------------------
1 | install_data (['ges-edit-clip-while-paused.scenario'],
2 | install_dir : join_paths(get_option('datadir'),
3 | 'gstreamer-1.0', 'validate', 'scenarios'))
4 |
--------------------------------------------------------------------------------
/docs/low_level.md:
--------------------------------------------------------------------------------
1 | # Low level APIs
2 |
3 | Those APIs should usually not be used unless you know
4 | what you are doing, check other parts of the documentation
5 | before deciding you should use one of those.
6 |
--------------------------------------------------------------------------------
/tests/validate/meson.build:
--------------------------------------------------------------------------------
1 | subdir ('scenarios')
2 |
3 | install_data (['geslaunch.py'],
4 | install_dir : join_paths(get_option('libdir'),
5 | 'gst-validate-launcher', 'python', 'launcher', 'apps'))
6 |
--------------------------------------------------------------------------------
/.arcconfig:
--------------------------------------------------------------------------------
1 | {
2 | "phabricator.uri" : "https://phabricator.freedesktop.org/",
3 | "repository.callsign" : "GES",
4 | "project": "GStreamer Editing Services",
5 | "default-reviewers": "thiblahute,Mathieu_Du"
6 | }
7 |
--------------------------------------------------------------------------------
/docs/libs/GESAudioUriSource-children-props.md:
--------------------------------------------------------------------------------
1 | #### `mute`
2 |
3 | mute channel
4 |
5 | Value type: #gboolean
6 |
7 | See #volume:mute
8 |
9 | #### `volume`
10 |
11 | volume factor, 1.0=100%
12 |
13 | Value type: #gdouble
14 |
15 | See #volume:volume
16 |
17 |
--------------------------------------------------------------------------------
/tests/validate/scenarios/ges-edit-clip-while-paused.scenario:
--------------------------------------------------------------------------------
1 | description, duration=4.0
2 | pause, playback_time=0.0
3 | wait, duration=1.0
4 | edit-clip, playback_time=0.0, clip-name="uriclip0", position=3.0, edit-mode="edit_trim", edge="edge_end"
5 | play, playback_time=0.0
6 |
--------------------------------------------------------------------------------
/docs/libs/GESTransitionClip-children-props.md:
--------------------------------------------------------------------------------
1 | #### `border`
2 |
3 | The border width
4 |
5 | Value type: #guint
6 |
7 | See #GESVideoTransition:border
8 |
9 | #### `invert`
10 |
11 | Whether the transition is inverted
12 |
13 | Value type: #gboolean
14 |
15 | See #GESVideoTransition:invert
16 |
17 |
--------------------------------------------------------------------------------
/tests/benchmarks/meson.build:
--------------------------------------------------------------------------------
1 | ges_benchmarks = ['timeline']
2 |
3 | foreach b : ges_benchmarks
4 | fname = '@0@.c'.format(b)
5 | executable('benchmark-' + b, fname,
6 | c_args : ges_c_args,
7 | include_directories : [configinc],
8 | dependencies : ges_dep
9 | )
10 | endforeach
11 |
--------------------------------------------------------------------------------
/README:
--------------------------------------------------------------------------------
1 | GStreamer Editing Services
2 | --------------------------
3 |
4 | This is a high-level library for facilitating the creation of audio/video
5 | non-linear editors.
6 |
7 | License:
8 | --------
9 |
10 | This package and its contents are licensend under the GNU Lesser General
11 | Public License (LGPL).
12 |
13 | Dependencies:
14 | -------------
15 |
16 | * GStreamer core
17 | * gst-plugins-base
18 |
19 |
--------------------------------------------------------------------------------
/plugins/ges/meson.build:
--------------------------------------------------------------------------------
1 | gstges_sources = ['gesplugin.c', 'gessrc.c', 'gesdemux.c', 'gesbasebin.c']
2 |
3 | gstges = library('gstges', gstges_sources,
4 | dependencies : [gst_dep, ges_dep],
5 | include_directories: [configinc],
6 | c_args : ges_c_args,
7 | install : true,
8 | install_dir : plugins_install_dir,
9 | )
10 | pkgconfig.generate(gstges, install_dir : plugins_pkgconfig_install_dir)
11 | plugins += [gstges]
--------------------------------------------------------------------------------
/tests/check/scenarios/set-layer-on-command-line.validatetest:
--------------------------------------------------------------------------------
1 | meta, handles-states=true,
2 | tool = "ges-launch-$(gst_api_version)",
3 | handles-states=true,
4 | args = {
5 | +test-clip, blue, "d=0.5", "layer=0", "name=blue",
6 | +test-clip, green, "d=0.5", "layer=1", "name=green",
7 | }
8 |
9 | check-ges-properties, element-name=blue, layer::priority=0
10 | check-ges-properties, element-name=green, layer::priority=1
11 | stop
--------------------------------------------------------------------------------
/plugins/nle/meson.build:
--------------------------------------------------------------------------------
1 | nle_sources = ['nleobject.c',
2 | 'nlecomposition.c',
3 | 'nleghostpad.c',
4 | 'nleoperation.c',
5 | 'nlesource.c',
6 | 'nleurisource.c',
7 | 'gstnle.c'
8 | ]
9 |
10 | nle = library('gstnle', nle_sources,
11 | dependencies : [gst_dep, gstbase_dep],
12 | include_directories: [configinc],
13 | c_args : ges_c_args,
14 | install : true,
15 | install_dir : plugins_install_dir,
16 | )
17 | pkgconfig.generate(nle, install_dir : plugins_pkgconfig_install_dir)
18 | plugins += [nle]
19 |
--------------------------------------------------------------------------------
/docs/libs/GESAudioTestSource-children-props.md:
--------------------------------------------------------------------------------
1 | #### `freq`
2 |
3 | Frequency of test signal. The sample rate needs to be at least 2 times higher.
4 |
5 | Value type: #gdouble
6 |
7 | See #audiotestsrc:freq
8 |
9 | #### `mute`
10 |
11 | mute channel
12 |
13 | Value type: #gboolean
14 |
15 | See #volume:mute
16 |
17 | #### `volume`
18 |
19 | volume factor, 1.0=100%
20 |
21 | Value type: #gdouble
22 |
23 | See #volume:volume
24 |
25 | #### `volume`
26 |
27 | Volume of test signal
28 |
29 | Value type: #gdouble
30 |
31 | See #audiotestsrc:volume
32 |
33 |
--------------------------------------------------------------------------------
/tests/check/scenarios/check-clip-positioning.validatetest:
--------------------------------------------------------------------------------
1 | meta,
2 | tool = "ges-launch-$(gst_api_version)",
3 | handles-states=true,
4 | args = {
5 | +test-clip, blue, "d=0.5", "asset-id=time-overlay, width=640, height=360, max-duration=5.0", "name=clip",
6 | --track-types, video,
7 | --videosink, "$(videosink) name=videosink sync=true",
8 | --video-caps, "video/x-raw,format=I420,width=640,height=360,framerate=10/1,chroma-site=mpeg2,colorimetry=bt709;",
9 | }
10 |
11 | check-child-properties, element-name=clip, width=0, height=0
12 | stop
--------------------------------------------------------------------------------
/examples/c/meson.build:
--------------------------------------------------------------------------------
1 | examples = [
2 | 'concatenate',
3 | 'gessrc',
4 | 'simple1',
5 | 'test1',
6 | 'test2',
7 | 'test3',
8 | 'test4',
9 | 'transition',
10 | 'thumbnails',
11 | 'overlays',
12 | 'text_properties',
13 | 'assets',
14 | 'multifilesrc',
15 | 'play_timeline_with_one_clip'
16 | ]
17 |
18 | # TODO Properly port to Gtk 3
19 | #
20 | # if gtk_dep.found()
21 | # examples = examples + ['ges-ui']
22 | # endif
23 |
24 |
25 | foreach example_name : examples
26 | exe = executable(example_name, '@0@.c'.format(example_name),
27 | c_args : ges_c_args,
28 | dependencies : libges_deps + [ges_dep],
29 | )
30 | endforeach
31 |
--------------------------------------------------------------------------------
/docs/random/lifecycle:
--------------------------------------------------------------------------------
1 | Lifecycle of a Timeline/Track Object
2 |
3 | * Adding a TimelineObject to a Layer
4 |
5 | (tlobj:timelineobject, trobj:trackobject)
6 |
7 | ges_timeline_layer_add_object(layer, tlobj)
8 | signal_emit "object-added", layer, tlobj
9 | GESTimeline receives signal
10 | for each TRACK {
11 | ges_timeline_object_create_track_objects(tlobj, TRACK)
12 | trobj = GESTimelineObject::create_track_objects
13 | ges_track_add_object(TRACK, trobj)
14 | ges_track_object_set_track(troj, TRACK)
15 | nleobj = GESTrackObject::create_gnl_object
16 | ges_timeline_object_fill_track_object(tlobj, trobj, nleobj)
17 | GESTimelineObject::fill_track_object
18 |
19 |
--------------------------------------------------------------------------------
/tests/check/scenarios/check_edit_in_frames_with_framerate_mismatch.scenario:
--------------------------------------------------------------------------------
1 | description, handles-states=true,
2 | ges-options={\
3 | --track-types, video,
4 | --disable-mixing,
5 | "--videosink=fakevideosink"\
6 | }
7 |
8 | add-clip, name=clip, asset-id="time-overlay,framerate=120/1", layer-priority=0, type=GESSourceClip, pattern=blue, duration=f240, inpoint=f100
9 | set-child-properties, element-name=clip, time-mode=time-code
10 | pause
11 |
12 | check-last-sample, sinkpad-caps="video/x-raw", timecode-frame-number=100
13 |
14 | edit, element-name=clip, edit-mode=normal, position=1.0
15 |
16 | edit, element-name=clip, edit-mode=edit_trim, edge=start, source-frame=60
17 | edit, element-name=clip, position=0
18 | commit;
19 | check-last-sample, sinkpad-caps="video/x-raw", timecode-frame-number=60
20 |
21 | edit, element-name=clip, edit-mode=edit_trim, edge=start, source-frame=120
22 | check-ges-properties, element-name=clip, start=0.5
23 | stop
24 |
--------------------------------------------------------------------------------
/ges/ges-time-overlay-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2020 Igalia S.L
3 | * Author: 2020 Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include "ges-source-clip.h"
24 |
25 | G_BEGIN_DECLS
26 |
27 | GES_API
28 | GESSourceClip* ges_source_clip_new_time_overlay (void);
29 |
30 | G_END_DECLS
--------------------------------------------------------------------------------
/tests/check/python/overrides_hack.py:
--------------------------------------------------------------------------------
1 | import os
2 | import gi.overrides
3 |
4 | LOCAL_OVERRIDE_PATH = "gst-editing-services/bindings/python/gi/overrides/"
5 | FILE = os.path.realpath(__file__)
6 | if not gi.overrides.__path__[0].endswith(LOCAL_OVERRIDE_PATH):
7 | local_overrides = None
8 | # our overrides don't take precedence, let's fix it
9 | for i, path in enumerate(gi.overrides.__path__):
10 | if path.endswith(LOCAL_OVERRIDE_PATH):
11 | local_overrides = path
12 |
13 | if local_overrides:
14 | gi.overrides.__path__.remove(local_overrides)
15 | else:
16 | local_overrides = os.path.abspath(os.path.join(FILE, "../../../../../", LOCAL_OVERRIDE_PATH))
17 |
18 | gi.overrides.__path__.insert(0, local_overrides)
19 |
20 | # Execute previously set sitecustomize.py script if it existed
21 | if os.environ.get("GST_ENV"):
22 | old_sitecustomize = os.path.join(os.path.dirname(__file__),
23 | "old.sitecustomize.gstuninstalled.py")
24 | if os.path.exists(old_sitecustomize):
25 | exec(compile(open(old_sitecustomize).read(), old_sitecustomize, 'exec'))
26 |
--------------------------------------------------------------------------------
/tests/check/scenarios/complex_effect_bin_desc/flow-expectations/log-videosink-sink-expected:
--------------------------------------------------------------------------------
1 | event stream-start: GstEventStreamStart, flags=(GstStreamFlags)GST_STREAM_FLAG_NONE;
2 | event caps: video/x-raw, chroma-site=(string)jpeg, colorimetry=(string)bt601, format=(string)I420, framerate=(fraction)30/1, height=(int)720, width=(int)1280;
3 | event segment: format=TIME, start=0:00:00.000000000, offset=0:00:00.000000000, stop=0:00:00.100000000, flags=0x01, time=0:00:00.000000000, base=0:00:00.000000000
4 | buffer: checksum=369888c2612267760fcfaa74e52fc53bd73e4d15, pts=0:00:00.000000000, dur=0:00:00.033333333, meta=GstVideoMeta
5 | buffer: checksum=369888c2612267760fcfaa74e52fc53bd73e4d15, pts=0:00:00.033333333, dur=0:00:00.033333334, meta=GstVideoMeta
6 | buffer: checksum=369888c2612267760fcfaa74e52fc53bd73e4d15, pts=0:00:00.066666667, dur=0:00:00.033333333, meta=GstVideoMeta
7 | event segment: format=TIME, start=0:00:00.100000000, offset=0:00:00.000000000, stop=0:00:00.100000001, flags=0x01, time=0:00:00.100000000, base=0:00:00.100000000
8 | buffer: checksum=b4a126ab26f314a74ef860a9af457327a28d680b, pts=0:00:00.100000000, dur=0:00:00.000000001, meta=GstVideoMeta
9 | event eos: (no structure)
10 |
--------------------------------------------------------------------------------
/ges/ges-version.h.in:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2014 Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | G_BEGIN_DECLS
23 |
24 | #define GES_VERSION_MAJOR (@GES_VERSION_MAJOR@)
25 | #define GES_VERSION_MINOR (@GES_VERSION_MINOR@)
26 | #define GES_VERSION_MICRO (@GES_VERSION_MICRO@)
27 | #define GES_VERSION_NANO (@GES_VERSION_NANO@)
28 |
29 | G_END_DECLS
30 |
--------------------------------------------------------------------------------
/ges/ges-screenshot.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 |
26 | G_BEGIN_DECLS
27 |
28 | GES_DEPRECATED GstSample *
29 | ges_play_sink_convert_frame (GstElement * playsink, GstCaps * caps);
30 |
31 | G_END_DECLS
32 |
--------------------------------------------------------------------------------
/tests/check/scenarios/check_layer_activness_gaps.scenario:
--------------------------------------------------------------------------------
1 | description, handles-states=true,
2 | ges-options={\
3 | "--disable-mixing",
4 | "--videosink=fakevideosink",
5 | "--audiosink=fakeaudiosink"\
6 | }
7 |
8 | add-clip, name=clip, asset-id="framerate=30/1", layer-priority=0, type=GESTestClip, pattern=blue, duration=5000.0
9 | set-layer-active, tracks={gesvideotrack0}, active=false, layer-priority=0
10 |
11 | pause;
12 |
13 | # Make sure the video test src is a gap test src.
14 | check-property, target-element-factory-name=videotestsrc, property-name=pattern, property-value="100% Black"
15 | check-property, target-element-factory-name=audiotestsrc, property-name=wave, property-value="Sine"
16 |
17 | set-layer-active, tracks={gesvideotrack0}, active=true, layer-priority=0
18 | set-layer-active, tracks={gesaudiotrack0}, active=false, layer-priority=0
19 | commit;
20 | # Make sure the video test src is the GESVideoTestSource and the audio test source is a gap
21 | check-property, target-element-factory-name=videotestsrc, property-name=pattern, property-value="Blue"
22 | check-property, target-element-factory-name=audiotestsrc, property-name=wave, property-value="Silence"
23 |
24 | stop;
--------------------------------------------------------------------------------
/tests/check/scenarios/complex_effect_bin_desc.validatetest:
--------------------------------------------------------------------------------
1 | # Check that we can have effect with sources integrated where GES will request a pad on some elements
2 | # In that example, we are blending a green rectangle on top of a blue GESVideoTestSource using an effect
3 | meta,
4 | tool = "ges-launch-$(gst_api_version)",
5 | handles-states=true,
6 | args = {
7 | "--track-types", "video",
8 | "--videosink", "$(videosink) name=videosink",
9 | "--video-caps", "video/x-raw, format=I420, width=1280, height=720, framerate=30/1, chroma-site=jpeg, colorimetry=bt601",
10 | },
11 | configs = {
12 | "$(validateflow), pad=videosink:sink, buffers-checksum=true, ignored-fields=\"stream-start={stream-id,group-id,stream}, segment={position,}\", ignored-event-types={gap}",
13 | }
14 |
15 |
16 | add-clip, name=c0, asset-id=GESTestClip, layer-priority=0, type=GESTestClip, start=0, duration=0.1
17 | set-child-properties, element-name=c0, pattern=blue
18 |
19 | container-add-child,
20 | container-name=c0,
21 | asset-id="videotestsrc pattern=green ! video/x-raw,width=640,height=360 ! compositor sink_0::xpos=320 sink_0::ypos=180 sink_0::zorder=500",
22 | child-type=GESEffect,
23 | child-name=effect
24 | play
--------------------------------------------------------------------------------
/tests/check/scenarios/seek_with_stop.check_clock_sync/flow-expectations/log-videosink-sink-expected:
--------------------------------------------------------------------------------
1 | event stream-start: GstEventStreamStart, flags=(GstStreamFlags)GST_STREAM_FLAG_NONE;
2 | event caps: video/x-raw, chroma-site=(string)mpeg2, colorimetry=(string)bt709, format=(string)I420, framerate=(fraction)10/1, height=(int)720, width=(int)1280;
3 | event segment: format=TIME, start=0:00:00.000000000, offset=0:00:00.000000000, stop=0:00:01.000000000, flags=0x01, time=0:00:00.000000000, base=0:00:00.000000000, position=none
4 | buffer: pts=0:00:00.000000000, dur=0:00:00.100000000, meta=GstVideoMeta
5 | event flush-start: (no structure)
6 | event flush-stop: GstEventFlushStop, reset-time=(boolean)true;
7 | event segment: format=TIME, start=0:00:00.000000000, offset=0:00:00.000000000, stop=0:00:00.500000000, flags=0x01, time=0:00:00.000000000, base=0:00:00.000000000, position=none
8 | buffer: pts=0:00:00.000000000, dur=0:00:00.100000000, meta=GstVideoMeta
9 | buffer: pts=0:00:00.100000000, dur=0:00:00.100000000, meta=GstVideoMeta
10 | buffer: pts=0:00:00.200000000, dur=0:00:00.100000000, meta=GstVideoMeta
11 | buffer: pts=0:00:00.300000000, dur=0:00:00.100000000, meta=GstVideoMeta
12 | buffer: pts=0:00:00.400000000, dur=0:00:00.100000000, meta=GstVideoMeta
13 | event eos: (no structure)
14 |
--------------------------------------------------------------------------------
/plugins/nle/nle.h:
--------------------------------------------------------------------------------
1 | /* Gnonlin
2 | * Copyright (C) <2001> Wim Taymans
3 | * <2004-2008> Edward Hervey
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #ifndef __NLE_H__
22 | #define __NLE_H__
23 |
24 | #include
25 |
26 | #include "nletypes.h"
27 |
28 | #include "nleobject.h"
29 | #include "nleghostpad.h"
30 | #include "nlesource.h"
31 | #include "nlecomposition.h"
32 | #include "nleoperation.h"
33 |
34 | #include "nleurisource.h"
35 |
36 | #endif /* __GST_H__ */
37 |
--------------------------------------------------------------------------------
/bindings/python/gi/overrides/__init__.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | #
3 | # __init__.py
4 | #
5 | # Copyright (C) 2012 Thibault Saunier
6 | #
7 | # This program is free software; you can redistribute it and/or
8 | # modify it under the terms of the GNU Lesser General Public
9 | # License as published by the Free Software Foundation; either
10 | # version 2.1 of the License, or (at your option) any later version.
11 | #
12 | # This program is distributed in the hope that it will be useful,
13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | # Lesser General Public License for more details.
16 | #
17 | # You should have received a copy of the GNU Lesser General Public
18 | # License along with this program; if not, write to the
19 | # Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 | # Boston, MA 02111-1307, USA.
21 | # This program is free software; you can redistribute it and/or modify
22 | # it under the terms of the GNU General Public License as published by
23 | # the Free Software Foundation; either version 3, or (at your option)
24 | # any later version.
25 |
26 | from pkgutil import extend_path
27 |
28 | __path__ = extend_path(__path__, __name__)
29 |
--------------------------------------------------------------------------------
/ges/ges-utils.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Edward Hervey
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 | #include
25 |
26 | G_BEGIN_DECLS
27 |
28 | GES_API
29 | GESTimeline * ges_timeline_new_audio_video (void);
30 | GES_API
31 | gboolean ges_pspec_equal (gconstpointer key_spec_1, gconstpointer key_spec_2);
32 | GES_API
33 | guint ges_pspec_hash (gconstpointer key_spec);
34 |
35 |
36 | G_END_DECLS
37 |
--------------------------------------------------------------------------------
/tests/check/scenarios/seek_with_stop.check_clock_sync.validatetest:
--------------------------------------------------------------------------------
1 | meta,
2 | tool = "ges-launch-$(gst_api_version)",
3 | args = {
4 | --track-types, video,
5 | --videosink, "$(videosink) name=videosink",
6 | --video-caps, "video/x-raw,format=I420,width=1280,height=720,framerate=10/1,chroma-site=mpeg2,colorimetry=bt709;",
7 | },
8 | handles-states=true,
9 | ignore-eos=true,
10 | configs = {
11 | # Ideally we should be able to record checksums... but they are not reproducible
12 | "$(validateflow), pad=videosink:sink, record-buffers=true, ignored-fields=\"stream-start={stream-id,group-id,stream}\"",
13 | }
14 |
15 | add-clip, name=c0, asset-id=time-overlay, layer-priority=0, type=GESSourceClip, start=0, duration=1.0
16 | set-child-properties, element-name=c0, pattern=blue, valignment=center, halignment=center, time-mode=time-code
17 |
18 | add-clip, name=c1, asset-id=time-overlay, layer-priority=0, type=GESSourceClip, start=1.0, duration=1.0
19 | set-child-properties, element-name=c1, pattern=red, valignment=center, halignment=center, time-mode=time-code
20 | commit;
21 | play
22 |
23 | seek, start=0.0, stop=0.5, flags=accurate+flush
24 | crank-clock, expected-elapsed-time=0.0
25 |
26 | # 4 remaining buffers + eos.
27 | crank-clock, repeat=5, expected-elapsed-time=0.1
28 |
29 | check-position, on-message=eos, expected-position=0.5
30 | stop;
--------------------------------------------------------------------------------
/tests/check/assets/test-properties.xges:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/ges/ges-prelude.h:
--------------------------------------------------------------------------------
1 | /* GStreamer GES Library
2 | * Copyright (C) 2018 GStreamer developers
3 | *
4 | * ges-prelude.h: prelude include header for gst-ges library
5 | *
6 | * This library is free software; you can redistribute it and/or
7 | * modify it under the terms of the GNU Library General Public
8 | * License as published by the Free Software Foundation; either
9 | * version 2 of the License, or (at your option) any later version.
10 | *
11 | * This library is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | * Library General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Library General Public
17 | * License along with this library; if not, write to the
18 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
19 | * Boston, MA 02110-1301, USA.
20 | */
21 | #pragma once
22 |
23 | #include
24 |
25 | #ifndef GES_API
26 | # ifdef BUILDING_GES
27 | # define GES_API GST_API_EXPORT /* from config.h */
28 | # else
29 | # define GES_API GST_API_IMPORT
30 | # endif
31 | #endif
32 |
33 | #ifndef GST_DISABLE_DEPRECATED
34 | #define GES_DEPRECATED GES_API
35 | #define GES_DEPRECATED_FOR(f) GES_API
36 | #else
37 | #define GES_DEPRECATED G_DEPRECATED GES_API
38 | #define GES_DEPRECATED_FOR(f) G_DEPRECATED_FOR(f) GES_API
39 | #endif
40 |
--------------------------------------------------------------------------------
/meson_options.txt:
--------------------------------------------------------------------------------
1 | # Common feature options
2 | option('doc', type : 'feature', value : 'auto', yield: true,
3 | description: 'Enable documentation.')
4 | option('examples', type : 'feature', value : 'auto', yield : true,
5 | description : 'Build examples')
6 | option('introspection', type : 'feature', value : 'auto', yield : true,
7 | description : 'Generate gobject-introspection bindings')
8 | option('tests', type : 'feature', value : 'auto', yield : true,
9 | description : 'Build and enable unit tests')
10 | option('tools', type : 'feature', value : 'auto', yield : true,
11 | description : 'Build ges-launch command line tool')
12 |
13 | # GES options
14 | option('bash-completion', type : 'feature', value : 'auto',
15 | description : 'Install bash completion files')
16 | option('pygi-overrides-dir', type : 'string', value : '',
17 | description: 'Path to pygobject overrides directory')
18 | option('xptv', type : 'feature', value : 'auto',
19 | description : 'Build the deprecated xptv formater')
20 | option('python', type : 'feature', value : 'auto', yield: true,
21 | description: 'Enable python formatters.')
22 | option('libpython-dir', type : 'string', value : '',
23 | description: 'Path to find libpythonXX.so')
24 | option('validate', type : 'feature', value : 'auto', yield: true,
25 | description: 'Enable GstValidate integration.')
26 | option('examples', type : 'feature', value : 'auto', yield : true)
--------------------------------------------------------------------------------
/tools/ges-launch.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Edward Hervey
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #include
21 | #include /* for LC_ALL */
22 | #include "ges-launcher.h"
23 |
24 |
25 | int
26 | main (int argc, gchar ** argv)
27 | {
28 | GESLauncher *launcher;
29 | gint ret;
30 |
31 | setlocale (LC_ALL, "");
32 |
33 | launcher = ges_launcher_new ();
34 |
35 | ret = g_application_run (G_APPLICATION (launcher), argc, argv);
36 |
37 | if (!ret)
38 | ret = ges_launcher_get_exit_status (launcher);
39 |
40 | g_object_unref (launcher);
41 | ges_deinit ();
42 | gst_deinit ();
43 |
44 | return ret;
45 | }
46 |
--------------------------------------------------------------------------------
/plugins/ges/gesbasebin.h:
--------------------------------------------------------------------------------
1 | /* GStreamer GES plugin
2 | *
3 | * Copyright (C) 2019 Thibault Saunier
4 | *
5 | * gesbasebin.h
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | *
22 | */
23 |
24 | #pragma once
25 |
26 | #include
27 | #include
28 | #include
29 |
30 | G_BEGIN_DECLS
31 |
32 | #define SUPRESS_UNUSED_WARNING(a) (void)a
33 |
34 | G_DECLARE_DERIVABLE_TYPE(GESBaseBin, ges_base_bin, GES, BASE_BIN, GstBin)
35 | struct _GESBaseBinClass
36 | {
37 | GstBinClass parent_class;
38 | };
39 |
40 | gboolean ges_base_bin_set_timeline (GESBaseBin * self, GESTimeline * timeline);
41 | GESTimeline * ges_base_bin_get_timeline (GESBaseBin * self);
42 |
43 | G_END_DECLS
44 |
--------------------------------------------------------------------------------
/ges/ges-xml-formatter.h:
--------------------------------------------------------------------------------
1 | /* Gstreamer Editing Services
2 | *
3 | * Copyright (C) <2012> Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 | #pragma once
21 |
22 | #include "ges-base-xml-formatter.h"
23 |
24 | G_BEGIN_DECLS
25 | #define GES_TYPE_XML_FORMATTER (ges_xml_formatter_get_type ())
26 | GES_DECLARE_TYPE(XmlFormatter, xml_formatter, XML_FORMATTER);
27 |
28 | struct _GESXmlFormatter
29 | {
30 | GESBaseXmlFormatter parent;
31 |
32 | GESXmlFormatterPrivate *priv;
33 |
34 | gpointer _ges_reserved[GES_PADDING];
35 | };
36 |
37 | struct _GESXmlFormatterClass
38 | {
39 | GESBaseXmlFormatterClass parent;
40 |
41 | gpointer _ges_reserved[GES_PADDING];
42 | };
43 |
44 | G_END_DECLS
45 |
--------------------------------------------------------------------------------
/examples/python/gst-player.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/python3
2 | import sys
3 | import gi
4 |
5 | gi.require_version('Gst', '1.0')
6 | gi.require_version('GES', '1.0')
7 | gi.require_version('GstPlayer', '1.0')
8 | gi.require_version('GLib', '2.0')
9 |
10 | from gi.repository import Gst, GES, GLib, GstPlayer
11 |
12 |
13 | if __name__ == "__main__":
14 | if len(sys.argv) < 2:
15 | print("You must specify a file URI")
16 | sys.exit(-1)
17 |
18 | Gst.init(None)
19 | GES.init()
20 |
21 | timeline = GES.Timeline.new_audio_video()
22 | layer = timeline.append_layer()
23 | start = 0
24 | for uri in sys.argv[1:]:
25 | if not Gst.uri_is_valid(uri):
26 | uri = Gst.filename_to_uri(uri)
27 |
28 | clip = GES.UriClip.new(uri)
29 | clip.props.start = start
30 | layer.add_clip(clip)
31 |
32 | start += clip.props.duration
33 |
34 | player = GstPlayer
35 | player = GstPlayer.Player.new(None, GstPlayer.PlayerGMainContextSignalDispatcher.new(None))
36 | player.set_uri("ges://")
37 | player.get_pipeline().connect("source-setup",
38 | lambda playbin, source: source.set_property("timeline", timeline))
39 |
40 | loop = GLib.MainLoop()
41 | player.connect("end-of-stream", lambda x: loop.quit())
42 |
43 | def error(player, err):
44 | loop.quit()
45 | print("Got error: %s" % err)
46 | sys.exit(1)
47 |
48 | player.connect("error", error)
49 | player.play()
50 | loop.run()
51 |
--------------------------------------------------------------------------------
/ges/ges-time-overlay-clip.c:
--------------------------------------------------------------------------------
1 | /**
2 | * SECTION:gestimeoverlayclip
3 | * @title: GESTimeOverlayClip
4 | * @short_description: Source with a time overlay on top
5 | * @symbols:
6 | * - ges_source_clip_new_time_overlay
7 | *
8 | * A #GESSourceClip that overlays timing information on top.
9 | *
10 | * ## Asset
11 | *
12 | * The default asset ID is "time-overlay" (of type #GES_TYPE_SOURCE_CLIP),
13 | * but the framerate and video size can be overridden using an ID of the form:
14 | *
15 | * ```
16 | * time-overlay, framerate=60/1, width=1920, height=1080, max-duration=5.0
17 | * ```
18 | *
19 | * ## Children properties
20 | *
21 | * {{ libs/GESTimeOverlayClip-children-props.md }}
22 | *
23 | * ## Symbols
24 | */
25 |
26 | #ifdef HAVE_CONFIG_H
27 | #include "config.h"
28 | #endif
29 |
30 | #include "ges-asset.h"
31 | #include "ges-time-overlay-clip.h"
32 |
33 |
34 | /**
35 | * ges_source_clip_new_time_overlay:
36 | *
37 | * Creates a new #GESSourceClip that renders a time overlay on top
38 | *
39 | * Returns: (transfer floating) (nullable): The newly created #GESSourceClip,
40 | * or %NULL if there was an error.
41 | * Since: 1.18
42 | */
43 | GESSourceClip *
44 | ges_source_clip_new_time_overlay (void)
45 | {
46 | GESSourceClip *new_clip;
47 | GESAsset *asset = ges_asset_request (GES_TYPE_SOURCE_CLIP,
48 | "time-overlay", NULL);
49 |
50 | new_clip = GES_SOURCE_CLIP (ges_asset_extract (asset, NULL));
51 | gst_object_unref (asset);
52 |
53 | return new_clip;
54 | }
55 |
--------------------------------------------------------------------------------
/tests/check/scenarios/check_edit_in_frames.scenario:
--------------------------------------------------------------------------------
1 | description, handles-states=true,
2 | ges-options={\
3 | --track-types, video\
4 | }
5 |
6 | add-clip, name=clip, asset-id=GESTestClip, layer-priority=0, type=GESTestClip, start=f0, inpoint=f30, duration=f60
7 |
8 | check-ges-properties, element-name=clip, start=0, in-point=1.0, duration=2.0
9 | edit, element-name=clip, position=f30
10 |
11 | check-ges-properties, element-name=clip, start=1.0, in-point=1.0, duration=2.0
12 |
13 | # Getting the 60th frame in the input media file, means inpoint=f30 + f30 = f60
14 | edit, element-name=clip, position=f60, edit-mode=edit_trim, edge=edge_end
15 | check-ges-properties, element-name=clip, start=1.0, in-point=1.0, duration=1.0
16 |
17 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1280,height=720,framerate=60/1"
18 |
19 | # 60 frames in media time, meaning 90 - inpoint (30) / 30 = 2 seconds
20 | edit, element-name=clip, source-frame=90, edit-mode=edit_trim, edge=edge_end
21 | check-ges-properties, element-name=clip, start=1.0, in-point=1.0, duration=2.0
22 |
23 | # 60 frames in timeline time, meaning 60/60 = 1 second
24 | edit, element-name=clip, position=f60
25 | check-ges-properties, element-name=clip, start=1.0, in-point=1.0, duration=2.0
26 |
27 | # 60 frames in timeline time, meaning 60/60 = 1 second
28 | edit, element-name=clip, source-frame=75, edit-mode=trim, edge=start
29 | check-ges-properties, element-name=clip, start=2.5, in-point=2.5, duration=0.5
30 |
31 | stop
--------------------------------------------------------------------------------
/ges/ges-transition.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | /**
22 | * SECTION:gestransition
23 | * @title: GESTransition
24 | * @short_description: base class for audio and video transitions
25 | *
26 | */
27 | #ifdef HAVE_CONFIG_H
28 | #include "config.h"
29 | #endif
30 |
31 | #include
32 | #include "ges-internal.h"
33 |
34 | G_DEFINE_ABSTRACT_TYPE (GESTransition, ges_transition, GES_TYPE_OPERATION);
35 |
36 | static void
37 | ges_transition_class_init (GESTransitionClass * klass)
38 | {
39 | }
40 |
41 | static void
42 | ges_transition_init (GESTransition * self)
43 | {
44 | }
45 |
--------------------------------------------------------------------------------
/tools/ges-launcher-kb.h:
--------------------------------------------------------------------------------
1 | /* GStreamer command line playback testing utility - keyboard handling helpers
2 | *
3 | * Copyright (C) 2013 Tim-Philipp Müller
4 | * Copyright (C) 2013 Centricular Ltd
5 | *
6 | * This library is free software; you can redistribute it and/or
7 | * modify it under the terms of the GNU Library General Public
8 | * License as published by the Free Software Foundation; either
9 | * version 2 of the License, or (at your option) any later version.
10 | *
11 | * This library is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | * Library General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Library General Public
17 | * License along with this library; if not, write to the
18 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
19 | * Boston, MA 02110-1301, USA.
20 | */
21 | #ifndef __GST_PLAY_KB_INCLUDED__
22 | #define __GST_PLAY_KB_INCLUDED__
23 |
24 | #include
25 |
26 | #define GST_PLAY_KB_ARROW_UP "\033[A"
27 | #define GST_PLAY_KB_ARROW_DOWN "\033[B"
28 | #define GST_PLAY_KB_ARROW_RIGHT "\033[C"
29 | #define GST_PLAY_KB_ARROW_LEFT "\033[D"
30 |
31 | typedef void (*GstPlayKbFunc) (const gchar * kb_input, gpointer user_data);
32 |
33 | gboolean gst_play_kb_set_key_handler (GstPlayKbFunc kb_func, gpointer user_data);
34 |
35 | #endif /* __GST_PLAY_KB_INCLUDED__ */
36 |
--------------------------------------------------------------------------------
/tools/ges-launch-1.0.1:
--------------------------------------------------------------------------------
1 | .TH GES\-LAUNCH\-1.0 "1" "December 2016" "GStreamer Editing Services API version 1.0" "User Commands"
2 | .SH NAME
3 | ges\-launch\-1.0 \- create and render multimedia timelines
4 | .SH "SYNOPSIS"
5 | \fBges\-launch\-1.0\fR \fI[OPTION...]\fR
6 | .SH DESCRIPTION
7 | ges\-launch\-1.0 creates a multimedia timeline and plays it back,
8 | or renders it to the specified format.
9 | .PP
10 | It can load a timeline from an existing project, or create one
11 | from the specified commands.
12 | .PP
13 | You can learn more about individual ges\-launch\-1.0 commands with
14 | "ges\-launch\-1.0 help command".
15 | .PP
16 | By default, ges\-launch\-1.0 is in "playback\-mode".
17 | .SH "OPTIONS"
18 | For the full list of \fIges\-launch\-1.0\fP options see the command line help:
19 | .TP 8
20 | \fB\-h\fR, \fB\-\-help\fR
21 | Show help options
22 | .TP 8
23 | \fB\-\-help\-all\fR
24 | Show all help options
25 | .TP 8
26 | \fB\-\-help\-gst\fR
27 | Show GStreamer Options
28 | .TP 8
29 | \fB\-\-help\-GES\fR
30 | Show GES Options
31 | .TP 8
32 | \fB\-\-help\-project\fR
33 | Show project\-related options
34 | .TP 8
35 | \fB\-\-help\-rendering\fR
36 | Show rendering options
37 | .TP 8
38 | \fB\-\-help\-playback\fR
39 | Show playback options
40 | .TP 8
41 | \fB\-\-help\-informative\fR
42 | Show informative options
43 | .SH "SEE ALSO"
44 | For more detailed info and some examples of use, also check out the on-line documentation:
45 | .br
46 | https://gstreamer.freedesktop.org/documentation/tools/ges-launch.html
47 | .SH "AUTHOR"
48 | Antonio Ospite https://ao2.it
49 |
--------------------------------------------------------------------------------
/docs/sitemap.txt:
--------------------------------------------------------------------------------
1 | gi-index
2 | ges.h
3 | ges-timeline.h
4 | ges-layer.h
5 | ges-clip.h
6 | ges-uri-clip.h
7 | ges-title-clip.h
8 | ges-test-clip.h
9 | ges-time-overlay-clip.h
10 | ges-effect-clip.h
11 | ges-transition-clip.h
12 | ges-pipeline.h
13 | ges-project.h
14 | base-classes.md
15 | ges-timeline-element.h
16 | ges-container.h
17 | ges-track.h
18 | ges-audio-track.h
19 | ges-video-track.h
20 | ges-asset.h
21 | ges-uri-asset.h
22 | ges-clip-asset.h
23 | ges-effect-asset.h
24 | ges-track-element-asset.h
25 | ges-source-clip-asset.h
26 | ges-effect.h
27 | ges-extractable.h
28 | ges-group.h
29 | ges-meta-container.h
30 | ges-marker-list.h
31 | ges-formatter.h
32 | ges-xml-formatter.h
33 | ges-track-element.h
34 | ges-video-source.h
35 | ges-audio-source.h
36 | ges-audio-test-source.h
37 | ges-audio-uri-source.h
38 | ges-video-uri-source.h
39 | ges-video-test-source.h
40 | ges-title-source.h
41 | ges-text-overlay.h
42 | ges-gerror.h
43 | ges-types.h
44 | ges-enums.h
45 | ges-utils.h
46 | low_level.md
47 | ges-base-xml-formatter.h
48 | ges-command-line-formatter.h
49 | ges-audio-transition.h
50 | ges-base-effect-clip.h
51 | ges-base-effect.h
52 | ges-base-transition-clip.h
53 | ges-operation-clip.h
54 | ges-operation.h
55 | ges-overlay-clip.h
56 | ges-source-clip.h
57 | ges-source.h
58 | ges-text-overlay-clip.h
59 | ges-transition.h
60 | ges-video-transition.h
61 | ges-prelude.h
62 | deprecated.md
63 | ges-pitivi-formatter.h
64 | ges-image-source.h
65 | ges-multi-file-source.h
--------------------------------------------------------------------------------
/ges/parse.l:
--------------------------------------------------------------------------------
1 | %{
2 | #include "ges-structure-parser.h"
3 |
4 | %}
5 |
6 | %option noyywrap
7 | %option nounput
8 | %option reentrant
9 | %option extra-type="GESStructureParser *"
10 | %option never-interactive
11 | %option noinput
12 | %option nounistd
13 |
14 | CLIP [ ]+\+clip[ ]+
15 | TEST_CLIP [ ]+\+test-clip[ ]+
16 | TRANSITION [ ]+\+transition[ ]+
17 | EFFECT [ ]+\+effect[ ]+
18 | TITLE [ ]+\+title[ ]+
19 | TRACK [ ]+\+track[ ]+
20 | KEYFRAME [ ]+\+keyframes[ ]+
21 |
22 | SETTER [ ]+set-[^ ]+[ ]+
23 |
24 | STRING \"(\\.|[^"])*\"
25 | /* A value string, as understood by gst_structure_from_string
26 | * Characters are from GST_ASCII_IS_STRING
27 | * NOTE: character set is *not* supposed to be locale dependent */
28 | VALUE {STRING}|([abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_+/:.-]+)
29 |
30 | %%
31 |
32 | ={VALUE} {
33 | ges_structure_parser_parse_value (yyextra, yytext);
34 | }
35 |
36 | {STRING} {
37 | ges_structure_parser_parse_string (yyextra, yytext, FALSE);
38 | }
39 |
40 | {KEYFRAME}|{TRACK}|{CLIP}|{TRANSITION}|{EFFECT}|{TEST_CLIP}|{TITLE} {
41 | ges_structure_parser_parse_symbol (yyextra, yytext);
42 | }
43 |
44 | {SETTER} {
45 | ges_structure_parser_parse_setter (yyextra, yytext);
46 | }
47 |
48 | [ \t\n]+ {
49 | ges_structure_parser_parse_whitespace (yyextra);
50 | }
51 |
52 | . {
53 | /* add everything else */
54 | ges_structure_parser_parse_default (yyextra, yytext);
55 | }
56 |
57 | %%
58 |
--------------------------------------------------------------------------------
/ges/ges-effect-asset.h:
--------------------------------------------------------------------------------
1 |
2 | /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4; tab-width: 4 -*- */
3 | /*
4 | * gst-editing-services
5 | * Copyright (C) 2013 Thibault Saunier
6 | *
7 | gst-editing-services is free software: you can redistribute it and/or modify it
8 | * under the terms of the GNU Lesser General Public License as published
9 | * by the Free Software Foundation, either version 3 of the License, or
10 | * (at your option) any later version.
11 | *
12 | * gst-editing-services is distributed in the hope that it will be useful, but
13 | * WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15 | * See the GNU Lesser General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Lesser General Public License
18 | * along with this program. If not, see .";
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include "ges-track-element-asset.h"
25 |
26 | G_BEGIN_DECLS
27 |
28 | #define GES_TYPE_EFFECT_ASSET (ges_effect_asset_get_type ())
29 | GES_DECLARE_TYPE(EffectAsset, effect_asset, EFFECT_ASSET);
30 |
31 | struct _GESEffectAssetClass
32 | {
33 | GESTrackElementAssetClass parent_class;
34 |
35 | gpointer _ges_reserved[GES_PADDING];
36 | };
37 |
38 | struct _GESEffectAsset
39 | {
40 | GESTrackElementAsset parent_instance;
41 |
42 | GESEffectAssetPrivate *priv;
43 |
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | G_END_DECLS
48 |
--------------------------------------------------------------------------------
/ges/ges-group.h:
--------------------------------------------------------------------------------
1 | /* * Gstreamer
2 | *
3 | * Copyright (C) <2013> Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 | #pragma once
21 |
22 | #include
23 | #include
24 | #include "ges-clip.h"
25 | #include "ges-container.h"
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_GROUP (ges_group_get_type ())
30 | GES_DECLARE_TYPE(Group, group, GROUP);
31 |
32 | struct _GESGroup {
33 | GESContainer parent;
34 |
35 | /*< private >*/
36 | GESGroupPrivate *priv;
37 |
38 | gpointer _ges_reserved[GES_PADDING];
39 | };
40 |
41 | struct _GESGroupClass {
42 | GESContainerClass parent_class;
43 |
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | GES_API
48 | GESGroup *ges_group_new (void);
49 |
50 | G_END_DECLS
51 |
--------------------------------------------------------------------------------
/tests/check/scenarios/seek_with_stop.validatetest:
--------------------------------------------------------------------------------
1 | meta,
2 | tool = "ges-launch-$(gst_api_version)",
3 | args = {
4 | --videosink, "$(videosink) sync=false name=videosink",
5 | --audiosink, "$(audiosink) sync=false name=audiosink",
6 | --video-caps, "video/x-raw,format=I420,width=1280,height=720,framerate=30/1,chroma-site=mpeg2,colorimetry=bt709",
7 | },
8 | handles-states=true,
9 | ignore-eos=true,
10 | configs = {
11 | "$(validateflow), pad=videosink:sink, record-buffers=true, ignored-fields=\"stream-start={stream-id,group-id,stream}, segment={position,}\", ignored-event-types={gap}",
12 | "$(validateflow), pad=audiosink:sink, record-buffers=true, ignored-fields=\"stream-start={stream-id,group-id,stream}, segment={position,}\", ignored-event-types={gap}",
13 | }
14 |
15 | add-clip, name=c0, asset-id=time-overlay, layer-priority=0, type=GESSourceClip, start=0, duration=1.0
16 | set-child-properties, element-name=c0, pattern=blue, valignment=center, halignment=center, time-mode=time-code
17 |
18 | add-clip, name=c1, asset-id=time-overlay, layer-priority=0, type=GESSourceClip, start=1.0, duration=1.0
19 | set-child-properties, element-name=c1, pattern=red, valignment=center, halignment=center, time-mode=time-code
20 | pause
21 |
22 | seek, start=0.0, stop=0.5, flags=accurate+flush
23 | play
24 |
25 | seek, on-message=eos, start=0.0, stop=0.5, flags=accurate+flush
26 | seek, on-message=eos, start=0.0, stop=1.0, flags=accurate+flush
27 | seek, on-message=eos, start=1.0, stop=1.5, flags=accurate+flush
28 | stop, on-message=eos
--------------------------------------------------------------------------------
/tools/ges-validate.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | *
3 | * Copyright (C) <2013> Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 | #pragma once
21 |
22 | #include
23 | #include
24 | #include
25 | #include
26 |
27 | #include "utils.h"
28 | #include "ges-launcher.h"
29 |
30 | G_BEGIN_DECLS
31 |
32 | gboolean
33 | ges_validate_activate(GstPipeline* pipeline, GESLauncher *launcher, GESLauncherParsedOptions* opts);
34 | void ges_launch_validate_uri(const gchar* nid);
35 |
36 | gint
37 | ges_validate_clean (GstPipeline *pipeline);
38 |
39 | void ges_validate_handle_request_state_change (GstMessage *message, GApplication *application);
40 | gint ges_validate_print_action_types (const gchar **types, gint num_types);
41 |
42 | G_END_DECLS
43 |
--------------------------------------------------------------------------------
/plugins/nle/nletypes.h:
--------------------------------------------------------------------------------
1 | /* GStreamer
2 | * Copyright (C) 2004 Edward Hervey
3 | *
4 | * nletypes.h: Header for class definition
5 | *
6 | * This library is free software; you can redistribute it and/or
7 | * modify it under the terms of the GNU Library General Public
8 | * License as published by the Free Software Foundation; either
9 | * version 2 of the License, or (at your option) any later version.
10 | *
11 | * This library is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | * Library General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Library General Public
17 | * License along with this library; if not, write to the
18 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
19 | * Boston, MA 02110-1301, USA.
20 | */
21 |
22 | #ifndef __NLE_TYPES_H__
23 | #define __NLE_TYPES_H__
24 |
25 | #include
26 |
27 | typedef struct _NleObject NleObject;
28 | typedef struct _NleObjectClass NleObjectClass;
29 |
30 | typedef struct _NleComposition NleComposition;
31 | typedef struct _NleCompositionClass NleCompositionClass;
32 |
33 | typedef struct _NleOperation NleOperation;
34 | typedef struct _NleOperationClass NleOperationClass;
35 |
36 | typedef struct _NleSource NleSource;
37 | typedef struct _NleSourceClass NleSourceClass;
38 |
39 | typedef struct _NleURISource NleURISource;
40 | typedef struct _NleURISourceClass NleURISourceClass;
41 |
42 | #endif
43 |
--------------------------------------------------------------------------------
/ges/ges-uri-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2020 Ubicast SAS
3 | * Author: Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 |
26 | G_BEGIN_DECLS
27 |
28 | typedef struct _GESUriSource GESUriSource;
29 |
30 | struct _GESUriSource
31 | {
32 | GstElement *decodebin; /* Reference owned by parent class */
33 | gchar *uri;
34 |
35 | GESTrackElement *element;
36 | };
37 |
38 | G_GNUC_INTERNAL gboolean ges_uri_source_select_pad (GESSource *self, GstPad *pad);
39 | G_GNUC_INTERNAL GstElement *ges_uri_source_create_source (GESUriSource *self);
40 | G_GNUC_INTERNAL void ges_uri_source_init (GESTrackElement *element, GESUriSource *self);
41 |
42 | G_END_DECLS
43 |
--------------------------------------------------------------------------------
/ges/ges-source-clip-asset.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2020 Igalia S.L
3 | * Author: 2020 Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 |
25 | G_BEGIN_DECLS
26 |
27 | #define GES_TYPE_SOURCE_CLIP_ASSET ges_source_clip_asset_get_type ()
28 |
29 | /**
30 | * GESSourceClipAsset:
31 | *
32 | * An asset types from which #GESSourceClip will be extracted
33 | *
34 | * Since: 1.18
35 | */
36 | GES_API
37 | G_DECLARE_DERIVABLE_TYPE(GESSourceClipAsset, ges_source_clip_asset, GES,
38 | SOURCE_CLIP_ASSET, GESClipAsset);
39 |
40 | struct _GESSourceClipAssetClass
41 | {
42 | GESClipAssetClass parent_class;
43 | /* FIXME 2.0: Add some padding, meanwhile that would break ABI */
44 | };
45 |
46 |
47 | G_END_DECLS
--------------------------------------------------------------------------------
/ges/ges-operation.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | /**
22 | * SECTION:gesoperation
23 | * @title: GESOperation
24 | * @short_description: Base Class for effects and overlays
25 | */
26 | #ifdef HAVE_CONFIG_H
27 | #include "config.h"
28 | #endif
29 |
30 | #include "ges-internal.h"
31 | #include "ges-track-element.h"
32 | #include "ges-operation.h"
33 |
34 | G_DEFINE_ABSTRACT_TYPE (GESOperation, ges_operation, GES_TYPE_TRACK_ELEMENT);
35 |
36 | static void
37 | ges_operation_class_init (GESOperationClass * klass)
38 | {
39 | GESTrackElementClass *track_class = GES_TRACK_ELEMENT_CLASS (klass);
40 |
41 | track_class->nleobject_factorytype = "nleoperation";
42 | }
43 |
44 | static void
45 | ges_operation_init (GESOperation * self)
46 | {
47 | }
48 |
--------------------------------------------------------------------------------
/ges/ges-video-track.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) <2013> Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 |
24 | #include "ges-track.h"
25 | #include "ges-types.h"
26 |
27 | G_BEGIN_DECLS
28 | #define GES_TYPE_VIDEO_TRACK (ges_video_track_get_type ())
29 | GES_DECLARE_TYPE(VideoTrack, video_track, VIDEO_TRACK);
30 |
31 | struct _GESVideoTrackClass
32 | {
33 | GESTrackClass parent_class;
34 |
35 | /* Padding for API extension */
36 | gpointer _ges_reserved[GES_PADDING];
37 | };
38 |
39 | struct _GESVideoTrack
40 | {
41 | GESTrack parent_instance;
42 |
43 | /*< private >*/
44 | GESVideoTrackPrivate *priv;
45 |
46 | /* Padding for API extension */
47 | gpointer _ges_reserved[GES_PADDING];
48 | };
49 |
50 | GES_API
51 | GESVideoTrack * ges_video_track_new (void);
52 |
53 | G_END_DECLS
54 |
--------------------------------------------------------------------------------
/ges/ges-audio-track.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) <2013> Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 |
24 | #include "ges-track.h"
25 | #include "ges-types.h"
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_AUDIO_TRACK (ges_audio_track_get_type ())
30 | GES_DECLARE_TYPE(AudioTrack, audio_track, AUDIO_TRACK);
31 |
32 |
33 | struct _GESAudioTrackClass
34 | {
35 | GESTrackClass parent_class;
36 |
37 | /* Padding for API extension */
38 | gpointer _ges_reserved[GES_PADDING];
39 | };
40 |
41 | struct _GESAudioTrack
42 | {
43 | GESTrack parent_instance;
44 |
45 | /*< private >*/
46 | GESAudioTrackPrivate *priv;
47 | /* Padding for API extension */
48 | gpointer _ges_reserved[GES_PADDING];
49 | };
50 |
51 | GES_API
52 | GESAudioTrack* ges_audio_track_new (void);
53 |
54 | G_END_DECLS
--------------------------------------------------------------------------------
/tests/check/assets/test-project.xges:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/tools/ges-launcher.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2015 Mathieu Duponchelle
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 |
24 | #include "utils.h"
25 |
26 | G_BEGIN_DECLS
27 |
28 | #define GES_TYPE_LAUNCHER ges_launcher_get_type()
29 |
30 | typedef struct _GESLauncherPrivate GESLauncherPrivate;
31 | G_DECLARE_FINAL_TYPE(GESLauncher, ges_launcher, GES, LAUNCHER, GApplication);
32 |
33 | struct _GESLauncher {
34 | GApplication parent;
35 |
36 | /*< private >*/
37 | GESLauncherPrivate *priv;
38 |
39 | /* Padding for API extension */
40 | gpointer _ges_reserved[GES_PADDING];
41 | };
42 |
43 | GESLauncher* ges_launcher_new (void);
44 | gint ges_launcher_get_exit_status (GESLauncher *self);
45 | gboolean ges_launcher_parse_options(GESLauncher* self, gchar*** arguments, gint *argc, GOptionContext* ctx, GError** error);
46 |
47 | G_END_DECLS
48 |
--------------------------------------------------------------------------------
/ges/ges-image-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_IMAGE_SOURCE ges_image_source_get_type()
30 | GES_DECLARE_TYPE(ImageSource, image_source, IMAGE_SOURCE);
31 |
32 | /**
33 | * GESImageSource:
34 | */
35 | struct _GESImageSource {
36 | /*< private >*/
37 | GESVideoSource parent;
38 |
39 | gchar *uri;
40 |
41 | GESImageSourcePrivate *priv;
42 |
43 | /* Padding for API extension */
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | struct _GESImageSourceClass {
48 | GESVideoSourceClass parent_class;
49 |
50 | /* Padding for API extension */
51 | gpointer _ges_reserved[GES_PADDING];
52 | };
53 |
54 | G_END_DECLS
55 |
--------------------------------------------------------------------------------
/plugins/ges/gesplugin.c:
--------------------------------------------------------------------------------
1 | /* GStreamer GES plugin
2 | *
3 | * Copyright (C) 2015 Thibault Saunier
4 | *
5 | * gstges.c
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | *
22 | */
23 |
24 | #ifdef HAVE_CONFIG_H
25 | #include "config.h"
26 | #endif
27 |
28 | #include
29 |
30 | extern GType ges_demux_get_type ();
31 | extern GType ges_src_get_type ();
32 |
33 | static gboolean
34 | plugin_init (GstPlugin * plugin)
35 | {
36 | gboolean res = 1;
37 |
38 | res |=
39 | gst_element_register (plugin, "gessrc", GST_RANK_NONE,
40 | ges_src_get_type ());
41 |
42 | res |= gst_element_register (plugin, "gesdemux", GST_RANK_PRIMARY,
43 | ges_demux_get_type ());
44 |
45 | return res;
46 | }
47 |
48 | /* plugin export resolution */
49 | GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
50 | GST_VERSION_MINOR,
51 | ges,
52 | "GStreamer Editing Services Plugin",
53 | plugin_init, VERSION, "LGPL", GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN);
54 |
--------------------------------------------------------------------------------
/ges/ges-base-effect-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2011 Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 |
25 | G_BEGIN_DECLS
26 |
27 | #define GES_TYPE_BASE_EFFECT_CLIP ges_base_effect_clip_get_type()
28 | GES_DECLARE_TYPE(BaseEffectClip, base_effect_clip, BASE_EFFECT_CLIP);
29 |
30 | /**
31 | * GESBaseEffectClip:
32 | */
33 | struct _GESBaseEffectClip {
34 | /*< private >*/
35 | GESOperationClip parent;
36 |
37 | GESBaseEffectClipPrivate *priv;
38 |
39 | /* Padding for API extension */
40 | gpointer _ges_reserved[GES_PADDING];
41 | };
42 |
43 | /**
44 | * GESBaseEffectClipClass:
45 | *
46 | */
47 |
48 | struct _GESBaseEffectClipClass {
49 | /*< private >*/
50 | GESOperationClipClass parent_class;
51 |
52 | /* Padding for API extension */
53 | gpointer _ges_reserved[GES_PADDING];
54 | };
55 |
56 | G_END_DECLS
--------------------------------------------------------------------------------
/tests/check/assets/test-auto-transition.xges:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/ges/ges-base-transition-clip.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | /**
22 | * SECTION: gesbasetransitionclip
23 | * @title: GESBaseTransitionClip
24 | * @short_description: Base classes for transitions
25 | */
26 | #ifdef HAVE_CONFIG_H
27 | #include "config.h"
28 | #endif
29 |
30 | #include
31 | #include "ges-internal.h"
32 |
33 | struct _GESBaseTransitionClipPrivate
34 | {
35 | /* Dummy variable */
36 | void *nothing;
37 | };
38 |
39 | G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (GESBaseTransitionClip,
40 | ges_base_transition_clip, GES_TYPE_OPERATION_CLIP);
41 |
42 | static void
43 | ges_base_transition_clip_class_init (GESBaseTransitionClipClass * klass)
44 | {
45 | }
46 |
47 | static void
48 | ges_base_transition_clip_init (GESBaseTransitionClip * self)
49 | {
50 | self->priv = ges_base_transition_clip_get_instance_private (self);
51 | }
52 |
--------------------------------------------------------------------------------
/ges/ges-operation-clip.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | /**
22 | * SECTION:gesoperationclip
23 | * @title: GESOperationClip
24 | * @short_description: Base Class for operations in a GESLayer
25 | *
26 | * Operations are any kind of object that both outputs AND consumes data.
27 | */
28 | #ifdef HAVE_CONFIG_H
29 | #include "config.h"
30 | #endif
31 |
32 | #include "ges.h"
33 | #include "ges-internal.h"
34 | #include "ges-operation-clip.h"
35 |
36 | struct _GESOperationClipPrivate
37 | {
38 | void *nada;
39 | };
40 |
41 | G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (GESOperationClip, ges_operation_clip,
42 | GES_TYPE_CLIP);
43 |
44 | static void
45 | ges_operation_clip_class_init (GESOperationClipClass * klass)
46 | {
47 | }
48 |
49 | static void
50 | ges_operation_clip_init (GESOperationClip * self)
51 | {
52 | self->priv = ges_operation_clip_get_instance_private (self);
53 | }
54 |
--------------------------------------------------------------------------------
/ges/ges-overlay-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_OVERLAY_CLIP ges_overlay_clip_get_type()
30 | GES_DECLARE_TYPE(OverlayClip, overlay_clip, OVERLAY_CLIP);
31 |
32 | /**
33 | * GESOverlayClip:
34 | */
35 |
36 | struct _GESOverlayClip {
37 | /*< private >*/
38 | GESOperationClip parent;
39 |
40 | GESOverlayClipPrivate *priv;
41 |
42 | /* Padding for API extension */
43 | gpointer _ges_reserved[GES_PADDING];
44 | };
45 |
46 | /**
47 | * GESOverlayClipClass:
48 | * @parent_class: parent class
49 | */
50 |
51 | struct _GESOverlayClipClass {
52 | GESOperationClipClass parent_class;
53 |
54 | /*< private >*/
55 | /* Padding for API extension */
56 | gpointer _ges_reserved[GES_PADDING];
57 | };
58 | G_END_DECLS
59 |
--------------------------------------------------------------------------------
/scripts/extract-release-date-from-doap-file.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 | #
3 | # extract-release-date-from-doap-file.py VERSION DOAP-FILE
4 | #
5 | # Extract release date for the given release version from a DOAP file
6 | #
7 | # Copyright (C) 2020 Tim-Philipp Müller
8 | #
9 | # This library is free software; you can redistribute it and/or
10 | # modify it under the terms of the GNU Library General Public
11 | # License as published by the Free Software Foundation; either
12 | # version 2 of the License, or (at your option) any later version.
13 | #
14 | # This library is distributed in the hope that it will be useful,
15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 | # Library General Public License for more details.
18 | #
19 | # You should have received a copy of the GNU Library General Public
20 | # License along with this library; if not, write to the
21 | # Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
22 | # Boston, MA 02110-1301, USA.
23 |
24 | import sys
25 | import xml.etree.ElementTree as ET
26 |
27 | if len(sys.argv) != 3:
28 | sys.exit('Usage: {} VERSION DOAP-FILE'.format(sys.argv[0]))
29 |
30 | release_version = sys.argv[1]
31 | doap_fn = sys.argv[2]
32 |
33 | tree = ET.parse(doap_fn)
34 | root = tree.getroot()
35 |
36 | namespaces = {'doap': 'http://usefulinc.com/ns/doap#'}
37 |
38 | for v in root.findall('doap:release/doap:Version', namespaces=namespaces):
39 | if v.findtext('doap:revision', namespaces=namespaces) == release_version:
40 | release_date = v.findtext('doap:created', namespaces=namespaces)
41 | if release_date:
42 | print(release_date)
43 | sys.exit(0)
44 |
45 | sys.exit('Could not find a release with version {} in {}'.format(release_version, doap_fn))
46 |
--------------------------------------------------------------------------------
/ges/ges-audio-transition.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_AUDIO_TRANSITION ges_audio_transition_get_type()
30 | GES_DECLARE_TYPE(AudioTransition, audio_transition, AUDIO_TRANSITION);
31 |
32 | /**
33 | * GESAudioTransition:
34 | *
35 | */
36 |
37 | struct _GESAudioTransition {
38 | GESTransition parent;
39 |
40 | /*< private >*/
41 | GESAudioTransitionPrivate *priv;
42 |
43 | /* Padding for API extension */
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | struct _GESAudioTransitionClass {
48 | GESTransitionClass parent_class;
49 |
50 | /* Padding for API extension */
51 | gpointer _ges_reserved[GES_PADDING];
52 | };
53 |
54 | GES_DEPRECATED
55 | GESAudioTransition* ges_audio_transition_new (void);
56 |
57 | G_END_DECLS
58 |
--------------------------------------------------------------------------------
/ges/ges-source-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 |
28 | G_BEGIN_DECLS
29 |
30 | #define GES_TYPE_SOURCE_CLIP ges_source_clip_get_type()
31 | GES_DECLARE_TYPE(SourceClip, source_clip, SOURCE_CLIP);
32 |
33 | /**
34 | * GESSourceClip:
35 | *
36 | * Base class for sources of a #GESLayer
37 | */
38 |
39 | struct _GESSourceClip {
40 | GESClip parent;
41 |
42 | /*< private >*/
43 | GESSourceClipPrivate *priv;
44 |
45 | /* Padding for API extension */
46 | gpointer _ges_reserved[GES_PADDING];
47 | };
48 |
49 | /**
50 | * GESSourceClipClass:
51 | */
52 |
53 | struct _GESSourceClipClass {
54 | /*< private >*/
55 | GESClipClass parent_class;
56 |
57 | /* Padding for API extension */
58 | gpointer _ges_reserved[GES_PADDING];
59 | };
60 |
61 | G_END_DECLS
62 |
--------------------------------------------------------------------------------
/ges/ges-effect-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2011 Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 |
25 | G_BEGIN_DECLS
26 |
27 | #define GES_TYPE_EFFECT_CLIP ges_effect_clip_get_type()
28 | GES_DECLARE_TYPE(EffectClip, effect_clip, EFFECT_CLIP);
29 |
30 | /**
31 | * GESEffectClip:
32 | */
33 | struct _GESEffectClip {
34 | /*< private >*/
35 | GESBaseEffectClip parent;
36 |
37 | GESEffectClipPrivate *priv;
38 |
39 | /* Padding for API extension */
40 | gpointer _ges_reserved[GES_PADDING];
41 | };
42 |
43 | /**
44 | * GESEffectClipClass:
45 | *
46 | */
47 |
48 | struct _GESEffectClipClass {
49 | /*< private >*/
50 | GESBaseEffectClipClass parent_class;
51 |
52 | /* Padding for API extension */
53 | gpointer _ges_reserved[GES_PADDING];
54 | };
55 |
56 | GES_API GESEffectClip *
57 | ges_effect_clip_new (const gchar * video_bin_description,
58 | const gchar * audio_bin_description);
59 |
60 | G_END_DECLS
--------------------------------------------------------------------------------
/plugins/nle/nleghostpad.h:
--------------------------------------------------------------------------------
1 | /* GStreamer
2 | * Copyright (C) 2009 Edward Hervey
3 | *
4 | * nleghostpad.h: Header for helper ghostpad
5 | *
6 | * This library is free software; you can redistribute it and/or
7 | * modify it under the terms of the GNU Library General Public
8 | * License as published by the Free Software Foundation; either
9 | * version 2 of the License, or (at your option) any later version.
10 | *
11 | * This library is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | * Library General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Library General Public
17 | * License along with this library; if not, write to the
18 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
19 | * Boston, MA 02110-1301, USA.
20 | */
21 |
22 |
23 | #ifndef __NLE_GHOSTPAD_H__
24 | #define __NLE_GHOSTPAD_H__
25 |
26 | #include
27 |
28 | #include "nletypes.h"
29 |
30 | G_BEGIN_DECLS
31 |
32 | GstPad *nle_object_ghost_pad (NleObject * object,
33 | const gchar * name, GstPad * target) G_GNUC_INTERNAL;
34 |
35 | GstPad *nle_object_ghost_pad_no_target (NleObject * object,
36 | const gchar * name, GstPadDirection dir, GstPadTemplate *templ) G_GNUC_INTERNAL;
37 |
38 | gboolean nle_object_ghost_pad_set_target (NleObject * object,
39 | GstPad * ghost, GstPad * target) G_GNUC_INTERNAL;
40 |
41 | void nle_object_remove_ghost_pad (NleObject * object, GstPad * ghost) G_GNUC_INTERNAL;
42 | GstEvent * nle_object_translate_incoming_seek (NleObject * object, GstEvent * event) G_GNUC_INTERNAL;
43 |
44 | void nle_init_ghostpad_category (void) G_GNUC_INTERNAL;
45 |
46 | G_END_DECLS
47 |
48 | #endif /* __NLE_GHOSTPAD_H__ */
49 |
--------------------------------------------------------------------------------
/ges/ges-command-line-formatter.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | *
3 | * Copyright (C) <2015> Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include "ges-formatter.h"
25 |
26 | G_BEGIN_DECLS
27 |
28 | typedef struct _GESCommandLineFormatterClass GESCommandLineFormatterClass;
29 | typedef struct _GESCommandLineFormatter GESCommandLineFormatter;
30 |
31 | #define GES_TYPE_COMMAND_LINE_FORMATTER (ges_command_line_formatter_get_type ())
32 | GES_DECLARE_TYPE(CommandLineFormatter, command_line_formatter, COMMAND_LINE_FORMATTER);
33 |
34 | struct _GESCommandLineFormatterClass
35 | {
36 | GESFormatterClass parent_class;
37 | };
38 |
39 | struct _GESCommandLineFormatter
40 | {
41 | GESFormatter parent_instance;
42 |
43 | GESCommandLineFormatterPrivate *priv;
44 | };
45 |
46 | GES_API
47 | gchar * ges_command_line_formatter_get_help (gint nargs, gchar ** commands);
48 |
49 | GES_API
50 | gchar * ges_command_line_formatter_get_timeline_uri (GESTimeline *timeline);
51 |
52 | G_END_DECLS
53 |
--------------------------------------------------------------------------------
/ges/ges-multi-file-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2013 Lubosz Sarnecki
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 | #include
25 |
26 | G_BEGIN_DECLS
27 | #define GES_TYPE_MULTI_FILE_SOURCE ges_multi_file_source_get_type()
28 | GES_DECLARE_TYPE(MultiFileSource, multi_file_source, MULTI_FILE_SOURCE);
29 |
30 | /**
31 | * GESMultiFileSource:
32 | */
33 | struct _GESMultiFileSource
34 | {
35 | /*< private > */
36 | GESVideoSource parent;
37 |
38 | gchar *uri;
39 |
40 | GESMultiFileSourcePrivate *priv;
41 |
42 | /* Padding for API extension */
43 | gpointer _ges_reserved[GES_PADDING];
44 | };
45 |
46 | struct _GESMultiFileSourceClass
47 | {
48 | GESVideoSourceClass parent_class;
49 |
50 | /* Padding for API extension */
51 | gpointer _ges_reserved[GES_PADDING];
52 | };
53 |
54 | GES_API
55 | GESMultiFileSource *ges_multi_file_source_new (gchar * uri);
56 |
57 | #define GES_MULTI_FILE_URI_PREFIX "multifile://"
58 |
59 | G_END_DECLS
60 |
--------------------------------------------------------------------------------
/ges/ges-operation.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 |
28 | G_BEGIN_DECLS
29 |
30 | #define GES_TYPE_OPERATION ges_operation_get_type()
31 | GES_DECLARE_TYPE(Operation, operation, OPERATION);
32 |
33 | /**
34 | * GESOperation:
35 | *
36 | * Base class for overlays, transitions, and effects
37 | */
38 |
39 | struct _GESOperation {
40 | /*< private >*/
41 | GESTrackElement parent;
42 |
43 | GESOperationPrivate *priv;
44 |
45 | /* Padding for API extension */
46 | gpointer _ges_reserved[GES_PADDING];
47 | };
48 |
49 | /**
50 | * GESOperationClass:
51 | */
52 |
53 | struct _GESOperationClass {
54 | /*< private >*/
55 | GESTrackElementClass parent_class;
56 |
57 | /*< private >*/
58 | /* Padding for API extension */
59 | gpointer _ges_reserved[GES_PADDING];
60 | };
61 |
62 | G_END_DECLS
63 |
--------------------------------------------------------------------------------
/ges/ges-source-clip-asset.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2020 Igalia S.L
3 | * Author: 2020 Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | /**
22 | * SECTION: gessourceclipasset
23 | * @title: GESSourceClipAsset
24 | * @short_description: A GESAsset subclass, baseclass for #GESSourceClip-s extraction
25 | */
26 |
27 | #ifdef HAVE_CONFIG_H
28 | #include "config.h"
29 | #endif
30 |
31 | #include "ges-source-clip-asset.h"
32 | #include "ges-internal.h"
33 |
34 | G_DEFINE_TYPE (GESSourceClipAsset, ges_source_clip_asset, GES_TYPE_CLIP_ASSET);
35 |
36 | static gboolean
37 | get_natural_framerate (GESClipAsset * self, gint * framerate_n,
38 | gint * framerate_d)
39 | {
40 | *framerate_n = DEFAULT_FRAMERATE_N;
41 | *framerate_d = DEFAULT_FRAMERATE_D;
42 | return TRUE;
43 | }
44 |
45 | static void
46 | ges_source_clip_asset_class_init (GESSourceClipAssetClass * klass)
47 | {
48 | GES_CLIP_ASSET_CLASS (klass)->get_natural_framerate = get_natural_framerate;
49 | }
50 |
51 | static void
52 | ges_source_clip_asset_init (GESSourceClipAsset * self)
53 | {
54 | }
55 |
--------------------------------------------------------------------------------
/ges/ges-base-transition-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include "ges-operation-clip.h"
24 |
25 | #include
26 | #include
27 |
28 | G_BEGIN_DECLS
29 |
30 | #define GES_TYPE_BASE_TRANSITION_CLIP ges_base_transition_clip_get_type()
31 | GES_DECLARE_TYPE(BaseTransitionClip, base_transition_clip, BASE_TRANSITION_CLIP);
32 |
33 | /**
34 | * GESBaseTransitionClip:
35 | */
36 | struct _GESBaseTransitionClip {
37 | /*< private >*/
38 | GESOperationClip parent;
39 |
40 | /*< private >*/
41 | GESBaseTransitionClipPrivate *priv;
42 |
43 | /* Padding for API extension */
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | /**
48 | * GESBaseTransitionClipClass:
49 | *
50 | */
51 |
52 | struct _GESBaseTransitionClipClass {
53 | /*< private >*/
54 | GESOperationClipClass parent_class;
55 |
56 | /* Padding for API extension */
57 | gpointer _ges_reserved[GES_PADDING];
58 | };
59 |
60 | G_END_DECLS
61 |
--------------------------------------------------------------------------------
/ges/ges-screenshot.c:
--------------------------------------------------------------------------------
1 | /* Small helper element for format conversion
2 | * Copyright (C) 2005 Tim-Philipp Müller
3 | * Copyright (C) 2010 Brandon Lewis
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 | #ifdef HAVE_CONFIG_H
21 | #include "config.h"
22 | #endif
23 |
24 | #include
25 | #include
26 | #include "ges-screenshot.h"
27 | #include "ges-internal.h"
28 |
29 | /**
30 | * ges_play_sink_convert_frame:
31 | * @playsink: The playsink to get last frame from
32 | * @caps: The caps defining the format the return value will have
33 | *
34 | * Get the last buffer @playsink showed
35 | *
36 | * Returns: (transfer full): A #GstSample containing the last frame from
37 | * @playsink in the format defined by the @caps
38 | *
39 | * Deprecated: 1.18: Use the "convert-sample" action signal of
40 | * #playsink instead.
41 | */
42 | GstSample *
43 | ges_play_sink_convert_frame (GstElement * playsink, GstCaps * caps)
44 | {
45 | GstSample *sample = NULL;
46 |
47 | g_signal_emit_by_name (playsink, "convert-sample", caps, &sample);
48 |
49 | return sample;
50 | }
51 |
--------------------------------------------------------------------------------
/ges/ges-operation-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Edward Hervey
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 |
28 | G_BEGIN_DECLS
29 |
30 | #define GES_TYPE_OPERATION_CLIP ges_operation_clip_get_type()
31 | GES_DECLARE_TYPE(OperationClip, operation_clip, OPERATION_CLIP);
32 |
33 | /**
34 | * GESOperationClip:
35 | *
36 | * The GESOperationClip subclass. Subclasses can access these fields.
37 | */
38 | struct _GESOperationClip {
39 | /*< private >*/
40 | GESClip parent;
41 |
42 | GESOperationClipPrivate *priv;
43 |
44 | /* Padding for API extension */
45 | gpointer _ges_reserved[GES_PADDING];
46 | };
47 |
48 | /**
49 | * GESOperationClipClass:
50 | */
51 | struct _GESOperationClipClass {
52 | /*< private >*/
53 | GESClipClass parent_class;
54 |
55 | /*< private >*/
56 | /* Padding for API extension */
57 | gpointer _ges_reserved[GES_PADDING];
58 | };
59 |
60 | G_END_DECLS
61 |
--------------------------------------------------------------------------------
/tools/meson.build:
--------------------------------------------------------------------------------
1 | deps = [ges_dep, gstpbutils_dep, gio_dep, gstvideo_dep, gstaudio_dep]
2 |
3 | ges_tool_args = [ges_c_args]
4 | if gstvalidate_dep.found()
5 | deps = deps + [gstvalidate_dep]
6 | ges_tool_args += ['-DGST_USE_UNSTABLE_API']
7 | endif
8 |
9 | ges_launch = executable('ges-launch-@0@'.format(apiversion),
10 | 'ges-validate.c', 'ges-launch.c', 'ges-launcher.c', 'utils.c', 'ges-launcher-kb.c',
11 | c_args : [ges_tool_args],
12 | dependencies : deps,
13 | install: true
14 | )
15 |
16 | install_man('ges-launch-1.0.1')
17 |
18 | # bash completion
19 | bashcomp_option = get_option('bash-completion')
20 | bashcomp_dep = dependency('bash-completion', version : '>= 2.0', required : bashcomp_option)
21 | bash_completions_dir = ''
22 | bash_helpers_dir = ''
23 |
24 | bashcomp_found = false
25 | if bashcomp_dep.found()
26 | bashcomp_found = true
27 | bashcomp_dir_override = bashcomp_dep.version().version_compare('>= 2.10') ? ['datadir', datadir] : ['prefix', prefix]
28 | bash_completions_dir = bashcomp_dep.get_pkgconfig_variable('completionsdir', define_variable: bashcomp_dir_override)
29 | if bash_completions_dir == ''
30 | msg = 'Found bash-completion but the .pc file did not set \'completionsdir\'.'
31 | if bashcomp_option.enabled()
32 | error(msg)
33 | else
34 | message(msg)
35 | endif
36 | bashcomp_found = false
37 | endif
38 |
39 | bash_helpers_dir = bashcomp_dep.get_pkgconfig_variable('helpersdir', define_variable: bashcomp_dir_override)
40 | if bash_helpers_dir == ''
41 | msg = 'Found bash-completion, but the .pc file did not set \'helpersdir\'.'
42 | if bashcomp_option.enabled()
43 | error(msg)
44 | else
45 | message(msg)
46 | endif
47 | bashcomp_found = false
48 | endif
49 |
50 | if bashcomp_found
51 | install_data('../data/completions/ges-launch-1.0', install_dir : bash_completions_dir)
52 | endif
53 | endif
54 |
--------------------------------------------------------------------------------
/ges/ges-audio-uri-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | typedef struct _GESUriSource GESUriSource;
30 | #define GES_TYPE_AUDIO_URI_SOURCE ges_audio_uri_source_get_type()
31 | GES_DECLARE_TYPE(AudioUriSource, audio_uri_source, AUDIO_URI_SOURCE);
32 |
33 | /**
34 | * GESAudioUriSource:
35 | *
36 | * ### Children Properties
37 | *
38 | * {{ libs/GESVideoUriSource-children-props.md }}
39 | */
40 | struct _GESAudioUriSource {
41 | /*< private >*/
42 | GESAudioSource parent;
43 |
44 | gchar *uri;
45 |
46 | GESUriSource *priv;
47 |
48 | /* Padding for API extension */
49 | gpointer _ges_reserved[GES_PADDING];
50 | };
51 |
52 | struct _GESAudioUriSourceClass {
53 | /*< private >*/
54 | GESAudioSourceClass parent_class;
55 |
56 | /* Padding for API extension */
57 | gpointer _ges_reserved[GES_PADDING];
58 | };
59 |
60 | G_END_DECLS
61 |
--------------------------------------------------------------------------------
/ges/ges-pitivi-formatter.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services Pitivi Formatter
2 | * Copyright (C) 2011-2012 Mathieu Duponchelle
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | G_BEGIN_DECLS
23 |
24 | #define GES_TYPE_PITIVI_FORMATTER ges_pitivi_formatter_get_type()
25 | GES_DECLARE_TYPE(PitiviFormatter, pitivi_formatter, PITIVI_FORMATTER);
26 |
27 | /**
28 | * GESPitiviFormatter: (attributes doc.skip=true):
29 | *
30 | * Serializes a #GESTimeline to a file using the xptv Pitivi file format
31 | */
32 | struct _GESPitiviFormatter {
33 | GESFormatter parent;
34 |
35 | /*< public > */
36 | /*< private >*/
37 | GESPitiviFormatterPrivate *priv;
38 |
39 | /* Padding for API extension */
40 | gpointer _ges_reserved[GES_PADDING];
41 | };
42 |
43 | /**
44 | * GESPitiviFormatterClass: (attributes doc.skip=true):
45 | */
46 | struct _GESPitiviFormatterClass
47 | {
48 | /*< private >*/
49 | GESFormatterClass parent_class;
50 |
51 | /* Padding for API extension */
52 | gpointer _ges_reserved[GES_PADDING];
53 | };
54 |
55 | GES_API
56 | GESPitiviFormatter *ges_pitivi_formatter_new (void);
57 |
58 | G_END_DECLS
59 |
--------------------------------------------------------------------------------
/ges/ges-transition.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 | #include
28 |
29 | G_BEGIN_DECLS
30 |
31 | #define GES_TYPE_TRANSITION ges_transition_get_type()
32 | GES_DECLARE_TYPE(Transition, transition, TRANSITION);
33 |
34 | /**
35 | * GESTransition:
36 | *
37 | * Base class for media transitions.
38 | */
39 |
40 | struct _GESTransition
41 | {
42 | /*< private >*/
43 | GESOperation parent;
44 |
45 | GESTransitionPrivate *priv;
46 |
47 | /* Padding for API extension */
48 | gpointer _ges_reserved[GES_PADDING];
49 | };
50 |
51 | /**
52 | * GESTransitionClass:
53 | */
54 |
55 | struct _GESTransitionClass {
56 | /*< private >*/
57 | GESOperationClass parent_class;
58 |
59 | /*< private >*/
60 | /* Padding for API extension */
61 | gpointer _ges_reserved[GES_PADDING];
62 | };
63 |
64 | G_END_DECLS
65 |
--------------------------------------------------------------------------------
/examples/c/play_timeline_with_one_clip.c:
--------------------------------------------------------------------------------
1 | /* This example can be found in the GStreamer Editing Services git repository in:
2 | * examples/c/play_timeline_with_one_clip.c
3 | */
4 | #include
5 |
6 | int
7 | main (int argc, char **argv)
8 | {
9 | GESLayer *layer;
10 | GESTimeline *timeline;
11 |
12 | if (argc == 1) {
13 | gst_printerr ("Usage: play_timeline_with_one_clip file:///clip/uri\n");
14 |
15 | return 1;
16 | }
17 |
18 | gst_init (NULL, NULL);
19 | ges_init ();
20 |
21 | timeline = ges_timeline_new_audio_video ();
22 | layer = ges_timeline_append_layer (timeline);
23 |
24 | {
25 | /* Add a clip with a duration of 5 seconds */
26 | GESClip *clip = GES_CLIP (ges_uri_clip_new (argv[1]));
27 |
28 | if (clip == NULL) {
29 | gst_printerr
30 | ("%s can not be used, make sure it is a supported media file",
31 | argv[1]);
32 |
33 | return 1;
34 | }
35 |
36 | g_object_set (clip, "duration", 5 * GST_SECOND, "start", 0, NULL);
37 | ges_layer_add_clip (layer, clip);
38 | }
39 |
40 | /* Commiting the timeline is always necessary for changes
41 | * inside it to be taken into account by the Non Linear Engine */
42 | ges_timeline_commit (timeline);
43 |
44 | {
45 | /* Play the timeline */
46 | GESPipeline *pipeline = ges_pipeline_new ();
47 | GstBus *bus = gst_pipeline_get_bus (GST_PIPELINE (pipeline));
48 |
49 | ges_pipeline_set_timeline (pipeline, timeline);
50 | gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_PLAYING);
51 |
52 | /* Simple way to just play the pipeline until EOS or an error pops on the bus */
53 | gst_bus_timed_pop_filtered (bus, 10 * GST_SECOND,
54 | GST_MESSAGE_EOS | GST_MESSAGE_ERROR);
55 |
56 | gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_NULL);
57 | gst_object_unref (bus);
58 | gst_object_unref (pipeline);
59 | }
60 |
61 |
62 | return 0;
63 | }
64 |
--------------------------------------------------------------------------------
/docs/libs/GESVideoUriSource-children-props.md:
--------------------------------------------------------------------------------
1 | #### `alpha`
2 |
3 | alpha of the stream
4 |
5 | Value type: #gdouble
6 |
7 | #### `fields`
8 |
9 | Fields to use for deinterlacing
10 |
11 | Valid values:
12 | - **All fields** (0) – all
13 | - **Top fields only** (1) – top
14 | - **Bottom fields only** (2) – bottom
15 | - **Automatically detect** (3) – auto
16 |
17 | See #deinterlace:fields
18 |
19 | #### `height`
20 |
21 | height of the source
22 |
23 | Value type: #gint
24 |
25 | #### `mode`
26 |
27 | Deinterlace Mode
28 |
29 | Valid values:
30 | - **Auto detection (best effort)** (0) – auto
31 | - **Force deinterlacing** (1) – interlaced
32 | - **Run in passthrough mode** (2) – disabled
33 | - **Auto detection (strict)** (3) – auto-strict
34 |
35 | See #deinterlace:mode
36 |
37 | #### `posx`
38 |
39 | x position of the stream
40 |
41 | Value type: #gint
42 |
43 | #### `posy`
44 |
45 | y position of the stream
46 |
47 | Value type: #gint
48 |
49 | #### `tff`
50 |
51 | Deinterlace top field first
52 |
53 | Valid values:
54 | - **Auto detection** (0) – auto
55 | - **Top field first** (1) – tff
56 | - **Bottom field first** (2) – bff
57 |
58 | See #deinterlace:tff
59 |
60 | #### `video-direction`
61 |
62 | Video direction: rotation and flipping
63 |
64 | Valid values:
65 | - **GST_VIDEO_ORIENTATION_IDENTITY** (0) – identity
66 | - **GST_VIDEO_ORIENTATION_90R** (1) – 90r
67 | - **GST_VIDEO_ORIENTATION_180** (2) – 180
68 | - **GST_VIDEO_ORIENTATION_90L** (3) – 90l
69 | - **GST_VIDEO_ORIENTATION_HORIZ** (4) – horiz
70 | - **GST_VIDEO_ORIENTATION_VERT** (5) – vert
71 | - **GST_VIDEO_ORIENTATION_UL_LR** (6) – ul-lr
72 | - **GST_VIDEO_ORIENTATION_UR_LL** (7) – ur-ll
73 | - **GST_VIDEO_ORIENTATION_AUTO** (8) – auto
74 | - **GST_VIDEO_ORIENTATION_CUSTOM** (9) – custom
75 |
76 | See #GstVideoDirection:video-direction
77 |
78 | #### `width`
79 |
80 | width of the source
81 |
82 | Value type: #gint
83 |
84 |
--------------------------------------------------------------------------------
/ges/ges-effect.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 | #include
25 |
26 | G_BEGIN_DECLS
27 | #define GES_TYPE_EFFECT ges_effect_get_type()
28 | GES_DECLARE_TYPE(Effect, effect, EFFECT);
29 |
30 | /**
31 | * GESEffect:
32 | *
33 | */
34 | struct _GESEffect
35 | {
36 | /*< private > */
37 | GESBaseEffect parent;
38 | GESEffectPrivate *priv;
39 |
40 | /* Padding for API extension */
41 | gpointer _ges_reserved[GES_PADDING];
42 | };
43 |
44 | /**
45 | * GESEffectClass:
46 | * @parent_class: parent class
47 | */
48 |
49 | struct _GESEffectClass
50 | {
51 | /*< private > */
52 | GESBaseEffectClass parent_class;
53 |
54 | GList *rate_properties;
55 |
56 | /* Padding for API extension */
57 | gpointer _ges_reserved[GES_PADDING];
58 |
59 | };
60 |
61 | GES_API GESEffect*
62 | ges_effect_new (const gchar * bin_description);
63 |
64 | GES_API gboolean
65 | ges_effect_class_register_rate_property (GESEffectClass *klass, const gchar *element_name, const gchar *property_name);
66 |
67 | G_END_DECLS
--------------------------------------------------------------------------------
/ges/ges-video-uri-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | /**
30 | * GESUriSource: (attributes doc.skip=true):
31 | */
32 | typedef struct _GESUriSource GESUriSource;
33 | #define GES_TYPE_VIDEO_URI_SOURCE ges_video_uri_source_get_type()
34 | GES_DECLARE_TYPE(VideoUriSource, video_uri_source, VIDEO_URI_SOURCE);
35 |
36 | /**
37 | * GESVideoUriSource:
38 | *
39 | * ### Children Properties
40 | *
41 | * {{ libs/GESVideoUriSource-children-props.md }}
42 | */
43 | struct _GESVideoUriSource {
44 | /*< private >*/
45 | GESVideoSource parent;
46 |
47 | gchar *uri;
48 |
49 | GESUriSource *priv;
50 |
51 | /* Padding for API extension */
52 | gpointer _ges_reserved[GES_PADDING];
53 | };
54 |
55 | struct _GESVideoUriSourceClass {
56 | /*< private >*/
57 | GESVideoSourceClass parent_class;
58 |
59 | /* Padding for API extension */
60 | gpointer _ges_reserved[GES_PADDING];
61 | };
62 |
63 | G_END_DECLS
64 |
--------------------------------------------------------------------------------
/docs/design/gstencodebin.h:
--------------------------------------------------------------------------------
1 | /* GStreamer encoding bin
2 | * Copyright (C) 2009 Edward Hervey
3 | * (C) 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #ifndef __GST_ENCODEBIN_H__
22 | #define __GST_ENCODEBIN_H__
23 |
24 | #include
25 | #include
26 |
27 | #define GST_TYPE_ENCODE_BIN (gst_encode_bin_get_type())
28 | #define GST_ENCODE_BIN(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_ENCODE_BIN,GstPlayBin))
29 | #define GST_ENCODE_BIN_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_ENCODE_BIN,GstPlayBinClass))
30 | #define GST_IS_ENCODE_BIN(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_ENCODE_BIN))
31 | #define GST_IS_ENCODE_BIN_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ENCODE_BIN))
32 |
33 | typedef struct _GstEncodebin GstEncodeBin;
34 |
35 | struct _GstEncodeBin {
36 | GstBin parent;
37 |
38 | GstProfile *profile;
39 | };
40 |
41 | GType gst_encode_bin_get_type(void);
42 |
43 | GstElement *gst_encode_bin_new (GstProfile *profile, gchar *name);
44 | gboolean gst_encode_bin_set_profile (GstEncodeBin *ebin, GstProfile *profile);
45 |
46 | #endif __GST_ENCODEBIN_H__
47 |
--------------------------------------------------------------------------------
/ges/ges-base-xml-formatter.h:
--------------------------------------------------------------------------------
1 | /* Gstreamer Editing Services
2 | *
3 | * Copyright (C) <2012> Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 |
21 | #include "ges-formatter.h"
22 |
23 | #pragma once
24 |
25 | G_BEGIN_DECLS
26 | typedef struct _GESBaseXmlFormatter GESBaseXmlFormatter;
27 | typedef struct _GESBaseXmlFormatterClass GESBaseXmlFormatterClass;
28 |
29 | #define GES_TYPE_BASE_XML_FORMATTER (ges_base_xml_formatter_get_type ())
30 | GES_DECLARE_TYPE(BaseXmlFormatter, base_xml_formatter, BASE_XML_FORMATTER);
31 |
32 | /**
33 | * GESBaseXmlFormatter:
34 | */
35 | struct _GESBaseXmlFormatter
36 | {
37 | GESFormatter parent;
38 |
39 | /*< public > */
40 | /* */
41 | GESBaseXmlFormatterPrivate *priv;
42 | gchar *xmlcontent;
43 |
44 | gpointer _ges_reserved[GES_PADDING - 1];
45 | };
46 |
47 | /**
48 | * GESBaseXmlFormatterClass:
49 | */
50 | struct _GESBaseXmlFormatterClass
51 | {
52 | GESFormatterClass parent;
53 |
54 | /* Should be overriden by subclasses */
55 | GMarkupParser content_parser;
56 |
57 | GString * (*save) (GESFormatter *formatter, GESTimeline *timeline, GError **error);
58 |
59 | gpointer _ges_reserved[GES_PADDING];
60 | };
61 |
62 | G_END_DECLS
63 |
--------------------------------------------------------------------------------
/plugins/nle/nleurisource.h:
--------------------------------------------------------------------------------
1 | /* GStreamer
2 | * Copyright (C) 2001 Wim Taymans
3 | * 2004-2008 Edward Hervey
4 | *
5 | * nleurisource.h: Header for NleURISource
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | */
22 |
23 |
24 | #ifndef __NLE_URI_SOURCE_H__
25 | #define __NLE_URI_SOURCE_H__
26 |
27 | #include
28 | #include "nlesource.h"
29 |
30 | G_BEGIN_DECLS
31 | #define NLE_TYPE_URI_SOURCE \
32 | (nle_urisource_get_type())
33 | #define NLE_URI_SOURCE(obj) \
34 | (G_TYPE_CHECK_INSTANCE_CAST((obj),NLE_TYPE_URI_SOURCE,NleURIsource))
35 | #define NLE_URI_SOURCE_CLASS(klass) \
36 | (G_TYPE_CHECK_CLASS_CAST((klass),NLE_TYPE_URI_SOURCE,NleURIsourceClass))
37 | #define NLE_IS_URI_SOURCE(obj) \
38 | (G_TYPE_CHECK_INSTANCE_TYPE((obj),NLE_TYPE_URI_SOURCE))
39 | #define NLE_IS_URI_SOURCE_CLASS(obj) \
40 | (G_TYPE_CHECK_CLASS_TYPE((klass),NLE_TYPE_URI_SOURCE))
41 |
42 | struct _NleURISource
43 | {
44 | NleSource parent;
45 |
46 | gchar *uri;
47 | GstElement *decodebin;
48 | };
49 |
50 | struct _NleURISourceClass
51 | {
52 | NleSourceClass parent_class;
53 | };
54 |
55 | GType nle_urisource_get_type (void) G_GNUC_INTERNAL;
56 |
57 | G_END_DECLS
58 | #endif /* __NLE_URI_SOURCE_H__ */
59 |
--------------------------------------------------------------------------------
/ges/ges-overlay-clip.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | /**
22 | * SECTION:gesoverlayclip
23 | * @title: GESOverlayClip
24 | * @short_description: Base Class for overlays in a GESLayer
25 | *
26 | * Overlays are objects which modify the underlying layer(s).
27 | *
28 | * Examples of overlays include text, image watermarks, or audio dubbing.
29 | *
30 | * Transitions, which change from one source to another over time, are
31 | * not considered overlays.
32 | */
33 | #ifdef HAVE_CONFIG_H
34 | #include "config.h"
35 | #endif
36 |
37 | #include "ges-internal.h"
38 | #include "ges-operation-clip.h"
39 | #include "ges-overlay-clip.h"
40 |
41 | struct _GESOverlayClipPrivate
42 | {
43 | /* Dummy variable */
44 | void *nothing;
45 | };
46 |
47 | G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (GESOverlayClip, ges_overlay_clip,
48 | GES_TYPE_OPERATION_CLIP);
49 |
50 | static void
51 | ges_overlay_clip_class_init (GESOverlayClipClass * klass)
52 | {
53 | }
54 |
55 | static void
56 | ges_overlay_clip_init (GESOverlayClip * self)
57 | {
58 | self->priv = ges_overlay_clip_get_instance_private (self);
59 | }
60 |
--------------------------------------------------------------------------------
/plugins/nle/gstnle.c:
--------------------------------------------------------------------------------
1 | /* Non Linear Engine plugin
2 | *
3 | * Copyright (C) 2015 Thibault Saunier
4 | *
5 | * gstnle.c
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | *
22 | */
23 |
24 | #ifdef HAVE_CONFIG_H
25 | #include "config.h"
26 | #endif
27 |
28 | #include
29 | #include "nle.h"
30 |
31 | struct _elements_entry
32 | {
33 | const gchar *name;
34 | GType (*type) (void);
35 | };
36 |
37 | static struct _elements_entry _elements[] = {
38 | {"nlesource", nle_source_get_type},
39 | {"nlecomposition", nle_composition_get_type},
40 | {"nleoperation", nle_operation_get_type},
41 | {"nleurisource", nle_urisource_get_type},
42 | {NULL, 0}
43 | };
44 |
45 | static gboolean
46 | plugin_init (GstPlugin * plugin)
47 | {
48 | gint i = 0;
49 |
50 | for (; _elements[i].name; i++)
51 | if (!(gst_element_register (plugin,
52 | _elements[i].name, GST_RANK_NONE, (_elements[i].type) ())))
53 | return FALSE;
54 |
55 | nle_init_ghostpad_category ();
56 |
57 | return TRUE;
58 | }
59 |
60 | /* plugin export resolution */
61 | GST_PLUGIN_DEFINE
62 | (GST_VERSION_MAJOR,
63 | GST_VERSION_MINOR,
64 | nle,
65 | "GStreamer Non Linear Engine",
66 | plugin_init, VERSION, "LGPL", GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN)
67 |
--------------------------------------------------------------------------------
/tests/check/scenarios/check_video_track_restriction_scale_with_keyframes.scenario:
--------------------------------------------------------------------------------
1 | description, handles-states=true, seek=true,
2 | ges-options={\
3 | --track-types, video,
4 | --video-caps, "video/x-raw,width=1280,height=720,framerate=30/1" \
5 | }
6 |
7 | add-clip, name=clip, asset-id=GESTestClip, layer-priority=0, type=GESTestClip, start=0.0, duration=1.0, pattern=blue
8 |
9 | set-control-source, element-name=videotestsource0, property-name=width, binding-type=direct-absolute, source-type=interpolation
10 | set-control-source, element-name=videotestsource0, property-name=height, binding-type=direct, source-type=interpolation
11 |
12 |
13 | # Goes from 1280x720 at 0, to 640x360 at 0.5 then back to 1280x720 ar 1.0
14 | add-keyframe, element-name=videotestsource0, property-name="width", timestamp=0.0, value=(gint)1280
15 | add-keyframe, element-name=videotestsource0, property-name="height", timestamp=0.0, value=0.0072
16 |
17 | add-keyframe, element-name=videotestsource0, property-name="width", timestamp=0.5, value=(gint)640
18 | add-keyframe, element-name=videotestsource0, property-name="height", timestamp=0.5, value=0.0036
19 |
20 | add-keyframe, element-name=videotestsource0, property-name="width", timestamp=1.0, value=(gint)1280
21 | add-keyframe, element-name=videotestsource0, property-name="height", timestamp=1.0, value=0.0072
22 |
23 | check-child-properties, element-name=videotestsource0, width=1280, height=720, posx=0, posy=0, at-time=0.0
24 | check-child-properties, element-name=videotestsource0, width=640, height=360, posx=0, posy=0, at-time=0.5
25 | check-child-properties, element-name=videotestsource0, width=1280, height=720, posx=0, posy=0, at-time=1.0
26 |
27 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1920,height=1080"
28 | check-child-properties, element-name=videotestsource0, width=1920, height=1080, posx=0, posy=0, at-time=0.0
29 | check-child-properties, element-name=videotestsource0, width=960, height=540, posx=0, posy=0, at-time=0.5
30 | check-child-properties, element-name=videotestsource0, width=1920, height=1080, posx=0, posy=0, at-time=1.0
31 |
32 | stop;
--------------------------------------------------------------------------------
/ges/ges-marker-list.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 |
3 | * Copyright (C) <2019> Mathieu Duponchelle
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 |
26 | G_BEGIN_DECLS
27 |
28 | #define GES_TYPE_MARKER ges_marker_get_type ()
29 |
30 | /**
31 | * GESMarker:
32 | *
33 | * A timed #GESMetaContainer object.
34 | *
35 | * Since: 1.18
36 | */
37 | GES_API
38 | G_DECLARE_FINAL_TYPE (GESMarker, ges_marker, GES, MARKER, GObject)
39 | #define GES_TYPE_MARKER_LIST ges_marker_list_get_type ()
40 |
41 | /**
42 | * GESMarkerList:
43 | *
44 | * A list of #GESMarker
45 | *
46 | * Since: 1.18
47 | */
48 | GES_API
49 | G_DECLARE_FINAL_TYPE (GESMarkerList, ges_marker_list, GES, MARKER_LIST, GObject)
50 |
51 | GES_API
52 | GESMarkerList * ges_marker_list_new (void);
53 |
54 | GES_API
55 | GESMarker * ges_marker_list_add (GESMarkerList * list, GstClockTime position);
56 |
57 | GES_API
58 | gboolean ges_marker_list_remove (GESMarkerList * list, GESMarker *marker);
59 |
60 | GES_API
61 | guint ges_marker_list_size (GESMarkerList * list);
62 |
63 |
64 | GES_API
65 | GList * ges_marker_list_get_markers (GESMarkerList *list);
66 |
67 | GES_API
68 | gboolean ges_marker_list_move (GESMarkerList *list, GESMarker *marker, GstClockTime position);
69 |
70 | G_END_DECLS
71 |
--------------------------------------------------------------------------------
/tests/check/ges/negative.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2019 Seungha Yang
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #include
21 | #include
22 | #include
23 |
24 | static void
25 | sigabrt_handler (int signum)
26 | {
27 | /* expected abort */
28 | exit (0);
29 | }
30 |
31 | static gpointer
32 | deinit_thread_func (gpointer user_data)
33 | {
34 | signal (SIGABRT, sigabrt_handler);
35 | ges_deinit ();
36 |
37 | /* shouldn't be reached */
38 | exit (1);
39 |
40 | return NULL;
41 | }
42 |
43 | GST_START_TEST (test_inconsistent_init_deinit_thread)
44 | {
45 | GThread *thread;
46 |
47 | fail_unless (ges_init ());
48 |
49 | /* test assertion, when trying to call ges_deinit() in a thread different
50 | * from that of ges_init() called.
51 | */
52 | thread = g_thread_new ("test-ges-deinit-thread",
53 | (GThreadFunc) deinit_thread_func, NULL);
54 |
55 | g_thread_join (thread);
56 | }
57 |
58 | GST_END_TEST;
59 |
60 | static Suite *
61 | ges_suite (void)
62 | {
63 | Suite *s = suite_create ("ges-negative");
64 | TCase *tc_chain = tcase_create ("negative");
65 |
66 | suite_add_tcase (s, tc_chain);
67 |
68 | tcase_add_test (tc_chain, test_inconsistent_init_deinit_thread);
69 |
70 | return s;
71 | }
72 |
73 | GST_CHECK_MAIN (ges);
74 |
--------------------------------------------------------------------------------
/ges/ges-uri-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 |
28 | G_BEGIN_DECLS
29 |
30 | #define GES_TYPE_URI_CLIP ges_uri_clip_get_type()
31 | GES_DECLARE_TYPE(UriClip, uri_clip, URI_CLIP);
32 |
33 | struct _GESUriClip {
34 | GESSourceClip parent;
35 |
36 | /*< private >*/
37 | GESUriClipPrivate *priv;
38 |
39 | /* Padding for API extension */
40 | gpointer _ges_reserved[GES_PADDING];
41 | };
42 |
43 | /**
44 | * GESUriClipClass:
45 | */
46 |
47 | struct _GESUriClipClass {
48 | /*< private >*/
49 | GESSourceClipClass parent_class;
50 |
51 | /* Padding for API extension */
52 | gpointer _ges_reserved[GES_PADDING];
53 | };
54 |
55 | GES_API void
56 | ges_uri_clip_set_mute (GESUriClip * self, gboolean mute);
57 |
58 | GES_API void
59 | ges_uri_clip_set_is_image (GESUriClip * self,
60 | gboolean is_image);
61 |
62 | GES_API
63 | gboolean ges_uri_clip_is_muted (GESUriClip * self);
64 | GES_API
65 | gboolean ges_uri_clip_is_image (GESUriClip * self);
66 | GES_API
67 | const gchar *ges_uri_clip_get_uri (GESUriClip * self);
68 |
69 | GES_API
70 | GESUriClip* ges_uri_clip_new (const gchar *uri);
71 |
72 | G_END_DECLS
73 |
--------------------------------------------------------------------------------
/ges/ges-video-test-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | * Copyright (C) 2020 Igalia S.L
5 | * Author: 2020 Thibault Saunier
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | */
22 |
23 | #pragma once
24 |
25 | #include
26 | #include
27 | #include
28 | #include
29 |
30 | G_BEGIN_DECLS
31 |
32 | #define GES_TYPE_VIDEO_TEST_SOURCE ges_video_test_source_get_type()
33 | GES_DECLARE_TYPE(VideoTestSource, video_test_source, VIDEO_TEST_SOURCE);
34 |
35 | /**
36 | * GESVideoTestSource:
37 | *
38 | * ### Children Properties
39 | *
40 | * {{ libs/GESVideoTestSource-children-props.md }}
41 | */
42 | struct _GESVideoTestSource {
43 | /*< private >*/
44 | GESVideoSource parent;
45 |
46 | GESVideoTestSourcePrivate *priv;
47 |
48 | /* Padding for API extension */
49 | gpointer _ges_reserved[GES_PADDING];
50 | };
51 |
52 | struct _GESVideoTestSourceClass {
53 | GESVideoSourceClass parent_class;
54 |
55 | /* Padding for API extension */
56 | gpointer _ges_reserved[GES_PADDING];
57 | };
58 |
59 | GES_API void
60 | ges_video_test_source_set_pattern(GESVideoTestSource *self,
61 | GESVideoTestPattern pattern);
62 | GES_API GESVideoTestPattern
63 | ges_video_test_source_get_pattern (GESVideoTestSource *source);
64 |
65 | G_END_DECLS
66 |
--------------------------------------------------------------------------------
/examples/python/simple.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 | #
3 | # GStreamer
4 | #
5 | # Copyright (C) 2013 Thibault Saunier
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 | #include
28 |
29 | G_BEGIN_DECLS
30 |
31 | #define GES_TYPE_AUDIO_SOURCE ges_audio_source_get_type()
32 | GES_DECLARE_TYPE(AudioSource, audio_source, AUDIO_SOURCE);
33 |
34 | /**
35 | * GESAudioSource:
36 | *
37 | * Base class for audio sources
38 | */
39 |
40 | struct _GESAudioSource {
41 | /*< private >*/
42 | GESSource parent;
43 |
44 | GESAudioSourcePrivate *priv;
45 |
46 | /* Padding for API extension */
47 | gpointer _ges_reserved[GES_PADDING];
48 | };
49 |
50 | /**
51 | * GESAudioSourceClass:
52 | */
53 | struct _GESAudioSourceClass {
54 | /*< private >*/
55 | GESSourceClass parent_class;
56 |
57 | /*< public >*/
58 | /**
59 | * GESAudioSource::create_element:
60 | * @object: The #GESTrackElement
61 | *
62 | * Returns: (transfer floating): the #GstElement that the underlying nleobject
63 | * controls.
64 | *
65 | * Deprecated: 1.20: Use #GESSourceClass::create_element instead.
66 | */
67 | GstElement* (*create_source) (GESTrackElement * object);
68 |
69 | /*< private >*/
70 | /* Padding for API extension */
71 | gpointer _ges_reserved[GES_PADDING];
72 | };
73 |
74 | G_END_DECLS
75 |
--------------------------------------------------------------------------------
/plugins/nle/nlecomposition.h:
--------------------------------------------------------------------------------
1 | /* GStreamer
2 | * Copyright (C) 2001 Wim Taymans
3 | * 2004-2008 Edward Hervey
4 | *
5 | * nlecomposition.h: Header for base NleComposition
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | */
22 |
23 |
24 | #ifndef __NLE_COMPOSITION_H__
25 | #define __NLE_COMPOSITION_H__
26 |
27 | #include
28 | #include "nleobject.h"
29 |
30 | G_BEGIN_DECLS
31 | #define NLE_TYPE_COMPOSITION \
32 | (nle_composition_get_type())
33 | #define NLE_COMPOSITION(obj) \
34 | (G_TYPE_CHECK_INSTANCE_CAST((obj),NLE_TYPE_COMPOSITION,NleComposition))
35 | #define NLE_COMPOSITION_CLASS(klass) \
36 | (G_TYPE_CHECK_CLASS_CAST((klass),NLE_TYPE_COMPOSITION,NleCompositionClass))
37 | #define NLE_COMPOSITION_GET_CLASS(obj) \
38 | (NLE_COMPOSITION_CLASS (G_OBJECT_GET_CLASS (obj)))
39 | #define NLE_IS_COMPOSITION(obj) \
40 | (G_TYPE_CHECK_INSTANCE_TYPE((obj),NLE_TYPE_COMPOSITION))
41 | #define NLE_IS_COMPOSITION_CLASS(obj) \
42 | (G_TYPE_CHECK_CLASS_TYPE((klass),NLE_TYPE_COMPOSITION))
43 |
44 | typedef struct _NleCompositionPrivate NleCompositionPrivate;
45 |
46 | struct _NleComposition
47 | {
48 | NleObject parent;
49 |
50 | GstTask * task;
51 | GRecMutex task_rec_lock;
52 |
53 | /*< private >*/
54 | NleCompositionPrivate * priv;
55 |
56 | };
57 |
58 | struct _NleCompositionClass
59 | {
60 | NleObjectClass parent_class;
61 | };
62 |
63 | GType nle_composition_get_type (void) G_GNUC_INTERNAL;
64 |
65 | G_END_DECLS
66 | #endif /* __NLE_COMPOSITION_H__ */
67 |
--------------------------------------------------------------------------------
/ges/ges-transition-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_TRANSITION_CLIP ges_transition_clip_get_type()
30 | GES_DECLARE_TYPE(TransitionClip, transition_clip, TRANSITION_CLIP);
31 |
32 | /**
33 | * GESTransitionClip:
34 | * @vtype: a #GESVideoStandardTransitionType indicating the type of video transition
35 | * to apply.
36 | *
37 | * ### Children Properties
38 | *
39 | * {{ libs/GESTransitionClip-children-props.md }}
40 | */
41 | struct _GESTransitionClip {
42 | /*< private >*/
43 | GESBaseTransitionClip parent;
44 |
45 | /*< public >*/
46 | GESVideoStandardTransitionType vtype;
47 |
48 | /*< private >*/
49 | GESTransitionClipPrivate *priv;
50 |
51 | /* Padding for API extension */
52 | gpointer _ges_reserved[GES_PADDING];
53 | };
54 |
55 | /**
56 | * GESTransitionClipClass:
57 | *
58 | */
59 |
60 | struct _GESTransitionClipClass {
61 | /*< private >*/
62 | GESBaseTransitionClipClass parent_class;
63 |
64 | /* Padding for API extension */
65 | gpointer _ges_reserved[GES_PADDING];
66 | };
67 |
68 | GES_API
69 | GESTransitionClip *ges_transition_clip_new (GESVideoStandardTransitionType vtype);
70 | GES_API
71 | GESTransitionClip *ges_transition_clip_new_for_nick (char *nick);
72 |
73 | G_END_DECLS
74 |
--------------------------------------------------------------------------------
/tests/check/scenarios/edit_while_seeked_with_stop.validatetest:
--------------------------------------------------------------------------------
1 | meta,
2 | tool = "ges-launch-$(gst_api_version)",
3 | args = {
4 | --track-types, video,
5 | --videosink, "$(videosink) name=videosink",
6 | --video-caps, "video/x-raw,format=I420,width=1280,height=720,framerate=10/1,chroma-site=mpeg2,colorimetry=bt709",
7 | },
8 | handles-states=true,
9 | ignore-eos=true,
10 | configs = {
11 | # Ideally we should be able to record checksums... but they are not reproducible
12 | "$(validateflow), pad=videosink:sink, record-buffers=true, ignored-fields=\"stream-start={stream-id,group-id,stream}\"",
13 | }
14 |
15 | add-clip, name=c0, asset-id=time-overlay, layer-priority=0, type=GESSourceClip, start=0, duration=1.0
16 | set-child-properties, element-name=c0, pattern=blue, valignment=center, halignment=center, time-mode=time-code
17 |
18 | add-clip, name=c1, asset-id=time-overlay, layer-priority=0, type=GESSourceClip, start=1.0, duration=1.0
19 | set-child-properties, element-name=c1, pattern=red, valignment=center, halignment=center, time-mode=time-code
20 | commit;
21 | play
22 |
23 | seek, start=0.0, stop=0.5, flags=accurate+flush
24 |
25 | edit, element-name=c0, position=0.5, edge=end, edit-mode=trim
26 | commit;
27 |
28 | crank-clock, expected-elapsed-time=0.0
29 | crank-clock, repeat=5, expected-elapsed-time=0.1
30 | check-position, on-message=eos, expected-position=0.5
31 |
32 | seek, start=0.5, stop=1.0, flags=accurate+flush
33 |
34 | edit, element-name=c1, position=5.0, edge=end, edit-mode=trim
35 | commit;
36 |
37 | crank-clock, expected-elapsed-time=0.0
38 | crank-clock, repeat=5, expected-elapsed-time=0.1
39 | check-position, on-message=eos, expected-position=1.0
40 |
41 | edit, element-name=c1, position=3.0, edge=end, edit-mode=trim
42 | commit;
43 | check-position, on-message=eos, expected-position=1.0
44 |
45 | seek, start=1.0, stop=2.0, flags=accurate+flush
46 | check-position, expected-position=1.0
47 |
48 | edit, element-name=c1, position=1.5, edge=end, edit-mode=trim
49 | commit;
50 |
51 | crank-clock, expected-elapsed-time=0.0
52 | crank-clock, repeat=5, expected-elapsed-time=0.1
53 |
54 | # Last 1ns clip added by GES
55 | crank-clock, repeat=1, expected-elapsed-time=(guint64)1
56 | check-position, on-message=eos, expected-position=1500000001
57 |
58 | stop;
--------------------------------------------------------------------------------
/ges/ges-audio-test-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_AUDIO_TEST_SOURCE ges_audio_test_source_get_type()
30 | GES_DECLARE_TYPE(AudioTestSource, audio_test_source, AUDIO_TEST_SOURCE);
31 |
32 | /**
33 | * GESAudioTestSource:
34 | *
35 | * ### Children Properties
36 | *
37 | * {{ libs/GESAudioTestSource-children-props.md }}
38 | */
39 |
40 | struct _GESAudioTestSource {
41 | GESAudioSource parent;
42 |
43 | /*< private >*/
44 | GESAudioTestSourcePrivate *priv;
45 |
46 | /* Padding for API extension */
47 | gpointer _ges_reserved[GES_PADDING];
48 | };
49 |
50 | struct _GESAudioTestSourceClass {
51 | /*< private >*/
52 | GESAudioSourceClass parent_class;
53 |
54 | /* Padding for API extension */
55 | gpointer _ges_reserved[GES_PADDING];
56 | };
57 |
58 | GES_API
59 | void ges_audio_test_source_set_freq(GESAudioTestSource *self,
60 | gdouble freq);
61 |
62 | GES_API
63 | void ges_audio_test_source_set_volume(GESAudioTestSource *self,
64 | gdouble volume);
65 |
66 | GES_API
67 | double ges_audio_test_source_get_freq(GESAudioTestSource *self);
68 | GES_API
69 | double ges_audio_test_source_get_volume(GESAudioTestSource *self);
70 | G_END_DECLS
71 |
--------------------------------------------------------------------------------
/plugins/nle/nlesource.h:
--------------------------------------------------------------------------------
1 | /* GStreamer
2 | * Copyright (C) 2001 Wim Taymans
3 | * 2004-2008 Edward Hervey
4 | *
5 | * nlesource.h: Header for base NleSource
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | */
22 |
23 |
24 | #ifndef __NLE_SOURCE_H__
25 | #define __NLE_SOURCE_H__
26 |
27 | #include
28 | #include "nleobject.h"
29 |
30 | G_BEGIN_DECLS
31 | #define NLE_TYPE_SOURCE \
32 | (nle_source_get_type())
33 | #define NLE_SOURCE(obj) \
34 | (G_TYPE_CHECK_INSTANCE_CAST((obj),NLE_TYPE_SOURCE,NleSource))
35 | #define NLE_SOURCE_CLASS(klass) \
36 | (G_TYPE_CHECK_CLASS_CAST((klass),NLE_TYPE_SOURCE,NleSourceClass))
37 | #define NLE_SOURCE_GET_CLASS(obj) \
38 | (G_TYPE_INSTANCE_GET_CLASS ((obj), NLE_TYPE_SOURCE, NleSourceClass))
39 | #define NLE_IS_SOURCE(obj) \
40 | (G_TYPE_CHECK_INSTANCE_TYPE((obj),NLE_TYPE_SOURCE))
41 | #define NLE_IS_SOURCE_CLASS(obj) \
42 | (G_TYPE_CHECK_CLASS_TYPE((klass),NLE_TYPE_SOURCE))
43 | typedef struct _NleSourcePrivate NleSourcePrivate;
44 |
45 | struct _NleSource
46 | {
47 | NleObject parent;
48 |
49 | /* controlled source element, acces with gst_bin_[add|remove]_element */
50 | GstElement *element;
51 |
52 | NleSourcePrivate *priv;
53 | };
54 |
55 | struct _NleSourceClass
56 | {
57 | NleObjectClass parent_class;
58 |
59 | /* control_element() takes care of controlling the given element */
60 | gboolean (*control_element) (NleSource * source, GstElement * element);
61 | };
62 |
63 | GType nle_source_get_type (void) G_GNUC_INTERNAL;
64 |
65 | G_END_DECLS
66 | #endif /* __NLE_SOURCE_H__ */
67 |
--------------------------------------------------------------------------------
/ges/ges-auto-transition.h:
--------------------------------------------------------------------------------
1 | /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 2; tab-width: 2 -*- */
2 | /*
3 | * gst-editing-services
4 | * Copyright (C) 2013 Thibault Saunier
5 | *
6 | * gst-editing-services is free software: you can redistribute it and/or modify it
7 | * under the terms of the GNU Lesser General Public License as published
8 | * by the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * gst-editing-services is distributed in the hope that it will be useful, but
12 | * WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14 | * See the GNU Lesser General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Lesser General Public License
17 | * along with this program. If not, see .";
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include "ges-track-element.h"
24 | #include "ges-clip.h"
25 | #include "ges-layer.h"
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_AUTO_TRANSITION (ges_auto_transition_get_type ())
30 | typedef struct _GESAutoTransitionClass GESAutoTransitionClass;
31 | typedef struct _GESAutoTransition GESAutoTransition;
32 |
33 | GES_DECLARE_TYPE(AutoTransition, auto_transition, AUTO_TRANSITION);
34 |
35 | struct _GESAutoTransitionClass
36 | {
37 | GObjectClass parent_class;
38 |
39 | /* Padding for API extension */
40 | gpointer _ges_reserved[GES_PADDING];
41 | };
42 |
43 | struct _GESAutoTransition
44 | {
45 | GObject parent_instance;
46 |
47 | /* */
48 | GESTrackElement *previous_source;
49 | GESTrackElement *next_source;
50 | GESTrackElement *transition;
51 |
52 | GESClip *transition_clip;
53 | gboolean positioning;
54 |
55 | gboolean frozen;
56 |
57 | /* Padding for API extension */
58 | gpointer _ges_reserved[GES_PADDING];
59 | };
60 |
61 | G_GNUC_INTERNAL void ges_auto_transition_update (GESAutoTransition *self);
62 | G_GNUC_INTERNAL GESAutoTransition * ges_auto_transition_new (GESTrackElement * transition,
63 | GESTrackElement * previous_source,
64 | GESTrackElement * next_source);
65 |
66 | G_END_DECLS
67 |
--------------------------------------------------------------------------------
/ges/ges-smart-adder.h:
--------------------------------------------------------------------------------
1 | /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4; tab-width: 4 -*- */
2 | /*
3 | * gst-editing-services
4 | * Copyright (C) 2013 Thibault Saunier
5 | *
6 | * gst-editing-services is free software: you can redistribute it and/or modify it
7 | * under the terms of the GNU Lesser General Public License as published
8 | * by the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * gst-editing-services is distributed in the hope that it will be useful, but
12 | * WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14 | * See the GNU Lesser General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Lesser General Public License
17 | * along with this program. If not, see .";
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 |
25 | #include "ges-track.h"
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_SMART_ADDER (ges_smart_adder_get_type ())
30 | #define GES_SMART_ADDER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_SMART_ADDER, GESSmartAdder))
31 | #define GES_SMART_ADDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GES_TYPE_SMART_ADDER, GESSmartAdderClass))
32 | #define GES_IS_SMART_ADDER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GES_TYPE_SMART_ADDER))
33 | #define GES_IS_SMART_ADDER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GES_TYPE_SMART_ADDER))
34 | #define GES_SMART_ADDER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GES_TYPE_SMART_ADDER, GESSmartAdderClass))
35 |
36 | typedef struct _GESSmartAdderClass GESSmartAdderClass;
37 | typedef struct _GESSmartAdder GESSmartAdder;
38 |
39 | struct _GESSmartAdderClass
40 | {
41 | GstBinClass parent_class;
42 |
43 | gpointer _ges_reserved[GES_PADDING];
44 | };
45 |
46 | struct _GESSmartAdder
47 | {
48 | GstBin parent_instance;
49 |
50 | GHashTable *pads_infos;
51 | GstPad *srcpad;
52 | GstElement *adder;
53 | GstElement *capsfilter;
54 | GMutex lock;
55 |
56 | GstCaps *caps;
57 |
58 | GESTrack *track;
59 |
60 | gpointer _ges_reserved[GES_PADDING];
61 | };
62 |
63 | GES_API
64 | GType ges_smart_adder_get_type (void) G_GNUC_CONST;
65 |
66 | GES_API
67 | GstElement* ges_smart_adder_new (GESTrack *track);
68 |
69 | G_END_DECLS
70 |
--------------------------------------------------------------------------------
/examples/c/assets.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2012 Volodymyr Rudyi
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 | * Boston, MA 02111-1307, USA.
18 | */
19 |
20 | #include
21 | #include
22 | #include
23 | #include
24 |
25 | static void
26 | asset_loaded_cb (GObject * source, GAsyncResult * res, GMainLoop * mainloop)
27 | {
28 | GESUriClipAsset *mfs =
29 | GES_URI_CLIP_ASSET (ges_asset_request_finish (res, NULL));
30 | GstDiscovererInfo *discoverer_info = NULL;
31 | discoverer_info = ges_uri_clip_asset_get_info (mfs);
32 |
33 | GST_DEBUG ("Result is %d", gst_discoverer_info_get_result (discoverer_info));
34 | GST_DEBUG ("Info type is %s", G_OBJECT_TYPE_NAME (mfs));
35 | GST_DEBUG ("Duration is %" GST_TIME_FORMAT,
36 | GST_TIME_ARGS (ges_uri_clip_asset_get_duration (mfs)));
37 |
38 | gst_object_unref (mfs);
39 |
40 | g_main_loop_quit (mainloop);
41 | }
42 |
43 | int
44 | main (int argc, gchar ** argv)
45 | {
46 | GMainLoop *mainloop;
47 |
48 | if (argc != 2) {
49 | return 1;
50 | }
51 | /* Initialize GStreamer (this will parse environment variables and commandline
52 | * arguments. */
53 | gst_init (NULL, NULL);
54 |
55 | /* Initialize the GStreamer Editing Services */
56 | ges_init ();
57 |
58 | /* ... and we start a GMainLoop. GES **REQUIRES** a GMainLoop to be running in
59 | * order to function properly ! */
60 | mainloop = g_main_loop_new (NULL, FALSE);
61 |
62 | ges_asset_request_async (GES_TYPE_URI_CLIP, argv[1], NULL,
63 | (GAsyncReadyCallback) asset_loaded_cb, mainloop);
64 |
65 | g_main_loop_run (mainloop);
66 | g_main_loop_unref (mainloop);
67 |
68 | return 0;
69 | }
70 |
--------------------------------------------------------------------------------
/docs/libs/GESVideoTestSource-children-props.md:
--------------------------------------------------------------------------------
1 | #### `alpha`
2 |
3 | alpha of the stream
4 |
5 | Value type: #gdouble
6 |
7 | #### `background-color`
8 |
9 | Background color to use (big-endian ARGB)
10 |
11 | Value type: #guint
12 |
13 | See #videotestsrc:background-color
14 |
15 | #### `foreground-color`
16 |
17 | Foreground color to use (big-endian ARGB)
18 |
19 | Value type: #guint
20 |
21 | See #videotestsrc:foreground-color
22 |
23 | #### `height`
24 |
25 | height of the source
26 |
27 | Value type: #gint
28 |
29 | #### `pattern`
30 |
31 | Type of test pattern to generate
32 |
33 | Valid values:
34 | - **SMPTE 100% color bars** (0) – smpte
35 | - **Random (television snow)** (1) – snow
36 | - **100% Black** (2) – black
37 | - **100% White** (3) – white
38 | - **Red** (4) – red
39 | - **Green** (5) – green
40 | - **Blue** (6) – blue
41 | - **Checkers 1px** (7) – checkers-1
42 | - **Checkers 2px** (8) – checkers-2
43 | - **Checkers 4px** (9) – checkers-4
44 | - **Checkers 8px** (10) – checkers-8
45 | - **Circular** (11) – circular
46 | - **Blink** (12) – blink
47 | - **SMPTE 75% color bars** (13) – smpte75
48 | - **Zone plate** (14) – zone-plate
49 | - **Gamut checkers** (15) – gamut
50 | - **Chroma zone plate** (16) – chroma-zone-plate
51 | - **Solid color** (17) – solid-color
52 | - **Moving ball** (18) – ball
53 | - **SMPTE 100% color bars** (19) – smpte100
54 | - **Bar** (20) – bar
55 | - **Pinwheel** (21) – pinwheel
56 | - **Spokes** (22) – spokes
57 | - **Gradient** (23) – gradient
58 | - **Colors** (24) – colors
59 |
60 | See #videotestsrc:pattern
61 |
62 | #### `posx`
63 |
64 | x position of the stream
65 |
66 | Value type: #gint
67 |
68 | #### `posy`
69 |
70 | y position of the stream
71 |
72 | Value type: #gint
73 |
74 | #### `video-direction`
75 |
76 | Video direction: rotation and flipping
77 |
78 | Valid values:
79 | - **GST_VIDEO_ORIENTATION_IDENTITY** (0) – identity
80 | - **GST_VIDEO_ORIENTATION_90R** (1) – 90r
81 | - **GST_VIDEO_ORIENTATION_180** (2) – 180
82 | - **GST_VIDEO_ORIENTATION_90L** (3) – 90l
83 | - **GST_VIDEO_ORIENTATION_HORIZ** (4) – horiz
84 | - **GST_VIDEO_ORIENTATION_VERT** (5) – vert
85 | - **GST_VIDEO_ORIENTATION_UL_LR** (6) – ul-lr
86 | - **GST_VIDEO_ORIENTATION_UR_LL** (7) – ur-ll
87 | - **GST_VIDEO_ORIENTATION_AUTO** (8) – auto
88 | - **GST_VIDEO_ORIENTATION_CUSTOM** (9) – custom
89 |
90 | See #GstVideoDirection:video-direction
91 |
92 | #### `width`
93 |
94 | width of the source
95 |
96 | Value type: #gint
97 |
98 |
--------------------------------------------------------------------------------
/ges/ges-smart-video-mixer.h:
--------------------------------------------------------------------------------
1 | /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4; tab-width: 4 -*- */
2 | /*
3 | * gst-editing-services
4 | * Copyright (C) 2013 Mathieu Duponchelle
5 | *
6 | * gst-editing-services is free software: you can redistribute it and/or modify it
7 | * under the terms of the GNU Lesser General Public License as published
8 | * by the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * gst-editing-services is distributed in the hope that it will be useful, but
12 | * WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14 | * See the GNU Lesser General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Lesser General Public License
17 | * along with this program. If not, see .";
18 | */
19 |
20 | #pragma once
21 |
22 | #include
23 | #include
24 |
25 | #include "ges-track.h"
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_SMART_MIXER (ges_smart_mixer_get_type ())
30 | #define GES_SMART_MIXER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_SMART_MIXER, GESSmartMixer))
31 | #define GES_SMART_MIXER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GES_TYPE_SMART_MIXER, GESSmartMixerClass))
32 | #define GES_IS_SMART_MIXER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GES_TYPE_SMART_MIXER))
33 | #define GES_IS_SMART_MIXER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GES_TYPE_SMART_MIXER))
34 | #define GES_SMART_MIXER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GES_TYPE_SMART_MIXER, GESSmartMixerClass))
35 |
36 | typedef struct _GESSmartMixerClass GESSmartMixerClass;
37 | typedef struct _GESSmartMixer GESSmartMixer;
38 |
39 | struct _GESSmartMixerClass
40 | {
41 | GstBinClass parent_class;
42 |
43 | gpointer _ges_reserved[GES_PADDING];
44 | };
45 |
46 | struct _GESSmartMixer
47 | {
48 | GstBin parent_instance;
49 |
50 | GHashTable *pads_infos;
51 | GstPad *srcpad;
52 | GstElement *mixer;
53 | GMutex lock;
54 |
55 | GstCaps *caps;
56 | gboolean is_transition;
57 |
58 | gpointer _ges_reserved[GES_PADDING];
59 | };
60 |
61 | G_GNUC_INTERNAL
62 | GType ges_smart_mixer_get_type (void) G_GNUC_CONST;
63 |
64 | G_GNUC_INTERNAL GstPad *
65 | ges_smart_mixer_get_mixer_pad (GESSmartMixer *self, GstPad **mixerpad);
66 |
67 | G_GNUC_INTERNAL
68 | GstElement* ges_smart_mixer_new (GESTrack *track);
69 |
70 | G_END_DECLS
--------------------------------------------------------------------------------
/ges/ges-clip-asset.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | *
3 | * Copyright (C) 2012 Thibault Saunier
4 | * Copyright (C) 2012 Volodymyr Rudyi
5 | *
6 | * This library is free software; you can redistribute it and/or
7 | * modify it under the terms of the GNU Library General Public
8 | * License as published by the Free Software Foundation; either
9 | * version 2 of the License, or (at your option) any later version.
10 | *
11 | * This library is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | * Library General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Library General Public
17 | * License along with this library; if not, write to the
18 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 | * Boston, MA 02111-1307, USA.
20 | */
21 |
22 |
23 | #pragma once
24 |
25 | #include
26 | #include
27 | #include
28 |
29 | G_BEGIN_DECLS
30 |
31 | #define GES_TYPE_CLIP_ASSET (ges_clip_asset_get_type ())
32 | GES_DECLARE_TYPE(ClipAsset, clip_asset, CLIP_ASSET);
33 |
34 | struct _GESClipAsset
35 | {
36 | GESAsset parent;
37 |
38 | /* */
39 | GESClipAssetPrivate *priv;
40 |
41 | gpointer _ges_reserved[GES_PADDING];
42 | };
43 |
44 | struct _GESClipAssetClass
45 | {
46 | GESAssetClass parent;
47 |
48 | /**
49 | * GESClipAssetClass::get_natural_framerate:
50 | * @self: A #GESClipAsset
51 | * @framerate_n: The framerate numerator to retrieve
52 | * @framerate_d: The framerate denominator to retrieve
53 | *
54 | * Returns: %TRUE if @self has a natural framerate @FALSE otherwise.
55 | *
56 | * Since: 1.18
57 | */
58 | gboolean (*get_natural_framerate) (GESClipAsset *self, gint *framerate_n, gint *framerate_d);
59 |
60 | gpointer _ges_reserved[GES_PADDING - 1];
61 | };
62 |
63 | GES_API
64 | void ges_clip_asset_set_supported_formats (GESClipAsset *self,
65 | GESTrackType supportedformats);
66 | GES_API
67 | GESTrackType ges_clip_asset_get_supported_formats (GESClipAsset *self);
68 | GES_API
69 | gboolean ges_clip_asset_get_natural_framerate (GESClipAsset* self, gint* framerate_n, gint* framerate_d);
70 | GES_API
71 | GstClockTime ges_clip_asset_get_frame_time (GESClipAsset* self, GESFrameNumber frame_number);
72 |
73 | G_END_DECLS
74 |
--------------------------------------------------------------------------------
/tools/utils.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2015 Mathieu Duponchelle
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #include
21 | #include
22 | #include
23 |
24 | #pragma once
25 |
26 | typedef struct
27 | {
28 | gboolean mute;
29 | gboolean disable_mixing;
30 | gchar *save_path;
31 | gchar *save_only_path;
32 | gchar *load_path;
33 | GESTrackType track_types;
34 | gboolean needs_set_state;
35 | gboolean smartrender;
36 | gchar *scenario;
37 | gchar *testfile;
38 | gchar *format;
39 | gchar *outputuri;
40 | gchar *encoding_profile;
41 | gchar *profile_from;
42 | gchar *videosink;
43 | gchar *audiosink;
44 | gboolean list_transitions;
45 | gboolean inspect_action_type;
46 | gchar *sanitized_timeline;
47 | gchar *video_track_caps;
48 | gchar *audio_track_caps;
49 | gboolean embed_nesteds;
50 | gboolean enable_validate;
51 |
52 | gboolean ignore_eos;
53 | gboolean interactive;
54 | gboolean forward_tags;
55 | } GESLauncherParsedOptions;
56 |
57 | gchar * sanitize_timeline_description (gchar **args, GESLauncherParsedOptions *opts);
58 | gboolean get_flags_from_string (GType type, const gchar * str_flags, guint *val);
59 | gchar * ensure_uri (const gchar * location);
60 | GstEncodingProfile * parse_encoding_profile (const gchar * format);
61 | void print_enum (GType enum_type);
62 |
63 | void ges_print (GstDebugColorFlags c, gboolean err, gboolean nline, const gchar * format, va_list var_args);
64 | void ges_ok (const gchar * format, ...);
65 | void ges_warn (const gchar * format, ...);
66 | void ges_printerr (const gchar * format, ...);
67 |
68 | gchar * get_file_extension (gchar * uri);
69 | void describe_encoding_profile (GstEncodingProfile *profile);
70 | void print_timeline(GESTimeline *timeline);
71 |
--------------------------------------------------------------------------------
/ges/ges-track-element-asset.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | *
3 | * Copyright (C) 2012 Thibault Saunier
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 | #pragma once
21 |
22 | #include
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_TRACK_ELEMENT_ASSET ges_track_element_asset_get_type()
30 | GES_DECLARE_TYPE(TrackElementAsset, track_element_asset, TRACK_ELEMENT_ASSET);
31 |
32 | struct _GESTrackElementAsset
33 | {
34 | GESAsset parent;
35 |
36 | /* */
37 | GESTrackElementAssetPrivate *priv;
38 |
39 | /* Padding for API extension */
40 | gpointer __ges_reserved[GES_PADDING];
41 | };
42 |
43 | struct _GESTrackElementAssetClass
44 | {
45 | GESAssetClass parent_class;
46 |
47 | /**
48 | * GESTrackElementAssetClass::get_natural_framerate:
49 | * @self: A #GESTrackElementAsset
50 | * @framerate_n: The framerate numerator to retrieve
51 | * @framerate_d: The framerate denominator to retrieve
52 | *
53 | * Returns: %TRUE if @self has a natural framerate @FALSE otherwise.
54 | *
55 | * Since: 1.18
56 | */
57 | gboolean (*get_natural_framerate) (GESTrackElementAsset *self, gint *framerate_n, gint *framerate_d);
58 |
59 | gpointer _ges_reserved[GES_PADDING - 1];
60 | };
61 |
62 | GES_API
63 | const GESTrackType ges_track_element_asset_get_track_type (GESTrackElementAsset *asset);
64 | GES_API
65 | void ges_track_element_asset_set_track_type (GESTrackElementAsset * asset, GESTrackType type);
66 | GES_API
67 | gboolean ges_track_element_asset_get_natural_framerate (GESTrackElementAsset *self,
68 | gint *framerate_n,
69 | gint *framerate_d);
70 |
71 | G_END_DECLS
72 |
--------------------------------------------------------------------------------
/ges/ges-gerror.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2013 Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 | #pragma once
20 |
21 | /**
22 | * SECTION: ges-gerror
23 | * @title: GESErrors
24 | * @short_description: GError — Categorized error messages
25 | */
26 |
27 | G_BEGIN_DECLS
28 |
29 | /**
30 | * GES_ERROR:
31 | *
32 | * An error happened in GES
33 | */
34 | #define GES_ERROR g_quark_from_static_string("GES_ERROR")
35 |
36 | /**
37 | * GESError:
38 | * @GES_ERROR_ASSET_WRONG_ID: The ID passed is malformed
39 | * @GES_ERROR_ASSET_LOADING: An error happened while loading the asset
40 | * @GES_ERROR_FORMATTER_MALFORMED_INPUT_FILE: The formatted files was malformed
41 | * @GES_ERROR_INVALID_FRAME_NUMBER: The frame number is invalid
42 | * @GES_ERROR_NEGATIVE_LAYER: The operation would lead to a negative
43 | * #GES_TIMELINE_ELEMENT_LAYER_PRIORITY. (Since: 1.18)
44 | * @GES_ERROR_NEGATIVE_TIME: The operation would lead to a negative time.
45 | * E.g. for the #GESTimelineElement:start #GESTimelineElement:duration or
46 | * #GESTimelineElement:in-point. (Since: 1.18)
47 | * @GES_ERROR_NOT_ENOUGH_INTERNAL_CONTENT: Some #GESTimelineElement does
48 | * not have a large enough #GESTimelineElement:max-duration to cover the
49 | * desired operation. (Since: 1.18)
50 | * @GES_ERROR_INVALID_OVERLAP_IN_TRACK: The operation would break one of
51 | * the overlap conditions for the #GESTimeline. (Since: 1.18)
52 | */
53 | typedef enum
54 | {
55 | GES_ERROR_ASSET_WRONG_ID,
56 | GES_ERROR_ASSET_LOADING,
57 | GES_ERROR_FORMATTER_MALFORMED_INPUT_FILE,
58 | GES_ERROR_INVALID_FRAME_NUMBER,
59 | GES_ERROR_NEGATIVE_LAYER,
60 | GES_ERROR_NEGATIVE_TIME,
61 | GES_ERROR_NOT_ENOUGH_INTERNAL_CONTENT,
62 | GES_ERROR_INVALID_OVERLAP_IN_TRACK,
63 | GES_ERROR_INVALID_EFFECT_BIN_DESCRIPTION,
64 | } GESError;
65 |
66 | G_END_DECLS
67 |
--------------------------------------------------------------------------------
/ges/ges-structure-parser.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | *
3 | * Copyright (C) <2015> Mathieu Duponchelle
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 | * Boston, MA 02111-1307, USA.
19 | */
20 | #pragma once
21 |
22 | #include
23 | #include
24 |
25 | G_BEGIN_DECLS
26 |
27 | #define GES_TYPE_STRUCTURE_PARSER ges_structure_parser_get_type()
28 | #define GES_STRUCTURE_PARSER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_STRUCTURE_PARSER, GESStructureParser))
29 |
30 | typedef struct _GESStructureParser GESStructureParser;
31 | typedef struct _GESStructureParserClass GESStructureParserClass;
32 |
33 | struct _GESStructureParser
34 | {
35 | GObject parent;
36 | GList *structures;
37 |
38 | GList *wrong_strings;
39 |
40 | /*< private > */
41 | gchar *current_string;
42 | gboolean add_comma;
43 | };
44 |
45 | struct _GESStructureParserClass
46 | {
47 | /*< private >*/
48 | GObjectClass parent_class;
49 | };
50 |
51 | G_GNUC_INTERNAL GType ges_structure_parser_get_type (void) G_GNUC_CONST;
52 |
53 | G_GNUC_INTERNAL GError * ges_structure_parser_get_error (GESStructureParser *self);
54 | G_GNUC_INTERNAL void ges_structure_parser_parse_string (GESStructureParser *self, const gchar *string, gboolean is_symbol);
55 | G_GNUC_INTERNAL void ges_structure_parser_parse_value (GESStructureParser *self, const gchar *string);
56 | G_GNUC_INTERNAL void ges_structure_parser_parse_default (GESStructureParser *self, const gchar *text);
57 | G_GNUC_INTERNAL void ges_structure_parser_parse_whitespace (GESStructureParser *self);
58 | G_GNUC_INTERNAL void ges_structure_parser_parse_symbol (GESStructureParser *self, const gchar *symbol);
59 | G_GNUC_INTERNAL void ges_structure_parser_parse_setter (GESStructureParser *self, const gchar *setter);
60 | G_GNUC_INTERNAL void ges_structure_parser_end_of_file (GESStructureParser *self);
61 |
62 | G_GNUC_INTERNAL GESStructureParser *ges_structure_parser_new(void);
63 | G_END_DECLS
64 |
--------------------------------------------------------------------------------
/ges/ges-source.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 |
28 | G_BEGIN_DECLS
29 |
30 | #define GES_TYPE_SOURCE ges_source_get_type()
31 | GES_DECLARE_TYPE(Source, source, SOURCE);
32 |
33 | /**
34 | * GESSource:
35 | *
36 | * Base class for single-media sources
37 | */
38 |
39 | struct _GESSource {
40 | /*< private >*/
41 | GESTrackElement parent;
42 |
43 | GESSourcePrivate *priv;
44 |
45 | /* Padding for API extension */
46 | gpointer _ges_reserved[GES_PADDING];
47 | };
48 |
49 | /**
50 | * GESSourceClass:
51 | */
52 |
53 | struct _GESSourceClass {
54 | /*< private >*/
55 | GESTrackElementClass parent_class;
56 |
57 | /**
58 | * GESSourceClass::select_pad:
59 | * @source: The @source for which to check if @pad should be used or not
60 | * @pad: The pad to check
61 | *
62 | * Check whether @pad should be exposed/used.
63 | *
64 | * Returns: %TRUE if @pad should be used %FALSE otherwise.
65 | *
66 | * Since: 1.20
67 | */
68 | gboolean (*select_pad)(GESSource *source, GstPad *pad);
69 |
70 | /**
71 | * GESSourceClass::create_source:
72 | * @source: The #GESAudioSource
73 | *
74 | * Creates the GstElement to put in the source topbin. Other elements will be
75 | * queued, like a volume. In the case of a AudioUriSource, for example, the
76 | * subclass will return a decodebin, and we will append a volume.
77 | *
78 | * Returns: (transfer floating): The source element to use.
79 | *
80 | * Since: 1.20
81 | */
82 | GstElement* (*create_source) (GESSource * source);
83 |
84 | /* Padding for API extension */
85 | gpointer _ges_reserved[GES_PADDING - 2];
86 | };
87 |
88 | G_END_DECLS
89 |
--------------------------------------------------------------------------------
/ges/ges-test-clip.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Brandon Lewis
3 | * 2009 Nokia Corporation
4 | * Copyright (C) 2020 Igalia S.L
5 | * Author: 2020 Thibault Saunier
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | */
22 |
23 | #pragma once
24 |
25 |
26 | #include
27 | #include
28 | #include
29 | #include
30 | #include
31 |
32 | G_BEGIN_DECLS
33 |
34 | #define GES_TYPE_TEST_CLIP ges_test_clip_get_type()
35 | GES_DECLARE_TYPE(TestClip, test_clip, TEST_CLIP);
36 |
37 | /**
38 | * GESTestClip:
39 | */
40 |
41 | struct _GESTestClip {
42 |
43 | GESSourceClip parent;
44 |
45 | /*< private >*/
46 | GESTestClipPrivate *priv;
47 |
48 | /* Padding for API extension */
49 | gpointer _ges_reserved[GES_PADDING];
50 | };
51 |
52 | /**
53 | * GESTestClipClass:
54 | */
55 |
56 | struct _GESTestClipClass {
57 | /*< private >*/
58 | GESSourceClipClass parent_class;
59 |
60 | /* Padding for API extension */
61 | gpointer _ges_reserved[GES_PADDING];
62 | };
63 |
64 | GES_API void
65 | ges_test_clip_set_mute (GESTestClip * self, gboolean mute);
66 |
67 | GES_API void
68 | ges_test_clip_set_vpattern (GESTestClip * self,
69 | GESVideoTestPattern vpattern);
70 |
71 | GES_API void
72 | ges_test_clip_set_frequency (GESTestClip * self, gdouble freq);
73 |
74 | GES_API void
75 | ges_test_clip_set_volume (GESTestClip * self,
76 | gdouble volume);
77 |
78 |
79 | GES_API GESVideoTestPattern
80 | ges_test_clip_get_vpattern (GESTestClip * self);
81 |
82 | GES_API
83 | gboolean ges_test_clip_is_muted (GESTestClip * self);
84 | GES_API
85 | gdouble ges_test_clip_get_frequency (GESTestClip * self);
86 | GES_API
87 | gdouble ges_test_clip_get_volume (GESTestClip * self);
88 |
89 | GES_API
90 | GESTestClip* ges_test_clip_new (void);
91 | GES_API
92 | GESTestClip* ges_test_clip_new_for_nick(gchar * nick);
93 |
94 | G_END_DECLS
95 |
--------------------------------------------------------------------------------
/bindings/python/examples/simple.py:
--------------------------------------------------------------------------------
1 | # GStreamer
2 | #
3 | # Copyright (C) 2013 Thibault Saunier
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 | #include
27 | #include
28 |
29 | G_BEGIN_DECLS
30 |
31 | #define GES_TYPE_VIDEO_SOURCE ges_video_source_get_type()
32 | GES_DECLARE_TYPE(VideoSource, video_source, VIDEO_SOURCE);
33 |
34 | /**
35 | * GESVideoSource:
36 | *
37 | * Base class for video sources
38 | */
39 |
40 | struct _GESVideoSource {
41 | /*< private >*/
42 | GESSource parent;
43 |
44 | GESVideoSourcePrivate *priv;
45 |
46 | /* Padding for API extension */
47 | gpointer _ges_reserved[GES_PADDING];
48 | };
49 |
50 | /**
51 | * GESVideoSourceClass:
52 | * @create_source: method to return the GstElement to put in the source topbin.
53 | * Other elements will be queued, like a videoscale.
54 | * In the case of a VideoUriSource, for example, the subclass will return a decodebin,
55 | * and we will append a videoscale.
56 | */
57 | struct _GESVideoSourceClass {
58 | /*< private >*/
59 | GESSourceClass parent_class;
60 |
61 | /*< public >*/
62 | /**
63 | * GESVideoSource::create_element:
64 | * @object: The #GESTrackElement
65 | *
66 | * Returns: (transfer floating): the #GstElement that the underlying nleobject
67 | * controls.
68 | *
69 | * Deprecated: 1.20: Use #GESSourceClass::create_element instead.
70 | */
71 | GstElement* (*create_source) (GESTrackElement * object);
72 |
73 | /*< private >*/
74 | /* Padding for API extension */
75 | union {
76 | gpointer _ges_reserved[GES_PADDING];
77 | struct {
78 | gboolean disable_scale_in_compositor;
79 | gboolean (*needs_converters)(GESVideoSource *self);
80 | gboolean (*get_natural_size)(GESVideoSource* self, gint* width, gint* height);
81 | gboolean (*create_filters)(GESVideoSource *self, GPtrArray *filters, gboolean needs_converters);
82 | } abi;
83 | } ABI;
84 | };
85 |
86 | GES_API
87 | gboolean ges_video_source_get_natural_size(GESVideoSource* self, gint* width, gint* height);
88 |
89 | G_END_DECLS
90 |
--------------------------------------------------------------------------------
/ges/ges-video-transition.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2010 Brandon Lewis
3 | * 2010 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_VIDEO_TRANSITION ges_video_transition_get_type()
30 | GES_DECLARE_TYPE(VideoTransition, video_transition, VIDEO_TRANSITION);
31 |
32 | /**
33 | * GESVideoTransition:
34 | */
35 |
36 | struct _GESVideoTransition {
37 | GESTransition parent;
38 |
39 | /*< private >*/
40 |
41 | GESVideoTransitionPrivate *priv;
42 |
43 | /* Padding for API extension */
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | /**
48 | * GESVideoTransitionClass:
49 | * @parent_class: parent class
50 | *
51 | */
52 |
53 | struct _GESVideoTransitionClass {
54 | GESTransitionClass parent_class;
55 |
56 | /*< private >*/
57 | /* Padding for API extension */
58 | gpointer _ges_reserved[GES_PADDING];
59 | };
60 |
61 | GES_DEPRECATED
62 | GESVideoTransition* ges_video_transition_new (void);
63 |
64 | GES_API
65 | gboolean ges_video_transition_set_transition_type (GESVideoTransition * self,
66 | GESVideoStandardTransitionType type);
67 | GES_API GESVideoStandardTransitionType
68 | ges_video_transition_get_transition_type (GESVideoTransition * trans);
69 |
70 | GES_DEPRECATED_FOR(ges_timeline_element_set_children_properties)
71 | void ges_video_transition_set_border (GESVideoTransition * self,
72 | guint value);
73 | GES_DEPRECATED_FOR(ges_timeline_element_get_children_properties)
74 | gint ges_video_transition_get_border (GESVideoTransition * self);
75 |
76 | GES_DEPRECATED_FOR(ges_timeline_element_set_children_properties)
77 | void ges_video_transition_set_inverted (GESVideoTransition * self,
78 | gboolean inverted);
79 | GES_DEPRECATED_FOR(ges_timeline_element_get_children_properties)
80 | gboolean ges_video_transition_is_inverted (GESVideoTransition * self);
81 |
82 | G_END_DECLS
83 |
--------------------------------------------------------------------------------
/ges/ges-base-effect-clip.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2011 Thibault Saunier
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | /**
21 | * SECTION: gesbaseeffectclip
22 | * @title: GESBaseEffectClip
23 | * @short_description: An effect in a #GESLayer
24 | *
25 | * #GESBaseEffectClip-s are clips whose core elements are
26 | * #GESBaseEffect-s.
27 | *
28 | * ## Effects
29 | *
30 | * #GESBaseEffectClip-s can have **additional** #GESBaseEffect-s added as
31 | * non-core elements. These additional effects are applied to the output
32 | * of the core effects of the clip that they share a #GESTrack with. See
33 | * #GESClip for how to add and move these effects from the clip.
34 | *
35 | * Note that you cannot add time effects to #GESBaseEffectClip, neither
36 | * as core children, nor as additional effects.
37 | */
38 |
39 | /* FIXME: properly handle the priority of the children. How should we sort
40 | * the priority of effects when two #GESBaseEffectClip's overlap? */
41 | #ifdef HAVE_CONFIG_H
42 | #include "config.h"
43 | #endif
44 |
45 | #include
46 | #include "ges-internal.h"
47 | #include "ges-types.h"
48 |
49 | struct _GESBaseEffectClipPrivate
50 | {
51 | void *nothing;
52 | };
53 |
54 | G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (GESBaseEffectClip, ges_base_effect_clip,
55 | GES_TYPE_OPERATION_CLIP);
56 |
57 | static gboolean
58 | ges_base_effect_clip_add_child (GESContainer * container,
59 | GESTimelineElement * element)
60 | {
61 | if (GES_IS_TIME_EFFECT (element)) {
62 | GST_WARNING_OBJECT (container, "Cannot add %" GES_FORMAT " as a child "
63 | "because it is a time effect", GES_ARGS (element));
64 | return FALSE;
65 | }
66 |
67 | return
68 | GES_CONTAINER_CLASS (ges_base_effect_clip_parent_class)->add_child
69 | (container, element);
70 | }
71 |
72 | static void
73 | ges_base_effect_clip_class_init (GESBaseEffectClipClass * klass)
74 | {
75 | GESContainerClass *container_class = GES_CONTAINER_CLASS (klass);
76 |
77 | GES_CLIP_CLASS_CAN_ADD_EFFECTS (klass) = TRUE;
78 | container_class->add_child = ges_base_effect_clip_add_child;
79 | }
80 |
81 | static void
82 | ges_base_effect_clip_init (GESBaseEffectClip * self)
83 | {
84 | self->priv = ges_base_effect_clip_get_instance_private (self);
85 | }
86 |
--------------------------------------------------------------------------------
/plugins/nle/nleoperation.h:
--------------------------------------------------------------------------------
1 | /* GStreamer
2 | * Copyright (C) 2001 Wim Taymans
3 | * 2004 Edward Hervey
4 | *
5 | * nleoperation.h: Header for base NleOperation
6 | *
7 | * This library is free software; you can redistribute it and/or
8 | * modify it under the terms of the GNU Library General Public
9 | * License as published by the Free Software Foundation; either
10 | * version 2 of the License, or (at your option) any later version.
11 | *
12 | * This library is distributed in the hope that it will be useful,
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 | * Library General Public License for more details.
16 | *
17 | * You should have received a copy of the GNU Library General Public
18 | * License along with this library; if not, write to the
19 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 | * Boston, MA 02110-1301, USA.
21 | */
22 |
23 |
24 | #ifndef __NLE_OPERATION_H__
25 | #define __NLE_OPERATION_H__
26 |
27 | #include
28 | #include "nleobject.h"
29 |
30 | G_BEGIN_DECLS
31 | #define NLE_TYPE_OPERATION \
32 | (nle_operation_get_type())
33 | #define NLE_OPERATION(obj) \
34 | (G_TYPE_CHECK_INSTANCE_CAST((obj),NLE_TYPE_OPERATION,NleOperation))
35 | #define NLE_OPERATION_CLASS(klass) \
36 | (G_TYPE_CHECK_CLASS_CAST((klass),NLE_TYPE_OPERATION,NleOperationClass))
37 | #define NLE_IS_OPERATION(obj) \
38 | (G_TYPE_CHECK_INSTANCE_TYPE((obj),NLE_TYPE_OPERATION))
39 | #define NLE_IS_OPERATION_CLASS(obj) \
40 | (G_TYPE_CHECK_CLASS_TYPE((klass),NLE_TYPE_OPERATION))
41 | struct _NleOperation
42 | {
43 | NleObject parent;
44 |
45 | /* */
46 |
47 | /* num_sinks:
48 | * Number of sink inputs of the controlled element.
49 | * -1 if the sink pads are dynamic */
50 | gint num_sinks;
51 |
52 | /* TRUE if element has request pads */
53 | gboolean dynamicsinks;
54 |
55 | /* realsinks:
56 | * Number of sink pads currently used on the contolled element. */
57 | gint realsinks;
58 |
59 | /* FIXME : We might need to use a lock to access this list */
60 | GList * sinks; /* The sink ghostpads */
61 |
62 | GstElement *element; /* controlled element */
63 | };
64 |
65 | struct _NleOperationClass
66 | {
67 | NleObjectClass parent_class;
68 |
69 | void (*input_priority_changed) (NleOperation * operation, GstPad *pad, guint32 priority);
70 | };
71 |
72 | GstPad * get_unlinked_sink_ghost_pad (NleOperation * operation) G_GNUC_INTERNAL;
73 |
74 | void
75 | nle_operation_signal_input_priority_changed(NleOperation * operation, GstPad *pad,
76 | guint32 priority) G_GNUC_INTERNAL;
77 |
78 | void nle_operation_update_base_time (NleOperation *operation,
79 | GstClockTime timestamp) G_GNUC_INTERNAL;
80 |
81 | void nle_operation_hard_cleanup (NleOperation *operation) G_GNUC_INTERNAL;
82 |
83 |
84 | /* normal GOperation stuff */
85 | GType nle_operation_get_type (void) G_GNUC_INTERNAL;
86 |
87 | G_END_DECLS
88 | #endif /* __NLE_OPERATION_H__ */
89 |
--------------------------------------------------------------------------------
/tests/check/scenarios/check_video_track_restriction_scale.scenario:
--------------------------------------------------------------------------------
1 | description, handles-states=true,
2 | ges-options={\
3 | --track-types, video,
4 | --video-caps, "video/x-raw,width=1200,height=1000" \
5 | }
6 |
7 | add-clip, name=clip, asset-id=GESTestClip, layer-priority=0, type=GESTestClip, duration=1.0
8 |
9 | # VideoTestSource natural size is 1280x720, so keeping aspect ratio, mean
10 | # that it will be scaled to 1200x675 (placed at x=0, y=163)
11 | check-child-properties, element-name=clip, width=1200, height=675, posx=0, posy=163
12 |
13 | set-child-properties, element-name=clip, width=1024, height=768
14 | check-child-properties, element-name=clip, width=1024, height=768
15 |
16 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1400,height=1200"
17 | check-child-properties, element-name=clip, width=1024, height=768
18 |
19 | set-child-properties, element-name=clip, width=0
20 | check-child-properties, element-name=clip, width=0, height=768
21 |
22 | set-child-properties, element-name=clip, height=0
23 | check-child-properties, element-name=clip, width=0, height=0
24 |
25 | set-child-properties, element-name=clip, width=1400, height=1200
26 | check-child-properties, element-name=clip, width=1400, height=1200
27 |
28 | # Changing track size, keeping aspect ratio should scale the video source
29 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=700,height=600"
30 | check-child-properties, element-name=clip, width=700, height=600
31 |
32 | # The video source has the same size as the track restriction caps but we
33 | # are changing the aspect ratio, the video should thus not be rescaled. */
34 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1920,height=1080"
35 | check-child-properties, element-name=clip, width=700, height=600
36 |
37 | set-child-properties, element-name=clip, width=1280, height=720, posx=320, posy=240
38 | check-child-properties, element-name=clip, width=1280, height=720, posx=320, posy=240
39 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=960,height=540"
40 | check-child-properties, element-name=clip, width=640, height=360, posx=160, posy=120
41 |
42 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1280,height=720"
43 | set-child-properties, element-name=clip, width=128, height=72, posx=-100, posy=-100
44 | check-child-properties, element-name=clip, width=128, height=72, posx=-100, posy=-100
45 |
46 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1920,height=1080"
47 | check-child-properties, element-name=clip, width=192, height=108, posx=-150, posy=-150
48 |
49 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=192,height=108"
50 | check-child-properties, element-name=clip, width=19, height=11, posx=-15, posy=-15
51 |
52 | set-child-properties, element-name=clip, posx=10, posy=-10
53 |
54 | # Make sure we do not lose precision when going back to previous size
55 | set-track-restriction-caps, track-type=video, caps="video/x-raw,width=1920,height=1080"
56 | check-child-properties, element-name=clip, width=192, height=108, posx=100, posy=-100
57 |
58 | stop
--------------------------------------------------------------------------------
/examples/c/multifilesrc.c:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2013 Lubosz Sarnecki
3 | *
4 | * This library is free software; you can redistribute it and/or
5 | * modify it under the terms of the GNU Library General Public
6 | * License as published by the Free Software Foundation; either
7 | * version 2 of the License, or (at your option) any later version.
8 | *
9 | * This library is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 | * Library General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU Library General Public
15 | * License along with this library; if not, write to the
16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 | * Boston, MA 02110-1301, USA.
18 | */
19 |
20 | #include
21 | #include
22 |
23 | /* A image sequence test */
24 | int
25 | main (int argc, gchar ** argv)
26 | {
27 | GError *err = NULL;
28 | GOptionContext *ctx;
29 | GESPipeline *pipeline;
30 | GESTimeline *timeline;
31 | GESAsset *asset;
32 | GESLayer *layer;
33 | GMainLoop *mainloop;
34 | GESTrack *track;
35 |
36 | gint duration = 10;
37 | gchar *filepattern = NULL;
38 |
39 | GOptionEntry options[] = {
40 | {"duration", 'd', 0, G_OPTION_ARG_INT, &duration,
41 | "duration to use from the file (in seconds, default:10s)", "seconds"},
42 | {"pattern-url", 'u', 0, G_OPTION_ARG_FILENAME, &filepattern,
43 | "Pattern of the files. i.e. multifile:///foo/%04d.jpg",
44 | "pattern-url"},
45 | {NULL}
46 | };
47 |
48 | ctx = g_option_context_new ("- Plays an image sequence");
49 | g_option_context_add_main_entries (ctx, options, NULL);
50 | g_option_context_add_group (ctx, gst_init_get_option_group ());
51 |
52 | if (!g_option_context_parse (ctx, &argc, &argv, &err)) {
53 | gst_print ("Error initializing %s\n", err->message);
54 | g_option_context_free (ctx);
55 | g_clear_error (&err);
56 | exit (1);
57 | }
58 |
59 | if (filepattern == NULL) {
60 | gst_print ("%s", g_option_context_get_help (ctx, TRUE, NULL));
61 | exit (0);
62 | }
63 | g_option_context_free (ctx);
64 |
65 | gst_init (&argc, &argv);
66 | ges_init ();
67 |
68 | timeline = ges_timeline_new ();
69 | track = GES_TRACK (ges_video_track_new ());
70 | ges_timeline_add_track (timeline, track);
71 |
72 | layer = ges_layer_new ();
73 | if (!ges_timeline_add_layer (timeline, layer))
74 | return -1;
75 |
76 | asset = GES_ASSET (ges_uri_clip_asset_request_sync (filepattern, &err));
77 |
78 | ges_layer_add_asset (layer, asset, 0, 0, 5 * GST_SECOND,
79 | GES_TRACK_TYPE_VIDEO);
80 |
81 | pipeline = ges_pipeline_new ();
82 |
83 | if (!ges_pipeline_set_timeline (pipeline, timeline))
84 | return -1;
85 |
86 | gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_PLAYING);
87 |
88 | mainloop = g_main_loop_new (NULL, FALSE);
89 |
90 | g_timeout_add_seconds (4, (GSourceFunc) g_main_loop_quit, mainloop);
91 | g_main_loop_run (mainloop);
92 |
93 | return 0;
94 | }
95 |
--------------------------------------------------------------------------------
/ges/ges-track-element-deprecated.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | GES_DEPRECATED_FOR(ges_track_element_get_nleobject)
4 | GstElement * ges_track_element_get_gnlobject (GESTrackElement * object);
5 |
6 |
7 | GES_DEPRECATED_FOR(ges_timeline_element_list_children_properties)
8 | GParamSpec **
9 | ges_track_element_list_children_properties (GESTrackElement *object,
10 | guint *n_properties);
11 |
12 | GES_DEPRECATED_FOR(ges_timeline_element_lookup_child)
13 | gboolean ges_track_element_lookup_child (GESTrackElement *object,
14 | const gchar *prop_name,
15 | GstElement **element,
16 | GParamSpec **pspec);
17 |
18 | GES_DEPRECATED_FOR(ges_timeline_element_get_child_property_valist)
19 | void
20 | ges_track_element_get_child_property_valist (GESTrackElement * object,
21 | const gchar * first_property_name,
22 | va_list var_args);
23 |
24 | GES_DEPRECATED_FOR(ges_timeline_element_get_child_properties)
25 | void ges_track_element_get_child_properties (GESTrackElement *object,
26 | const gchar * first_property_name,
27 | ...) G_GNUC_NULL_TERMINATED;
28 |
29 | GES_DEPRECATED_FOR(ges_timeline_element_set_child_property_valist)
30 | void
31 | ges_track_element_set_child_property_valist (GESTrackElement * object,
32 | const gchar * first_property_name,
33 | va_list var_args);
34 |
35 | GES_DEPRECATED_FOR(ges_timeline_element_set_child_property_by_spec)
36 | void
37 | ges_track_element_set_child_property_by_pspec (GESTrackElement * object,
38 | GParamSpec * pspec,
39 | GValue * value);
40 |
41 | GES_DEPRECATED_FOR(ges_timeline_element_set_child_properties)
42 | void
43 | ges_track_element_set_child_properties (GESTrackElement * object,
44 | const gchar * first_property_name,
45 | ...) G_GNUC_NULL_TERMINATED;
46 |
47 | GES_DEPRECATED_FOR(ges_timeline_element_set_child_property)
48 | gboolean ges_track_element_set_child_property (GESTrackElement *object,
49 | const gchar *property_name,
50 | GValue * value);
51 |
52 | GES_DEPRECATED_FOR(ges_timeline_element_get_child_property)
53 | gboolean ges_track_element_get_child_property (GESTrackElement *object,
54 | const gchar *property_name,
55 | GValue * value);
56 |
57 | GES_DEPRECATED_FOR(ges_timeline_element_edit)
58 | gboolean
59 | ges_track_element_edit (GESTrackElement * object,
60 | GList *layers, GESEditMode mode,
61 | GESEdge edge, guint64 position);
62 |
--------------------------------------------------------------------------------
/ges/ges-pipeline.h:
--------------------------------------------------------------------------------
1 | /* GStreamer Editing Services
2 | * Copyright (C) 2009 Edward Hervey
3 | * 2009 Nokia Corporation
4 | *
5 | * This library is free software; you can redistribute it and/or
6 | * modify it under the terms of the GNU Library General Public
7 | * License as published by the Free Software Foundation; either
8 | * version 2 of the License, or (at your option) any later version.
9 | *
10 | * This library is distributed in the hope that it will be useful,
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | * Library General Public License for more details.
14 | *
15 | * You should have received a copy of the GNU Library General Public
16 | * License along with this library; if not, write to the
17 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 | * Boston, MA 02110-1301, USA.
19 | */
20 |
21 | #pragma once
22 |
23 | #include
24 | #include
25 | #include
26 |
27 | G_BEGIN_DECLS
28 |
29 | #define GES_TYPE_PIPELINE ges_pipeline_get_type()
30 | GES_DECLARE_TYPE(Pipeline, pipeline, PIPELINE);
31 |
32 | /**
33 | * GESPipeline:
34 | *
35 | */
36 |
37 | struct _GESPipeline {
38 | /*< private >*/
39 | GstPipeline parent;
40 |
41 | GESPipelinePrivate *priv;
42 |
43 | /* Padding for API extension */
44 | gpointer _ges_reserved[GES_PADDING];
45 | };
46 |
47 | /**
48 | * GESPipelineClass:
49 | * @parent_class: parent class
50 | *
51 | */
52 |
53 | struct _GESPipelineClass {
54 | /*< private >*/
55 | GstPipelineClass parent_class;
56 |
57 | /* Padding for API extension */
58 | gpointer _ges_reserved[GES_PADDING];
59 | };
60 |
61 | GES_API
62 | GESPipeline* ges_pipeline_new (void);
63 |
64 | GES_API
65 | gboolean ges_pipeline_set_timeline (GESPipeline * pipeline,
66 | GESTimeline * timeline);
67 |
68 | GES_API
69 | gboolean ges_pipeline_set_render_settings (GESPipeline *pipeline,
70 | const gchar * output_uri,
71 | GstEncodingProfile *profile);
72 | GES_API
73 | gboolean ges_pipeline_set_mode (GESPipeline *pipeline,
74 | GESPipelineFlags mode);
75 |
76 | GES_API
77 | GESPipelineFlags ges_pipeline_get_mode (GESPipeline *pipeline);
78 |
79 | GES_API GstSample *
80 | ges_pipeline_get_thumbnail(GESPipeline *self, GstCaps *caps);
81 |
82 | GES_API GstSample *
83 | ges_pipeline_get_thumbnail_rgb24(GESPipeline *self,
84 | gint width, gint height);
85 |
86 | GES_API gboolean
87 | ges_pipeline_save_thumbnail(GESPipeline *self,
88 | int width, int height, const gchar *format, const gchar *location,
89 | GError **error);
90 |
91 | GES_API GstElement *
92 | ges_pipeline_preview_get_video_sink (GESPipeline * self);
93 |
94 | GES_API void
95 | ges_pipeline_preview_set_video_sink (GESPipeline * self,
96 | GstElement * sink);
97 |
98 | GES_API GstElement *
99 | ges_pipeline_preview_get_audio_sink (GESPipeline * self);
100 |
101 | GES_API void
102 | ges_pipeline_preview_set_audio_sink (GESPipeline * self,
103 | GstElement * sink);
104 |
105 | G_END_DECLS
106 |
--------------------------------------------------------------------------------