Chromium Code Reviews| Index: webrtc/modules/desktop_capture/desktop_geometry.h |
| diff --git a/webrtc/modules/desktop_capture/desktop_geometry.h b/webrtc/modules/desktop_capture/desktop_geometry.h |
| index 047eeec3d9c8fd89c13f29347a0a67b77b2096da..b9a912758e98418edb71589a8ebd2f51b121030b 100644 |
| --- a/webrtc/modules/desktop_capture/desktop_geometry.h |
| +++ b/webrtc/modules/desktop_capture/desktop_geometry.h |
| @@ -105,6 +105,13 @@ class DesktopRect { |
| int32_t width() const { return right_ - left_; } |
| int32_t height() const { return bottom_ - top_; } |
| + // Create a new DesktopRect instance to represent a rectangle which is |
| + // |padding| pixels larger than current instance in each direction. This is |
| + // for VideoEncoderVpx and ScreenCapturerWinDirectx. |
|
Sergey Ulanov
2016/04/14 23:10:42
Don't need this sentence (it will expire quickly a
Hzj_jie
2016/04/15 19:42:17
Done.
|
| + // Note, left and top of the new instance won't be less than zero, and right |
| + // and bottom wont't be larger than the desktop size. |
|
Sergey Ulanov
2016/04/14 23:10:42
So it looks like this function currently does two
Hzj_jie
2016/04/15 19:42:17
Done.
|
| + DesktopRect Expand(uint32_t padding, const DesktopSize& size) const; |
|
Sergey Ulanov
2016/04/14 23:10:42
Other functions in this class mutate the rect in-p
Sergey Ulanov
2016/04/14 23:10:42
nit: Move this function below, after other mutator
Sergey Ulanov
2016/04/14 23:10:42
padding should be int.
From https://google.github.
Hzj_jie
2016/04/15 19:42:17
Considering this is a simple class, mutable eventu
Hzj_jie
2016/04/15 19:42:17
Done.
Hzj_jie
2016/04/15 19:42:17
Done.
|
| + |
| DesktopVector top_left() const { return DesktopVector(left_, top_); } |
| DesktopSize size() const { return DesktopSize(width(), height()); } |