[Cin] User Defined Blend Algebra

Andrea paz gamberucci.andrea at gmail.com
Thu Feb 13 15:56:48 CET 2025


CIN_CONFIG I apply it at compile time (./configure) via the flag
“--with-config-dir=/home/paz/.bcast6”. So I think your plugin fails to
catch this change of mine and takes .bcast5 by default. But this is
not a problem because it only affects my customization.

> At the end of help text the script prints values from his environment, check
> them.

>From the script help I get:

[...]
Relevant environment variables

$CIN_CC: currently not set, fallback: gcc
$CC: currently not set, fallback: gcc
CIN_EDITOR=kate
$CIN_DAT: currently not set
CIN_CONFIG=/home/paz/.bcast6
$CIN_USERLIB: currently not set, fallback: /home/paz/.bcast6lib


NOTE: I have a BlendAlgebraCompile.pl also in .bcast5, despite never
having started appimage since I did the compilation with your plugin.
This file maintains emacs and .bcast5.

Come to think of it, there is no reason to use separate .bcast6 and
thus create further complications for me.

> destination became #0, source #1,

Great, that clarifies a lot of things for me.

> There are more confusions. For example, if you have red and green, both
> opaque, over black background, and do subtraction, if you subtract red from
> black, you get black (clipped from '-red'). If you subtract red from green,
> perhaps you would think, you should get green, but actually you can get
> black because here you subtract also alpha from alpha, both being 1.0, and
> as the result you get alpha = 1-1 = 0.0, also black.

And this makes me understand some of the many doubts I had about overlays....

> In CGG there is also a questionable feature, what contents is seen through
> transparency if there is no completely opaque track in the stack. You must
> place an extra track with opaque background on the very bottom to get
> predictable results. It has nothing to do with Blend Algebra, it is a
> fundamental property in CGG.
>
> Perhaps to make yourself familiar, first try unpack some of my examples,
> load a project from there, play it through. Then edit something other.
>
> For the 'ovl2' example, you can test to attach the Overlay plugin and switch
> Blend Algebra off, to see the difference between the two.
>
> For some cases you can switch top or bottom first, and the output track, see
> the result and understand what happens. But for some other cases it can look
> really confusing, until replaying the formula in own brain:(

I tried your ovl2.xml project. Thank you, it is good job. I understand
what you are saying, until you examine the formulas carefully, the
result is hard to guess. I feel like I am dealing with Quantum
Mechanics!  :)

> > - Hide imput tracks, use output exclusively: active (I do not
> > understand in which cases to use off)
>
> Perhaps if you have additionally a mask over the result track and want that
> one of the argument tracks be seen through the hole in the mask.

Thanks.

I would like to use your explanations by summarizing them in the
manual (and perhaps keep the full text in a separate file for users
interested in further analysis). What do you think? Better to use all
your writing in the manual?


More information about the Cin mailing list