F:/KPlato/koffice/libs/pigment/KoCompositeOp.cpp

Aller à la documentation de ce fichier.
00001 /*
00002  *  Copyright (c) 2005 Adrian Page <adrian@pagenet.plus.com>
00003  *
00004  * This library is free software; you can redistribute it and/or
00005  * modify it under the terms of the GNU Library General Public
00006  * License as published by the Free Software Foundation; either
00007  * version 2 of the License, or (at your option) any later version.
00008  *
00009  * This library is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012  * Library General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU Library General Public License
00015  * along with this library; see the file COPYING.LIB.  If not, write to
00016  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00017  * Boston, MA 02110-1301, USA.
00018 */
00019 
00020 #include <klocale.h>
00021 
00022 #include "KoCompositeOp.h"
00023 #include "KoColorSpace.h"
00024 
00025 KoCompositeOp::KoCompositeOp()
00026 {
00027 
00028 }
00029 
00030 
00031 KoCompositeOp::KoCompositeOp(KoColorSpace * cs, const QString& id,  const QString& description,  const bool userVisible)
00032     : m_colorSpace( cs )
00033     , m_id( id )
00034     , m_description( description )
00035     , m_userVisible( userVisible )
00036 {
00037 }
00038 
00039 void KoCompositeOp::composite(quint8 *dstRowStart, qint32 dstRowStride,
00040                               const quint8 *srcRowStart, qint32 srcRowStride,
00041                               const quint8 *maskRowStart, qint32 maskRowStride,
00042                               qint32 rows, qint32 numColumns,
00043                               quint8 opacity) const
00044 {
00045     if (m_defaultChannelFlags.isNull() || m_defaultChannelFlags.isEmpty()) {
00046         m_defaultChannelFlags.fill( true, m_colorSpace->nChannels() );
00047     }
00048 
00049     composite( dstRowStart, dstRowStride,
00050                srcRowStart, srcRowStride,
00051                maskRowStart, maskRowStride,
00052                rows, numColumns,
00053                opacity, m_defaultChannelFlags);
00054 }
00055 

Généré le Wed Nov 22 23:41:13 2006 pour KPlato par  doxygen 1.5.1-p1