LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 02-20-2011, 01:56 PM   #91
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Original Poster
Rep: Reputation: Disabled

slack-fu...

I was not aware of this. Maybe it works. I dont know. I will find a bluray dvd (because thats what I have a hard time to rip) and try then post back here. In the meantime, I assume you are a slacker as well.. can you help me with my issues as mentioned in my previous post?
 
Old 02-20-2011, 02:19 PM   #92
slack-fu
Member
 
Registered: Feb 2006
Location: Norway
Distribution: Slackware Linux 13.37
Posts: 71

Rep: Reputation: 10
Im not sure it will work myself, thats why i asked.. lol
i think it will dump the stream, but you will lose the functionality of menu settings like for example audio or subtitles..
it will give you just the movie and nothing else. (i think..)

as for your previous post about the audio: did you try to use alsaconf?

alsaconf will write the /etc/modprode.d/sound file that is missing

Last edited by slack-fu; 02-20-2011 at 04:55 PM. Reason: Edited for clarification
 
Old 02-20-2011, 03:14 PM   #93
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
This looks very much like an ALSA configuration issue. You should create a separate thread for that I think, assuming it does that for any video (and if it didn't I'd be surprised). I recently got a Blu-ray drive and have been using MakeMKV without 'much' trouble. There is one disc that only includes 1080i video (a weird choice for a Blu-ray disc) and playback is a problem (in mplayer the A/V desynchronizes constantly and I can't use vdpau with that video, and in VLC parts of the movie are *very* choppy). I haven't had that problem with any other movie so I'll call it a one-off for now. I should note however that I use mplayer from the CLI exclusively to play MakeMKV streams and/or MKV files generated by MakeMKV. VLC's playback with vdpau (via libva/vdpau-video) is terrible (worse than without vdpau at all), whereas mplayer plays videos much better using libvdpau directly. Of course that's irrelevant if you don't have an nVidia card. I've never had much luck with mplayer GUIs so I can't help you there. I use this script to play video streams or file created by MakeMKV:
Code:
#!/bin/sh

MPLAYER=/usr/bin/mplayer

if echo "$1" | grep "^[0-9]*$"; then
	FILENAME="http://localhost:51000/stream/title${1}.ts"
else
	FILENAME="$1"
fi
#$MPLAYER -heartbeat-cmd "xscreensaver-command -deactivate &>/dev/null &" -ao alsa:device=surround51 -channels 6 -fs -demuxer lavf -vo vdpau:hqscaling=1 -vc ffmpeg12vdpau,ffh264vdpau,ffvc1vdpau,ffwmv3vdpau, -vfm ffmpeg, -ac fftruehd,ffdca,ffeac3,ffac3,fflpcm, -afm ffmpeg, -alang en -slang en -forcedsubsonly -af volnorm -cache 8192 -dvd-device /dev/sr1 "$FILENAME"
$MPLAYER -heartbeat-cmd "xscreensaver-command -deactivate &>/dev/null &" -ao alsa:device=surround51 -channels 6 -fs -vo vdpau:hqscaling=1 -vc ffmpeg12vdpau,ffh264vdpau,ffvc1vdpau,ffwmv3vdpau, -vfm ffmpeg, -ac fftruehd,ffdca,ffeac3,ffac3,fflpcm, -afm ffmpeg, -alang en -slang en -forcedsubsonly -af volnorm -cache 8192 -dvd-device /dev/sr1 "$FILENAME"
Of course you would have to adjust -dvd-device (which actually shouldn't be needed) and the alsa stuff. When streaming from MakeMKV I just issue `/path/to/bluray.sh 0` to play title 0 (or 1/2/3/etc. for other titles) or `/path/to/bluray.sh filename.mkv` to play an MKV file. That commented line includes "-demuxer lavf" which worked fine until MakeMKV version 1.6.4, where it broke...I've recompiled ffmpeg/mplayer (in that order) without any luck, so I'm not sure if it's MakeMKV or a bug in the version of ffmpeg/mplayer I'm using.

Again, aside from the one disc that's giving me trouble across the board, that mplayer command has been working nicely. Your current mplayer/VLC GUI problems are probably due to ALSA misconfiguration (which, again, deserves a separate thread).
 
Old 02-21-2011, 01:25 PM   #94
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
small typo the colon should be before the slashes dvd:// NOT dvd//:
 
Old 02-21-2011, 01:50 PM   #95
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Original Poster
Rep: Reputation: Disabled
hey T3Slider, your script seems to work fine, after correcting the typo mentioned by Keith Ledger.

I have an improvement to propose, and I am asking here because my scripting skills in bash are mostly horrible... Lots of learning to do there!

Would it be possible to add some code so when a user launch the script, an open box appears and its possible to pick a file to open? The file being picked would then be passed to the script under the variable $FILENAME as it is already implemented in the script?

THis would remove the need for a terminal to launch the script , much better for a htpc front end like my machine...

Let me know guys what do you think!
 
Old 02-21-2011, 02:41 PM   #96
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Quote:
Originally Posted by lpallard View Post
hey T3Slider, your script seems to work fine, after correcting the typo mentioned by Keith Ledger.

I have an improvement to propose, and I am asking here because my scripting skills in bash are mostly horrible... Lots of learning to do there!

Would it be possible to add some code so when a user launch the script, an open box appears and its possible to pick a file to open? The file being picked would then be passed to the script under the variable $FILENAME as it is already implemented in the script?

THis would remove the need for a terminal to launch the script , much better for a htpc front end like my machine...

Let me know guys what do you think!
With the standard software included with Slackware this is difficult (if not impossible). You could do such a thing with xdialog, but it's not included. I could rig something up that would launch dialog in a terminal but dialog's file handling is terrible (I have another script that has to navigate through directories using a loop). I just tested opening an MKV file with the script from Konqueror and it works (the filename gets sent as a parameter to the script), so you could just associate MKVs with the script and clicking would just open them (or at least add an entry to Open With). I would assume this would work with any file manager. Likewise, if you wanted a dedicated icon to open a MakeMKV stream, you could just specify a desktop icon or menu entry to give the command "/path/to/script 0" (assuming 0 is the movie; sometimes it's 1 instead).
 
Old 02-21-2011, 03:20 PM   #97
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Original Poster
Rep: Reputation: Disabled
I agree... Slackware is dramatically incomplete. At least for a "polished" and user friendly experience...

As for the script code that would generate an open file dialog box, could you post some snippets so I can try? Right now on this htpc machine, VLC plainly sucks (terrible framerate, LOTS of visual tearing, choppy & sluggish playback), Mplayer GUI cries out loud with that Alsa problem I have, so the CLI version of mplayer is my last option (excluding XBMC which works perfectly), but for a quick & dirty video playing, CLI mplayer is all I have left.

I never liked xine, gxine and that dragon player and have no use for them... they should simply disappear.

Using linux might have been the single biggest mistake I've made in this htpc project... I have a feeling this htpc will never feel like an htpc. Thats why I am trying to get rid, or minimize the user interaction and inputs as much as I can.

If you want to post the code so I can try, please do so. I will look on my side as well to see if I can find something easy to use.. Doubt I will, but who knows!

 
Old 02-21-2011, 04:17 PM   #98
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Quote:
Originally Posted by lpallard View Post
I agree... Slackware is dramatically incomplete. At least for a "polished" and user friendly experience...

As for the script code that would generate an open file dialog box, could you post some snippets so I can try? Right now on this htpc machine, VLC plainly sucks (terrible framerate, LOTS of visual tearing, choppy & sluggish playback), Mplayer GUI cries out loud with that Alsa problem I have, so the CLI version of mplayer is my last option (excluding XBMC which works perfectly), but for a quick & dirty video playing, CLI mplayer is all I have left.

I never liked xine, gxine and that dragon player and have no use for them... they should simply disappear.

Using linux might have been the single biggest mistake I've made in this htpc project... I have a feeling this htpc will never feel like an htpc. Thats why I am trying to get rid, or minimize the user interaction and inputs as much as I can.

If you want to post the code so I can try, please do so. I will look on my side as well to see if I can find something easy to use.. Doubt I will, but who knows!

Well, this uses Xdialog, so you'd have to install that (there's a SlackBuild at slackbuilds.org).
Code:
#!/bin/sh

MPLAYER=/usr/bin/mplayer

if echo "$1" | grep "^[0-9]\+$"; then
	FILENAME="http://localhost:51000/stream/title${1}.ts"
else
	FILENAME="$1"
fi
if [ -z "$FILENAME" ]; then
	FILENAME=`Xdialog --stdout --inputbox "Play MakeMKV stream? If so, enter the full stream URL below. If not, click cancel to select a file." 50 50 "http://localhost:51000/stream/title0.ts"`
	if [ $? -ne 0 ]; then
		FILENAME=`Xdialog --stdout --fselect "$(pwd)" 50 50`
		if [ $? -ne 0 ]; then
			exit 1
		fi
		if [ ! -f "$FILENAME" ]; then
			exit 2
		fi
	fi
fi

#$MPLAYER -heartbeat-cmd "xscreensaver-command -deactivate &>/dev/null &" -ao alsa:device=surround51 -channels 6 -fs -demuxer lavf -vo vdpau:hqscaling=1 -vc ffmpeg12vdpau,ffh264vdpau,ffvc1vdpau,ffwmv3vdpau, -vfm ffmpeg, -ac fftruehd,ffdca,ffeac3,ffac3,fflpcm, -afm ffmpeg, -alang en -slang en -forcedsubsonly -af volnorm -cache 8192 -dvd-device /dev/sr1 "$FILENAME"
$MPLAYER -heartbeat-cmd "xscreensaver-command -deactivate &>/dev/null &" -ao alsa:device=surround51 -channels 6 -fs -vo vdpau:hqscaling=1 -vc ffmpeg12vdpau,ffh264vdpau,ffvc1vdpau,ffwmv3vdpau, -vfm ffmpeg, -ac fftruehd,ffdca,ffeac3,ffac3,fflpcm, -afm ffmpeg, -alang en -slang en -forcedsubsonly -af volnorm -cache 8192 -dvd-device /dev/sr1 "$FILENAME"
You will almost certainly have to adjust the heights/widths for both Xdialog commands (I just used 50x50 for both boxes, but I use a tiling window manager that automatically expands that to fill empty space so I have no idea how big each box really is). If you pass a parameter to the script (on the command-line, for example) it will act as it did before. However, if you just run the script without any parameters, it will prompt you for a stream, and if you cancel that, you can select a file to play. Also note that I have the script starting the file selection in whatever directory you are currently in ($(pwd)). You can hard-code that to some video directory if you want by replacing "$(pwd)" with "/path/to/videos".
 
Old 02-21-2011, 04:46 PM   #99
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Original Poster
Rep: Reputation: Disabled
I'd say this is a very good starting point Sir!

2 things:

I dont get the relevance of the -dvd-device switch... Can you explain what it does? Is it helping mplayer to map the dvd device?

I am testing on a different machine than my htpc. So far, it is working perfectly, except with a specific small avi file that plays very well with vlc, mplayer GUI, mplayer CLI... With your script, it plays for like 2 sec and then freeze.

There is so many switches in your script. Which ones could be causing this problem?

Thanks!!!
 
Old 02-21-2011, 07:15 PM   #100
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Quote:
Originally Posted by lpallard View Post
I dont get the relevance of the -dvd-device switch... Can you explain what it does? Is it helping mplayer to map the dvd device?
It's not really needed in this instance. I just have it in my regular every-day mplayer alias and copied it over from there. It just identifies the device to use (if you have multiple DVD devices) and you can get rid of it in this case (since it's not even being used here anyway).
Quote:
Originally Posted by lpallard View Post
I am testing on a different machine than my htpc. So far, it is working perfectly, except with a specific small avi file that plays very well with vlc, mplayer GUI, mplayer CLI... With your script, it plays for like 2 sec and then freeze.

There is so many switches in your script. Which ones could be causing this problem?
I don't think there's an easy way to determine that...you may have to try some out. You should make sure that all of the specified codecs work -- `mplayer -vc help` will show the status of all of the video codecs, for example (so you should make sure they all work; do the same for -ac audio codecs). You may have to rebuild mplayer after installing vdpau (assuming you have an nVidia card and use the proprietary drivers). I notice that on my system there are some problems with the wmv3 and vc1 codecs (both the vdpau and non-vdpau counterparts) so I'll have to check into that...but I have no WMV files to play so I can't test it. If you are not using vdpau-capable nVidia hardware then you should adjust all of the video codecs (remove the vdpau suffix for each). Other than that, you may just have to try removing options one by one until it works. That script is set to use the highest quality codecs available to utilize the video hardware (to improve playback and lower the CPU usage), but they may introduce some problems depending on the video and your system. Removing some of the codecs from the list may help.
 
Old 02-21-2011, 09:25 PM   #101
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Original Poster
Rep: Reputation: Disabled
The file that did not played fine was for sure corrupted. I tried again and seems to be generating all kind of errors in mplayer CLI. I havent noticed before and thought it played fine but I guess I was wrong...

Your script as it is right now suffice me. If you find a way to polish it, let us know, but as far as I am concerned, all playback is very good with the vdpau driver and the optimized mplayer rebuilt after I installed the nvidia card and their drivers.

Good job T3Slider!

Second thoughts, I meant to ask this but forgot... I am trying to make a backup of one of my dvd's and I cant.

At first I tried with makemkv, but it was some time ago (about 5 weeks ago) and it failed. I cant recall what it said, but it was failing with some read errors or something... Now, I am retrying with dvdrip and its failing again. When I am scanning the DVD table of contents, I get a window saying:

Quote:
Job 'Probe all DVD titles' failed with error message:
Job 'Probe - title #31' failed with error message:
Command exits with failure code:
Command: execflow tcprobe -H 10 -i /dev/sr0 -T 31 && echo EXECFLOW_OK; execflow dvdxchap -t 31 /dev/sr0 2>/dev/null

Output: libdvdread: Using libdvdcss version 1.2.10 for DVD access
libdvdread: Using libdvdcss version 1.2.10 for DVD access

*** libdvdread: CHECK_VALUE failed in ifo_read.c:639 ***
*** for vtsi_mat->vts_pgcit <= vtsi_mat->vtsi_last_sector ***


*** libdvdread: CHECK_VALUE failed in ifo_read.c:642 ***
*** for vtsi_mat->vtsm_c_adt <= vtsi_mat->vtsi_last_sector ***


*** libdvdread: CHECK_VALUE failed in ifo_read.c:644 ***
*** for vtsi_mat->vts_c_adt <= vtsi_mat->vtsi_last_sector ***

libdvdread: Invalid title IFO (VTS_21_0.IFO).
[dvd_reader.c] critical: Can't open the title 21 info file.
[probe_dvd.c] critical: failed to probe DVD title information
[tcprobe] critical: failed to probe source

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Is my disk damaged or its a copy protection?
 
Old 02-21-2011, 10:10 PM   #102
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Just found kdialog included by default with Slackware that makes things integrate a little better if you use KDE (I do not so I'll stick with Xdialog). Barely had to change anything so here's the same script that would work without needing Xdialog (got rid of the stray -dvd-device stuff as well).
Code:
#!/bin/sh

MPLAYER=/usr/bin/mplayer

if echo "$1" | grep "^[0-9]\+$"; then
	FILENAME="http://localhost:51000/stream/title${1}.ts"
else
	FILENAME="$1"
fi
if [ -z "$FILENAME" ]; then
	FILENAME=`kdialog --inputbox "Play MakeMKV stream? If so, enter the full stream URL below. If not, click cancel to select a file." "http://localhost:51000/stream/title0.ts"`
	if [ $? -ne 0 ]; then
		FILENAME=`kdialog --getopenfilename "$(pwd)"`
		if [ $? -ne 0 ]; then
			exit 1
		fi
		if [ ! -f "$FILENAME" ]; then
			exit 2
		fi
	fi
fi

#$MPLAYER -heartbeat-cmd "xscreensaver-command -deactivate &>/dev/null &" -ao alsa:device=surround51 -channels 6 -fs -demuxer lavf -vo vdpau:hqscaling=1 -vc ffmpeg12vdpau,ffh264vdpau,ffvc1vdpau,ffwmv3vdpau, -vfm ffmpeg, -ac fftruehd,ffdca,ffeac3,ffac3,fflpcm, -afm ffmpeg, -alang en -slang en -forcedsubsonly -af volnorm -cache 8192 -dvd-device /dev/sr1 "$FILENAME"
$MPLAYER -heartbeat-cmd "xscreensaver-command -deactivate &>/dev/null &" -ao alsa:device=surround51 -channels 6 -fs -vo vdpau:hqscaling=1 -vc ffmpeg12vdpau,ffh264vdpau,ffvc1vdpau,ffwmv3vdpau, -vfm ffmpeg, -ac fftruehd,ffdca,ffeac3,ffac3,fflpcm, -afm ffmpeg, -alang en -slang en -forcedsubsonly -af volnorm -cache 8192 "$FILENAME"
Quote:
Originally Posted by lpallard View Post
Second thoughts, I meant to ask this but forgot... I am trying to make a backup of one of my dvd's and I cant.

At first I tried with makemkv, but it was some time ago (about 5 weeks ago) and it failed. I cant recall what it said, but it was failing with some read errors or something... Now, I am retrying with dvdrip and its failing again. When I am scanning the DVD table of contents, I get a window saying:

Is my disk damaged or its a copy protection?
I've never tried dvdrip, just vobcopy+mencoder/ffmpeg, so I'm not sure how to help you there. You may try posting on their forums if no one pipes up. I also haven't used MakeMKV for DVDs though I would have thought it would decrypt nearly any DVD. You could try vobcopy or try using dd to copy the entire DVD image to an iso image (though this may fail and won't decrypt the image even if it succeeds).
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Error writing blu ray data discs with k3b? elfoozo Linux - Software 4 12-09-2010 08:06 AM
Problem with blu-ray in Slackware 13.0 Monkey114 Linux - Newbie 7 01-01-2010 05:02 PM
Blu-ray discs Won't Mount for Reading on openSUSE 10.3 rslucchese Linux - Hardware 4 07-07-2009 10:46 PM
LXer: Michael Bay: 'HD DVD vs Blu-ray is a Microsoft conspiracy' LXer Syndicated Linux News 0 12-10-2007 05:40 PM
LXer: ISO images dumped from PS3 Blu-ray discs via Linux LXer Syndicated Linux News 0 11-28-2006 01:03 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:33 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration