Welcome, Guest
Username Password: Remember me
  • Page:
  • 1

TOPIC: Adding border to an embedded video

Adding border to an embedded video 5 months, 1 week ago #215912

  • andrixnet
  • Pro User
  • OFFLINE
  • Gold Boarder
  • Posts: 172
  • 5 months, 1 week ago
I am trying to assemble a second video as embedded image in a larger video.
I placed the full-frame video V1 in illustration on track V2.
I placed the to be smaller video V2 on illustration on track V1.
I am using from Picture-in-Picture presets "Top left" and adjusting Z value a bit so it doesn't touch the edges.
So far so good.

But I also want the embedded video to have a solid color border like this:
This image is hidden for guests. Please log in or register to see it.


I got from this forum the Border effect. (category Key, Edge effects presets, file borderfx.fx).

Since using the Border effect on it's own adds a border at the edges of the full video frame, intuition tells me to add Border effect to the smaller video, then scale and position it with 3D DVE (top-left preset).

Unfortunately this does not work.
Instead of the intended result I get this:
This image is hidden for guests. Please log in or register to see it.


Notes:
- the outer gray contour shows the embedded video frame size (without border effect)
- the inner gray contour shows the embedded video apparent visible area (with border effect).

Where the border color should have been, after applying 3D DVE, it became transparent.

I tried several combinations of the order in which I apply these two effects, both folded and unfolded. None yielded the desired result, not even close.
I also tried fiddling with the order in the routing graph, still nothing.

Depending on the order of the effects, the border is applied either to the small, scaled video or to the entire video size, but always makes the area it should be solid color as a transparency for the smaller video.
If 3D DVE is not applied, solid color is visible correctly.
I tried 2D DVE as well, same transparency, but getting subpixel countours for the smaller video, a known issue with bundled 2D DVE.

Tried 2D DVE + alpha effect, same result.
The moment I add the DVE effect, the border color becomes transparency.
Just adding key/border and dve/2D DVE at default settings.

What am I doing wrong?

Thank you.
Video enthuziast; IT specialist
Lenovo V510 laptop
i7 7500U
AMD RADEON R7 M340

Re: Adding border to an embedded video 5 months, 1 week ago #215914

  • schrauber
  • OFFLINE
  • Platinum Boarder
  • Posts: 4460
  • 5 months, 1 week ago
andrixnet wrote:
.. I got from this forum the Border effect. (category Key, Edge effects presets, file borderfx.fx).


Where did you find the effect?

In our current library I find: BorderFx.fx
But the effect is installed in a different Lightworks category and subcategory, and works on my system together with the DVE effects as expected.

You might also like the "TRIPLE DVE" effect, which includes borders and DVE: www.lwks.com/index.php?option=com_kunena&func=view&catid=7&id=188603&limit=15&limitstart=120&Itemid=81#189601
Mainly automatically translated
--------------------------------------------
Software: Lightworks 2020.1; || Windows 10, 64 Bit
Hardware: Intel i5-4440 (3,1 GHz); || shared RAM: 8 GB; || Intel HD Graphics 4600 (can use max. 2 GB of shared RAM)

Re: Adding border to an embedded video 5 months, 1 week ago #215915

  • andrixnet
  • Pro User
  • OFFLINE
  • Gold Boarder
  • Posts: 172
  • 5 months, 1 week ago
It shows up in my LWKS under category Key.
I'll look up "Triple DVE" as well, thank you.
Video enthuziast; IT specialist
Lenovo V510 laptop
i7 7500U
AMD RADEON R7 M340

Re: Adding border to an embedded video 5 months, 1 week ago #215916

  • andrixnet
  • Pro User
  • OFFLINE
  • Gold Boarder
  • Posts: 172
  • 5 months, 1 week ago
"Triple DVE": interesting. Quite interesting.

The fact that Alpha channel in color selector for Color 1 and Color 2 has no effect is a feature or a bug?
Video enthuziast; IT specialist
Lenovo V510 laptop
i7 7500U
AMD RADEON R7 M340

Re: Adding border to an embedded video 5 months, 1 week ago #215919

  • schrauber
  • OFFLINE
  • Platinum Boarder
  • Posts: 4460
  • 5 months, 1 week ago
As far as I can see, manually changing the alpha value affects the alpha value at the output of the effect, not the internal mixing ratio.
In the effect code itself, the default value is 1.0 (opaque) and is used here, although the untouched slider shows something else. There are known issues with the automatic positioning of the slider to the preset default value.
Although these issues were supposedly fixed ?
www.lwks.com/index.php?option=com_kunena&func=view&catid=508&id=214200&Itemid=81
... but I still see the issues in beta 2020.1 revision 120537

If you want to make the border to the background transparent, you can currently do so by increasing the edge softness and, if necessary, like reducing the border width.
Mainly automatically translated
--------------------------------------------
Software: Lightworks 2020.1; || Windows 10, 64 Bit
Hardware: Intel i5-4440 (3,1 GHz); || shared RAM: 8 GB; || Intel HD Graphics 4600 (can use max. 2 GB of shared RAM)
Last Edit: 5 months, 1 week ago by schrauber.

Re: Adding border to an embedded video 5 months, 1 week ago #215942

  • jwrl
  • Moderator
    Pro User
  • OFFLINE
  • Moderator
  • Posts: 12894
  • 5 months, 1 week ago
I'll have a look at the code, andrixnet.

