LibreOffice Module svx (master)  1
viewcontactofe3d.hxx
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 #pragma once
21 
22 #include <svx/obj3d.hxx>
25 
26 namespace drawinglayer { namespace attribute {
27  class SdrLineAttribute;
28 }}
29 
30 namespace basegfx {
31  class BColor;
32  class B3DHomMatrix;
33 }
34 
35 namespace sdr { namespace contact {
36 
37 class ViewContactOfE3dScene;
38 
40 {
41 protected:
42  // Create an Object-Specific ViewObjectContact, set ViewContact and
43  // ObjectContact. Always needs to return something.
45 
46 public:
47  // basic constructor, used from E3dObject.
48  explicit ViewContactOfE3d(E3dObject& rObj);
49  virtual ~ViewContactOfE3d() override;
50 
51  // access to E3dObject
52  const E3dObject& GetE3dObject() const
53  {
54  return static_cast<const E3dObject&>(GetSdrObject());
55  }
56 
57  // public helpers
59  const drawinglayer::primitive3d::Primitive3DContainer& rxContent3D) const;
60 
61 
62  // primitive stuff
63 
64  // Primitive3DContainer of the ViewContact. This contains all necessary information
65  // for the graphical visualisation and needs to be supported by all 3D VCs which
66  // can be visualized. It does NOT contain the object transformation to be able to
67  // buffer for all possible usages
69 
70 protected:
71  // This method is responsible for creating the graphical visualisation data which is
72  // stored in mxViewIndependentPrimitive3DContainer, but without object transformation
74 
75  // This method is responsible for creating the graphical visualisation data derived ONLY from
76  // the model data. The default implementation will try to create a 3D to 2D embedding (will work
77  // when scene is known) which can then be used for 2D processing concerning ranges
79 
80 public:
81  // access to the local primitive without the object's local 3D transform. This is e.g. needed
82  // to get the not-yet transformed BoundVolume for e.g. interactions
84 
85  // access to the local primitive. This will ensure that the list is
86  // current in comparing the local list content with a fresh created incarnation. It will
87  // use getVIP3DSWithoutObjectTransform and embed to 3d transform primitive when object's
88  // local 3d transform is used
90 };
91 
92 }}
93 
94 
95 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual ViewObjectContact & CreateObjectSpecificViewObjectContact(ObjectContact &rObjectContact) override
drawinglayer::primitive3d::Primitive3DContainer getViewIndependentPrimitive3DContainer() const
virtual drawinglayer::primitive3d::Primitive3DContainer createViewIndependentPrimitive3DContainer() const =0
const E3dObject & GetE3dObject() const
drawinglayer::primitive2d::Primitive2DContainer impCreateWithGivenPrimitive3DContainer(const drawinglayer::primitive3d::Primitive3DContainer &rxContent3D) const
sal_Int32 attribute
virtual drawinglayer::primitive2d::Primitive2DContainer createViewIndependentPrimitive2DSequence() const override
drawinglayer::primitive3d::Primitive3DContainer const & getVIP3DSWithoutObjectTransform() const
drawinglayer::primitive3d::Primitive3DContainer mxViewIndependentPrimitive3DContainer