java.lang.Object
de.grogra.graph.impl.Edge
de.grogra.graph.impl.Node
de.grogra.imp3d.shading.ChannelMapNode
de.grogra.imp3d.shading.Filter
- All Implemented Interfaces:
ChannelMap
,Manageable
,PersistenceCapable
,Shareable
,UserFields
,XObject
,Map
,Serializable
A Filter is the base for 3D image filtering operations.
Subclasses provide a 3D filter coefficient matrix (which is queried by the getCoefficient* functions).
The filter is applied to the requested channel by sampling values for each coefficient in the matrix
and then calculating the weigthed sum. The size of the sampling cube can be adjusted by the fields
sx, sy and sy (in x/y/z and u/v directions).
- Author:
- nmi
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class de.grogra.graph.impl.Node
Node.AccessorBridge, Node.FieldAttributeAccessor, Node.NType
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Node.NType
static final Node.NType.Field
static final Node.NType.Field
static final Node.NType.Field
Fields inherited from class de.grogra.imp3d.shading.ChannelMapNode
AMBIENT, COLOR, COLOR_2, DIFFUSE_TRANSPARENCY, DISPLACEMENT, EMISSIVE, FIRST_OP, INPUT, input$FIELD, MIN_UNUSED_SPECIAL_OF_TARGET, SECOND_OP, SHININESS, SPECULAR, TRANSPARENCY, TRANSPARENCY_SHININESS
Fields inherited from class de.grogra.graph.impl.Node
ADDITIONAL_FIELDS, bits, DELETED, EXTENT_BIT, EXTENT_MASK, extentIndex$FIELD, extentTail$FIELD, HAS_OBSERVERS, IS_INTERPRETIVE, isInterpretive$FIELD, LAST_EXTENT_INDEX, layer$FIELD, MARK, mark$FIELD, MAX_RESOLUTION, MIME_TYPE, MIN_RESOLUTION, MIN_UNUSED_SPECIAL_OF_SOURCE, name$FIELD, RESOLUTION_BIT, RESOLUTION_MASK, resolution$FIELD, USED_BITS
Fields inherited from interface de.grogra.util.Map
DEFAULT_VALUE, EMPTY_MAP
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
accept
(ChannelMapNodeVisitor visitor) protected abstract float
getCoefficient
(int gx, int gy, int gz) Get the coefficient at position (gx/gy/gz) in the filter matrix.float
getFloatValue
(ChannelData data, int channel) float
getSx()
float
getSy()
float
getSz()
void
setSx
(float value) void
setSy
(float value) void
setSz
(float value) Methods inherited from class de.grogra.imp3d.shading.ChannelMapNode
accept, getInput, getObjectValue, setInput
Methods inherited from class de.grogra.graph.impl.Node
addEdgeBitsTo, addReference, appendBranchNode, appendBranchNode, appendReferencesTo, clone, clone, cloneGraph, dump, dumpTree, dup, dupFrom, dupnew, dupUnmanagedFields, edgeChanged, fieldModified, findAdjacent, findRefinementType, get, getAccessor, getAccessor, getAttributes, getAxisParent, getBoolean, getBranch, getBranchLength, getBranchNode, getBranchTail, getByte, getChar, getCommonAncestor, getCurrentGraphState, getDirectChildCount, getDouble, getEdgeAttributeAccessor, getEdgeAttributes, getEdgeBitsTo, getEdgeTo, getExtentIndex, getFirst, getFirstEdge, getFloat, getGraph, getId, getIgnored, getIndex, getInstantiator, getInt, getLayer, getLong, getManageableType, getName, getNeighbor, getNext, getNType, getNTypeImpl, getObject, getOrCreateEdgeTo, getOrNull, getPersistenceManager, getPredecessor, getProvider, getResolution, getShort, getSource, getStamp, getSuccessor, getSymbol, getSymbolColor, getTarget, getTransaction, getUserField, getUserFieldCount, getXClass, getXData, hasName, initProvider, initXClass, insertBranchNode, insertBranchNode, instantiateGraph, isAncestorOf, isDirection, isEncoarseOf, isManagingInstance, isMarked, isRoot, isSource, isTarget, manageableReadResolve, manageableWriteReplace, newInstance, paramString, removeAll, removeEdgeBitsTo, removeFromChain, removeFromChain, removeReference, setBranch, setBranch, setExtentIndex, setGraphForDeserialization, setIgnored, setLayer, setMark, setName, setResolution, setSuccessor, setSuccessor, specialEdgeAdded, specialEdgeRefModified, specialEdgeRemoved, toString, writeReplace
Methods inherited from class de.grogra.graph.impl.Edge
addEdgeBits, getBitMark, getEdgeBits, getEdgeKeys, getObjectMark, getSpecialEdgeDescriptor, parseEdgeKeys, remove, removeEdgeBits, setBitMark, setEdgeBits, setObjectMark, testEdgeBits
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface de.grogra.math.ChannelMap
getStamp
Methods inherited from interface de.grogra.persistence.PersistenceCapable
getBitMark, getObjectMark, setBitMark, setObjectMark
-
Field Details
-
$TYPE
-
sx$FIELD
-
sy$FIELD
-
sz$FIELD
-
-
Constructor Details
-
Filter
public Filter()
-
-
Method Details
-
getSx
public float getSx() -
setSx
public void setSx(float value) -
getSy
public float getSy() -
setSy
public void setSy(float value) -
getSz
public float getSz() -
setSz
public void setSz(float value) -
getCoefficient
protected abstract float getCoefficient(int gx, int gy, int gz) Get the coefficient at position (gx/gy/gz) in the filter matrix. The functions getCoefficientMaskSize* are used to obtain the indexable range (i.e. sx, sy and sz), so 0 <= gx <= sx. Derived classes implement this function to provide filter coefficients. The Filter class will perform the filtering by applying those coefficients as weigths to the sampled values from the input channel.- Parameters:
gx
-gy
-gz
-- Returns:
-
getFloatValue
- Specified by:
getFloatValue
in interfaceChannelMap
- Overrides:
getFloatValue
in classChannelMapNode
-
accept
- Overrides:
accept
in classChannelMapNode
-