This folder contains C and C++ examples to perform some Open GoPro functionality. There are two examples, each of which are detailed in a section below.
This demo depends on the following external libraries:
To use the build system contained here, the following programs are required to be installed:
build.sh file. This will:
build/binBefore running the executables built here, you must first be connected to the camera's WiFi Access Point. This can be done via:
A programmatic example of this process can be found in the Open GoPro Python SDK's Connect Wifi Demo. This can be run (assuming a local Python 3.8.x installation exists) via:
pip install open-gopro
gopro-wifi
This demo shows one way to get the media list and download the first media file. It also supports requests to get the media list, media info and downloading specific media files.
For a list of possible commands, do:
$ ./build/bin/media_commands --help
Media List:
$ ./build/bin/media_commands <-l, --list_files>
Media List(Pretty Print):
$ ./build/bin/media_commands <-f, --list_files_pretty>
Media Info:
$ ./build/bin/media_commands <-i, --info> <camera_file_path>
Media Info(Pretty Print):
$ ./build/bin/media_commands <-p, --info_pretty> <camera_file_path>
Media Download:
$ ./build/bin/media_commands <-g, --download> <camera_file_path> <output_path/output_file_name>
Media Hilight Moment:
$ ./build/bin/media_commands --tag
Media Hilight File:
$ ./build/bin/media_commands --tag-video <video_file_path> <offset_ms>
$ ./build/bin/media_commands --tag-photo <photo_file_path>
Media Hilight Remove:
$ ./build/bin/media_commands --tag-video-remove <video_file_path> <offset_ms>
$ ./build/bin/media_commands --tag-photo-remove <photo_file_path>
Media Demo:
$ ./build/bin/media_commands <-d, --demo> <output_path>
This demo demonstrates one way to start and stop the preview stream.
Note: To run the Preview Stream demo. A media player (i.e: VLC) that supports UDP is needed to view the preview stream. The UDP address is udp://0.0.0.0:8554
Start Stream:
$ ./build/bin/stream_commands <-s, --start>
Stop Stream:
$ ./build/bin/stream_commands <-e, --end>
Preview Stream Demo:
$ ./build/bin/stream_commands <-d, --demo>