Lcd companion boards support (VKLCD50RTA & VKLCD70RT)

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers window_surfaces_typedef.h Source File

window_surfaces_typedef.h

Go to the documentation of this file.
00001 /*******************************************************************************
00002 * DISCLAIMER
00003 * This software is supplied by Renesas Electronics Corporation and is only
00004 * intended for use with Renesas products. No other uses are authorized. This
00005 * software is owned by Renesas Electronics Corporation and is protected under
00006 * all applicable laws, including copyright laws.
00007 * THIS SOFTWARE IS PROVIDED "AS IS" AND RENESAS MAKES NO WARRANTIES REGARDING
00008 * THIS SOFTWARE, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING BUT NOT
00009 * LIMITED TO WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE
00010 * AND NON-INFRINGEMENT. ALL SUCH WARRANTIES ARE EXPRESSLY DISCLAIMED.
00011 * TO THE MAXIMUM EXTENT PERMITTED NOT PROHIBITED BY LAW, NEITHER RENESAS
00012 * ELECTRONICS CORPORATION NOR ANY OF ITS AFFILIATED COMPANIES SHALL BE LIABLE
00013 * FOR ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR
00014 * ANY REASON RELATED TO THIS SOFTWARE, EVEN IF RENESAS OR ITS AFFILIATES HAVE
00015 * BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
00016 * Renesas reserves the right, without notice, to make changes to this software
00017 * and to discontinue the availability of this software. By using this software,
00018 * you agree to the additional terms and conditions found by accessing the
00019 * following link:
00020 * http://www.renesas.com/disclaimer
00021 * Copyright (C) 2012 - 2014 Renesas Electronics Corporation. All rights reserved.
00022 *******************************************************************************/
00023 /**
00024 * @file  window_surfaces_typedef.h
00025 * @brief   $Module: CLibCommon $ $PublicVersion: 1.00 $ (=CLIB_VERSION)
00026 * $Rev: 47 $
00027 * $Date:: 2014-01-06 18:18:48 +0900#$
00028 */
00029 
00030 #ifndef  WINDOW_SURFACES_TYPEDEF_H
00031 #define  WINDOW_SURFACES_TYPEDEF_H
00032 
00033 /******************************************************************************
00034 Includes   <System Includes> , "Project Includes"
00035 ******************************************************************************/
00036 #include  "Project_Config.h"
00037 #include  "r_vdc5.h"
00038 #include  "frame_buffer_typedef.h "
00039 #include  "RGA_Port_typedef.h "
00040 #ifdef  IS_WINDOW_SURFACES_EX
00041 #include  "window_surfaces_ex_typedef.h "
00042 #endif
00043 
00044 
00045 #ifdef __cplusplus
00046 extern "C" {
00047 #endif /* __cplusplus */
00048 
00049 
00050 /******************************************************************************
00051 Typedef definitions
00052 ******************************************************************************/
00053 
00054 /**
00055 * @enum   background_format_t
00056 * @brief  background_format_t
00057 *
00058 *    - BACKGROUND_FORMAT_SOLID_COLOR - 0
00059 *    - BACKGROUND_FORMAT_VIDEO_INTERLACE - 1
00060 */
00061 enum st_background_format_t {
00062     BACKGROUND_FORMAT_SOLID_COLOR,
00063     BACKGROUND_FORMAT_VIDEO_INTERLACE
00064 };
00065 typedef enum st_background_format_t  background_format_t;
00066 /* "typedef" must be after "enum". Because GCC_ARM raises an error */
00067 
00068 
00069 /**
00070 * @struct  window_surfaces_vdc5_layer_t
00071 * @brief  VDC5 layer
00072 */
00073 typedef struct st_window_surfaces_vdc5_layer_t  window_surfaces_vdc5_layer_t;
00074 struct st_window_surfaces_vdc5_layer_t {
00075 
00076     /*-----------------------------------------------------------*/
00077     /* Group: Layer */
00078 
00079     /** layer_num */
00080     int8_t  layer_num;
00081 
00082     /** graphics_layer_ID */
00083     vdc5_graphics_type_t   graphics_layer_ID;
00084 
00085 
00086     /*-----------------------------------------------------------*/
00087     /* Group: Data Control */
00088 
00089     /** is_data_control */
00090     bool_t  is_data_control;
00091 
00092     /** data_control_ID */
00093     vdc5_layer_id_t   data_control_ID;
00094 
00095 
00096     /*-----------------------------------------------------------*/
00097     /* Group: Color Format */
00098 
00099     /** vdc5_format */
00100     vdc5_gr_format_t   vdc5_format;
00101 
00102     /** layer_color */
00103     r8g8b8a8_t  layer_color;
00104 };
00105 
00106 
00107 /**
00108 * @struct  window_surfaces_t
00109 * @brief  window_surfaces_t
00110 */
00111 typedef struct st_window_surfaces_t  window_surfaces_t;
00112 #define   WINDOW_SURFACES_T_MAX_LAYERS_COUNT   3
00113 
00114 struct st_window_surfaces_t {
00115     /** Index is 0 .. (layer_num_max + background_frame_count) */
00116     frame_buffer_t  frame_buffers[ WINDOW_SURFACES_T_MAX_LAYERS_COUNT ];
00117 
00118     /** screen_channel */
00119     vdc5_channel_t   screen_channel;
00120 
00121     /** layer_num_min */
00122     int8_t  layer_num_min;
00123 
00124     /** layer_num_max */
00125     int8_t  layer_num_max;
00126 
00127     /** layers */
00128     window_surfaces_vdc5_layer_t  layers[ WINDOW_SURFACES_T_MAX_LAYERS_COUNT ];
00129 
00130     /** attributes */
00131 #ifdef  IS_WINDOW_SURFACES_EX
00132     window_surfaces_attribute_t   attributes[ WINDOW_SURFACES_T_MAX_LAYERS_COUNT ];
00133 #endif
00134 
00135     /** vdc5_disp_sel_array */
00136     vdc5_gr_disp_sel_t    vdc5_disp_sel_array[ VDC5_GR_TYPE_NUM  ];
00137 
00138     /** background_format */
00139     background_format_t  background_format;
00140 
00141     /** background_frame_count */
00142     int_fast32_t   background_frame_count;
00143 
00144 
00145     /*-----------------------------------------------------------*/
00146     /* Group: VRAM */
00147 
00148     /** start_of_VRAM */
00149     uint8_t  *start_of_VRAM;
00150 
00151     /** over_of_VRAM */
00152     uint8_t  *over_of_VRAM;
00153 
00154     /** stack_pointer_of_VRAM */
00155     uint8_t  *stack_pointer_of_VRAM;
00156 
00157 
00158     /*-----------------------------------------------------------*/
00159     /* Group: State */
00160 
00161     /** is_initialized */
00162     bool_t  is_initialized;  /* For reduce loading */
00163 };
00164 
00165 
00166 /**
00167 * @struct  window_surfaces_config_t
00168 * @brief  window_surfaces_config_t
00169 */
00170 typedef struct st_window_surfaces_config_t  window_surfaces_config_t;
00171 struct st_window_surfaces_config_t {
00172     /** 0 | F_WINDOW_SURFACES_PIXEL_FORMAT | ... */
00173     bit_flags_fast32_t  flags;
00174 
00175     /** pixel_format */
00176     pixel_format_t  pixel_format;
00177 
00178     /** layer_count */
00179     int_fast32_t  layer_count;
00180 
00181     /** buffer_height */
00182     int_fast32_t  buffer_height;
00183 
00184     /** background_color */
00185     r8g8b8a8_t  background_color;
00186 
00187     /** background_format */
00188     background_format_t  background_format;
00189 };
00190 enum  /* "window_surfaces_config_t::flags" */
00191 {
00192     F_WINDOW_SURFACES_PIXEL_FORMAT      = 0x08,
00193     F_WINDOW_SURFACES_LAYER_COUNT       = 0x20,
00194 #define  F_WINDOW_SURFACES_BACKGROUND_COLOR    0x40u
00195     F_WINDOW_SURFACES_BUFFER_HEIGHT     = 0x80,
00196     F_WINDOW_SURFACES_BACKGROUND_FORMAT = 0x100
00197 };
00198 
00199 
00200 /***********************************************************************
00201 * Section: Global
00202 ************************************************************************/
00203 
00204 /******************************************************************************
00205 Macro definitions
00206 ******************************************************************************/
00207 
00208 /**
00209 * @def  WINDOW_SURFACES_DEFAULT_CHANNEL
00210 * @brief  0 or 1
00211 */
00212 #define  WINDOW_SURFACES_DEFAULT_CHANNEL  0
00213 
00214 
00215 /******************************************************************************
00216 Variable Externs
00217 ******************************************************************************/
00218 
00219 /******************************************************************************
00220 Functions Prototypes
00221 ******************************************************************************/
00222 /* In "frame_buffer.h" */
00223 
00224 #ifdef __cplusplus
00225 }  /* extern "C" */
00226 #endif /* __cplusplus */
00227 
00228 #endif
00229