Play movie files in multi-file .rar archives

Feature requests for VLC.

Play movie files in multi-file .rar archives

Postby Sparks » Sun Mar 05, 2006 11:56 pm

This topic is a continuation of a previous topic which was locked.

I must say that videolan is a robust video player. Thanks to everyone for working so hard to make the best video player!

It has all the features you could ever want. Except one:

* Play movie files in multi-file .rar archives. So it will play a movie that is split up in .rar,.r01,r02,etc.

Also if, possible with seeking in movie.

Thanks & Bye!


I have discovered some new information that makes it possible to add this feature thus making a thread like this not a waste of the developers time, namely i have found the location of a GPL Library to decode RAR files.

This is part of the XBMC sourcecode and XBMC can currently play muti part rar files instantly (if rar is not compressed) or will cache/unrar (if rar has compression).

This is extremely handy for watching multi-part rar videos that are commonly sourced on the internet.

Anyway onto the code ;)

http://cvs.sourceforge.net/viewcvs.py/x ... 4&view=log

http://cvs.sourceforge.net/viewcvs.py/x ... 4&view=log

http://cvs.sourceforge.net/viewcvs.py/x ... 9&view=log

http://cvs.sourceforge.net/viewcvs.py/x ... 2&view=log

http://cvs.sourceforge.net/viewcvs.py/x ... 6&view=log

http://cvs.sourceforge.net/viewcvs.py/x ... 5&view=log

There is also ZIP support added in the same directory as the RAR Libs.

Thanks for a great program devolopers I hope you can add the feature I desire most!

Sparks
Sparks
 

Postby tonsofpcs » Mon Mar 06, 2006 7:38 pm

Fkuehne wrote:@J.C. This might be possible, but I don't think that anyone in the team is willing to spend time on this. We are always open for patches though.
The development on VLC is mostly done by the principle "implement what you personally need". Most of us think that they don't need this, ergo they don't implement it.
Additionally, a media player isn't responsible to extract files automatically. That's the special field of a decompression-application in my opinion. If we were implementing complete rar-support, the next time people would ask us to implement zip-support, etc. pp. so we would end up with a huge app which can decrypt everything, although these features are used by very few people only, because most of our users download VLC to be able to play movies, not to decompress movies.

So feel free to write a patch and submit it :)
tonsofpcs
Cone that earned his stripes
Cone that earned his stripes
 
Posts: 356
Joined: Wed Jan 04, 2006 11:03 am
Location: Binghamton, NY, USA

Postby Guest LX » Fri Mar 10, 2006 3:12 am

There's no need for a library. As one person noted in the previous thread:

"Scene releases are released in .rar uncompressed format just for ease of transport over the net and to fit in with scene rules."

So the files are just "split files". VLC is often able to play *.part1.rar because it auto-detects the file type (which is always awesome!!!). To play all the files, it would simply need the logic: "Ok, I'm currently playing *.part1.rar, IF the next file is *.part2.rar, THEN I'll just treat the two files as one continuous file".

The same logic applies to pure split files *.001, *.002, ...
Guest LX
 

Postby Guest LX » Fri Mar 10, 2006 4:09 am

Well, it might be a little more complicated than what I stated above.

For example, VLC might not be able to play *.part1.rar of a WMV file (not able to play the partial WMV file). However, it could be smart enough to look for the very last rar file, *.partN.rar, to get the necessary stream info.
(I'm assuming the stream info is contained in the last file, I'm an idiot so I dont know for sure).

If it just treats the collection of RARs as one big file, then we're golden baby 95% of the time.
Guest LX
 

Postby tonsofpcs » Sat Mar 11, 2006 1:34 am

Multi-part RARs are not simply split files. Some people rename their split files to ".rar" to make it easier for them to use WinRAR to re-join the files, but these are not the same.
tonsofpcs
Cone that earned his stripes
Cone that earned his stripes
 
Posts: 356
Joined: Wed Jan 04, 2006 11:03 am
Location: Binghamton, NY, USA

Postby Guest » Sat Mar 11, 2006 2:01 am

tonsofpcs wrote:Multi-part RARs are not simply split files. Some people rename their split files to ".rar" to make it easier for them to use WinRAR to re-join the files, but these are not the same.


