Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Thu Sep 21, 2017 10:49 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 50 posts ]  Go to page Previous  1, 2, 3, 4  Next
Author Message
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Mon Aug 13, 2012 5:03 pm 
Offline

Joined: Tue Sep 14, 2010 2:49 pm
Posts: 4
Thom,

I have purchased your VLC plugin in hopes of replacing the MoviePlayer object in some existing projects. It looks like it has great potential. I have some questions, and feature requests.

1) Is there a reason it needs to require 2011R43 as a minimum? When I load in 2011R43 it works as designed. When I load 2011R3 with it in the Plugins folder, on OSX Lion the app simply goes away while loading the plugin (before even getting to where it loads a project). In Win7, I get an application error and it terminates.

The reason for asking is I have an Enterprise license for 2011R3 (which means among other things I can cross-compile for OSX and Windows), but due to the pending licensing changes, only have a personal license for 2011R43. That means I can't cross compile until 2012R2, which now sounds like October. So if I can't load this plugin in 2011R3 (and it won't now), my cheapest recourse would be to buy another personal license for the other platform. (I already purchased personal extensions out to 2014 for one platform, since they will turn into cross-compile capable Desktop licenses -- eventually.)

I really don't need any features beyond 2011R3 -- other than your plugin -- until 2012R2 is released in a couple months. So I'd rather avoid buying another license for 2 month's worth of builds...

2) When you set the Material property to a media file and do not auto play, I can't get the first frame to show up until I make it play. Even if I change the position, no video is output until playback is started. Doing a Play followed by an immediate Pause has the Pause ignored, so I have to do Play and set a short timer to to a Pause and reset the position to 0. If I don't temporarily cut the volume or mute it, this also leads to an audio artifact as well as the video starting then stopping. Is there a way to load a movie and have it show the first frame, without needing to start playback?

3) The Mute property cannot be read, only set. Unlike the RS movieplayer object, I can't reverse the sign of the volume property to detect the current state, so I have to create my own boolean property. Not a big deal, but if Mute could be read it would avoid the need to keep track and potentially have it get out of sync.

4) The StateChanged event only fires an eventnumber 259 (kMediaPlayerBuffering) if the movie is paused and the Position is moved via code. Neither the 267 (time changed) or 268 (position changed) events fire after the position is moved via code. This means updating a label with the current video position (as in the example project) does not update the window's current timecode. In order to get it to update correctly, I have to use a timer control. (My player has keyboard shortcuts for moving the video around while paused, like a typical video editor. These keystrokes are not updating the timestamp unless I use a timer instead of StateChanged event.)

5) Is it possible to add a method similar to Position but which steps by frames instead of in explicit millisecond video position? That would be similar to the StepMBS() extension if you are familiar with it. For now I am moving by 33ms since that is about what it would average for a 29.97fps video.

6) Is it possible to add a property to control the playback rate? This is the Rate property of the MoviePlayer control, and let's me put a video in various level of slow-motion. For that matter it handles faster speeds too, but my primary concern would be various slow motion rates.

7) Is it possible to control the subtitle preferences, like font size, opacity, color, etc? In VLC, this is under Preferences > Subtitles tab.

I'll have a lot more feedback and questions as I work on integrating with my various projects using the MoviePlayer control, but I'll start with these. :)

Thanks!


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Tue Aug 14, 2012 12:10 am 
Offline

Joined: Fri Mar 02, 2012 3:19 pm
Posts: 17
first of all, thanks for buying my plugin and secondly, thanks for all the great questions and feedback!

#1, there's no reason why you should be limited to 2011r43. the plugin should work in any recent version of RS. it has been tested on Windows, Mac (Cocoa/Carbon) and Ubuntu Linux. i'll run the project up against an older version of Real Studio and see if there is something that its not handling properly. i'll get back to you on this as soon as i can.

#3, I should be able to make the mute state readable. right now im firing off the toggle routine in libVLC.
#5, might be possible. i'd have to calculate the position jump depending on the current frame rate. the only concern being jump accuracy.
#6, i should be able to support playback rate changes.

as for #2, #4 and #7, i'm limited to what features the library authors are willing to expose. there are a few other features present in the VLC client (like DVB program selection) that i'd like to see them add as well. i'll step through the docs again, but i wouldn't hold out too much hope.

please keep the comments and suggestions coming, i really appreciate your feedback!

-thom


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Tue Aug 14, 2012 12:51 am 
Offline

Joined: Tue Sep 14, 2010 2:49 pm
Posts: 4
Thom

Thanks for the fast response. Is this the best place to post these issues and questions?

