Patch: Many composite/blend modes mostly compatible to Adobe Photoshop (c)
Silvio Heinrich
plassy at web.de
Mon Feb 7 00:16:38 CET 2011
On 02/06/2011 11:57 PM, Sven Langkamp wrote:
> In both cases I get:
>
>
> CMakeFiles/pigmentcms.dir/colorspaces/KoLabColorSpace.o: In function
> `unsigned short cfVividLight<unsigned short>(unsigned short, unsigned
> short)':
> KoLabColorSpace.cpp:(.text._Z12cfVividLightItET_S0_S0_[unsigned short
> cfVividLight<unsigned short>(unsigned short, unsigned short)]+0x31):
> undefined reference to `KoColorSpaceMathsTraits<unsigned
> short>::unitValue'
> KoLabColorSpace.cpp:(.text._Z12cfVividLightItET_S0_S0_[unsigned short
> cfVividLight<unsigned short>(unsigned short, unsigned short)]+0x3d):
> undefined reference to `KoColorSpaceMathsTraits<unsigned
> short>::zeroValue'
> KoLabColorSpace.cpp:(.text._Z12cfVividLightItET_S0_S0_[unsigned short
> cfVividLight<unsigned short>(unsigned short, unsigned short)]+0xb3):
> undefined reference to `KoColorSpaceMathsTraits<unsigned
> short>::zeroValue'
> KoLabColorSpace.cpp:(.text._Z12cfVividLightItET_S0_S0_[unsigned short
> cfVividLight<unsigned short>(unsigned short, unsigned short)]+0xbf):
> undefined reference to `KoColorSpaceMathsTraits<unsigned
> short>::unitValue'
> CMakeFiles/pigmentcms.dir/colorspaces/KoRgbU8ColorSpace.o: In function
> `unsigned char cfVividLight<unsigned char>(unsigned char, unsigned char)':
> KoRgbU8ColorSpace.cpp:(.text._Z12cfVividLightIhET_S0_S0_[unsigned char
> cfVividLight<unsigned char>(unsigned char, unsigned char)]+0x27):
> undefined reference to `KoColorSpaceMathsTraits<unsigned char>::unitValue'
> KoRgbU8ColorSpace.cpp:(.text._Z12cfVividLightIhET_S0_S0_[unsigned char
> cfVividLight<unsigned char>(unsigned char, unsigned char)]+0x33):
> undefined reference to `KoColorSpaceMathsTraits<unsigned char>::zeroValue'
> KoRgbU8ColorSpace.cpp:(.text._Z12cfVividLightIhET_S0_S0_[unsigned char
> cfVividLight<unsigned char>(unsigned char, unsigned char)]+0x97):
> undefined reference to `KoColorSpaceMathsTraits<unsigned char>::zeroValue'
> KoRgbU8ColorSpace.cpp:(.text._Z12cfVividLightIhET_S0_S0_[unsigned char
> cfVividLight<unsigned char>(unsigned char, unsigned char)]+0xa3):
> undefined reference to `KoColorSpaceMathsTraits<unsigned char>::unitValue'
> collect2: ld returned 1 exit status
> make[2]: *** [lib/libpigmentcms.so.8.0.0] Fehler 1
> make[1]: *** [libs/pigment/CMakeFiles/pigmentcms.dir/all] Fehler 2
> make: *** [all] Fehler 2
>
Ok... next two test cases:
#ifndef _KO_COMPOSITEOPS_H_
#define _KO_COMPOSITEOPS_H_
#include <KoColorSpace.h>
#include <KoColorSpaceTraits.h>
#include <KoColorSpaceMaths.h>
#include "compositeops/KoCompositeOpFunctions.h"
#include "compositeops/KoCompositeOpGeneric.h"
template<class T>
T cfTest(T src, T dst)
{
return dst;
}
template<class _Traits_>
void addStandardCompositeOps(KoColorSpace* cs)
{
cs->addCompositeOp(new KoCompositeOpGenericSC<Traits, &cfTest>(cs,
COMPOSITE_VIVID_LIGHT, i18n("Vivid Light"),
KoCompositeOp::categoryLight(), true));
}
// _KO_COMPOSITEOPS_H_
and:
#ifndef _KO_COMPOSITEOPS_H_
#define _KO_COMPOSITEOPS_H_
#include <KoColorSpace.h>
#include <KoColorSpaceTraits.h>
#include <KoColorSpaceMaths.h>
#include "compositeops/KoCompositeOpFunctions.h"
#include "compositeops/KoCompositeOpGeneric.h"
template<class T>
T cfTest(T src, T dst)
{
return KoColorSpaceMathsTraits<T>::zeroValue;
}
template<class _Traits_>
void addStandardCompositeOps(KoColorSpace* cs)
{
cs->addCompositeOp(new KoCompositeOpGenericSC<Traits, &cfTest>(cs,
COMPOSITE_VIVID_LIGHT, i18n("Vivid Light"),
KoCompositeOp::categoryLight(), true));
}
// _KO_COMPOSITEOPS_H_
Sorry for the inconvenience :-/
More information about the kimageshop
mailing list