The "Store" format is typically used as the compression format for movies posted on Usenet and elsewhere. So, they are basically split files. Anybody that applies compression to a movie file is wasting everyone's time. VLC should not cater to such idiots.
Guest
 

Postby Guest » Sat Mar 11, 2006 2:27 am

Well, I guess there's a slight difference between a "split file" and a "stored RAR file", but only in the first or last few bytes.

Currently, it's already possible to drop a rar file (of the proper movie format) in the "store" format onto VLC and it will play it.

What I'm suggesting is that VLC recognize the *.part#.rar pattern to find the index of a DIVX or WMV file, etc (i.e., treat the collection of files as one file).

It's just a time saver for people who don't want to create a 4.7GB file after they've downloaded 97 or so 50MB segments (it's also much easier on the HD). (Beating a dead horse here, I know)
Guest
 

Postby The DJ » Mon Mar 13, 2006 1:53 am

No one ever said it wouldn't be done.
However:

1 it's a very low priority
2 it's a terrible idea because people will start to put more .rar content in the wild, which is not what is the intention, but it is the result.
3 no one that wants this is a coder able to do this.
Don't use PMs for support questions.
The DJ
Developer
Developer
 
Posts: 5987
Joined: Sat Nov 22, 2003 10:52 pm
Location: Enschede, Holland
VLC version: git
Operating System: Mac OS X

Postby Sparks » Mon Apr 17, 2006 9:01 am

So a lot of people responded.

It seems an application has been released to do what I wanted, although unfortunately its for mac os x only atm.

Has anyone the time/patience to release this for windows?

A link to the application:

http://vlcrarloader.jjabba.com
Sparks
 

Postby Guest » Mon Apr 17, 2006 8:41 pm

This is a must have function. You should see this in action on XBMC. It's amazing. What is almost more amazing is that it exists on xbox and not yet for windows. What are the odds of that, haha.

You guys have my support on this. Must have function!!!!!

/Michael
Guest
 

Postby Guest » Tue Apr 18, 2006 11:18 am

Yes I agree...the way XBMC handles RAR files is amazing, my primary reason for requesting this is that 100% of all the video I download is in RAR format.

It takes quite a bit longer to load videos on a 3.2GHZ PC than it does on a 700Mhz Xbox.

If I could code myself I would add this feature, but alas I code like a dodo.
Guest
 

Postby Sparks » Tue Apr 18, 2006 8:37 pm

Well.....I found two ways of doing this.

1. Using this version of MPlayer http://mplayer.sunset-utopia.homeip.net/

Get these files and install them in this order:
a. mplayer-win32-cygwin-dev-cvs<latest_date>.exe
b. mplayer-win32-mingw-dev-cvs<latest_date>.exe

Get Cygwin and Install it, in C:\cygwin\bin (or wherever you installed it) you will find one of the files required to get Mplayer working called "cygncurses-8.dll", copy this file into your mplayer directory.

Install WinRAR.

Check that play_rar.bat is setup correctly and drag and drop your RAR file onto it.

2. This method uses VLC (by far my preferred player) , but unfortunately (for me anyway) you will get skipping.

a. Install VLC
b. Install WinRAR to a temp folder.
c. Install mplayer-win32-mingw-dev-cvs<latest_date>.exe. to a temp folder.
d. Copy unrar.exe from your winrar install to VLC install.
e. Copy play_rar.bat from the Mplayer install to your VLC directory and change paths to match as well as change mplayer.exe to vlc.exe
f. Drag and drop RAR files onto this batch file.

I hope someone uses these to create a better solution, just thought I would share my progress.

Sparks
Sparks
 

Postby sparks » Sat Apr 22, 2006 7:39 am

Well......

I went away determined to make playing video files easier.

I needed to learn programming to do this.....so I went to what I thought would be the easiest.....Java.

I have created a Java based executable that plays rar files, it needs to be in the same directory as MPlayer with UNRAR.exe.

RARPlayer can open your RAR File with either "Open with" or Drag and Drop from explorer.

Click play

Go here to get:

http://sourceforge.net/project/showfile ... _id=167742

Look forward to hearing feedback!
Last edited by sparks on Thu May 18, 2006 2:32 pm, edited 2 times in total.
sparks
Blank Cone
Blank Cone
 
Posts: 14
Joined: Wed Apr 19, 2006 1:33 pm

Playrar.bat

