1035a2f44SArmin Le Grand /************************************************************** 2035a2f44SArmin Le Grand * 3035a2f44SArmin Le Grand * Licensed to the Apache Software Foundation (ASF) under one 4035a2f44SArmin Le Grand * or more contributor license agreements. See the NOTICE file 5035a2f44SArmin Le Grand * distributed with this work for additional information 6035a2f44SArmin Le Grand * regarding copyright ownership. The ASF licenses this file 7035a2f44SArmin Le Grand * to you under the Apache License, Version 2.0 (the 8035a2f44SArmin Le Grand * "License"); you may not use this file except in compliance 9035a2f44SArmin Le Grand * with the License. You may obtain a copy of the License at 10035a2f44SArmin Le Grand * 11035a2f44SArmin Le Grand * http://www.apache.org/licenses/LICENSE-2.0 12035a2f44SArmin Le Grand * 13035a2f44SArmin Le Grand * Unless required by applicable law or agreed to in writing, 14035a2f44SArmin Le Grand * software distributed under the License is distributed on an 15035a2f44SArmin Le Grand * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16035a2f44SArmin Le Grand * KIND, either express or implied. See the License for the 17035a2f44SArmin Le Grand * specific language governing permissions and limitations 18035a2f44SArmin Le Grand * under the License. 19035a2f44SArmin Le Grand * 20035a2f44SArmin Le Grand *************************************************************/ 21035a2f44SArmin Le Grand 22035a2f44SArmin Le Grand #ifndef INCLUDED_DRAWINGLAYER_PRIMITIVE2D_GRAPHICPRIMITIVEHELPER2D_HXX 23035a2f44SArmin Le Grand #define INCLUDED_DRAWINGLAYER_PRIMITIVE2D_GRAPHICPRIMITIVEHELPER2D_HXX 24035a2f44SArmin Le Grand 25035a2f44SArmin Le Grand #include <drawinglayer/drawinglayerdllapi.h> 26035a2f44SArmin Le Grand #include <drawinglayer/primitive2d/baseprimitive2d.hxx> 27*49c58f9bSArmin Le Grand #include <svtools/grfmgr.hxx> 28035a2f44SArmin Le Grand 29035a2f44SArmin Le Grand ////////////////////////////////////////////////////////////////////////////// 30035a2f44SArmin Le Grand // predefines 31035a2f44SArmin Le Grand 32035a2f44SArmin Le Grand class Graphic; 33035a2f44SArmin Le Grand 34035a2f44SArmin Le Grand ////////////////////////////////////////////////////////////////////////////// 35035a2f44SArmin Le Grand 36035a2f44SArmin Le Grand namespace drawinglayer 37035a2f44SArmin Le Grand { 38035a2f44SArmin Le Grand namespace primitive2d 39035a2f44SArmin Le Grand { 40035a2f44SArmin Le Grand /** Helper method with supports decomposing a Graphic with all 41035a2f44SArmin Le Grand possible contents to lower level primitives. 42035a2f44SArmin Le Grand 43035a2f44SArmin Le Grand #121194# Unified to use this helper for FillGraphicPrimitive2D 44035a2f44SArmin Le Grand and GraphicPrimitive2D at the same time. It is able to handle 45035a2f44SArmin Le Grand Bitmaps (with the sub-categories animated bitmap, and SVG), 46035a2f44SArmin Le Grand and Metafiles. 47035a2f44SArmin Le Grand */ 48035a2f44SArmin Le Grand Primitive2DSequence create2DDecompositionOfGraphic( 49035a2f44SArmin Le Grand const Graphic& rGraphic, 50035a2f44SArmin Le Grand const basegfx::B2DHomMatrix& rTransform); 51*49c58f9bSArmin Le Grand 52*49c58f9bSArmin Le Grand /** Helper to embed given sequence of primitives to evtl. a stack 53*49c58f9bSArmin Le Grand of ModifiedColorPrimitive2D's to get all the needed modifications 54*49c58f9bSArmin Le Grand applied. 55*49c58f9bSArmin Le Grand */ 56*49c58f9bSArmin Le Grand Primitive2DSequence create2DColorModifierEmbeddingsAsNeeded( 57*49c58f9bSArmin Le Grand const Primitive2DSequence& rChildren, 58*49c58f9bSArmin Le Grand GraphicDrawMode aGraphicDrawMode = GRAPHICDRAWMODE_STANDARD, 59*49c58f9bSArmin Le Grand double fLuminance = 0.0, // [-1.0 .. 1.0] 60*49c58f9bSArmin Le Grand double fContrast = 0.0, // [-1.0 .. 1.0] 61*49c58f9bSArmin Le Grand double fRed = 0.0, // [-1.0 .. 1.0] 62*49c58f9bSArmin Le Grand double fGreen = 0.0, // [-1.0 .. 1.0] 63*49c58f9bSArmin Le Grand double fBlue = 0.0, // [-1.0 .. 1.0] 64*49c58f9bSArmin Le Grand double fGamma = 1.0, // ]0.0 .. 10.0] 65*49c58f9bSArmin Le Grand bool bInvert = false); 66*49c58f9bSArmin Le Grand 67*49c58f9bSArmin Le Grand } // end of namespace primitive2d 68035a2f44SArmin Le Grand } // end of namespace drawinglayer 69035a2f44SArmin Le Grand 70035a2f44SArmin Le Grand ////////////////////////////////////////////////////////////////////////////// 71035a2f44SArmin Le Grand 72035a2f44SArmin Le Grand #endif // INCLUDED_DRAWINGLAYER_PRIMITIVE2D_GRAPHICPRIMITIVEHELPER2D_HXX 73035a2f44SArmin Le Grand 74035a2f44SArmin Le Grand ////////////////////////////////////////////////////////////////////////////// 75035a2f44SArmin Le Grand // eof 76