001package com.hfg.svg.filtereffect; 002 003import com.hfg.svg.AbstractSvgNode; 004import com.hfg.svg.SVG; 005import com.hfg.svg.SvgAttr; 006import com.hfg.svg.SvgNode; 007import com.hfg.xml.XMLTag; 008 009//------------------------------------------------------------------------------ 010/** 011 Object representation of an SVG (Scalable Vector Graphics) 'feMerge' filter effect tag. 012 013 From <a href='http://www.w3.org/TR/2003/REC-SVG11-20030114/filters.html#feMerge'> 014 http://www.w3.org/TR/2003/REC-SVG11-20030114/filters.html#feMerge</a>: 015 <p style='font-style:italic'> 016 "This filter primitive composites input image layers on top of each other using 017 the over operator with Input1 (corresponding to the first 'feMergeNode' child element) 018 on the bottom and the last specified input, InputN (corresponding to the last 019 'feMergeNode' child element), on top." 020 </p> 021 @author J. Alex Taylor, hairyfatguy.com 022 */ 023//------------------------------------------------------------------------------ 024// com.hfg XML/HTML Coding Library 025// 026// This library is free software; you can redistribute it and/or 027// modify it under the terms of the GNU Lesser General Public 028// License as published by the Free Software Foundation; either 029// version 2.1 of the License, or (at your option) any later version. 030// 031// This library is distributed in the hope that it will be useful, 032// but WITHOUT ANY WARRANTY; without even the implied warranty of 033// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 034// Lesser General Public License for more details. 035// 036// You should have received a copy of the GNU Lesser General Public 037// License along with this library; if not, write to the Free Software 038// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 039// 040// J. Alex Taylor, President, Founder, CEO, COO, CFO, OOPS hairyfatguy.com 041// jataylor@hairyfatguy.com 042//------------------------------------------------------------------------------ 043 044public class SvgFeMerge extends AbstractSvgNode implements SvgNode 045{ 046 //########################################################################### 047 // CONSTRUCTORS 048 //########################################################################### 049 050 //--------------------------------------------------------------------------- 051 public SvgFeMerge() 052 { 053 super(SVG.feMerge); 054 } 055 056 //--------------------------------------------------------------------------- 057 public SvgFeMerge(XMLTag inXMLTag) 058 { 059 this(); 060 initFromXMLTag(inXMLTag); 061 } 062 063 //########################################################################### 064 // PUBLIC METHODS 065 //########################################################################### 066 067 068 //--------------------------------------------------------------------------- 069 public SvgFeMerge setResult(String inValue) 070 { 071 setAttribute(SvgAttr.result, inValue); 072 return this; 073 } 074 075 076 //--------------------------------------------------------------------------- 077 public SvgFeMergeNode addFeMergeNode() 078 { 079 SvgFeMergeNode newTag = new SvgFeMergeNode(); 080 addSubtag(newTag); 081 return newTag; 082 } 083 084 //--------------------------------------------------------------------------- 085 public void addFeMergeNode(SvgFeMergeNode inValue) 086 { 087 addSubtag(inValue); 088 } 089 090 //--------------------------------------------------------------------------- 091 public SvgFeMerge setColorInterpolationFilters(ColorInterpolationFilters inValue) 092 { 093 setAttribute(SvgAttr.colorInterpolationFilters, inValue); 094 return this; 095 } 096}