DirectX AudioVideoPlayback Video Background Transparency

756 views Asked by At

I'm playing video on my form using DirectX AudioVideoPlayback. Source code is pretty simple

using System;
using System.Windows.Forms;
using Microsoft.DirectX.AudioVideoPlayback;

namespace WindowsFormsApplication1
{
public partial class Form2 : Form
{
    public Video MyVideo;

    public Form2()
    {
        InitializeComponent();
        ShowVideo();
    }

    void ShowVideo()
    {
        MyVideo = new Video("bottle.mp4", true);
        MyVideo.Owner = this;            
    }
}
}

video itself bottle.mp4 designed the way that it can have transparent background

http://youtu.be/T35kGZMXg5g

Here are my questions:

  1. How can I put my custom background image instead of green video background?
  2. How can I make this background transparent? So I can see the bottle and my desktop behind it
  3. Is it necessary to have h.264 (.mp4) format video, will this also work with .wmv file?

Thanks.

0

There are 0 answers