Postby eiduag » Sat Apr 22, 2006 4:02 pm

The simplest way to play rar files with mplayer is:

1. Download mplayer binaries and codecs:
http://www.mplayerhq.hu/

2. Download WinRAR:
http://www.rarlab.com/

3. Put the following in a bat file on your desktop and edit accordingly

Code: Select all
"%Path to Winrar%\unrar.exe" p -inul "%1" | "%Path to mplayer%\mplayer.exe" -


The unrar executable is freeware and open source and can be found in many places, most people who would want to do this probably have WinRAR installed already.

Play_rar.bat can also be used with vlc but it stutters and I couldn't get it to work properly.(Just change the path to mplayer so it point so vlc to try)

Regards,
Eidur
eiduag
 

Postby sparks » Sat Apr 22, 2006 5:17 pm

Yes you can use the more frequently updated default mplayer binaries with that batch file.

I also updated my RARPlayer and it can now support associations with your RAR files.

Still I cannot fix the stuttering with VLC.

Note to developers: Is there someway to allow VLC to not stutter when receiving a data redirect from UNRAR.exe?

I am sure the reason mPlayer does not stutter is due to the Buffer Cache (8MB in size I believe).

--file-caching is it! Now you can play without stutter!

Edit: Added note about buffer.
Edit: --file-caching comment
Last edited by sparks on Sat Apr 22, 2006 6:59 pm, edited 1 time in total.
sparks
Blank Cone
Blank Cone
 
Posts: 14
Joined: Wed Apr 19, 2006 1:33 pm

Postby sparks » Sat Apr 22, 2006 6:57 pm

Well I found the fix to enable this to work with VLC Media Player!

1.
Download UNRAR here: http://www.rarlab.com/rar/unrarw32.exe and extract into your VLC Directory.

2. Download VLCRAAR here: http://sourceforge.net/project/showfiles.php?group_id=167742 and extract into your VLC Directory.

3. Drag and Drop RAR Files onto it open the rar file with it.

This took me ages of digging/coding to find so I hope you enjoy!
Last edited by sparks on Thu May 18, 2006 2:31 pm, edited 2 times in total.
sparks
Blank Cone
Blank Cone
 
Posts: 14
Joined: Wed Apr 19, 2006 1:33 pm

THank YOu

Postby J5 » Mon Apr 24, 2006 1:07 am

Sparks!!!

THank YOU FOR that it works Great!!!

I too think this is must have feature. XBMC was my perferred method of watching video until I got my Widescreen laptop. I also love VLC(Cant get any better than this).

Thanks,
Jason,
J5
 

Postby sparks » Thu Apr 27, 2006 6:06 am

Glad you like it, if you can program please help me tidy it up :)

I would like the few lines of code I made into a simple program, being added into VLC (although I am aware Java is not the same thing as C++)

All it really needs is something along these lines:

Code: Select all
if file = .rar {
if unrar.exe exists {
unrar -p -inul "file.rar" [data redirected into vlc with some caching]
}
}
sparks
Blank Cone
Blank Cone
 
Posts: 14
Joined: Wed Apr 19, 2006 1:33 pm

Postby tonsofpcs » Sun Apr 30, 2006 4:07 am

Code: Select all
if file = .rar {
fair enough
Code: Select all
if unrar.exe exists {
ok, a bunch of proprietary filesystem calls, but we probably have what it takes to check already. fair enough
Code: Select all
unrar -p -inul "file.rar"
ah, calling another BINARY from within one... nice memory hogging and system waiting...
[data redirected into vlc with some caching]
and here is the major problem. Data redirection and caching -- how much? how long? how fast can your machine unrar? how will vlc know?
tonsofpcs
Cone that earned his stripes
Cone that earned his stripes
 
Posts: 356
Joined: Wed Jan 04, 2006 11:03 am
Location: Binghamton, NY, USA

Postby sparks » Sun Apr 30, 2006 11:03 am

In my experiments anything under 1000ms worth of cache has lag.

The ideal level was at around 1500 but I used 2000ms just to be sure.

Although I am aware your post was not a question, but a statement.
sparks
Blank Cone
Blank Cone
 
Posts: 14
Joined: Wed Apr 19, 2006 1:33 pm

Next

Return to VLC media player Feature Requests

Who is online

Users browsing this forum: Google [Bot] and 4 guests