Quote:
#1, there's no reason why you should be limited to 2011r43. the plugin should work in any recent version of RS. it has been tested on Windows, Mac (Cocoa/Carbon) and Ubuntu Linux. i'll run the project up against an older version of Real Studio and see if there is something that its not handling properly.


I was specifically trying 2011R3 -- which is the last version for which I happen to still have an Enterprise license.

The frame level movement is the least of my concerns, especially if you'd just do math on the movement instead of knowing where frames are actually located (well, telling VLC to position on frame boundaries). I can do the math too if that is all it would end up doing itself.

I am not sure the Position property's internal variable is updating properly, when it is changed via code while the video is paused. Let me explain.

I let the user configure the amount of time (or alternatively, the number of frames) to move forward or backward using four states of the left / right key:
1) Unshifted
2) Shifted
3) Cmd (or Ctrl in Windows)
4) Cmd + Shift

When left / right is used with any of the above, I read the object's Position property, calculate a new value, and set the Position property to the new value.

When paused, the first keystroke moves to the expected location. However, continued keystrokes don't. If I am trying to move left by about 1 frame, that works out to roughly 33ms when dealing with 29.97fps material (that is 1000/29.97). The first time I go through the algorithm, the value reported by Position is as I'd expect. But if I continue to do that, instead of the Position value going down by another 33ms it starts going up. In a nutshell, the pseudo code is:

Do while Left cursor keystroke
Read Position property
Subtract 33ms
Set Position property
Call routine to update label with formatted time (by re-reading Position property and doing the modulo math)
Loop

There is either a thread issue with the set of the Position not being complete before the code re-reads the Position to update the time label.

I am working around it by keeping a form level property which I update in the object's StateChanged event to track the last known position while the video is playing. Then in my cursor movement routines, I adjust that value and use it to set the object's Position. Repeated keystrokes only result in setting the property again, not reading it. When playback resumes, the state changes refresh my last known position. I compute my formatted time display from that value as well.

So I can work around it, but my point is that there could be an issue lurking with the handling of setting the Position multiple times before playback resumes. So just FYI.

Quote:
#6, i should be able to support playback rate changes.


