Do you have any plans to add watermark support for ffmpeg? I've worked out the chained -vf command to do this, but needs coding up in the module and testing. Let me know if there's anything I can do to help.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Digitalier’s picture

Version: master » 7.x-2.x-dev
Category: feature » bug
FileSize
6.47 KB

Attached patch file adds watermark support for ffmpeg using 7.x-2.10+10-dev release.

Digitalier’s picture

Priority: Normal » Major
Status: Active » Needs review

Please review and let me know if any changes are needed.

Heihachi88’s picture

It is added to a latest 7.x-2.10+14 dev?

Digitalier’s picture

No - I didn't get any response from the maintainers so I manually add it to each release and it's been working fine for me - over 2k conversions and no issues.

Heihachi88’s picture

Can you please send me your patched file? I tried to implement it manually but had no luck, got errors when trying to transcode a video

nickaein’s picture

@Heihachi88: Are you on Windows?

Heihachi88’s picture

I am using windows on my laptop and CentOS 6 on the web-server.

nickaein’s picture

Hi Heihachi88,

I'm the guy in the comments on Drupal Answers.

It's the drupal server that matters. You would check the log of drupal (at http:///admin/reports/dblog ) and take a look at latest transcoder errors to see why the FFMPEG is failing. You should see some error like FFmpeg failed to transcode....

nickaein’s picture

The attached patch will take care of watermark file path on Windows.

This patch is basically the same patch submitted by @umm plus considering the Windows path syntax when providing the watermark file path to the FFMPEG.

Three issues are taken care of:

  1. The "\" characters are replaced with "\\" as they are skip characters otherwise the path is invalid.
  2. The colon character (":") in the path (e.g. "C:\inetpub\") also must be skipped (by replacing it with "\:") since it is interpreted by FFMPEG as a separator for arguments.
  3. The whole path is put between quotation marks to avoid any trouble with space characters.

Status: Needs review » Needs work

The last submitted patch, 9: _patch.video_.1999000.watermark_support_ffmpeg.7.patch, failed testing.

nickaein’s picture

nickaein’s picture

nickaein’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 11: _patch.video_.1999000.watermark_support_ffmpeg.10.patch, failed testing.

lostkangaroo’s picture

I am not familiar enough with this module to really test but it looks like your patch is full of whitespace errors. I would review https://drupal.org/coding-standards and try resubmitting when the patch is fixed.

nickaein’s picture

I still can't get it right. It might be something wrong with the relative path.

Anyway, I currently have free time to look into this. The patch is working in my experience but if somebody needs more info about this patch, please let me know by posting a comment in this issue.

Bests,

decibel.places’s picture

I can confirm that patch in OP works against 7.x-2.x branch of Video module from Git

on Ubuntu 13.10

using ffmpeg version git-2013-09-15-d59213b

The only changes are in /transcoders/TranscoderAbstractionFactoryFfmpeg.inc

Heihachi88’s picture

So watermark works with FFmpeg now?

nickaein’s picture

@Heihachi88:

The patched submitted in #11 works for me. The reported "FAILED" for this patch is probably because of code formatting.