epoc32/include/VG/1.0/vgu.h
branchSymbian3
changeset 4 837f303aceeb
parent 3 e1b950c65cb4
equal deleted inserted replaced
3:e1b950c65cb4 4:837f303aceeb
     1 /*------------------------------------------------------------------------
     1 /*------------------------------------------------------------------------
     2  * 
     2  *
     3  * VGU 1.1 Reference Implementation
     3  * OpenVG 1.0.1 Reference Implementation
     4  * -------------------------------------
     4  * -------------------------------------
     5  *
     5  *
     6  * Copyright (c) 2008 The Khronos Group Inc.
     6  * Copyright (c) 2007-2009 The Khronos Group Inc.
     7  *
     7  *
     8  * Permission is hereby granted, free of charge, to any person obtaining a
     8  * Permission is hereby granted, free of charge, to any person obtaining a
     9  * copy of this software and /or associated documentation files
     9  * copy of this software and /or associated documentation files
    10  * (the "Materials "), to deal in the Materials without restriction,
    10  * (the "Materials "), to deal in the Materials without restriction,
    11  * including without limitation the rights to use, copy, modify, merge,
    11  * including without limitation the rights to use, copy, modify, merge,
    24  * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE MATERIALS OR
    24  * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE MATERIALS OR
    25  * THE USE OR OTHER DEALINGS IN THE MATERIALS.
    25  * THE USE OR OTHER DEALINGS IN THE MATERIALS.
    26  *
    26  *
    27  *//**
    27  *//**
    28  * \file
    28  * \file
    29  * \brief	VGU 1.1 API.
    29  * \brief	OpenVG VGU 1.0.1 API.
    30  *//*-------------------------------------------------------------------*/
    30  *//*-------------------------------------------------------------------*/
    31 
    31 
    32 #ifndef __VG_1_1_VGU_H
    32 #ifndef __VG_1_0_VGU_H
    33 #define __VG_1_1_VGU_H
    33 #define __VG_1_0_VGU_H
    34 
    34 
    35 #ifndef __VG_VGU_H_
    35 #ifndef __VG_VGU_H_
    36 #error Do not include this file directly. Use <VG/vgu.h>.
    36 #error Do not include this file directly. Use <VG/vgu.h>.
    37 #endif
    37 #endif
    38 
    38 
    48 
    48 
    49 /**
    49 /**
    50 @publishedAll
    50 @publishedAll
    51 @released
    51 @released
    52 */
    52 */
    53 #ifdef __cplusplus
    53 
    54 extern "C" {
    54 #ifdef __cplusplus 
       
    55 extern "C" { 
    55 #endif
    56 #endif
    56 
    57 
    57 #include <VG/openvg.h>
    58 #include <VG/openvg.h>
    58 
    59 
    59 #define VGU_VERSION_1_0 1
    60 #define VGU_VERSION_1_0		1
    60 #define VGU_VERSION_1_1 2
    61 #define VGU_VERSION_1_0_1	1
    61 
    62 
    62 #ifndef VGU_API_CALL
    63 #ifndef VGU_API_CALL
    63 #define VGU_API_CALL IMPORT_C
    64 #   if defined(SYMBIAN_VG_DLL_EXPORTS)
    64 #endif
    65 #       define VGU_API_CALL EXPORT_C
    65 #ifndef VGU_APIENTRY
    66 #   else
    66 #define VGU_APIENTRY /* nothing */
    67 #       define VGU_API_CALL IMPORT_C
    67 #endif
    68 #   endif //defined(SYMBIAN_VG_DLL_EXPORTS)
    68 #ifndef VGU_APIEXIT
       
    69 #define VGU_APIEXIT __SOFTFP
       
    70 #endif
    69 #endif
    71 
    70 
    72 typedef enum {
    71 typedef enum {
    73   VGU_NO_ERROR                                 = 0,
    72   VGU_NO_ERROR                                 = 0,
    74   VGU_BAD_HANDLE_ERROR                         = 0xF000,
    73   VGU_BAD_HANDLE_ERROR                         = 0xF000,
    82   VGU_ARC_OPEN                                 = 0xF100,
    81   VGU_ARC_OPEN                                 = 0xF100,
    83   VGU_ARC_CHORD                                = 0xF101,
    82   VGU_ARC_CHORD                                = 0xF101,
    84   VGU_ARC_PIE                                  = 0xF102
    83   VGU_ARC_PIE                                  = 0xF102
    85 } VGUArcType;
    84 } VGUArcType;
    86 
    85 
    87 VGU_API_CALL VGUErrorCode VGU_APIENTRY
    86 VGU_API_CALL VGUErrorCode vguLine(VGPath path,
    88      vguLine(VGPath path,
    87                                   VGfloat x0, VGfloat y0,
    89         VGfloat x0, VGfloat y0,
    88                                   VGfloat x1, VGfloat y1) __SOFTFP;
    90         VGfloat x1, VGfloat y1) VGU_APIEXIT;
       
    91 
    89 
    92 VGU_API_CALL VGUErrorCode VGU_APIENTRY
    90 VGU_API_CALL VGUErrorCode vguPolygon(VGPath path,
    93      vguPolygon(VGPath path,
    91                                      const VGfloat * points, VGint count,
    94         const VGfloat * points,
    92                                      VGboolean closed);
    95         VGint count,
       
    96         VGboolean closed) VGU_APIEXIT;
       
    97 
    93 
    98 VGU_API_CALL VGUErrorCode VGU_APIENTRY
    94 VGU_API_CALL VGUErrorCode vguRect(VGPath path,
    99      vguRect(VGPath path,
    95                                   VGfloat x, VGfloat y,
   100         VGfloat x, VGfloat y,
    96                                   VGfloat width, VGfloat height) __SOFTFP;
   101         VGfloat width, VGfloat height) VGU_APIEXIT;
       
   102 
    97 
   103 VGU_API_CALL VGUErrorCode VGU_APIENTRY
    98 VGU_API_CALL VGUErrorCode vguRoundRect(VGPath path,
   104      vguRoundRect(VGPath path,
    99                                        VGfloat x, VGfloat y,
   105         VGfloat x, VGfloat y,
   100                                        VGfloat width, VGfloat height,
   106         VGfloat width,
   101                                        VGfloat arcWidth, VGfloat arcHeight) __SOFTFP;
   107         VGfloat height,
       
   108         VGfloat arcWidth,
       
   109         VGfloat arcHeight) VGU_APIEXIT;
       
   110 
   102 
   111 VGU_API_CALL VGUErrorCode VGU_APIENTRY
   103 VGU_API_CALL VGUErrorCode vguEllipse(VGPath path,
   112      vguEllipse(VGPath path,
   104                                      VGfloat cx, VGfloat cy,
   113         VGfloat cx, VGfloat cy,
   105                                      VGfloat width, VGfloat height) __SOFTFP;
   114         VGfloat width,
       
   115         VGfloat height) VGU_APIEXIT;
       
   116 
   106 
   117 VGU_API_CALL VGUErrorCode VGU_APIENTRY
   107 VGU_API_CALL VGUErrorCode vguArc(VGPath path,
   118      vguArc(VGPath path,
   108                                  VGfloat x, VGfloat y,
   119         VGfloat x, VGfloat y,
   109                                  VGfloat width, VGfloat height,
   120         VGfloat width, VGfloat height,
   110                                  VGfloat startAngle, VGfloat angleExtent,
   121         VGfloat startAngle,
   111                                  VGUArcType arcType) __SOFTFP;
   122         VGfloat angleExtent,
       
   123         VGUArcType arcType) VGU_APIEXIT;
       
   124 
   112 
   125 VGU_API_CALL VGUErrorCode VGU_APIENTRY
   113 VGU_API_CALL VGUErrorCode vguComputeWarpQuadToSquare(VGfloat sx0, VGfloat sy0,
   126     vguComputeWarpQuadToSquare(VGfloat sx0, VGfloat sy0,
   114                                                      VGfloat sx1, VGfloat sy1,
   127         VGfloat sx1, VGfloat sy1,
   115                                                      VGfloat sx2, VGfloat sy2,
   128         VGfloat sx2, VGfloat sy2,
   116                                                      VGfloat sx3, VGfloat sy3,
   129         VGfloat sx3, VGfloat sy3,
   117                                                      VGfloat * matrix) __SOFTFP;
   130         VGfloat * matrix) VGU_APIEXIT;
       
   131 
   118 
   132 VGU_API_CALL VGUErrorCode VGU_APIENTRY
   119 VGU_API_CALL VGUErrorCode vguComputeWarpSquareToQuad(VGfloat dx0, VGfloat dy0,
   133     vguComputeWarpSquareToQuad(VGfloat dx0, VGfloat dy0,
   120                                                      VGfloat dx1, VGfloat dy1,
   134         VGfloat dx1, VGfloat dy1,
   121                                                      VGfloat dx2, VGfloat dy2,
   135         VGfloat dx2, VGfloat dy2,
   122                                                      VGfloat dx3, VGfloat dy3,
   136         VGfloat dx3, VGfloat dy3,
   123                                                      VGfloat * matrix) __SOFTFP;
   137         VGfloat * matrix) VGU_APIEXIT;
       
   138 
   124 
   139 VGU_API_CALL VGUErrorCode VGU_APIENTRY
   125 VGU_API_CALL VGUErrorCode vguComputeWarpQuadToQuad(VGfloat dx0, VGfloat dy0,
   140     vguComputeWarpQuadToQuad(VGfloat dx0, VGfloat dy0,
   126                                                    VGfloat dx1, VGfloat dy1,
   141         VGfloat dx1, VGfloat dy1,
   127                                                    VGfloat dx2, VGfloat dy2,
   142         VGfloat dx2, VGfloat dy2,
   128                                                    VGfloat dx3, VGfloat dy3,
   143         VGfloat dx3, VGfloat dy3,
   129                                                    VGfloat sx0, VGfloat sy0,
   144         VGfloat sx0, VGfloat sy0,
   130                                                    VGfloat sx1, VGfloat sy1,
   145         VGfloat sx1, VGfloat sy1,
   131                                                    VGfloat sx2, VGfloat sy2,
   146         VGfloat sx2, VGfloat sy2,
   132                                                    VGfloat sx3, VGfloat sy3,
   147         VGfloat sx3, VGfloat sy3,
   133                                                    VGfloat * matrix) __SOFTFP;
   148         VGfloat * matrix) VGU_APIEXIT;
       
   149 
   134 
   150 #ifdef __cplusplus
   135 #ifdef __cplusplus 
   151 } /* extern "C" */
   136 } /* extern "C" */
   152 #endif
   137 #endif
   153 
   138 
   154 #endif /* __VG_1_1_VGU_H */
   139 #endif /*__VG_1_0_VGU_H */