Pepper_56_C_interfaces
Pepper_56_C_interfaces
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
pp_rect.h
Go to the documentation of this file.
1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved.
2  * Use of this source code is governed by a BSD-style license that can be
3  * found in the LICENSE file.
4  */
5 
6 /* From pp_rect.idl modified Thu Oct 20 13:57:04 2016. */
7 
8 #ifndef PPAPI_C_PP_RECT_H_
9 #define PPAPI_C_PP_RECT_H_
10 
11 #include "ppapi/c/pp_macros.h"
12 #include "ppapi/c/pp_point.h"
13 #include "ppapi/c/pp_size.h"
14 #include "ppapi/c/pp_stdint.h"
15 
30 struct PP_Rect {
35  struct PP_Point point;
37  struct PP_Size size;
38 };
39 PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_Rect, 16);
40 
45 struct PP_FloatRect {
53 };
77 PP_INLINE struct PP_Rect PP_MakeRectFromXYWH(int32_t x, int32_t y,
78  int32_t w, int32_t h) {
79  struct PP_Rect ret;
80  ret.point.x = x;
81  ret.point.y = y;
82  ret.size.width = w;
83  ret.size.height = h;
84  return ret;
85 }
86 
100 PP_INLINE struct PP_FloatRect PP_MakeFloatRectFromXYWH(float x, float y,
101  float w, float h) {
102  struct PP_FloatRect ret;
103  ret.point.x = x;
104  ret.point.y = y;
105  ret.size.width = w;
106  ret.size.height = h;
107  return ret;
108 }
109 
114 #endif /* PPAPI_C_PP_RECT_H_ */
115 
PP_INLINE struct PP_Rect PP_MakeRectFromXYWH(int32_t x, int32_t y, int32_t w, int32_t h)
Definition: pp_rect.h:77
float width
Definition: pp_size.h:40
int32_t y
Definition: pp_point.h:38
Definition: pp_point.h:46
struct PP_FloatPoint point
Definition: pp_rect.h:50
Definition: pp_size.h:38
struct PP_Point point
Definition: pp_rect.h:35
int32_t height
Definition: pp_size.h:31
PP_INLINE struct PP_FloatRect PP_MakeFloatRectFromXYWH(float x, float y, float w, float h)
Definition: pp_rect.h:100
Definition: pp_point.h:28
struct PP_Size size
Definition: pp_rect.h:37
Definition: pp_rect.h:30
struct PP_FloatSize size
Definition: pp_rect.h:52
Definition: pp_rect.h:45
float height
Definition: pp_size.h:42
int32_t width
Definition: pp_size.h:29
int32_t x
Definition: pp_point.h:33
Definition: pp_size.h:27