31#include <com/sun/star/drawing/ShadeMode.hpp>
50 if(rSubSequence.empty())
62 const css::awt::GradientStyle aGradientStyle(rFillGradient.
getStyle());
63 std::shared_ptr< texture::GeoTexSvx > pNewTex;
68 switch(aGradientStyle)
71 case css::awt::GradientStyle_LINEAR:
73 pNewTex = std::make_shared<texture::GeoTexSvxGradientLinear>(
82 case css::awt::GradientStyle_AXIAL:
84 pNewTex = std::make_shared<texture::GeoTexSvxGradientAxial>(
93 case css::awt::GradientStyle_RADIAL:
96 std::make_shared<texture::GeoTexSvxGradientRadial>(
105 case css::awt::GradientStyle_ELLIPTICAL:
108 std::make_shared<texture::GeoTexSvxGradientElliptical>(
118 case css::awt::GradientStyle_SQUARE:
121 std::make_shared<texture::GeoTexSvxGradientSquare>(
131 case css::awt::GradientStyle_RECT:
134 std::make_shared<texture::GeoTexSvxGradientRect>(
151 pNewTex = std::make_shared<texture::GeoTexSvxMono>(aSingleColor, 1.0 - aSingleColor.
luminance());
187 if(rSubSequence.empty())
193 std::shared_ptr< texture::GeoTexSvx > pOldTex =
mpGeoTexSvx;
198 aInvObjectToView.
invert();
205 double fLogicPixelSizeWorld(std::max(std::max(fabs(aLogicPixel.
getX()), fabs(aLogicPixel.
getY())), fabs(aLogicPixel.
getZ())));
208 const double fLogicTexSizeX(fLogicPixelSizeWorld / rPrimitive.
getTextureSize().
getX());
209 const double fLogicTexSizeY(fLogicPixelSizeWorld / rPrimitive.
getTextureSize().
getY());
210 const double fLogicTexSize(std::max(fLogicTexSizeX, fLogicTexSizeY));
213 mpGeoTexSvx = std::make_shared<texture::GeoTexSvxMultiHatch>(rPrimitive, fLogicTexSize);
228 if(rSubSequence.empty())
234 std::shared_ptr< texture::GeoTexSvx > pOldTex =
mpGeoTexSvx;
252 std::make_shared<texture::GeoTexSvxBitmapExTiled>(
261 std::make_shared<texture::GeoTexSvxBitmapEx>(
279 if(!rSubSequence.empty())
296 if(!aHairline.
count())
321 bool bPaintIt(aFill.
count());
324 const css::drawing::ShadeMode aShadeMode(
337 if(css::drawing::ShadeMode_FLAT == aShadeMode)
358 if(aPlaneNormal.
getZ() > 0.0)
376 if(aPlaneNormal.
getZ() > 0.0)
379 aNormalTransform.
scale(-1.0, -1.0, -1.0);
385 case css::drawing::ShadeMode_PHONG:
391 case css::drawing::ShadeMode_SMOOTH:
403 for(sal_uInt32
a(0);
a < aFill.
count();
a++)
407 for(sal_uInt32 b(0); b < aPartFill.
count(); b++)
421 case css::drawing::ShadeMode_FLAT:
554 mrSdrSceneAttribute(rSdrSceneAttribute),
555 mrSdrLightingAttribute(rSdrLightingAttribute),
556 maBColorModifierStack(),
557 mnTransparenceCounter(0),
560 mbSimpleTextureActive(false)
BitmapEx GetBitmapEx(const GraphicConversionParameters &rParameters=GraphicConversionParameters()) const
BASEGFX_DLLPUBLIC void transform(const B2DHomMatrix &rMatrix)
void scale(double fX, double fY, double fZ)
void transformNormals(const B3DHomMatrix &rMatrix)
bool areTextureCoordinatesUsed() const
void setB3DPolygon(sal_uInt32 nIndex, const B3DPolygon &rPolygon)
void transform(const basegfx::B3DHomMatrix &rMatrix)
bool areNormalsUsed() const
void clearTextureCoordinates()
B3DPolygon const & getB3DPolygon(sal_uInt32 nIndex) const
B3DVector const & getNormal() const
void clearTextureCoordinates()
void transform(const B3DHomMatrix &rMatrix)
void setBColor(sal_uInt32 nIndex, const BColor &rValue)
void push(const BColorModifierSharedPtr &rNew)
::basegfx::BColor getModifiedColor(const ::basegfx::BColor &rSource) const
bool isSingleColor(BColor &rSingleColor) const
void expand(const Tuple2D< TYPE > &rTuple)
bool overlaps(const Range2D &rRange) const
sal_uInt16 getSteps() const
double getOffsetY() const
css::awt::GradientStyle getStyle() const
const basegfx::BColorStops & getColorStops() const
double getOffsetX() const
double getOffsetY() const
const Graphic & getGraphic() const
double getOffsetX() const
const basegfx::B2DRange & getGraphicRange() const
sal_uInt16 getSpecularIntensity() const
const basegfx::BColor & getSpecular() const
const basegfx::BColor & getEmission() const
const basegfx::BColor & getColor() const
basegfx::BColor solveColorModel(const basegfx::B3DVector &rNormalInEyeCoordinates, const basegfx::BColor &rColor, const basegfx::BColor &rSpecular, const basegfx::BColor &rEmission, sal_uInt16 nSpecularIntensity) const
virtual Primitive3DContainer get3DDecomposition(const geometry::ViewInformation3D &rViewInformation) const
The default implementation returns an empty sequence.
virtual sal_uInt32 getPrimitive3DID() const =0
provide unique ID for fast identifying of known primitive implementations in renderers.
BitmapTexturePrimitive3D class.
const attribute::FillGraphicAttribute & getFillGraphicAttribute() const
data read access
GradientTexturePrimitive3D class.
const attribute::FillGradientAttribute & getGradient() const
data read access
const Primitive3DContainer & getChildren() const
data read access
HatchTexturePrimitive3D class.
ModifiedColorPrimitive3D class.
const basegfx::BColorModifierSharedPtr & getColorModifier() const
data read access
PolyPolygonMaterialPrimitive3D class.
const attribute::MaterialAttribute3D & getMaterial() const
const basegfx::B3DPolyPolygon & getB3DPolyPolygon() const
data read access
bool getDoubleSided() const
PolygonHairlinePrimitive3D class.
const basegfx::BColor & getBColor() const
const basegfx::B3DPolygon & getB3DPolygon() const
data read access
const basegfx::B2DVector & getTextureSize() const
data read access
TransparenceTexturePrimitive3D class.
void process(const primitive3d::Primitive3DContainer &rSource)
const geometry::ViewInformation3D & getViewInformation3D() const
void updateViewInformation(const geometry::ViewInformation3D &rViewInformation3D)
std::shared_ptr< texture::GeoTexSvx > mpTransparenceGeoTexSvx
the current active transparence texture
void impRenderGradientTexturePrimitive3D(const primitive3d::GradientTexturePrimitive3D &rPrimitive, bool bTransparence)
bool mbSimpleTextureActive
bool getSimpleTextureActive() const
const attribute::SdrLightingAttribute & getSdrLightingAttribute() const
DefaultProcessor3D(const geometry::ViewInformation3D &rViewInformation, const attribute::SdrSceneAttribute &rSdrSceneAttribute, const attribute::SdrLightingAttribute &rSdrLightingAttribute)
std::shared_ptr< texture::GeoTexSvx > mpGeoTexSvx
the current active texture
const attribute::SdrSceneAttribute & getSdrSceneAttribute() const
data read access
virtual void rasterconvertB3DPolyPolygon(const attribute::MaterialAttribute3D &rMaterial, const basegfx::B3DPolyPolygon &rFill) const =0
const std::shared_ptr< texture::GeoTexSvx > & getGeoTexSvx() const
void impRenderPolygonHairlinePrimitive3D(const primitive3d::PolygonHairlinePrimitive3D &rPrimitive) const
basegfx::B2DRange maRasterRange
renderer range.
virtual ~DefaultProcessor3D() override
void impRenderTransformPrimitive3D(const primitive3d::TransformPrimitive3D &rTransformCandidate)
virtual void rasterconvertB3DPolygon(const attribute::MaterialAttribute3D &rMaterial, const basegfx::B3DPolygon &rHairline) const =0
basegfx::BColorModifierStack maBColorModifierStack
the modifiedColorPrimitive stack
void impRenderHatchTexturePrimitive3D(const primitive3d::HatchTexturePrimitive3D &rPrimitive)
void impRenderBitmapTexturePrimitive3D(const primitive3d::BitmapTexturePrimitive3D &rPrimitive)
sal_uInt32 mnTransparenceCounter
counter for entered transparence textures
const std::shared_ptr< texture::GeoTexSvx > & getTransparenceGeoTexSvx() const
void impRenderModifiedColorPrimitive3D(const primitive3d::ModifiedColorPrimitive3D &rModifiedCandidate)
virtual void processBasePrimitive3D(const primitive3d::BasePrimitive3D &rBasePrimitive) override
void impRenderPolyPolygonMaterialPrimitive3D(const primitive3d::PolyPolygonMaterialPrimitive3D &rPrimitive) const
#define PRIMITIVE3D_ID_TRANSFORMPRIMITIVE3D
#define PRIMITIVE3D_ID_POLYGONHAIRLINEPRIMITIVE3D
#define PRIMITIVE3D_ID_POLYPOLYGONMATERIALPRIMITIVE3D
#define PRIMITIVE3D_ID_MODIFIEDCOLORPRIMITIVE3D
#define PRIMITIVE3D_ID_GRADIENTTEXTUREPRIMITIVE3D
#define PRIMITIVE3D_ID_TRANSPARENCETEXTUREPRIMITIVE3D
#define PRIMITIVE3D_ID_HATCHTEXTUREPRIMITIVE3D
#define PRIMITIVE3D_ID_BITMAPTEXTUREPRIMITIVE3D
B2VectorOrientation getOrientation(const B2DPolygon &rCandidate)
B2DHomMatrix createScaleB2DHomMatrix(double fScaleX, double fScaleY)
B2DRange getRange(const B2DPolygon &rCandidate)