Flash Media Player plugin with visual integration (play flv/mp4/mp3/aac files) - Page 5 Flash Media Player plugin with visual integration (play flv/mp4/mp3/aac files) - Page 5
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Flash Media Player plugin with visual integration (play flv/mp4/mp3/aac files)

Started by Αndré, December 01, 2009, 04:09:38 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

gldickens3

I have revised the bash scripts that I posted earlier which make it very easy to quickly convert videos in any format to flash format (flv) and for creating thumbnails (thumb_ files) and intermediate photos (normal_ files).  Attached is an updated file named video2ools.tar.gz file which includes the following four scripts:

video2pics - Create thumb_ and normal_ pics from a video in the current directory.
video2pics4all - Create thumb_ and normal_ pics from all videos in the current directory (batch mode).
video2flv - Create a flash video (<videoname>.flv) from a video of a certain type in the current directory.
video2flv4all - Create flash videos (<videoname>.flv) from all videos of a certain type in the current directory (batch mode).

These scripts require that ffmpeg and imagemagick are installed.

Download the tarball and extract its contents using "tar xvzpf video2ools.tar.gz".

When using video2flv and video2flv4all you can examine the source videos to determine their video bitrate, video frame rate and audio bitrate using ffmpeg -i <videoname.wmv>.

A play button is applied to the thumb_ images by the video2pics and video2pics4all scripts.  You need to specify the location of the playbutton on the source image and the size of the thumb_ and normal_ images in the scripts.  The playbutton included in the tarball is named playbutton.gif but you can use your own playbutton image if you prefer.  By default, the playbutton.gif image is placed in the top left hand corner of the thumbnail using "northwest" in the composite command in the scripts. The default thumb_ size is width = 109 and normal_ size = 640.  However, you can change the location of the play button, thumb_ size and normal_ size to wherever you would prefer by modifying the convert and composite commands in the script.

FYI,

Gordon

yogibear7

First of all, great plugin!
One issue that some of my users have is that when they use my site from an iPad/iPhone/iPod Touch, they cannot view the video because they are in flash.  The solution to this is to show the video using HTML5 video tags.  However, flash is still the better solution for most computers.  So, what I'm working on is a way to show the JW flash player on systems that have flash, and show the HTML5 player on systems that do not have flash.

<object id="FlashID3" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="{$CURRENT_PIC_DATA['pwidth']}" height="{$CURRENT_PIC_DATA['pheight']}" data="$player">
          <param name="movie" value="$player" />
          <param name="quality" value="high" />
          <param name="scale" value="exactfit" />
          <param name="wmode" value="transparent" />
          <param name="bgcolor" value="#ffffff" />
          <param name="swfversion" value="6.0.65.0" />
          <!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don't want users to see the prompt. -->
          <!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. -->
          <!--[if !IE]>-->
          <object type="application/x-shockwave-flash" data="$player" width="{$CURRENT_PIC_DATA['pwidth']}" height="{$CURRENT_PIC_DATA['pheight']}">
            <!--<![endif]-->
            <param name="quality" value="high" />
            <param name="wmode" value="transparent" />
            <param name="scale" value="exactfit" />
            <param name="swfversion" value="6.0.65.0" />
            <!-- The browser displays the following alternative content for users with Flash Player 6.0 and older. -->
            <div>

<video
    src="$file"
    height="{$CURRENT_PIC_DATA['pheight']}"
    poster=$thumb
controls="controls"
    width="{$CURRENT_PIC_DATA['pwidth']}">
</video>


            </div>
            <!--[if !IE]>-->
          </object>
          <!--<![endif]-->
                    <!--<![endif]-->
     
     
        </object>
EOT;


It almost works (the HTML5 player shows the thumbnail image, but no video).  Right now I'm trying to solve the issue of no video (as in determining which variable to use for the "src").  If anyone has any idea, let me know. 

ff

Wonderfull plugin :) It worked directly.

But I saw something strange in the filmstrip below the movies, which wasn't there before.
At the thumbs overview I get all thumbs, but in the filmstrip some of them are larger images (see attached screenshots).

Can it be something influenced by this plugin?
Without the plugin, I only get trashcans as thumbs and images.

Αndré

How did you created the thumbnails for the video files? Did you use the custom thumbnail plugin or have you uploaded them manually via ftp?

ff

Quote from: Αndré on November 28, 2010, 07:11:00 PM
How did you created the thumbnails for the video files? Did you use the custom thumbnail plugin or have you uploaded them manually via ftp?

They're very old, I don't remember.

But I'm sorry, it isn't anything your plugin did wrong, it was me.

I went to check the thumbs with "identify -format '%w %h\n' " and found out the thumbs were of the wrong size.
I guess the filmstrip of 1.5 is different to the from 1.4 which shows the thumbs small.

Sorry to bother you.

yogibear7

I figured it out.  For anyone interested:

