Find the answer to your Linux question:
Page 2 of 2 FirstFirst 1 2
Results 11 to 16 of 16
Originally Posted by josolanes it seems like, if i put this after opening mplayer (in lcvid), it will never happen (it seems like mplayer is where the script stops without ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #11
    Linux Engineer
    Join Date
    Nov 2004
    Location
    home
    Posts
    796

    Quote Originally Posted by josolanes
    it seems like, if i put this after opening mplayer (in lcvid), it will never happen (it seems like mplayer is where the script stops without going any further). this is where i run into problems. it doesn't even seem to bother finding out what happens after starting mplayer...is there a way to tell it the windows dimensions before loading the window maybe?
    You could start mplayer in the background, then sleep a couple secs (however long it takes to get the mplayer window up) before running wmctrl. This way the window will be open for wmctrl to manipulate it. Though now that I think of it, Devil's Pie might be a better choice. It does the same sorta thing, except runs as a daemon, so anything you specify in the config file it automatically applies it's rules to. Or also some window managers (such as icewm) will allow you to do the same thing.

  2. #12
    Linux Enthusiast
    Join Date
    Jun 2005
    Location
    Odessa, FL
    Posts
    586
    Quote Originally Posted by valan
    Quote Originally Posted by josolanes
    it seems like, if i put this after opening mplayer (in lcvid), it will never happen (it seems like mplayer is where the script stops without going any further). this is where i run into problems. it doesn't even seem to bother finding out what happens after starting mplayer...is there a way to tell it the windows dimensions before loading the window maybe?
    You could start mplayer in the background, then sleep a couple secs (however long it takes to get the mplayer window up) before running wmctrl. This way the window will be open for wmctrl to manipulate it. Though now that I think of it, Devil's Pie might be a better choice. It does the same sorta thing, except runs as a daemon, so anything you specify in the config file it automatically applies it's rules to. Or also some window managers (such as icewm) will allow you to do the same thing.
    i'll give "devil's pie" a shot when i get back home tonight. so, would i just tell it that a window with "MPlayer" in it's title would have a certain set of attributes in the config file? that sounds like what it would do, and that sounds like it would work really well

    just for curiousity's sake, how would i make mplayer start in the background? would wmctrl sleep a couple of seconds or mplayer? i tried doing a short while-loop that would count to a certain number before running wmctrl, but i think the code probably waited for the loop to complete before loading mplayer (as nothing happened to mplayer once it opened). what should i have done?

  3. #13
    Linux Guru lakerdonald's Avatar
    Join Date
    Jun 2004
    Location
    St. Petersburg, FL
    Posts
    5,035
    If you want to keep it in bash, you could always just take the ID number from all the files, and keep comparing $RANDOM ( built-in bash variable that contains a random number ) to each file until it matches, then play that file.

  4. $spacer_open
    $spacer_close
  5. #14
    Linux Enthusiast
    Join Date
    Jun 2005
    Location
    Odessa, FL
    Posts
    586
    hmm....so, now lcvid isn't even doing anything. i haven't changed anything big in it...

    can someone please try running it to see whether it's a problem on my end or is yahoo changing something?

    it would be run (assuming lcvid is the name), like this "lcvid 2145555"

    you can try that number and all....it's just the number i've always been using to test the vids....easy to type

    thanks in advance

  6. #15
    Linux Guru Cabhan's Avatar
    Join Date
    Jan 2005
    Location
    Seattle, WA, USA
    Posts
    3,252
    I just ran it, and it seems that mplayer is having some sort of problem.

    My guess is that your value of $file2 may be off. But this is entirely a guess.

  7. #16
    Linux Enthusiast
    Join Date
    Jun 2005
    Location
    Odessa, FL
    Posts
    586
    Quote Originally Posted by Cabhan
    I just ran it, and it seems that mplayer is having some sort of problem.

    My guess is that your value of $file2 may be off. But this is entirely a guess.
    thanks

    this script worked perfectly fine before...i'm not sure what has changed (i'm assuming yahoo changed something). i wonder what i should do to attempt to fix it...

    i'll just have to investigate and see if i can come up with a solution...if i find one, i'll post the revised script

Page 2 of 2 FirstFirst 1 2

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •