Video effects

Richard richardmg at trolltech.com
Fri Jul 13 13:56:59 CEST 2007


I agree that creating a separate class for every kind of effect seems  
like not a good idea (Therefore I didn't suggest it either) My main  
issue is that it will be impossible to write a cross-platform app  
with phonon that uses any of the effects? E.g. the Gaussian blur  
effect on mac (using core image filters) is called CIGaussianBlur.  
While I guess e.g. Windows has a similar filter, but called something  
slightly different?

So the only thing the user can do with any of the effects is to show  
them in a list to the app-user to choose from?
With the enumeration style it will not make phonon bigger, and at  
least you can use the effects cross platform programatically, with  
perhaps using default values for the parameters (if we cannot come up  
with something better).

I'm not saying the below solution is the best, I just wonder if we  
can solve this in a more cross platform way...

-Richard


> The problem is still the same: we can't easily have a common base of
> effects. So adding a GaussianBlurEffect class would not make sense  
> out of
> the Quicktime world.
>
> Thinking loud: Maybe a factory could do that job?
>
> Thierry
>
> -----Original Message-----
> From: Matthias Kretz [mailto:kretz at kde.org]
> Sent: vendredi 13 juillet 2007 13:23
> To: phonon-backends at kde.org
> Subject: Re: Video effects
>
> On Friday 13 July 2007, Richard wrote:
>> What I would prefer is something more like this:
>> ---
>>      if (Backendcapabilies::hasVideoEffect(Effect::GaussianBlur))
>>      	Effect * e = new Effect(Effect::GaussianBlur, parent);
>>
>> or alternatively:
>>
>>      Effect * e = new Effect(Effect::GaussianBlur, parent);
>>      if (e->isValid()){
>>          ...
>>      }
>> ---
>
> Why not go the whole way and provide
> GaussianBlurEffect *e = new GaussianBlurEffect(parent); if (e- 
> >isValid()) {
>     ...
> }
> then? Because otherwise you still have no guarantees about the  
> parameters.
>
> The generic Effect class was meant to be used by user interaction  
> only. If
> an app needs to integrate an effect then it needs a specialized  
> interface to
> that effect.
>
> This, of course, will blow up the lib size again so perhaps this  
> should be
> in a second library or #ifdefed as a feature?
>
> --
> ________________________________________________________
> Matthias Kretz (Germany)                            <><
> http://Vir.homelinux.org/
> MatthiasKretz at gmx.net, kretz at kde.org,
> Matthias.Kretz at urz.uni-heidelberg.de
>
> _______________________________________________
> Phonon-backends mailing list
> Phonon-backends at kde.org
> https://mail.kde.org/mailman/listinfo/phonon-backends



--
Richard Moe Gustavsen
Software Engineer II, Trolltech ASA
Sandakerveien 116, NO-0484 Oslo, Norway


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/phonon-backends/attachments/20070713/f32c0e3f/attachment-0001.html 


More information about the Phonon-backends mailing list