Re: Adding border to an embedded video 5 months, 1 week ago #215943

  • jwrl
  • Moderator
    Pro User
  • OFFLINE
  • Moderator
  • Posts: 12894
  • 5 months, 1 week ago
OK, I've had a look at the effect. My intention was that the alpha channel wouldn't be supported, and I assumed that by not explicitly setting the flag to true it would be ignored. Apparently the default for that flag is in fact true. I have now explicitly set it to false.

Re: Adding border to an embedded video 5 months, 1 week ago #215962

  • andrixnet
  • Pro User
  • OFFLINE
  • Gold Boarder
  • Posts: 172
  • 5 months, 1 week ago
Does that mean the Alpha control slider not being shown?
I removed from the effects list TripleDVE (right click->remove) and added it again, the updated version (create template from .fx file).
The Alpha slider for the 2 color controls is still present. It affects the small square showing the selected color, though not the effect result.

This image is hidden for guests. Please log in or register to see it.


I did this on a project where I already used the previous version of the effect. Then I did it on another proiect that never used this effect before. Same result in both places.

Did I perform the steps correctly?
Video enthuziast; IT specialist
Lenovo V510 laptop
i7 7500U
AMD RADEON R7 M340

Re: Adding border to an embedded video 5 months, 1 week ago #215968

  • jwrl
  • Moderator
    Pro User
  • OFFLINE
  • Moderator
  • Posts: 12894
  • 5 months, 1 week ago
Yes, you did. This is our understanding of the situation (from this post in the beta forums).

schrauber wrote:
What I haven't understood so far is the purpose of `SupportsAlpha`, especially when it is deactivated:
   bool SupportsAlpha = false;

At first, I expected that this would remove the alpha slider in the effects settings, but it remains visible.

Great White wrote:
That's the intention, yes (although changing the shader after creating an effect-template from it would have no effect)

Now you know as much as we do!
Last Edit: 5 months, 1 week ago by jwrl.

Re: Adding border to an embedded video 5 months, 1 week ago #215991

  • andrixnet
  • Pro User
  • OFFLINE
  • Gold Boarder
  • Posts: 172
  • 5 months, 1 week ago
I see.

Thank you very much.
Video enthuziast; IT specialist
Lenovo V510 laptop
i7 7500U
AMD RADEON R7 M340

Re: Adding border to an embedded video 5 months ago #216315

  • andrixnet
  • Pro User
  • OFFLINE
  • Gold Boarder
  • Posts: 172
  • 5 months ago
I discovered another thing.

There's a "Border" effect in the Key category
And there's a "Border" effect in the DVE category (missed it before).

If I use the one from Key category, I get transparency instead of border.
If I use the one from DVE it seems to work as expected.

Video enthuziast; IT specialist
Lenovo V510 laptop
i7 7500U
AMD RADEON R7 M340

Re: Adding border to an embedded video 5 months ago #216327

  • schrauber
  • OFFLINE
  • Platinum Boarder
  • Posts: 4460
  • 5 months ago
andrixnet wrote:
.. There's a "Border" effect in the Key category
And there's a "Border" effect in the DVE category (missed it before)..

These are probably all user effects that were programmed or modified and installed at different times. Of course it can also be an effect template.
Standard effects that came with the Lightworks installation can be seen by the fact that the installations have no delete option.

So the Lightworks category is not a good way to identify the effect. More helpful would be the website from which you downloaded the effect, and at what time. Also the fx-file on your system often contains information about the author, updates etc.

If you have problems with user effects that have been installed on your system for a long time, I would recommend to test a current version from the current user library first. Be careful with effect files of the same name, because replacing an old file with a new one can in some cases lead to incompatibilities if the effect has already been used in a project and / or with the old installation.

If you have several old user effects on your system that you have never used before, it might be easiest to uninstall these effects, delete the associated FX files or move them to an archive folder, and load and install only the required effect from the current library.

If you have found problems with this new effect, the exact name of the fx file would be helpful to identify it.
Mainly automatically translated
--------------------------------------------
Software: Lightworks 2020.1; || Windows 10, 64 Bit
Hardware: Intel i5-4440 (3,1 GHz); || shared RAM: 8 GB; || Intel HD Graphics 4600 (can use max. 2 GB of shared RAM)
Last Edit: 5 months ago by schrauber.

Re: Adding border to an embedded video 5 months ago #216341

  • jwrl
  • Moderator
    Pro User
  • OFFLINE
  • Moderator
  • Posts: 12894
  • 5 months ago
I have just checked the border effect. I notice that, significantly, the following two updates are listed.

// Modified 22 November 2018 jwrl.
// Fixed a bug that meant that the border was always transparent.  Transparency can now
// be set by adjusting the alpha value of "Color".
//
// Modified 23 December 2018 jwrl.
// Changed category and subcategory.

The December 2018 update changed the category to DVE, consistent with other border and crop effects. Going back through the effect's history, it was originally placed in the Key category. You should not use that version. As well as the transparency problem, it may also have cross-platform issues.

Just a note: over time there have been changes to the way that Lightworks effects have been written. Some changes are to take advantage of new features, some address cross platform issues in the effects subsystem that have been discovered by the Lightworks developers after the user effect was written, some just address bugs in the original code. It must be said that for the most part that last problem has appeared in remarkably few effects. The users who post here are pretty good at nailing problems before release.

It's always a good idea to check the current version release dates after any new update to Lightworks. I try and stay on top of any changes mandated by a Lightworks update.
Last Edit: 5 months ago by jwrl.
  • Page:
  • 1
Time to create page: 0.42 seconds
Scroll To Top