Define a variable (put this below all the "$player ." variables):
$pics_link = 'albums/' . $CURRENT_PIC_DATA['filepath'] . $CURRENT_PIC_DATA['filename'];

<object id="FlashID3" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="{$CURRENT_PIC_DATA['pwidth']}" height="{$CURRENT_PIC_DATA['pheight']}" data="$player">
          <param name="movie" value="$player" />
          <param name="quality" value="high" />
          <param name="scale" value="exactfit" />
          <param name="wmode" value="transparent" />
          <param name="bgcolor" value="#ffffff" />
          <param name="swfversion" value="6.0.65.0" />
          <!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don't want users to see the prompt. -->
          <!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. -->
          <!--[if !IE]>-->
          <object type="application/x-shockwave-flash" data="$player" width="{$CURRENT_PIC_DATA['pwidth']}" height="{$CURRENT_PIC_DATA['pheight']}">
            <!--<![endif]-->
            <param name="quality" value="high" />
            <param name="wmode" value="transparent" />
            <param name="scale" value="exactfit" />
            <param name="swfversion" value="6.0.65.0" />
            <!-- The browser displays the following alternative content for users with Flash Player 6.0 and older. -->
            <div>

<video
    src="$pics_link"
    height="{$CURRENT_PIC_DATA['pheight']}"
    poster="$thumb"
controls="controls"
    width="{$CURRENT_PIC_DATA['pwidth']}">
</video>


Good plugin.  If anyone is interested, I'll attach the codebase file.

Αndré

Quote from: yogibear7 on November 28, 2010, 09:34:09 PM
If anyone is interested, I'll attach the codebase file.
I'm looking forward to your contribution. It cannot hurt to have that file available here :)

cavok

Hello,
Is it possible that the video is displayed in real size to the player  (not full screen, there is a button for that) when reading the file.
It seems to me that the video appears like in the configuration of Coppermine to the adjustment of the intermediate image. (But maybe it's not like that).

Thank's
Coppermine 1.5.22 hosting by Free

Αndré

Quote from: cavok on November 29, 2010, 02:52:48 PM
Hello,
Is it possible that the video is displayed in real size to the player  (not full screen, there is a button for that) when reading the file.
It seems to me that the video appears like in the configuration of Coppermine to the adjustment of the intermediate image. (But maybe it's not like that).

Thank's
That's intended, as PHP cannot fetch the video dimensions afaik. If you set the dimensions in the edit files form, they will be used.

cavok

Quote from: ΑndréThat's intended, as PHP cannot fetch the video dimensions afaik. If you set the dimensions in the edit files form, they will be used.
Fabulous, I do not know this possibility.
The world (with Coppermine) is wonderful.

I use Custom Thumbnail plugin as recommended, but but when I view the video page /coppermine/displayimage.php, after the video (when an automatic start) is the thumbnail that appears in large format.
So the quality is really bad. Can not we create an intermediate image of better quality?

Thank's


Coppermine 1.5.22 hosting by Free

Αndré

Quote from: cavok on November 30, 2010, 01:47:11 AM
Can not we create an intermediate image of better quality?
Not related to this plugin. Please post your question in the custom thumbnail plugin announcement thread.

CJS0815

Hello,

sorry, i've the same problem like the User in Post 3 - but i find no Solution in the Thread. Of Course my english is not so good, to understand 100% of the written below.

For my better understanding, i dont have to install the JW-Player 5.4 from the longtailvideo-side (i dont have), i have only to install the plugin via the coppermine admin-plugin-page (i have - its on the side from installed plugins).

My Gallery and the related videos are at www.kajotes.de

Whats wrong with me or my coppermine?

Claus



Αndré


CJS0815

@André
Thanks a lot - it works - a little - now the .flv-file is playing perfectly, but the same original handy-file as mp4 is playing without pictures, only with sound. Its a problem with the decoding/recording from my handy or a known plugin-problem?
   



Αndré

Quote from: CJS0815 on December 19, 2010, 10:16:39 PM
the same original handy-file as mp4 is playing without pictures, only with sound.
Seems that your handy uses a codec that isn't supported by the player. I cannot fix that, as I'm not the author of the flash player.

Αndré

Version 1.8 (attached to initial post) now uses the intermediate-sized picture as preview, if available. Additionally the player.swf file has been updated to version 5.4.1492.

cavok

This year, Christmas has come earlier.

Thank you for this update of the plugin that works perfectly.
With its intermediate image is much more beautiful, for sure.

I wish you a very good Christmas.
Coppermine 1.5.22 hosting by Free

ligerzero

Heya. Is there anyway to embed the video and the player onto a site? im wanting to embed it onto my blog.

Αndré

Sure. Just have a look at the HTML code when you view the video and copy that code to your blog.

François Keller

Avez vous lu la DOC ? la FAQ ? et cherché sur le forum avant de poster ?
Did you read the DOC ? the FAQ ? and search the board before posting ?
Mon Blog