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