LibreOffice Module svx (master)  1
unoshap3.cxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 
20 #include <sal/config.h>
21 
22 #include <initializer_list>
23 
24 #include <com/sun/star/drawing/HomogenMatrix.hpp>
25 #include <com/sun/star/drawing/Position3D.hpp>
26 #include <com/sun/star/drawing/Direction3D.hpp>
27 #include <com/sun/star/drawing/DoubleSequence.hpp>
28 #include <com/sun/star/drawing/CameraGeometry.hpp>
29 #include <com/sun/star/lang/IndexOutOfBoundsException.hpp>
30 #include <vcl/svapp.hxx>
31 #include <comphelper/sequence.hxx>
32 #include <sal/log.hxx>
33 
34 #include <svx/svdpool.hxx>
35 #include <svx/svditer.hxx>
36 #include <svx/unoshape.hxx>
37 #include <svx/unopage.hxx>
38 #include <editeng/unoprnms.hxx>
39 #include <svx/globl3d.hxx>
40 #include <svx/cube3d.hxx>
41 #include <svx/sphere3d.hxx>
42 #include <svx/lathe3d.hxx>
43 #include <svx/extrud3d.hxx>
44 #include <svx/polygn3d.hxx>
45 #include <svx/unoshprp.hxx>
46 #include <svx/svdmodel.hxx>
47 #include <svx/scene3d.hxx>
50 #include <com/sun/star/drawing/PolyPolygonShape3D.hpp>
53 #include "shapeimpl.hxx"
54 
55 using namespace ::cppu;
56 using namespace ::com::sun::star;
57 using namespace ::com::sun::star::uno;
58 using namespace ::com::sun::star::lang;
59 using namespace ::com::sun::star::container;
60 
61 #define QUERYINT( xint ) \
62  if( rType == cppu::UnoType<xint>::get() ) \
63  aAny <<= Reference< xint >(this)
64 
66 : SvxShape( pObj, getSvxMapProvider().GetMap(SVXMAP_3DSCENEOBJECT), getSvxMapProvider().GetPropertySet(SVXMAP_3DSCENEOBJECT, SdrObject::GetGlobalDrawObjectItemPool()) )
67 , mxPage( pDrawPage )
68 {
69 }
70 
71 
73 {
74 }
75 
76 
77 void Svx3DSceneObject::Create( SdrObject* pNewObj, SvxDrawPage* pNewPage )
78 {
79  SvxShape::Create( pNewObj, pNewPage );
80  mxPage = pNewPage;
81 }
82 
83 
85 {
86  uno::Any aAny;
87 
88  QUERYINT( drawing::XShapes );
89  else QUERYINT( container::XIndexAccess );
90  else QUERYINT( container::XElementAccess );
91  else
92  return SvxShape::queryAggregation( rType );
93 
94  return aAny;
95 }
96 
98 {
99  return SvxShape::queryInterface( rType );
100 }
101 
102 void SAL_CALL Svx3DSceneObject::acquire() throw ( )
103 {
105 }
106 
107 void SAL_CALL Svx3DSceneObject::release() throw ( )
108 {
110 }
111 
112 // XTypeProvider
113 
114 uno::Sequence< sal_Int8 > SAL_CALL Svx3DSceneObject::getImplementationId()
115 {
116  return css::uno::Sequence<sal_Int8>();
117 }
118 
119 
120 void SAL_CALL Svx3DSceneObject::add( const Reference< drawing::XShape >& xShape )
121 {
122  SolarMutexGuard aGuard;
123 
124  SvxShape* pShape = comphelper::getUnoTunnelImplementation<SvxShape>( xShape );
125 
126  if(!HasSdrObject() || !mxPage.is() || pShape == nullptr || nullptr != pShape->GetSdrObject() )
127  throw uno::RuntimeException();
128 
129  SdrObject* pSdrShape = mxPage->CreateSdrObject_( xShape );
130  if( dynamic_cast<const E3dObject* >(pSdrShape) != nullptr )
131  {
132  GetSdrObject()->GetSubList()->NbcInsertObject( pSdrShape );
133  pShape->Create(pSdrShape, mxPage.get());
134  }
135  else
136  {
137  SdrObject::Free( pSdrShape );
138  throw uno::RuntimeException();
139  }
140 
142 }
143 
144 
145 void SAL_CALL Svx3DSceneObject::remove( const Reference< drawing::XShape >& xShape )
146 {
147  SolarMutexGuard aGuard;
148 
149  SvxShape* pShape = comphelper::getUnoTunnelImplementation<SvxShape>( xShape );
150 
151  if(!HasSdrObject() || pShape == nullptr)
152  throw uno::RuntimeException();
153 
154  SdrObject* pSdrShape = pShape->GetSdrObject();
155  if(pSdrShape == nullptr || pSdrShape->getParentSdrObjectFromSdrObject() != GetSdrObject())
156  {
157  throw uno::RuntimeException();
158  }
159 
160  SdrObjList& rList = *pSdrShape->getParentSdrObjListFromSdrObject();
161 
162  const size_t nObjCount = rList.GetObjCount();
163  size_t nObjNum = 0;
164  while( nObjNum < nObjCount )
165  {
166  if(rList.GetObj( nObjNum ) == pSdrShape )
167  break;
168  nObjNum++;
169  }
170 
171  if( nObjNum < nObjCount )
172  {
173  SdrObject* pObject = rList.NbcRemoveObject( nObjNum );
174  SdrObject::Free( pObject );
175  }
176  else
177  {
178  SAL_WARN( "svx", "Fatality! SdrObject is not belonging to its SdrObjList! [CL]" );
179  }
180 }
181 
182 
183 sal_Int32 SAL_CALL Svx3DSceneObject::getCount()
184 {
185  SolarMutexGuard aGuard;
186 
187  sal_Int32 nRetval = 0;
188 
189  if(HasSdrObject() && dynamic_cast<const E3dScene* >(GetSdrObject()) != nullptr && GetSdrObject()->GetSubList())
190  nRetval = GetSdrObject()->GetSubList()->GetObjCount();
191  return nRetval;
192 }
193 
194 
196 {
197  SolarMutexGuard aGuard;
198 
199  if( !HasSdrObject() || GetSdrObject()->GetSubList() == nullptr )
200  throw uno::RuntimeException();
201 
202  if( Index<0 || GetSdrObject()->GetSubList()->GetObjCount() <= static_cast<size_t>(Index) )
203  throw lang::IndexOutOfBoundsException();
204 
205  SdrObject* pDestObj = GetSdrObject()->GetSubList()->GetObj( Index );
206  if(pDestObj == nullptr)
207  throw lang::IndexOutOfBoundsException();
208 
209  Reference< drawing::XShape > xShape( pDestObj->getUnoShape(), uno::UNO_QUERY );
210  return uno::Any(xShape);
211 }
212 
213 
214 // css::container::XElementAccess
215 
217 {
219 }
220 
221 
223 {
224  SolarMutexGuard aGuard;
225 
226  return HasSdrObject() && GetSdrObject()->GetSubList() && (GetSdrObject()->GetSubList()->GetObjCount() > 0);
227 }
228 
229 
230 static bool ConvertHomogenMatrixToObject( E3dObject* pObject, const Any& rValue )
231 {
232  drawing::HomogenMatrix aMat;
233  if( rValue >>= aMat )
234  {
236  return true;
237  }
238  return false;
239 }
240 
241 static void ConvertObjectToHomogenMatric( E3dObject const * pObject, Any& rValue )
242 {
243  drawing::HomogenMatrix aHomMat;
244  const basegfx::B3DHomMatrix& rMat = pObject->GetTransform();
246  rValue <<= aHomMat;
247 }
248 
249 namespace {
250 
251 struct ImpRememberTransAndRect
252 {
253  basegfx::B3DHomMatrix maMat;
254  tools::Rectangle maRect;
255 };
256 
257 }
258 
259 bool Svx3DSceneObject::setPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, const css::uno::Any& rValue )
260 {
261  switch( pProperty->nWID )
262  {
264  {
265  // patch transformation matrix to the object
266  if( ConvertHomogenMatrixToObject( static_cast< E3dObject* >( GetSdrObject() ), rValue ) )
267  return true;
268  break;
269  }
271  {
272  // set CameraGeometry at scene
273  E3dScene* pScene = static_cast< E3dScene* >( GetSdrObject() );
274  drawing::CameraGeometry aCamGeo;
275 
276  if(rValue >>= aCamGeo)
277  {
278  basegfx::B3DPoint aVRP(aCamGeo.vrp.PositionX, aCamGeo.vrp.PositionY, aCamGeo.vrp.PositionZ);
279  basegfx::B3DVector aVPN(aCamGeo.vpn.DirectionX, aCamGeo.vpn.DirectionY, aCamGeo.vpn.DirectionZ);
280  basegfx::B3DVector aVUP(aCamGeo.vup.DirectionX, aCamGeo.vup.DirectionY, aCamGeo.vup.DirectionZ);
281 
282  // rescue scene transformation
283  ImpRememberTransAndRect aSceneTAR;
284  aSceneTAR.maMat = pScene->GetTransform();
285  aSceneTAR.maRect = pScene->GetSnapRect();
286 
287  // rescue object transformations
289  std::vector<basegfx::B3DHomMatrix*> aObjTrans;
290  while(aIter.IsMore())
291  {
292  E3dObject* p3DObj = static_cast<E3dObject*>(aIter.Next());
294  *pNew = p3DObj->GetTransform();
295  aObjTrans.push_back(pNew);
296  }
297 
298  // reset object transformations
299  aIter.Reset();
300  while(aIter.IsMore())
301  {
302  E3dObject* p3DObj = static_cast<E3dObject*>(aIter.Next());
304  }
305 
306  // reset scene transformation and make a complete recalc
308 
309  // fill old camera from new parameters
310  Camera3D aCam(pScene->GetCamera());
311  const basegfx::B3DRange& rVolume = pScene->GetBoundVolume();
312  double fW = rVolume.getWidth();
313  double fH = rVolume.getHeight();
314 
315  const SfxItemSet& rSceneSet = pScene->GetMergedItemSet();
316  double fCamPosZ =
317  static_cast<double>(rSceneSet.Get(SDRATTR_3DSCENE_DISTANCE).GetValue());
318  double fCamFocal =
319  static_cast<double>(rSceneSet.Get(SDRATTR_3DSCENE_FOCAL_LENGTH).GetValue());
320 
321  aCam.SetAutoAdjustProjection(false);
322  aCam.SetViewWindow(- fW / 2, - fH / 2, fW, fH);
323  basegfx::B3DPoint aLookAt;
324  basegfx::B3DPoint aCamPos(0.0, 0.0, fCamPosZ);
325  aCam.SetPosAndLookAt(aCamPos, aLookAt);
326  aCam.SetFocalLength(fCamFocal / 100.0);
327  aCam.SetDeviceWindow(tools::Rectangle(0, 0, static_cast<long>(fW), static_cast<long>(fH)));
328 
329  // set at scene
330  pScene->SetCamera(aCam);
331 
332  // #91047# use imported VRP, VPN and VUP (if used)
333  bool bVRPUsed(!aVRP.equal(basegfx::B3DPoint(0.0, 0.0, 1.0)));
334  bool bVPNUsed(!aVPN.equal(basegfx::B3DVector(0.0, 0.0, 1.0)));
335  bool bVUPUsed(!aVUP.equal(basegfx::B3DVector(0.0, 1.0, 0.0)));
336 
337  if(bVRPUsed || bVPNUsed || bVUPUsed)
338  {
339  pScene->GetCameraSet().SetViewportValues(aVRP, aVPN, aVUP);
340  }
341 
342  // set object transformations again at objects
343  aIter.Reset();
344  sal_uInt32 nIndex(0);
345  while(aIter.IsMore())
346  {
347  E3dObject* p3DObj = static_cast<E3dObject*>(aIter.Next());
348  basegfx::B3DHomMatrix* pMat = aObjTrans[nIndex++];
349  p3DObj->NbcSetTransform(*pMat);
350  delete pMat;
351  }
352 
353  // set scene transformation again at scene
354  pScene->NbcSetTransform(aSceneTAR.maMat);
355  pScene->NbcSetSnapRect(aSceneTAR.maRect);
356 
357  return true;
358  }
359  break;
360  }
361  default:
362  return SvxShape::setPropertyValueImpl(rName, pProperty, rValue);
363  }
364 
365  throw IllegalArgumentException();
366 }
367 
368 
369 bool Svx3DSceneObject::getPropertyValueImpl(const OUString& rName, const SfxItemPropertySimpleEntry* pProperty,
370  css::uno::Any& rValue)
371 {
372  switch( pProperty->nWID )
373  {
375  {
376  // patch object to a homogeneous 4x4 matrix
377  ConvertObjectToHomogenMatric( static_cast< E3dObject* >( GetSdrObject() ), rValue );
378  break;
379  }
381  {
382  // get CameraGeometry from scene
383  E3dScene* pScene = static_cast< E3dScene* >( GetSdrObject() );
384  drawing::CameraGeometry aCamGeo;
385 
386  // fill Vectors from scene camera
387  B3dCamera& aCameraSet = pScene->GetCameraSet();
388  basegfx::B3DPoint aVRP(aCameraSet.GetVRP());
389  basegfx::B3DVector aVPN(aCameraSet.GetVPN());
390  basegfx::B3DVector aVUP(aCameraSet.GetVUV());
391 
392  // transfer to structure
393  aCamGeo.vrp.PositionX = aVRP.getX();
394  aCamGeo.vrp.PositionY = aVRP.getY();
395  aCamGeo.vrp.PositionZ = aVRP.getZ();
396  aCamGeo.vpn.DirectionX = aVPN.getX();
397  aCamGeo.vpn.DirectionY = aVPN.getY();
398  aCamGeo.vpn.DirectionZ = aVPN.getZ();
399  aCamGeo.vup.DirectionX = aVUP.getX();
400  aCamGeo.vup.DirectionY = aVUP.getY();
401  aCamGeo.vup.DirectionZ = aVUP.getZ();
402 
403  rValue <<= aCamGeo;
404  break;
405  }
406  default:
407  return SvxShape::getPropertyValueImpl( rName, pProperty, rValue );
408  }
409 
410  return true;
411 }
412 
413 // css::lang::XServiceInfo
414 uno::Sequence< OUString > SAL_CALL Svx3DSceneObject::getSupportedServiceNames()
415 {
418  std::initializer_list<OUStringLiteral>{ "com.sun.star.drawing.Shape3DScene" });
419 }
420 
422 : SvxShape( pObj, getSvxMapProvider().GetMap(SVXMAP_3DCUBEOBJECT), getSvxMapProvider().GetPropertySet(SVXMAP_3DCUBEOBJECT, SdrObject::GetGlobalDrawObjectItemPool()) )
423 {
424 }
425 
427 {
428 }
429 
430 bool Svx3DCubeObject::setPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, const css::uno::Any& rValue )
431 {
432  SolarMutexGuard aGuard;
433 
434  switch( pProperty->nWID )
435  {
437  {
438  // pack transformationmatrix to the object
439  if( ConvertHomogenMatrixToObject( static_cast< E3dObject* >( GetSdrObject() ), rValue ) )
440  return true;
441  break;
442  }
444  {
445  // pack position to the object
446  drawing::Position3D aUnoPos;
447  if( rValue >>= aUnoPos )
448  {
449  basegfx::B3DPoint aPos(aUnoPos.PositionX, aUnoPos.PositionY, aUnoPos.PositionZ);
450  static_cast< E3dCubeObj* >( GetSdrObject() )->SetCubePos(aPos);
451  return true;
452  }
453  break;
454  }
456  {
457  // pack size to the object
458  drawing::Direction3D aDirection;
459  if( rValue >>= aDirection )
460  {
461  basegfx::B3DVector aSize(aDirection.DirectionX, aDirection.DirectionY, aDirection.DirectionZ);
462  static_cast< E3dCubeObj* >( GetSdrObject() )->SetCubeSize(aSize);
463  return true;
464  }
465  break;
466  }
468  {
469  bool bNew = false;
470  // pack sal_Bool bPosIsCenter to the object
471  if( rValue >>= bNew )
472  {
473  static_cast< E3dCubeObj* >( GetSdrObject() )->SetPosIsCenter(bNew);
474  return true;
475  }
476  break;
477  }
478  default:
479  return SvxShape::setPropertyValueImpl( rName, pProperty, rValue );
480  }
481 
482  throw IllegalArgumentException();
483 }
484 
485 bool Svx3DCubeObject::getPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, css::uno::Any& rValue )
486 {
487  switch( pProperty->nWID )
488  {
490  {
491  // pack transformation to a homogeneous matrix
492  ConvertObjectToHomogenMatric( static_cast< E3dObject* >( GetSdrObject() ), rValue );
493  break;
494  }
496  {
497  // pack position
498  const basegfx::B3DPoint& rPos = static_cast<E3dCubeObj*>(GetSdrObject())->GetCubePos();
499  drawing::Position3D aPos;
500 
501  aPos.PositionX = rPos.getX();
502  aPos.PositionY = rPos.getY();
503  aPos.PositionZ = rPos.getZ();
504 
505  rValue <<= aPos;
506  break;
507  }
509  {
510  // pack size
511  const basegfx::B3DVector& rSize = static_cast<E3dCubeObj*>(GetSdrObject())->GetCubeSize();
512  drawing::Direction3D aDir;
513 
514  aDir.DirectionX = rSize.getX();
515  aDir.DirectionY = rSize.getY();
516  aDir.DirectionZ = rSize.getZ();
517 
518  rValue <<= aDir;
519  break;
520  }
522  {
523  rValue <<= static_cast<E3dCubeObj*>(GetSdrObject())->GetPosIsCenter();
524  break;
525  }
526  default:
527  return SvxShape::getPropertyValueImpl( rName, pProperty, rValue );
528  }
529 
530  return true;
531 }
532 
533 // css::lang::XServiceInfo
534 uno::Sequence< OUString > SAL_CALL Svx3DCubeObject::getSupportedServiceNames()
535 {
538  std::initializer_list<OUStringLiteral>{ "com.sun.star.drawing.Shape3D",
539  "com.sun.star.drawing.Shape3DCube" });
540 }
541 
543  : SvxShape( pObj, getSvxMapProvider().GetMap(SVXMAP_3DSPHEREOBJECT), getSvxMapProvider().GetPropertySet(SVXMAP_3DSPHEREOBJECT, SdrObject::GetGlobalDrawObjectItemPool()) )
544 {
545 }
546 
548 {
549 }
550 
551 bool Svx3DSphereObject::setPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, const css::uno::Any& rValue )
552 {
553  switch( pProperty->nWID )
554  {
556  {
557  // pack transformation matrix to the object
558  if( ConvertHomogenMatrixToObject( static_cast< E3dObject* >( GetSdrObject() ), rValue ) )
559  return true;
560  break;
561  }
562 
564  {
565  // pack position to the object
566  drawing::Position3D aUnoPos;
567  if( rValue >>= aUnoPos )
568  {
569  basegfx::B3DPoint aPos(aUnoPos.PositionX, aUnoPos.PositionY, aUnoPos.PositionZ);
570  static_cast<E3dSphereObj*>(GetSdrObject())->SetCenter(aPos);
571  return true;
572  }
573  break;
574  }
575 
577  {
578  // pack size to the object
579  drawing::Direction3D aDir;
580  if( rValue >>= aDir )
581  {
582  basegfx::B3DVector aPos(aDir.DirectionX, aDir.DirectionY, aDir.DirectionZ);
583  static_cast<E3dSphereObj*>(GetSdrObject())->SetSize(aPos);
584  return true;
585  }
586  break;
587  }
588  default:
589  return SvxShape::setPropertyValueImpl( rName, pProperty, rValue );
590  }
591 
592  throw IllegalArgumentException();
593 }
594 
595 bool Svx3DSphereObject::getPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, css::uno::Any& rValue )
596 {
597  switch( pProperty->nWID )
598  {
600  {
601  // pack transformation to a homogeneous matrix
602  ConvertObjectToHomogenMatric( static_cast< E3dObject* >( GetSdrObject() ), rValue );
603  break;
604  }
606  {
607  // pack position
608  const basegfx::B3DPoint& rPos = static_cast<E3dSphereObj*>(GetSdrObject())->Center();
609  drawing::Position3D aPos;
610 
611  aPos.PositionX = rPos.getX();
612  aPos.PositionY = rPos.getY();
613  aPos.PositionZ = rPos.getZ();
614 
615  rValue <<= aPos;
616  break;
617  }
619  {
620  // pack size
621  const basegfx::B3DVector& rSize = static_cast<E3dSphereObj*>(GetSdrObject())->Size();
622  drawing::Direction3D aDir;
623 
624  aDir.DirectionX = rSize.getX();
625  aDir.DirectionY = rSize.getY();
626  aDir.DirectionZ = rSize.getZ();
627 
628  rValue <<= aDir;
629  break;
630  }
631  default:
632  return SvxShape::getPropertyValueImpl( rName, pProperty, rValue );
633  }
634 
635  return true;
636 }
637 
638 // css::lang::XServiceInfo
639 uno::Sequence< OUString > SAL_CALL Svx3DSphereObject::getSupportedServiceNames()
640 {
643  std::initializer_list<OUStringLiteral>{ "com.sun.star.drawing.Shape3D",
644  "com.sun.star.drawing.Shape3DSphere" });
645 }
646 
648 : SvxShape( pObj, getSvxMapProvider().GetMap(SVXMAP_3DLATHEOBJECT), getSvxMapProvider().GetPropertySet(SVXMAP_3DLATHEOBJECT, SdrObject::GetGlobalDrawObjectItemPool()) )
649 {
650 }
651 
653 {
654 }
655 
657  const Any& rValue,
658  basegfx::B3DPolyPolygon& rResultPolygon,
659  bool bCorrectPolygon)
660 {
661  drawing::PolyPolygonShape3D aSourcePolyPolygon;
662  if( !(rValue >>= aSourcePolyPolygon) )
663  return false;
664 
665  sal_Int32 nOuterSequenceCount = aSourcePolyPolygon.SequenceX.getLength();
666  if(nOuterSequenceCount != aSourcePolyPolygon.SequenceY.getLength() || nOuterSequenceCount != aSourcePolyPolygon.SequenceZ.getLength())
667  return false;
668 
669  drawing::DoubleSequence* pInnerSequenceX = aSourcePolyPolygon.SequenceX.getArray();
670  drawing::DoubleSequence* pInnerSequenceY = aSourcePolyPolygon.SequenceY.getArray();
671  drawing::DoubleSequence* pInnerSequenceZ = aSourcePolyPolygon.SequenceZ.getArray();
672  for(sal_Int32 a(0);a<nOuterSequenceCount;a++)
673  {
674  sal_Int32 nInnerSequenceCount = pInnerSequenceX->getLength();
675  if(nInnerSequenceCount != pInnerSequenceY->getLength() || nInnerSequenceCount != pInnerSequenceZ->getLength())
676  {
677  return false;
678  }
679  basegfx::B3DPolygon aNewPolygon;
680  double* pArrayX = pInnerSequenceX->getArray();
681  double* pArrayY = pInnerSequenceY->getArray();
682  double* pArrayZ = pInnerSequenceZ->getArray();
683  for(sal_Int32 b(0);b<nInnerSequenceCount;b++)
684  {
685  aNewPolygon.append(basegfx::B3DPoint(*pArrayX++,*pArrayY++,*pArrayZ++));
686  }
687  pInnerSequenceX++;
688  pInnerSequenceY++;
689  pInnerSequenceZ++;
690 
691  // #i101520# correction is needed for imported polygons of old format,
692  // see callers
693  if(bCorrectPolygon)
694  {
695  basegfx::utils::checkClosed(aNewPolygon);
696  }
697 
698  rResultPolygon.append(aNewPolygon);
699  }
700  return true;
701 }
702 
703 static void B3dPolyPolygon_to_PolyPolygonShape3D( const basegfx::B3DPolyPolygon& rSourcePolyPolygon, Any& rValue )
704 {
705  drawing::PolyPolygonShape3D aRetval;
706  aRetval.SequenceX.realloc(rSourcePolyPolygon.count());
707  aRetval.SequenceY.realloc(rSourcePolyPolygon.count());
708  aRetval.SequenceZ.realloc(rSourcePolyPolygon.count());
709  drawing::DoubleSequence* pOuterSequenceX = aRetval.SequenceX.getArray();
710  drawing::DoubleSequence* pOuterSequenceY = aRetval.SequenceY.getArray();
711  drawing::DoubleSequence* pOuterSequenceZ = aRetval.SequenceZ.getArray();
712  for(sal_uInt32 a(0);a<rSourcePolyPolygon.count();a++)
713  {
714  const basegfx::B3DPolygon& aPoly(rSourcePolyPolygon.getB3DPolygon(a));
715  sal_Int32 nPointCount(aPoly.count());
716  if(aPoly.isClosed()) nPointCount++;
717  pOuterSequenceX->realloc(nPointCount);
718  pOuterSequenceY->realloc(nPointCount);
719  pOuterSequenceZ->realloc(nPointCount);
720  double* pInnerSequenceX = pOuterSequenceX->getArray();
721  double* pInnerSequenceY = pOuterSequenceY->getArray();
722  double* pInnerSequenceZ = pOuterSequenceZ->getArray();
723  for(sal_uInt32 b(0);b<aPoly.count();b++)
724  {
725  const basegfx::B3DPoint aPoint(aPoly.getB3DPoint(b));
726  *pInnerSequenceX++ = aPoint.getX();
727  *pInnerSequenceY++ = aPoint.getY();
728  *pInnerSequenceZ++ = aPoint.getZ();
729  }
730  if(aPoly.isClosed())
731  {
732  const basegfx::B3DPoint aPoint(aPoly.getB3DPoint(0));
733  *pInnerSequenceX++ = aPoint.getX();
734  *pInnerSequenceY++ = aPoint.getY();
735  *pInnerSequenceZ++ = aPoint.getZ();
736  }
737  pOuterSequenceX++;
738  pOuterSequenceY++;
739  pOuterSequenceZ++;
740  }
741  rValue <<= aRetval;
742 }
743 
744 bool Svx3DLatheObject::setPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, const css::uno::Any& rValue )
745 {
746  switch( pProperty->nWID )
747  {
749  {
750  // pack transformation matrix to the object
751  if( ConvertHomogenMatrixToObject( static_cast< E3dObject* >( GetSdrObject() ), rValue ) )
752  return true;
753  break;
754  }
756  {
757  // pack polygon definition to the object
758  basegfx::B3DPolyPolygon aNewB3DPolyPolygon;
759 
760  // #i101520# Probably imported
761  if( PolyPolygonShape3D_to_B3dPolyPolygon( rValue, aNewB3DPolyPolygon, true ) )
762  {
763  // #105127# SetPolyPoly3D sets the Svx3DVerticalSegmentsItem to the number
764  // of points of the polygon. Thus, value gets lost. To avoid this, rescue
765  // item here and re-set after setting the polygon.
766  const sal_uInt32 nPrevVerticalSegs(static_cast<E3dLatheObj*>(GetSdrObject())->GetVerticalSegments());
767 
768  // set polygon
769  const basegfx::B3DHomMatrix aIdentity;
770  const basegfx::B2DPolyPolygon aB2DPolyPolygon(basegfx::utils::createB2DPolyPolygonFromB3DPolyPolygon(aNewB3DPolyPolygon, aIdentity));
771  static_cast<E3dLatheObj*>(GetSdrObject())->SetPolyPoly2D(aB2DPolyPolygon);
772  const sal_uInt32 nPostVerticalSegs(static_cast<E3dLatheObj*>(GetSdrObject())->GetVerticalSegments());
773 
774  if(nPrevVerticalSegs != nPostVerticalSegs)
775  {
776  // restore the vertical segment count
777  static_cast<E3dLatheObj*>(GetSdrObject())->SetMergedItem(makeSvx3DVerticalSegmentsItem(nPrevVerticalSegs));
778  }
779  return true;
780  }
781  break;
782  }
783  default:
784  return SvxShape::setPropertyValueImpl( rName, pProperty, rValue );
785  }
786 
787  throw IllegalArgumentException();
788 }
789 
790 bool Svx3DLatheObject::getPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, css::uno::Any& rValue )
791 {
792  switch( pProperty->nWID )
793  {
795  {
796  // pack transformation to a homogeneous matrix
797  drawing::HomogenMatrix aHomMat;
798  basegfx::B3DHomMatrix aMat = static_cast<E3dObject*>(GetSdrObject())->GetTransform();
800  rValue <<= aHomMat;
801  break;
802  }
804  {
805  const basegfx::B2DPolyPolygon& rPolyPoly = static_cast<E3dLatheObj*>(GetSdrObject())->GetPolyPoly2D();
807 
808  B3dPolyPolygon_to_PolyPolygonShape3D(aB3DPolyPolygon, rValue);
809  break;
810  }
811  default:
812  return SvxShape::getPropertyValueImpl( rName, pProperty, rValue );
813  }
814 
815  return true;
816 }
817 
818 // css::lang::XServiceInfo
819 uno::Sequence< OUString > SAL_CALL Svx3DLatheObject::getSupportedServiceNames()
820 {
823  std::initializer_list<OUStringLiteral>{ "com.sun.star.drawing.Shape3D",
824  "com.sun.star.drawing.Shape3DLathe" });
825 }
826 
828 : SvxShape( pObj, getSvxMapProvider().GetMap(SVXMAP_3DEXTRUDEOBJECT), getSvxMapProvider().GetPropertySet(SVXMAP_3DEXTRUDEOBJECT, SdrObject::GetGlobalDrawObjectItemPool()) )
829 {
830 }
831 
833 {
834 }
835 
836 bool Svx3DExtrudeObject::setPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, const css::uno::Any& rValue )
837 {
838  switch( pProperty->nWID )
839  {
841  {
842  // pack transformation matrix to the object
843  if( ConvertHomogenMatrixToObject( static_cast< E3dObject* >( GetSdrObject() ), rValue ) )
844  return true;
845  break;
846  }
847 
849  {
850  // pack polygon definition to the object
851  basegfx::B3DPolyPolygon aNewB3DPolyPolygon;
852 
853  // #i101520# Probably imported
854  if( PolyPolygonShape3D_to_B3dPolyPolygon( rValue, aNewB3DPolyPolygon, true ) )
855  {
856  // set polygon
857  const basegfx::B3DHomMatrix aIdentity;
858  const basegfx::B2DPolyPolygon aB2DPolyPolygon(basegfx::utils::createB2DPolyPolygonFromB3DPolyPolygon(aNewB3DPolyPolygon, aIdentity));
859  static_cast<E3dExtrudeObj*>(GetSdrObject())->SetExtrudePolygon(aB2DPolyPolygon);
860  return true;
861  }
862  break;
863  }
864  default:
865  return SvxShape::setPropertyValueImpl( rName, pProperty, rValue );
866  }
867 
868  throw IllegalArgumentException();
869 }
870 
871 bool Svx3DExtrudeObject::getPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, css::uno::Any& rValue )
872 {
873  switch( pProperty->nWID )
874  {
876  {
877  // pack transformation to a homogeneous matrix
878  drawing::HomogenMatrix aHomMat;
879  basegfx::B3DHomMatrix aMat = static_cast<E3dObject*>(GetSdrObject())->GetTransform();
881  rValue <<= aHomMat;
882  break;
883  }
884 
886  {
887  // pack polygon definition
888  const basegfx::B2DPolyPolygon& rPolyPoly = static_cast<E3dExtrudeObj*>(GetSdrObject())->GetExtrudePolygon();
890 
891  B3dPolyPolygon_to_PolyPolygonShape3D(aB3DPolyPolygon, rValue);
892  break;
893  }
894  default:
895  return SvxShape::getPropertyValueImpl( rName, pProperty, rValue );
896  }
897 
898  return true;
899 }
900 
901 // css::lang::XServiceInfo
902 uno::Sequence< OUString > SAL_CALL Svx3DExtrudeObject::getSupportedServiceNames()
903 {
906  std::initializer_list<OUStringLiteral>{ "com.sun.star.drawing.Shape3D",
907  "com.sun.star.drawing.Shape3DExtrude" });
908 }
909 
911 : SvxShape( pObj, getSvxMapProvider().GetMap(SVXMAP_3DPOLYGONOBJECT), getSvxMapProvider().GetPropertySet(SVXMAP_3DPOLYGONOBJECT, SdrObject::GetGlobalDrawObjectItemPool()) )
912 {
913 }
914 
916 {
917 }
918 
919 bool Svx3DPolygonObject::setPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, const css::uno::Any& rValue )
920 {
921  switch( pProperty->nWID )
922  {
924  {
925  // pack transformation matrix to the object
926  if( ConvertHomogenMatrixToObject( static_cast< E3dObject* >( GetSdrObject() ), rValue ) )
927  return true;
928  break;
929  }
930 
932  {
933  // pack polygon definition to the object
934  basegfx::B3DPolyPolygon aNewB3DPolyPolygon;
935 
936  // #i101520# Direct API data (e.g. from chart)
937  if( PolyPolygonShape3D_to_B3dPolyPolygon( rValue, aNewB3DPolyPolygon, false ) )
938  {
939  // set polygon
940  static_cast<E3dPolygonObj*>(GetSdrObject())->SetPolyPolygon3D(aNewB3DPolyPolygon);
941  return true;
942  }
943  break;
944  }
946  {
947  // pack perpendicular definition to the object
948  basegfx::B3DPolyPolygon aNewB3DPolyPolygon;
949 
950  // #i101520# Direct API data (e.g. from chart)
951  if( PolyPolygonShape3D_to_B3dPolyPolygon( rValue, aNewB3DPolyPolygon, false ) )
952  {
953  // set polygon
954  static_cast<E3dPolygonObj*>(GetSdrObject())->SetPolyNormals3D(aNewB3DPolyPolygon);
955  return true;
956  }
957  break;
958  }
960  {
961  // pack texture definition to the object
962  basegfx::B3DPolyPolygon aNewB3DPolyPolygon;
963 
964  // #i101520# Direct API data (e.g. from chart)
965  if( PolyPolygonShape3D_to_B3dPolyPolygon( rValue, aNewB3DPolyPolygon, false ) )
966  {
967  // set polygon
968  const basegfx::B3DHomMatrix aIdentity;
969  const basegfx::B2DPolyPolygon aB2DPolyPolygon(basegfx::utils::createB2DPolyPolygonFromB3DPolyPolygon(aNewB3DPolyPolygon, aIdentity));
970  static_cast<E3dPolygonObj*>(GetSdrObject())->SetPolyTexture2D(aB2DPolyPolygon);
971  return true;
972  }
973  break;
974  }
976  {
977  bool bNew = false;
978  if( rValue >>= bNew )
979  {
980  static_cast<E3dPolygonObj*>(GetSdrObject())->SetLineOnly(bNew);
981  return true;
982  }
983  break;
984  }
985  default:
986  return SvxShape::setPropertyValueImpl( rName, pProperty, rValue );
987  }
988 
989  throw IllegalArgumentException();
990 }
991 
992 bool Svx3DPolygonObject::getPropertyValueImpl( const OUString& rName, const SfxItemPropertySimpleEntry* pProperty, css::uno::Any& rValue )
993 {
994  switch( pProperty->nWID )
995  {
997  {
998  ConvertObjectToHomogenMatric( static_cast< E3dObject* >( GetSdrObject() ), rValue );
999  break;
1000  }
1001 
1003  {
1004  B3dPolyPolygon_to_PolyPolygonShape3D(static_cast<E3dPolygonObj*>(GetSdrObject())->GetPolyPolygon3D(),rValue);
1005  break;
1006  }
1007 
1009  {
1010  B3dPolyPolygon_to_PolyPolygonShape3D(static_cast<E3dPolygonObj*>(GetSdrObject())->GetPolyNormals3D(),rValue);
1011  break;
1012  }
1013 
1015  {
1016  // pack texture definition
1017  const basegfx::B2DPolyPolygon& rPolyPoly = static_cast<E3dPolygonObj*>(GetSdrObject())->GetPolyTexture2D();
1019 
1020  B3dPolyPolygon_to_PolyPolygonShape3D(aB3DPolyPolygon,rValue);
1021  break;
1022  }
1023 
1025  {
1026  rValue <<= static_cast<E3dPolygonObj*>(GetSdrObject())->GetLineOnly();
1027  break;
1028  }
1029 
1030  default:
1031  return SvxShape::getPropertyValueImpl( rName, pProperty, rValue );
1032  }
1033 
1034  return true;
1035 }
1036 
1037 // css::lang::XServiceInfo
1038 uno::Sequence< OUString > SAL_CALL Svx3DPolygonObject::getSupportedServiceNames()
1039 {
1042  std::initializer_list<OUStringLiteral>{ "com.sun.star.drawing.Shape3D",
1043  "com.sun.star.drawing.Shape3DPolygon" });
1044 }
1045 
1046 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshape.cxx:3124
virtual void SAL_CALL remove(const css::uno::Reference< css::drawing::XShape > &xShape) override
Definition: unoshap3.cxx:145
virtual void SAL_CALL release() SAL_OVERRIDE
#define OWN_ATTR_3D_VALUE_SIZE
Definition: unoshprp.hxx:84
virtual css::uno::Any SAL_CALL queryAggregation(const css::uno::Type &aType) override
Definition: unoshape.cxx:279
sal_Int32 nIndex
#define OWN_ATTR_3D_VALUE_CAMERA_GEOMETRY
Definition: unoshprp.hxx:110
void append(const B3DPolygon &rPolygon, sal_uInt32 nCount=1)
Svx3DSphereObject(SdrObject *pObj)
Definition: unoshap3.cxx:542
virtual css::uno::Any SAL_CALL queryInterface(css::uno::Type const &rType) SAL_OVERRIDE
const basegfx::B3DVector & GetVPN() const
Svx3DExtrudeObject(SdrObject *pObj)
Definition: unoshap3.cxx:827
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshap3.cxx:902
#define OWN_ATTR_3D_VALUE_TEXTUREPOLYGON3D
Definition: unoshprp.hxx:171
const basegfx::B3DPoint & GetVRP() const
void B3DHomMatrixToUnoHomogenMatrix(const B3DHomMatrix &rMatrixIn, com::sun::star::drawing::HomogenMatrix &rMatrixOut)
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue) override
Definition: unoshap3.cxx:744
virtual ~Svx3DLatheObject() override
Definition: unoshap3.cxx:652
virtual void NbcInsertObject(SdrObject *pObj, size_t nPos=SAL_MAX_SIZE)
Definition: svdpage.cxx:307
#define OWN_ATTR_3D_VALUE_LINEONLY
Definition: unoshprp.hxx:87
SdrObject * GetObj(size_t nNum) const
Definition: svdpage.cxx:773
size_t GetObjCount() const
Definition: svdpage.cxx:767
#define OWN_ATTR_3D_VALUE_POS_IS_CENTER
Definition: unoshprp.hxx:85
const basegfx::B3DVector & GetVUV() const
double getZ() const
#define SVXMAP_3DSCENEOBJECT
Definition: unoprov.hxx:58
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue) override
Definition: unoshap3.cxx:551
SfxUInt32Item makeSvx3DVerticalSegmentsItem(sal_uInt32 nVal)
Definition: svx3ditems.hxx:49
B2DPolyPolygon createB2DPolyPolygonFromB3DPolyPolygon(const B3DPolyPolygon &rCandidate, const B3DHomMatrix &rMat)
const basegfx::B3DHomMatrix & GetTransform() const
Definition: obj3d.hxx:111
static void Free(SdrObject *&_rpObject)
Definition: svdobj.cxx:423
virtual SdrObjList * GetSubList() const override
Definition: scene3d.cxx:877
virtual const tools::Rectangle & GetSnapRect() const override
Definition: svdoattr.cxx:91
Center
EmbeddedObjectRef * pObject
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue)
Definition: unoshape.cxx:2508
virtual SdrObjList * GetSubList() const
Definition: svdobj.cxx:674
rtl::Reference< SvxDrawPage > mxPage
Definition: unoshape.hxx:654
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue) override
Definition: unoshap3.cxx:836
virtual sal_Bool SAL_CALL hasElements() override
Definition: unoshap3.cxx:222
Svx3DCubeObject(SdrObject *pObj)
Definition: unoshap3.cxx:421
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue) override
Definition: unoshap3.cxx:430
double getX() const
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue) override
Definition: unoshap3.cxx:871
static bool ConvertHomogenMatrixToObject(E3dObject *pObject, const Any &rValue)
Definition: unoshap3.cxx:230
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue) override
Definition: unoshap3.cxx:369
virtual css::uno::Reference< css::uno::XInterface > getUnoShape()
Definition: svdobj.cxx:2793
B3DPolyPolygon createB3DPolyPolygonFromB2DPolyPolygon(const B2DPolyPolygon &rCandidate, double fZCoordinate)
virtual ~Svx3DPolygonObject() override
Definition: unoshap3.cxx:915
virtual void Create(SdrObject *pNewOpj, SvxDrawPage *pNewPage)
Definition: unoshape.cxx:379
virtual void NbcSetTransform(const basegfx::B3DHomMatrix &rMatrix) override
Definition: scene3d.cxx:609
#define SVXMAP_3DEXTRUDEOBJECT
Definition: unoprov.hxx:62
void SetCamera(const Camera3D &rNewCamera)
Definition: scene3d.cxx:322
#define SVXMAP_3DCUBEOBJECT
Definition: unoprov.hxx:59
virtual ~Svx3DSphereObject() override
Definition: unoshap3.cxx:547
sal_uInt32 count() const
#define SVXMAP_3DSPHEREOBJECT
Definition: unoprov.hxx:60
virtual css::uno::Any SAL_CALL queryInterface(const css::uno::Type &rType) override
Definition: unoshap3.cxx:97
#define OWN_ATTR_3D_VALUE_NORMALSPOLYGON3D
Definition: unoshprp.hxx:170
void append(const B3DPoint &rPoint, sal_uInt32 nCount=1)
static void B3dPolyPolygon_to_PolyPolygonShape3D(const basegfx::B3DPolyPolygon &rSourcePolyPolygon, Any &rValue)
Definition: unoshap3.cxx:703
B3DHomMatrix UnoHomogenMatrixToB3DHomMatrix(const com::sun::star::drawing::HomogenMatrix &rMatrixIn)
#define SDRATTR_3DSCENE_FOCAL_LENGTH
Definition: svddef.hxx:360
virtual void SetChanged(bool bFlg=true)
Definition: svdmodel.cxx:1274
bool HasSdrObject() const
Definition: unoshape.hxx:211
virtual void NbcSetTransform(const basegfx::B3DHomMatrix &rMatrix)
Definition: obj3d.cxx:366
SphereObject with diameter r3DSize.
Definition: sphere3d.hxx:35
virtual css::uno::Any SAL_CALL getByIndex(sal_Int32 Index) override
Definition: unoshap3.cxx:195
virtual void SAL_CALL acquire() SAL_OVERRIDE
void checkClosed(B2DPolygon &rCandidate)
virtual ~Svx3DExtrudeObject() override
Definition: unoshap3.cxx:832
uno_Any a
void SetViewportValues(const basegfx::B3DPoint &rNewVRP, const basegfx::B3DVector &rNewVPN, const basegfx::B3DVector &rNewVUV)
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue) override
Definition: unoshap3.cxx:919
css::drawing::Direction3D aDirection
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshap3.cxx:414
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshap3.cxx:819
#define SVXMAP_3DPOLYGONOBJECT
Definition: unoprov.hxx:63
virtual void Create(SdrObject *pNewOpj, SvxDrawPage *pNewPage) override
Definition: unoshap3.cxx:77
unsigned char sal_Bool
SdrModel & getSdrModelFromSdrObject() const
Definition: svdobj.cxx:299
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshap3.cxx:1038
const basegfx::B3DRange & GetBoundVolume() const
Definition: obj3d.cxx:323
css::uno::Type const & get()
virtual void SAL_CALL acquire() override
Definition: unoshap3.cxx:102
Svx3DLatheObject(SdrObject *pObj)
Definition: unoshap3.cxx:647
virtual SdrObject * NbcRemoveObject(size_t nObjNum)
remove from list without delete
Definition: svdpage.cxx:397
css::uno::Sequence< T > concatSequences(const css::uno::Sequence< T > &rS1, const Ss &...rSn)
Abstract DrawObject.
Definition: svdobj.hxx:312
#define QUERYINT(xint)
Definition: unoshap3.cxx:61
virtual css::uno::Type SAL_CALL getElementType() override
Definition: unoshap3.cxx:216
virtual void SAL_CALL add(const css::uno::Reference< css::drawing::XShape > &xShape) override
Definition: unoshap3.cxx:120
#define SDRATTR_3DSCENE_DISTANCE
Definition: svddef.hxx:359
bool equal(const B3DTuple &rTup) const
virtual sal_Int32 SAL_CALL getCount() override
Definition: unoshap3.cxx:183
double getWidth() const
virtual void SetTransform(const basegfx::B3DHomMatrix &rMatrix)
Definition: obj3d.cxx:377
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue) override
Definition: unoshap3.cxx:485
#define OWN_ATTR_3D_VALUE_POSITION
Definition: unoshprp.hxx:83
static bool PolyPolygonShape3D_to_B3dPolyPolygon(const Any &rValue, basegfx::B3DPolyPolygon &rResultPolygon, bool bCorrectPolygon)
Definition: unoshap3.cxx:656
#define OWN_ATTR_3D_VALUE_POLYPOLYGON3D
Definition: unoshprp.hxx:86
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override
Definition: unoshap3.cxx:114
virtual void SAL_CALL release() override
Definition: unoshap3.cxx:107
const SfxItemSet & GetMergedItemSet() const
Definition: svdobj.cxx:1911
SdrObject * GetSdrObject() const
Definition: unoshape.hxx:210
virtual ~Svx3DCubeObject() override
Definition: unoshap3.cxx:426
#define SVXMAP_3DLATHEOBJECT
Definition: unoprov.hxx:61
SdrObject * getParentSdrObjectFromSdrObject() const
Definition: svdobj.cxx:679
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue) override
Definition: unoshap3.cxx:790
virtual ~Svx3DSceneObject() override
Definition: unoshap3.cxx:72
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue) override
Definition: unoshap3.cxx:992
static void ConvertObjectToHomogenMatric(E3dObject const *pObject, Any &rValue)
Definition: unoshap3.cxx:241
#define SAL_WARN(area, stream)
virtual bool getPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, css::uno::Any &rValue) override
Definition: unoshap3.cxx:595
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue) override
Definition: unoshap3.cxx:259
#define OWN_ATTR_3D_VALUE_TRANSFORM_MATRIX
Definition: unoshprp.hxx:82
double getY() const
virtual bool setPropertyValueImpl(const OUString &rName, const SfxItemPropertySimpleEntry *pProperty, const css::uno::Any &rValue)
Definition: unoshape.cxx:2057
SdrObjList * getParentSdrObjListFromSdrObject() const
Definition: svdobj.cxx:325
Svx3DSceneObject(SdrObject *pObj, SvxDrawPage *pDrawPage)
Definition: unoshap3.cxx:65
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshap3.cxx:534
B3DPolygon const & getB3DPolygon(sal_uInt32 nIndex) const
SvxUnoPropertyMapProvider & getSvxMapProvider()
Definition: unoprov.cxx:873
struct _ADOIndex Index
virtual css::uno::Any SAL_CALL queryAggregation(const css::uno::Type &rType) override
Definition: unoshap3.cxx:84
const Camera3D & GetCamera() const
Definition: scene3d.hxx:127
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Definition: unoshap3.cxx:639
Svx3DPolygonObject(SdrObject *pObj)
Definition: unoshap3.cxx:910
B3dCamera & GetCameraSet()
Definition: scene3d.hxx:148
virtual void NbcSetSnapRect(const tools::Rectangle &rRect) override
Definition: scene3d.cxx:294