| 104 | } |
| 105 | |
| 106 | openstudio::Transformation ShadingSurfaceGroup_Impl::buildingTransformation() const { |
| 107 | Transformation transformation; |
| 108 | |
| 109 | auto shadingSurfaceType = this->shadingSurfaceType(); |
| 110 | if (istringEqual("Space", shadingSurfaceType)) { |
| 111 | |
| 112 | boost::optional<Space> space = this->space(); |
| 113 | if (space) { |
| 114 | transformation = space->transformation() * this->transformation(); |
| 115 | } else { |
| 116 | transformation = this->transformation(); |
| 117 | } |
| 118 | |
| 119 | } else if (istringEqual("Building", shadingSurfaceType)) { |
| 120 | |
| 121 | transformation = this->transformation(); |
| 122 | |
| 123 | } else if (istringEqual("Site", shadingSurfaceType)) { |
| 124 | |
| 125 | boost::optional<Building> building = this->model().building(); |
| 126 | if (building) { |
| 127 | transformation = building->transformation().inverse() * this->transformation(); |
| 128 | } else { |
| 129 | transformation = this->transformation(); |
| 130 | } |
| 131 | } |
| 132 | |
| 133 | return transformation; |
| 134 | } |
| 135 | |
| 136 | bool ShadingSurfaceGroup_Impl::changeTransformation(const openstudio::Transformation& transformation) { |
| 137 | Transformation oldTransformation = this->transformation(); |
nothing calls this directly
no test coverage detected