Skip to content

Become a Developer

Jonathan Thomas edited this page Apr 4, 2023 · 13 revisions

If you are a software developer (or want to become one), and are interested in developing new features, fixing bugs, or improving the user interface for OpenShot, the following sections will explain how to get started and get involved (from a programmer perspective)!

The Big Picture

OpenShot Video Editor has 3 main components:

If you are not familiar with Python, PyQt, or C++, those would be great topics to research and learn more about at this point.

However, many bugs and new features can be added with only Python knowledge, since the C++ components are typically not involved in the user interface. Python is an amazing language, and is super fun to learn, and is the only prerequisite skill needed to become an OpenShot developer!

Getting the Latest Source Code

Before we can fix any bugs or add any features, we need to get the source code onto your computer. These instructions are for Ubuntu Linux, which is the easiest environment to configure for OpenShot development. If you are using another OS, I suggest running a virtual machine with Ubuntu LTS before continuing any further.

If you must use Windows or Mac for development, take a look at these OS specific instructions:

Use git to clone our 3 repositories:

   git clone https://github.com/OpenShot/libopenshot-audio.git
   git clone https://github.com/OpenShot/libopenshot.git
   git clone https://github.com/OpenShot/openshot-qt.git

Configuring your Development Environment

In order to actually compile or run OpenShot, we need to install some dependencies on your system. The easiest way to accomplish this is with our Daily PPA. A PPA is an unofficial Ubuntu repository, which has our software packages available to download and install.

   sudo add-apt-repository ppa:openshot.developers/libopenshot-daily
   sudo apt-get update
   sudo apt-get install openshot-qt \
                        cmake \
                        libx11-dev \
                        libasound2-dev \
                        libavcodec-dev \
                        libavdevice-dev \
                        libavfilter-dev \
                        libavformat-dev \
                        libswresample-dev \
                        libavutil-dev \
                        libfdk-aac-dev \
                        libfreetype6-dev \
                        libjsoncpp-dev \
                        libmagick++-dev \
                        libopenshot-audio-dev \
                        libprotobuf-dev \
                        libqt5svg5-dev \
                        libswscale-dev \
                        libunittest++-dev \
                        libxcursor-dev \
                        libxinerama-dev \
                        libxrandr-dev \
                        libzmq3-dev \
                        pkg-config \
                        python3-dev \
                        protobuf-compiler \
                        qtbase5-dev \
                        qtmultimedia5-dev \
                        swig

At this point, you should have all 3 OpenShot components source code cloned into local folders, the OpenShot daily PPA installed, and all of the required development and runtime dependencies installed. This is a great start, and we are now ready to start compiling some code!

libopenshot-audio (Build Instructions)

This library is required for audio playback and audio effects. It is based on the JUCE audio framework. Here are the commands to build and install it:

   cd libopenshot-audio
   mkdir build
   cd build
   cmake ../
   make install

Essentially, we are switching to the libopenshot-audio/build folder, and running cmake ../ on the parent folder, which finds dependencies and creates all the needed Makefiles used to compile this library. Then make install uses those Makefiles to compile, and install this library. This should result in files being installed to your /usr/local/ folder.

libopenshot (Build Instructions)

This library is required for video decoding, encoding, animation, and just about everything else. It does all the heavy lifting of video editing and video playback. Here are the commands to build and install it.

   cd libopenshot
   mkdir build
   cd build
   cmake ../
   make install
   sudo ldconfig

Essentially, we are switching to the libopenshot/build folder, and running cmake ../ on the parent folder, which finds dependencies and creates all the needed Makefiles used to compile this library. Then make install uses those Makefiles to compile, and install this library. This should result in files being installed to your /usr/local/ folder and in your Python site-packages folder. The ldconfig command updates the system's library cache.

openshot-qt (Build Instructions)

This is our main PyQt Python application. Because it is written in Python, it does not require any compiling to run. To launch openshot-qt from the source code, use the following commands:

   cd openshot-qt
   python3 src/launch.py

This should launch the OpenShot user interface, and include any changes you have made to the source code files (*.py Python files, *.ui PyQt UI files, etc...). This requires the libopenshot-audio and libopenshot libraries, and if anything went wrong with the steps above, OpenShot will likely not launch.

If OpenShot launches at this point, congratulations, you now have a working local version of OpenShot, which is running off your local source code! Try making some changes to the source code and re-launch OpenShot... you should now see your changes!

Folder Structure (openshot-qt)

The source code is divided up into the following folders.

doc/

  • This folder contains documentation and related files, such as logos and images required by the sphinx auto-generated documentation.

images/

  • This folder contains all icons and images used in the user interface.

installer/

  • This folder contains all packaging and installer related files, for each OS.

src/

  • This folder contains all source code (*.py) used by openshot-qt.

src / classes/

  • This folder holds most classes used by OpenShot, related to data structures, utility functions, etc...

src / timeline/

  • This folder holds the timeline, and all timeline-related assets and code (HTML/CSS/AngularJS).

src / windows/

  • This folder holds most of the UI rendering code, including views and models for each screen, and UI layouts.

src / tests/

  • This folder contains all unit test code.

xdg/

  • This folder contains icons and desktop launchers for Linux distros

Congratulations Developer!

You have successfully compiled and launched OpenShot Video Editor! Now it's time to introduce yourself, so please shoot me an email at hello@openshot.org! You are also invited to join our Zulip chat room (similar to Slack but open-source), where we discuss the project daily with many of our contributors and developers. I can send you an invite if you are interested.

Your First Bug Fix

You can browse bug reports at https://github.com/OpenShot/openshot-qt/issues. Easy and well-understood bugs are marked with the newcomer label on GitHub. If you aren't sure what to work on, feel free to email me at jonathan@openshot.org. See Issue Management for more details on issue labels and how we use GitHub issues.

Share your Changes

Once you have fixed a bug or added an amazing new feature, be sure to share it with the OpenShot team, and ideally, we can merge this into our main source code (i.e. our develop branch). The easiest way to share your changes is by creating a fork of our repo, pushing your changes back to GitHub, and creating a Pull Request. A Pull Request lets the OpenShot team know you have changes ready to be merged, and we can review things, give feedback, and hopefully merge in your changes.

Clone this wiki locally