Using alpha blended transitions in windowless mode

All you've ever wanted to know about the ActiveX, Mozilla plugins, the web interface and various PHP extensions
troycarr88
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Apr 2013 03:45

Using alpha blended transitions in windowless mode

Postby troycarr88 » 22 Apr 2013 05:59

Question-- I'm experimenting with the Mozilla plugin in windowless mode on Windows 7. I'm showing a series of videos one after another by deleting and creating <embed> objects for VLC in Javascript and attaching/removing them from the DOM as I go. For the most part, it's working well. The only thing I'm having trouble with are transitions. I have a transparent <div> over the whole thing, and towards the end of each video, I smoothly transition the div from transparent to opaque over 1.5 seconds, do my vlc swap while no one can see behind it, then fade it back to transparent to reveal the new video. This is all done with CSS transitions and the idea is to simply "dip to black" between videos.

However, it appears VLC can't handle semi-transparent items on top of it. When the opacity hits the 50% mark, VLC appears/disappears, depending on which direction the transition is going. I'm guessing alpha blending just isn't supported in the very new windowless mode. If I'm right on this, any plans to add this support, or am I stuck with hard cuts between vids? Anyone have ideas on how to accomplish the same thing, if this doesn't work?

- Troy

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: Using alpha blended transitions in windowless mode

Postby Jean-Baptiste Kempf » 22 Apr 2013 12:26

Nice setup.

VLC version used? Browser?
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

troycarr88
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Apr 2013 03:45

Re: Using alpha blended transitions in windowless mode

Postby troycarr88 » 22 Apr 2013 17:52

It was a long day...sorry to leave out critical info. Version 2.0.6 of VLC. Firefox 20.0.1. Win 7 64bit.

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: Using alpha blended transitions in windowless mode

Postby Jean-Baptiste Kempf » 24 Apr 2013 02:03

Can you share a simple sample page? (or a complex one)
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

troycarr88
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Apr 2013 03:45

Re: Using alpha blended transitions in windowless mode

Postby troycarr88 » 26 Apr 2013 17:29

Here you go. You will need to replace the "target" parameter of vlc with a URL to a video file.

Once you get it loaded, notice that when you move your mouse over the blue area, it fades down and up smoothly. VLC, in contrast, pops in and out of being visible. One thing that was incorrect in my original post-- VLC is fully visible if the opacity of the item above it is less than 1.0. I had originally said 0.5.

Also, I tested the same code with Flash and it works, so I think I've eliminated it being a general problem of Firefox plugins.

Code: Select all

<html> <head> <style> .mask { position: absolute; background-color: #FFF; top: 8px; left: 8px; z-index: 1; height: 400px; width: 200px; opacity: 0; transition: opacity 1.0s ease-in-out; } .mask:hover { opacity: 1.0; } </style> </head> <body> <embed type="application/x-vlc-plugin" width="200" height="200" autostart="true" target="some video file" windowsless="true" controls="false" /> <div style="height: 200px; width: 200px; color: #FFF; line-height: 200px; background-color: #00A;">Move your mouse here</div> <div class="mask"></div> </body> </html>

agrilledfish
New Cone
New Cone
Posts: 1
Joined: 11 Jun 2014 06:12

Re: Using alpha blended transitions in windowless mode

Postby agrilledfish » 11 Jun 2014 06:22

I've been running into the same problem with firefox, chrome and IE on Windows 7. I'm trying to display subtitles over a VLC plugin video, but they only show up if I give the div with the subtitles a non-transparent background.

Code: Select all

background-color: none
and

Code: Select all

background-color:rgba(255,255,255,0.6);
result in the subtitles being hidden under the window.

It seems that VLC windowless mode can't deal with any kind of alpha at all. Is there any workaround for this?

RSATom
Big Cone-huna
Big Cone-huna
Posts: 513
Joined: 24 Nov 2011 06:55
Operating System: Windows/Linux/OsX
Location: Russia, Tomsk

Re: Using alpha blended transitions in windowless mode

Postby RSATom » 11 Jun 2014 07:27

Code: Select all

<embed type="application/x-vlc-plugin" width="200" height="200" autostart="true" target="some video file" windowsless="true" controls="false" />
how about use "windowless" instead of "windowsless" ?


Return to “Web and scripting”

Who is online

Users browsing this forum: No registered users and 2 guests