Page 1 of 6 123 ... LastLast
Results 1 to 10 of 55

Thread: Hardcoded video watermark mod

  1. #1
    Join Date
    May 2007
    Posts
    588

    Default Hardcoded video watermark mod

    Ok so if you want your FLV files to have a watermark hardcoded onto them then this guide should help you. You might want this feature if you offer FLV files for download ( http://forums.buyscripts.in/viewtopic.php?t=1438 ) and want to keep your site URL on the video or if you want to make sure no one is removing the watermark from the embeded code.

    You have 2 choices depending on what you use to convert you videos. I use mencoder as it seems to have better quaility results and is default converter on vshare, however if you use ffmpeg you have a better option.

    ffmepg
    If you use ffmpeg for converting you can use the vhook feature ( http://ffmpeg.mplayerhq.hu/hooks.html#SEC7 ) to add image watermarks to your videos.

    You will have to read the docs and work it out yourself though....post a guide if you use this way as i dont have time to look into it.

    mencoder
    If you use mencoder for converting it has a feature that is supposed to add image watermarks called bmov, however from my research it doesn't work great and no one knows how to use it. So for mencoder i just used the subtitler feature which lets me have a text watermark pop up with my site URL when i want and for how long i want.

    Here is how to do it, first of all you need to create your watermark text file (subs file).

    just open up a text editor and paste this into it.

    Code:
    1
    00:00:05,000 --> 00:00:20,000
    mysite.com
    the code above will after 5 seconds of watching the video display "mysite.com" on the video for 15 seconds and then disapear. Edit it to display how you want, more info can be found here http://en.wikipedia.org/wiki/.srt

    save the text file as watermark.srt and upload it to your include/settings/ directory.

    Then open up include/settings/video_conversion.php with a text editor.

    change the mencoder line so it looks like this
    Code:
    $cmd_mencoder = "$config[mencoder] '$video_src' -o $video_flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -srate 22050 -lavfopts i_certify_that_my_video_stream_does_not_use_b_frames -sub /home/USER/public_html/include/settings/watermark.srt -subpos 98";
    Remember to change the /home/USER/public_html to your path to vshare.

    The -subpos 98 bit puts the watermark 98% down from the top of the video....so it would be right at the bottom....you could change it to -subpos 2 if you wanted the watermark at the top of the video.

    And thats it....when your video is converted you should have a hardcoded text watermark on your video :)

    You should also be able to change the font, size, colour, width position etc but i have not had time to look into that yet.

  2. #2
    Join Date
    Jul 2007
    Posts
    169

    Default

    Thanks !!
    SPEED UP YOUR VSHARE SITE!
    Speed up your vshare site by "offloading" your images and video thumbs!
    Just visit http://offload.limbar.com for details.

  3. #3
    Join Date
    Jul 2007
    Posts
    169

    Default

    Question:
    When I save the watermark file as "watermark.srt" .. my text editor puts a .txt at the end of the name -- is this a problem? Im using WordPad. In anycase, I followed the directions, but there was no text that showed up on my new vids uploaded :cry:
    SPEED UP YOUR VSHARE SITE!
    Speed up your vshare site by "offloading" your images and video thumbs!
    Just visit http://offload.limbar.com for details.

  4. #4
    Join Date
    May 2007
    Posts
    588

    Default

    when saving the filename put quotes around it..like "watermark.srt"....that will stop wordpad putting a .txt on the end.

    or you could just rename the file after you uploaded it to remove the .txt

  5. #5
    Join Date
    Jul 2007
    Posts
    169

    Default

    I did remove the txt.. uploaded it, and changed the php file -- however, it didnt work on the vids I uploaded afterwards. Any thoughts on why? The text I put in the file said "from MyWebSite.com"
    SPEED UP YOUR VSHARE SITE!
    Speed up your vshare site by "offloading" your images and video thumbs!
    Just visit http://offload.limbar.com for details.

  6. #6
    Join Date
    May 2007
    Posts
    588

    Default

    post everything from you include/settings/video_conversion.php file here

  7. #7
    Join Date
    Jul 2007
    Posts
    169

    Default

    Quote Originally Posted by leki
    post everything from you include/settings/video_conversion.php file here
    Here it is:
    $cmd_mencoder = "$config[mencoder] '$video_src' -o $video_flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:l ast_pred=3 -srate 22050 -lavfopts i_certify_that_my_video_stream_does_not_use_b_fram es -sub /home/boot7com/public_html/include/settings/watermark.srt -subpos 2";
    SPEED UP YOUR VSHARE SITE!
    Speed up your vshare site by "offloading" your images and video thumbs!
    Just visit http://offload.limbar.com for details.

  8. #8
    Join Date
    May 2007
    Posts
    588

    Default

    is that everything in the from the whole file?

  9. #9
    Join Date
    Jul 2007
    Posts
    169

    Default

    No sorry -- heres everything:

    <?php

    $cmd_ffmpeg = "$config[ffmpeg] -i $video_src -acodec mp3 -ar 22050 -ab 32 -f flv $video_flv";
    $cmd_mencoder = "$config[mencoder] '$video_src' -o $video_flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:l ast_pred=3 -srate 22050 -lavfopts i_certify_that_my_video_stream_does_not_use_b_fram es -sub /home/boot7com/public_html/include/settings/watermark.srt -subpos 2";
    $cmd_all = $cmd_mencoder;


    $convert_3gp = $cmd_all;
    $convert_mp4 = $cmd_all;
    $convert_mov = $cmd_all;
    $convert_asf = $cmd_all;
    $convert_mpg = $cmd_all;
    $convert_avi = $cmd_all;
    $convert_mpeg = $cmd_all;
    $convert_wmv = $cmd_all;
    $convert_rm = $cmd_all;
    $convert_dat = $cmd_all;
    SPEED UP YOUR VSHARE SITE!
    Speed up your vshare site by "offloading" your images and video thumbs!
    Just visit http://offload.limbar.com for details.

  10. #10
    Join Date
    May 2007
    Posts
    588

    Default

    well that looks fine, re-check all steps were done correctly, if not post the whole of your watermark.srt file and say if you have SSH access.

    also if you are importing FLV files or uploading FLV files it wont put the watermark on as these files do not get converted. Do a test with an AVI or WMV file.

Page 1 of 6 123 ... LastLast

Similar Threads

  1. Place watermark anywhere on video!
    By mersh in forum Template Modifications
    Replies: 2
    Last Post: 07-24-2008, 03:57 PM
  2. watermark
    By ostendo in forum Installation Support
    Replies: 3
    Last Post: 01-14-2008, 09:13 PM
  3. Watermark
    By Alexy in forum Feature Requests
    Replies: 12
    Last Post: 08-14-2007, 09:27 PM
  4. Watermark
    By admin in forum Frequently Asked Questions
    Replies: 7
    Last Post: 08-01-2007, 02:51 AM
  5. .Swf Or .Flv as A watermark
    By zeffer in forum Feature Requests
    Replies: 2
    Last Post: 06-03-2007, 10:11 PM

Bookmarks

Posting Permissions

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