yumataesu / ofxGen

1 stars 0 forks source link

[question] what's the simpler usage to mix composite some layers? #3

Open moebiussurfing opened 4 years ago

moebiussurfing commented 4 years ago

hey @yumataesu , thanks for sharing your code. I am trying to figure out if I can use this addon to be used as layer composer.

I checked your 'vanadium' app and I like it, but I would like to have a tiny addon to mix some layers with easy alpha/blending tunning.

(I have a video layer with ofxHapPlayer + another layer with ofxFontStash letters + some glitch/post shaders ofxPostProcessing/ofxPostGlitch. But I am having some problems when mixing all layers ofFbo/ofClear/AlphaBlending...etc. Sometimes I get the letters effected ofFbo without transparency, and I can't mix with the video layer at the end. Sometimes I get some weird glitchy redraws.)

Do you think could ofxGen help me with this? Do you have any tiny snippet/example of how to try to do this?

Best

moebiussurfing commented 4 years ago

hey @yumataesu , sorry to ask again, but there's any chance that you push a simple example to use this addon alone as a mixer?

yumataesu commented 4 years ago

Hi, @moebiussurfing moebiussurfing Sorry for late. This addon is only for a layer manage in vanadium. So now I have no plan to push example. But I recommend this quick check tool to understand blending. It might help you.

Visual glBlendFunc + glBlendEquation Tool Even if you haven't seen glBlendFunc(), you don't need to worry about it. ofEnableBlend() is using glBlendFunc() internally :) https://www.andersriggelsen.dk/glblendfunc.php

And now I noticed that ofxGen's blending is taking a detour. I will fix this.