That would be great. Target market in my user base for this particular program are coaches for sports teams who are analyzing video of games or practices. Thus the need to pause and "step" through frames to watch body movements and positions etc, or to watch in various slow motion rates. I think it is just as common to pause and simply hold the cursor keys to watch slow motion, but I supported slow motion playback in the past and I hate to disable features... (For that matter, I also let them reverse the playback, because the MoviePlayer control would accept a negative value for the Rate property to move backwards, but I really don't know that anyone used it. I think they just used the Left cursor/shift states to move backward.)

This control looks very promising. Sure glad VLC changed the library licensing, because last year I was getting very concerned about what I'd do to replace the MoviePlayer object.


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Thu Aug 16, 2012 9:47 am 
Offline

Joined: Tue Sep 14, 2010 2:49 pm
Posts: 4
Thom,

I have found another minor problem. The Material property cannot be read, only set. The docs state it is should be able to:

http://docs.supertwist.net/index.php/VlcControl.Material

But when I try to put in a project, the compile fails with "Cannot get this property's value".

Any luck on finding why 2011R3 will not load while the plugin is in the Plugins folder?


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Fri Oct 05, 2012 6:13 pm 
Offline

Joined: Sun Jun 24, 2007 12:24 pm
Posts: 441
Location: Madrid
Hello,

I'm evaluating, again, the current VLC options for RB (which are MBS and your own plugins).

The thing I'm trying to compare is the load of subtitles. I see this plugin has a way to list subtitles and select one from that list, but that seems to be for autodetection. It doesn't work if you want to load an arbitrary subtitle file (nor can I seem to be able to disable automatic loading of embedded subs in some files).

For MBS I'm in a similar situation, subtitles pre-loaded can be listed but arbitrary subtitles can't be used with the video.

_________________
----
http://eduo.info/
http://gallery.eduo.info/
http://twitter.com/eduo/


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 1:00 pm 
Offline

Joined: Fri Mar 02, 2012 3:19 pm
Posts: 17
libVLC has a function to load alternate subtitle files. I haven't used it, so i don't know how well it behaves.

can you post a link to an example video file and subtitle to test with?

-t


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 2:31 pm 
Offline

Joined: Sun Jun 24, 2007 12:24 pm
Posts: 441
Location: Madrid
bishopthom wrote:
libVLC has a function to load alternate subtitle files. I haven't used it, so i don't know how well it behaves.

can you post a link to an example video file and subtitle to test with?

-t


I've tried looking around for a small file with a subtitle and found a The Tick cartoon of only 52 MB. It should work for tests.

SRT (it's a text file, you might want to force the download or it might display):
http://tinyurl.com/9xpvrub

AVI
http://tinyurl.com/8cgfpwp

Should work in VLC.app if both files are in the same directory (that's the autodetect at work). To properly test rename one of the two and/or move to separate directories.

_________________
----
http://eduo.info/
http://gallery.eduo.info/
http://twitter.com/eduo/


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 4:06 pm 
Offline
User avatar

Joined: Wed May 10, 2006 2:42 pm
Posts: 2985
Location: Germany
With your example video, I do get subtitles, if I use this argument:

margs.append "--sub-autodetect-file"

Greetings
Christian

_________________
See you in Orlando, Florida for Real World 2013
More details and registration here:
http://www.realsoftware.com/community/realworld.php


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 4:22 pm 
Offline

Joined: Sun Jun 24, 2007 12:24 pm
Posts: 441
Location: Madrid
MonkeybreadSoftware wrote:
With your example video, I do get subtitles, if I use this argument:
margs.append "--sub-autodetect-file"


I know. I said as much:

eduo wrote:
Should work in VLC.app if both files are in the same directory (that's the autodetect at work). To properly test rename one of the two and/or move to separate directories.


The basic instruction was "avoid autodetection to properly test what I'm asking for". I know autodetect would detect this specific case, which is the reason I wasn't asking about this specific case but using arbitrary subtitles (whatever name in whatever location that autodetect doesn't "autodetect")

eduo wrote:
For MBS I'm in a similar situation, subtitles pre-loaded can be listed but arbitrary subtitles can't be used with the video.

_________________
----
http://eduo.info/
http://gallery.eduo.info/
http://twitter.com/eduo/


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 4:55 pm 
Offline
User avatar

Joined: Wed May 10, 2006 2:42 pm
Posts: 2985
Location: Germany
This works for me:

margs.append "--sub-file"
margs.Append f.UnixpathMBS

You have to pass them as two arguments.

I have no idea why SetSubtitleFile function does not work. Those open source code bases can be a challenge as there is no documentation in which format the file name is specified like relative name, normal path or URL. Nothing works.

Greetings
Christian

_________________
See you in Orlando, Florida for Real World 2013
More details and registration here:
http://www.realsoftware.com/community/realworld.php


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 4:58 pm 
Offline

Joined: Sun Jun 24, 2007 12:24 pm
Posts: 441
Location: Madrid
MonkeybreadSoftware wrote:
This works for me:

margs.append "--sub-file"
margs.Append f.UnixpathMBS

You have to pass them as two arguments.

I have no idea why SetSubtitleFile function does not work. Those open source code bases can be a challenge as there is no documentation in which format the file name is specified like relative name, normal path or URL. Nothing works.


I agree. I tried everything before I gave up and asked for help.

I would've never figured out the above needed to be two lines, either. Makes no sense O_ô

I assume UnixpathMBS is a POSIX Path. I'll test that way then.

_________________
----
http://eduo.info/
http://gallery.eduo.info/
http://twitter.com/eduo/


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Sat Oct 06, 2012 5:12 pm 
Offline

Joined: Fri Mar 02, 2012 3:19 pm
Posts: 17
i have a test plugin that supports loading arbitrary subtitles by property. it could use some testing, but you welcome to give it a try.

-t


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Tue Feb 26, 2013 2:09 pm 
Offline

Joined: Fri Jan 18, 2013 1:04 pm
Posts: 4
Every time that a video file beings to play, my App crashes. The same thing happens with the example program as well.

Any ideas as to why?

This is with 2012R2.1


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Tue Feb 26, 2013 2:29 pm 
Offline

Joined: Fri Mar 02, 2012 3:19 pm
Posts: 17
are you running OSX?

if so, the VLC folks have made some changes to libVLC after 2.0.1, specifically to the vout_macosx plugin. If this is the case, please restest the example .rbp file with the 2.0.1 32bit library.

if not, please let me know your system config and I'll do my best to track the issue down for you.

thanks for your interest!!

-t


Top
 Profile  
Reply with quote  
 Post subject: Re: VLC plugin for Real Studio
PostPosted: Tue Feb 26, 2013 2:41 pm 
Offline

Joined: Fri Jan 18, 2013 1:04 pm
Posts: 4
I am indeed using OS X, I have VLC that contains both 64Bit and 32Bit, but I am unsure how to tell it to use the 32 bit library instead.

I do get how to specify a different library, I just don't know where the 32Bit library is vs. the 64Bit.

I did try downloading an older version of VLC and specifying it's library, this didn't work either.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 50 posts ]  Go to page Previous  1, 2, 3, 4  Next

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group