///////////////////////////////////////////////////////
| 287 | |
| 288 | //////////////////////////////////////////////////////////// |
| 289 | IntRect RenderTarget::getScissor(const View& view) const |
| 290 | { |
| 291 | const auto [width, height] = Vector2f(getSize()); |
| 292 | const FloatRect& scissor = view.getScissor(); |
| 293 | |
| 294 | return IntRect(Rect<long>({std::lround(width * scissor.position.x), std::lround(height * scissor.position.y)}, |
| 295 | {std::lround(width * scissor.size.x), std::lround(height * scissor.size.y)})); |
| 296 | } |
| 297 | |
| 298 | |
| 299 | //////////////////////////////////////////////////////////// |
no outgoing calls
no test coverage detected