LibreOffice Module drawinglayer (master) 1
|
Shadow3DExtractingProcessor class. More...
#include <shadow3dextractor.hxx>
Public Member Functions | |
Shadow3DExtractingProcessor (const geometry::ViewInformation3D &rViewInformation, basegfx::B2DHomMatrix aObjectTransformation, const basegfx::B3DVector &rLightNormal, double fShadowSlant, const basegfx::B3DRange &rContained3DRange) | |
virtual | ~Shadow3DExtractingProcessor () override |
const primitive2d::Primitive2DContainer & | getPrimitive2DSequence () const |
data read access More... | |
const basegfx::B2DHomMatrix & | getObjectTransformation () const |
const basegfx::B3DHomMatrix & | getWorldToEye () const |
Public Member Functions inherited from drawinglayer::processor3d::BaseProcessor3D | |
BaseProcessor3D (geometry::ViewInformation3D aViewInformation) | |
virtual | ~BaseProcessor3D () |
void | process (const primitive3d::Primitive3DContainer &rSource) |
const geometry::ViewInformation3D & | getViewInformation3D () const |
Private Member Functions | |
basegfx::B2DPolygon | impDoShadowProjection (const basegfx::B3DPolygon &rSource) |
local helpers More... | |
basegfx::B2DPolyPolygon | impDoShadowProjection (const basegfx::B3DPolyPolygon &rSource) |
virtual void | processBasePrimitive3D (const primitive3d::BasePrimitive3D &rCandidate) override |
Private Attributes | |
primitive2d::Primitive2DContainer | maPrimitive2DSequence |
result holding vector (2D) and target vector for stacking (inited to &maPrimitive2DSequence) More... | |
primitive2d::Primitive2DContainer * | mpPrimitive2DSequence |
basegfx::B2DHomMatrix | maObjectTransformation |
object transformation for scene for 2d definition More... | |
basegfx::B3DHomMatrix | maWorldToEye |
prepared data (transformations) for 2D/3D shadow calculations More... | |
basegfx::B3DHomMatrix | maEyeToView |
basegfx::B3DVector | maLightNormal |
basegfx::B3DVector | maShadowPlaneNormal |
basegfx::B3DPoint | maPlanePoint |
double | mfLightPlaneScalar |
bool | mbShadowProjectionIsValid: 1 |
flag if shadow plane projection preparation led to valid results More... | |
bool | mbConvert: 1 |
flag if conversion is switched on More... | |
bool | mbUseProjection: 1 |
flag if conversion shall use projection More... | |
Additional Inherited Members | |
Protected Member Functions inherited from drawinglayer::processor3d::BaseProcessor3D | |
void | updateViewInformation (const geometry::ViewInformation3D &rViewInformation3D) |
virtual void | processBasePrimitive3D (const primitive3d::BasePrimitive3D &rCandidate) |
Shadow3DExtractingProcessor class.
This processor extracts the 2D shadow geometry (projected geometry) of all fed primitives. It is used to create the shadow of 3D objects which consists of 2D geometry. It needs quite some data to do so since we do not only offer flat projected 2D shadow, but also projections dependent on the light source
Definition at line 42 of file shadow3dextractor.hxx.
drawinglayer::processor3d::Shadow3DExtractingProcessor::Shadow3DExtractingProcessor | ( | const geometry::ViewInformation3D & | rViewInformation, |
basegfx::B2DHomMatrix | aObjectTransformation, | ||
const basegfx::B3DVector & | rLightNormal, | ||
double | fShadowSlant, | ||
const basegfx::B3DRange & | rContained3DRange | ||
) |
Definition at line 205 of file shadow3dextractor.cxx.
References basegfx::B3DRange::getDepth(), drawinglayer::geometry::ViewInformation3D::getDeviceToView(), basegfx::B3DRange::getMaxX(), basegfx::B3DRange::getMaxY(), basegfx::B3DRange::getMinX(), basegfx::B3DRange::getMinY(), basegfx::B3DRange::getMinZ(), drawinglayer::geometry::ViewInformation3D::getObjectTransformation(), drawinglayer::geometry::ViewInformation3D::getOrientation(), drawinglayer::geometry::ViewInformation3D::getProjection(), drawinglayer::processor3d::BaseProcessor3D::getViewInformation3D(), getWorldToEye(), basegfx::Tuple3D< typename TYPE >::getX(), basegfx::Tuple3D< typename TYPE >::getY(), maEyeToView, maLightNormal, maPlanePoint, maShadowPlaneNormal, maWorldToEye, mbShadowProjectionIsValid, mfLightPlaneScalar, basegfx::fTools::more(), basegfx::B3DVector::normalize(), basegfx::B3DVector::scalar(), basegfx::Tuple3D< typename TYPE >::setX(), basegfx::Tuple3D< typename TYPE >::setY(), basegfx::Tuple3D< typename TYPE >::setZ(), and basegfx::B3DRange::transform().
|
overridevirtual |
Definition at line 245 of file shadow3dextractor.cxx.
References maPrimitive2DSequence.
|
inline |
Definition at line 89 of file shadow3dextractor.hxx.
References maObjectTransformation.
Referenced by processBasePrimitive3D().
const primitive2d::Primitive2DContainer & drawinglayer::processor3d::Shadow3DExtractingProcessor::getPrimitive2DSequence | ( | ) | const |
data read access
Definition at line 292 of file shadow3dextractor.cxx.
References maPrimitive2DSequence.
Referenced by drawinglayer::primitive2d::Embedded3DPrimitive2D::impGetShadow3D(), and drawinglayer::primitive2d::ScenePrimitive2D::impGetShadow3D().
|
inline |
Definition at line 90 of file shadow3dextractor.hxx.
References maWorldToEye.
Referenced by impDoShadowProjection(), and Shadow3DExtractingProcessor().
|
private |
local helpers
Definition at line 251 of file shadow3dextractor.cxx.
References a, basegfx::B2DPolygon::append(), basegfx::B3DPolygon::count(), basegfx::B3DPolygon::getB3DPoint(), getWorldToEye(), basegfx::Tuple3D< typename TYPE >::getX(), basegfx::Tuple3D< typename TYPE >::getY(), basegfx::B3DPolygon::isClosed(), maEyeToView, maLightNormal, maPlanePoint, maShadowPlaneNormal, mfLightPlaneScalar, and basegfx::B2DPolygon::setClosed().
Referenced by impDoShadowProjection(), and processBasePrimitive3D().
|
private |
Definition at line 280 of file shadow3dextractor.cxx.
References a, basegfx::B2DPolyPolygon::append(), basegfx::B3DPolyPolygon::count(), basegfx::B3DPolyPolygon::getB3DPolygon(), and impDoShadowProjection().
|
overrideprivatevirtual |
Reimplemented from drawinglayer::processor3d::BaseProcessor3D.
Definition at line 44 of file shadow3dextractor.cxx.
References basegfx::B2DPolygon::count(), basegfx::B2DPolyPolygon::count(), basegfx::utils::createB2DPolygonFromB3DPolygon(), basegfx::utils::createB2DPolyPolygonFromB3DPolyPolygon(), drawinglayer::primitive3d::BasePrimitive3D::get3DDecomposition(), drawinglayer::primitive3d::PolygonHairlinePrimitive3D::getB3DPolygon(), drawinglayer::primitive3d::PolyPolygonMaterialPrimitive3D::getB3DPolyPolygon(), drawinglayer::primitive3d::GroupPrimitive3D::getChildren(), drawinglayer::geometry::ViewInformation3D::getDeviceToView(), drawinglayer::geometry::ViewInformation3D::getExtendedInformationSequence(), getObjectTransformation(), drawinglayer::geometry::ViewInformation3D::getObjectTransformation(), drawinglayer::geometry::ViewInformation3D::getOrientation(), drawinglayer::primitive3d::BasePrimitive3D::getPrimitive3DID(), drawinglayer::geometry::ViewInformation3D::getProjection(), drawinglayer::primitive3d::ShadowPrimitive3D::getShadow3D(), drawinglayer::primitive3d::ShadowPrimitive3D::getShadowColor(), drawinglayer::primitive3d::ShadowPrimitive3D::getShadowTransform(), drawinglayer::primitive3d::ShadowPrimitive3D::getShadowTransparence(), drawinglayer::primitive3d::TransformPrimitive3D::getTransformation(), drawinglayer::processor3d::BaseProcessor3D::getViewInformation3D(), drawinglayer::geometry::ViewInformation3D::getViewTime(), impDoShadowProjection(), maEyeToView, maWorldToEye, mbConvert, mbShadowProjectionIsValid, mbUseProjection, basegfx::fTools::more(), mpPrimitive2DSequence, PRIMITIVE3D_ID_POLYGONHAIRLINEPRIMITIVE3D, PRIMITIVE3D_ID_POLYPOLYGONMATERIALPRIMITIVE3D, PRIMITIVE3D_ID_SHADOWPRIMITIVE3D, PRIMITIVE3D_ID_TRANSFORMPRIMITIVE3D, drawinglayer::processor3d::BaseProcessor3D::process(), basegfx::B2DPolygon::transform(), basegfx::B2DPolyPolygon::transform(), and drawinglayer::processor3d::BaseProcessor3D::updateViewInformation().
|
private |
Definition at line 54 of file shadow3dextractor.hxx.
Referenced by impDoShadowProjection(), processBasePrimitive3D(), and Shadow3DExtractingProcessor().
|
private |
Definition at line 55 of file shadow3dextractor.hxx.
Referenced by impDoShadowProjection(), and Shadow3DExtractingProcessor().
|
private |
object transformation for scene for 2d definition
Definition at line 50 of file shadow3dextractor.hxx.
Referenced by getObjectTransformation().
|
private |
Definition at line 57 of file shadow3dextractor.hxx.
Referenced by impDoShadowProjection(), and Shadow3DExtractingProcessor().
|
private |
result holding vector (2D) and target vector for stacking (inited to &maPrimitive2DSequence)
Definition at line 46 of file shadow3dextractor.hxx.
Referenced by getPrimitive2DSequence(), and ~Shadow3DExtractingProcessor().
|
private |
Definition at line 56 of file shadow3dextractor.hxx.
Referenced by impDoShadowProjection(), and Shadow3DExtractingProcessor().
|
private |
prepared data (transformations) for 2D/3D shadow calculations
Definition at line 53 of file shadow3dextractor.hxx.
Referenced by getWorldToEye(), processBasePrimitive3D(), and Shadow3DExtractingProcessor().
|
private |
flag if conversion is switched on
Definition at line 64 of file shadow3dextractor.hxx.
Referenced by processBasePrimitive3D().
|
private |
flag if shadow plane projection preparation led to valid results
Definition at line 61 of file shadow3dextractor.hxx.
Referenced by processBasePrimitive3D(), and Shadow3DExtractingProcessor().
|
private |
flag if conversion shall use projection
Definition at line 67 of file shadow3dextractor.hxx.
Referenced by processBasePrimitive3D().
|
private |
Definition at line 58 of file shadow3dextractor.hxx.
Referenced by impDoShadowProjection(), and Shadow3DExtractingProcessor().
|
private |
Definition at line 47 of file shadow3dextractor.hxx.
Referenced by processBasePrimitive3D().