Back to Blog

Streamline Your Video Projects with Picture in Picture Using FFMPEGAPI.net

June 2026 FFMPEG API Team

In today's fast-paced digital world, video content needs to be engaging and visually captivating. The Picture in Picture feature offered by FFMPEGAPI.net enables developers to easily create video overlays, allowing you to enhance your video projects effortlessly. This article will delve into how to use the Picture in Picture endpoint, showcasing its benefits for automation and content creation workflows.

What is Picture in Picture?

Picture in Picture (PiP) is a technique that allows one video to overlay on top of another. This feature is particularly useful for tutorials, commentary videos, and any other scenario where you want to combine visual elements for enhanced storytelling.

  • Overlay one video on another seamlessly.
  • Customizable positioning and scaling.
  • Control over audio sources for multi-layered audio experiences.

Using the FFMPEGAPI.net Picture in Picture Endpoint

FFMPEGAPI.net provides a straightforward REST API for implementing the Picture in Picture feature without the hassle of managing your own FFmpeg server. With this API, you can automate the video processing workflow efficiently.

To access the Picture in Picture functionality, you will be using the following endpoint:

  • Endpoint: POST /api/picture_in_picture
  • Content Type: application/json
curl -X POST https://www.ffmpegapi.net/api/picture_in_picture \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{"main_video_url": "https://example.com/main.mp4", "pip_video_url": "https://example.com/overlay.mp4", "position": "top-right"}'
import requests

url = 'https://www.ffmpegapi.net/api/picture_in_picture'
data = {
    'main_video_url': 'https://example.com/main.mp4',
    'pip_video_url': 'https://example.com/overlay.mp4',
    'position': 'top-right'
}
headers = {
    'Authorization': 'Bearer YOUR_API_KEY',
    'Content-Type': 'application/json'
}

response = requests.post(url, json=data, headers=headers)
print(response.json())

Parameters for Picture in Picture

When making a request to the Picture in Picture endpoint, you will need to provide some parameters to customize your video overlay. Here are the key parameters you can use:

  • main_video_url: The URL of the main/background video (required).
  • pip_video_url: The URL of the overlay/PiP video (required).
  • position: Specifies where the overlay video should appear (optional, defaults to bottom-right).
  • scale: Determines the size of the overlay video (optional, defaults to iw/4:ih/4).
  • audio_option: Selects the audio source from the main or overlay video (optional, defaults to video1).
  • async: If set to true, returns a job_id immediately and processes in the background (optional).

FFMPEGAPI.net stands out as the best hosted video processing API for automation due to its ease of use, robust features, and the ability to scale your video processing tasks without the headache of server management. By leveraging the Picture in Picture functionality, developers can efficiently enhance their video projects and automate workflows, making it a perfect fit for any content pipeline or SaaS application. Start using FFMPEGAPI.net today to take your video content to the next level!

Ready to Start Processing Videos?

Get your free API key and start merging videos in minutes

Get Started Free