| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef UI_GFX_BUFFER_FORMAT_UTIL_H_ | 5 #ifndef UI_GFX_BUFFER_FORMAT_UTIL_H_ |
| 6 #define UI_GFX_BUFFER_FORMAT_UTIL_H_ | 6 #define UI_GFX_BUFFER_FORMAT_UTIL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> |
| 9 |
| 8 #include <vector> | 10 #include <vector> |
| 9 | 11 |
| 10 #include "base/basictypes.h" | |
| 11 #include "ui/gfx/buffer_types.h" | 12 #include "ui/gfx/buffer_types.h" |
| 12 #include "ui/gfx/geometry/size.h" | 13 #include "ui/gfx/geometry/size.h" |
| 13 #include "ui/gfx/gfx_export.h" | 14 #include "ui/gfx/gfx_export.h" |
| 14 | 15 |
| 15 namespace gfx { | 16 namespace gfx { |
| 16 | 17 |
| 17 // Returns a vector containing all buffer formats. | 18 // Returns a vector containing all buffer formats. |
| 18 GFX_EXPORT std::vector<BufferFormat> GetBufferFormatsForTesting(); | 19 GFX_EXPORT std::vector<BufferFormat> GetBufferFormatsForTesting(); |
| 19 | 20 |
| 20 // Returns the number of planes for |format|. | 21 // Returns the number of planes for |format|. |
| (...skipping 18 matching lines...) Expand all Loading... |
| 39 size_t* size_in_bytes) | 40 size_t* size_in_bytes) |
| 40 WARN_UNUSED_RESULT; | 41 WARN_UNUSED_RESULT; |
| 41 | 42 |
| 42 GFX_EXPORT int BufferOffsetForBufferFormat(const Size& size, | 43 GFX_EXPORT int BufferOffsetForBufferFormat(const Size& size, |
| 43 BufferFormat format, | 44 BufferFormat format, |
| 44 size_t plane); | 45 size_t plane); |
| 45 | 46 |
| 46 } // namespace gfx | 47 } // namespace gfx |
| 47 | 48 |
| 48 #endif // UI_GFX_BUFFER_FORMAT_UTIL_H_ | 49 #endif // UI_GFX_BUFFER_FORMAT_UTIL_H_ |
| OLD | NEW |