INTEGRATION: CWS chart2mst3 (1.2.10); FILE MERGED

2006/11/22 17:27:00 iha 1.2.10.3: RESYNC: (1.3-1.4); FILE MERGED
2006/10/18 17:24:22 bm 1.2.10.2: RESYNC: (1.2-1.3); FILE MERGED
2006/09/23 07:47:19 iha 1.2.10.1: apply texture correctly to floor, bottom and 3D lines
This commit is contained in:
Vladimir Glazounov 2007-05-22 18:25:56 +00:00
parent eef67e19e9
commit 7415d3383d

View file

@ -4,9 +4,9 @@
*
* $RCSfile: Stripe.cxx,v $
*
* $Revision: 1.4 $
* $Revision: 1.5 $
*
* last change: $Author: ihi $ $Date: 2006-11-14 15:36:32 $
* last change: $Author: vg $ $Date: 2007-05-22 19:25:56 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@ -74,6 +74,18 @@ Stripe::Stripe( const drawing::Position3D& rPoint1
}
Stripe::Stripe( const drawing::Position3D& rPoint1
, const drawing::Position3D& rPoint2
, double fDepth )
: m_aPoint1(rPoint1)
, m_aPoint2(rPoint2)
, m_aPoint3(rPoint2)
, m_aPoint4(rPoint1)
{
m_aPoint3.PositionZ += fDepth;
m_aPoint4.PositionZ += fDepth;
}
drawing::Direction3D Stripe::GetDirectionTo4() const
{
return m_aPoint4-m_aPoint1;
@ -142,7 +154,7 @@ drawing::Direction3D Stripe::getNormal() const
return B3DVectorToDirection3D(aNormal);
}
uno::Any Stripe::getNormalsPolyPolygonShape3D() const
uno::Any Stripe::getNormalsPolygon() const
{
drawing::PolyPolygonShape3D aPP;
@ -173,6 +185,45 @@ uno::Any Stripe::getNormalsPolyPolygonShape3D() const
return uno::Any( &aPP, ::getCppuType((const drawing::PolyPolygonShape3D*)0) );
}
uno::Any Stripe::getTexturePolygon() const
{
drawing::PolyPolygonShape3D aPP;
aPP.SequenceX.realloc(1);
aPP.SequenceY.realloc(1);
aPP.SequenceZ.realloc(1);
drawing::DoubleSequence* pOuterSequenceX = aPP.SequenceX.getArray();
drawing::DoubleSequence* pOuterSequenceY = aPP.SequenceY.getArray();
drawing::DoubleSequence* pOuterSequenceZ = aPP.SequenceZ.getArray();
pOuterSequenceX->realloc(4);
pOuterSequenceY->realloc(4);
pOuterSequenceZ->realloc(4);
double* pInnerSequenceX = pOuterSequenceX->getArray();
double* pInnerSequenceY = pOuterSequenceY->getArray();
double* pInnerSequenceZ = pOuterSequenceZ->getArray();
*pInnerSequenceX++ = 0.0;
*pInnerSequenceY++ = 0.0;
*pInnerSequenceZ++ = 0.0;
*pInnerSequenceX++ = 1.0;
*pInnerSequenceY++ = 0.0;
*pInnerSequenceZ++ = 0.0;
*pInnerSequenceX++ = 1.0;
*pInnerSequenceY++ = 1.0;
*pInnerSequenceZ++ = 0.0;
*pInnerSequenceX++ = 0.0;
*pInnerSequenceY++ = 1.0;
*pInnerSequenceZ++ = 0.0;
return uno::Any( &aPP, ::getCppuType((const drawing::PolyPolygonShape3D*)0) );
}
//.............................................................................
} //namespace chart
//.............................................................................