xref: /utopia/UTPA2-700.0.x/modules/graphic/api/gop/apiGOP_priv.h (revision 53ee8cc121a030b8d368113ac3e966b4705770ef)
1 //<MStar Software>
2 //******************************************************************************
3 // MStar Software
4 // Copyright (c) 2010 - 2012 MStar Semiconductor, Inc. All rights reserved.
5 // All software, firmware and related documentation herein ("MStar Software") are
6 // intellectual property of MStar Semiconductor, Inc. ("MStar") and protected by
7 // law, including, but not limited to, copyright law and international treaties.
8 // Any use, modification, reproduction, retransmission, or republication of all
9 // or part of MStar Software is expressly prohibited, unless prior written
10 // permission has been granted by MStar.
11 //
12 // By accessing, browsing and/or using MStar Software, you acknowledge that you
13 // have read, understood, and agree, to be bound by below terms ("Terms") and to
14 // comply with all applicable laws and regulations:
15 //
16 // 1. MStar shall retain any and all right, ownership and interest to MStar
17 //    Software and any modification/derivatives thereof.
18 //    No right, ownership, or interest to MStar Software and any
19 //    modification/derivatives thereof is transferred to you under Terms.
20 //
21 // 2. You understand that MStar Software might include, incorporate or be
22 //    supplied together with third party`s software and the use of MStar
23 //    Software may require additional licenses from third parties.
24 //    Therefore, you hereby agree it is your sole responsibility to separately
25 //    obtain any and all third party right and license necessary for your use of
26 //    such third party`s software.
27 //
28 // 3. MStar Software and any modification/derivatives thereof shall be deemed as
29 //    MStar`s confidential information and you agree to keep MStar`s
30 //    confidential information in strictest confidence and not disclose to any
31 //    third party.
32 //
33 // 4. MStar Software is provided on an "AS IS" basis without warranties of any
34 //    kind. Any warranties are hereby expressly disclaimed by MStar, including
35 //    without limitation, any warranties of merchantability, non-infringement of
36 //    intellectual property rights, fitness for a particular purpose, error free
37 //    and in conformity with any international standard.  You agree to waive any
38 //    claim against MStar for any loss, damage, cost or expense that you may
39 //    incur related to your use of MStar Software.
40 //    In no event shall MStar be liable for any direct, indirect, incidental or
41 //    consequential damages, including without limitation, lost of profit or
42 //    revenues, lost or damage of data, and unauthorized system use.
43 //    You agree that this Section 4 shall still apply without being affected
44 //    even if MStar Software has been modified by MStar in accordance with your
45 //    request or instruction for your use, except otherwise agreed by both
46 //    parties in writing.
47 //
48 // 5. If requested, MStar may from time to time provide technical supports or
49 //    services in relation with MStar Software to you for your use of
50 //    MStar Software in conjunction with your or your customer`s product
51 //    ("Services").
52 //    You understand and agree that, except otherwise agreed by both parties in
53 //    writing, Services are provided on an "AS IS" basis and the warranty
54 //    disclaimer set forth in Section 4 above shall apply.
55 //
56 // 6. Nothing contained herein shall be construed as by implication, estoppels
57 //    or otherwise:
58 //    (a) conferring any license or right to use MStar name, trademark, service
59 //        mark, symbol or any other identification;
60 //    (b) obligating MStar or any of its affiliates to furnish any person,
61 //        including without limitation, you and your customers, any assistance
62 //        of any kind whatsoever, or any information; or
63 //    (c) conferring any license or right under any intellectual property right.
64 //
65 // 7. These terms shall be governed by and construed in accordance with the laws
66 //    of Taiwan, R.O.C., excluding its conflict of law rules.
67 //    Any and all dispute arising out hereof or related hereto shall be finally
68 //    settled by arbitration referred to the Chinese Arbitration Association,
69 //    Taipei in accordance with the ROC Arbitration Law and the Arbitration
70 //    Rules of the Association by three (3) arbitrators appointed in accordance
71 //    with the said Rules.
72 //    The place of arbitration shall be in Taipei, Taiwan and the language shall
73 //    be English.
74 //    The arbitration award shall be final and binding to both parties.
75 //
76 //******************************************************************************
77 //<MStar Software>
78 ////////////////////////////////////////////////////////////////////////////////
79 //
80 // Copyright (c) 2008-2009 MStar Semiconductor, Inc.
81 // All rights reserved.
82 //
83 // Unless otherwise stipulated in writing, any and all information contained
84 // herein regardless in any format shall remain the sole proprietary of
85 // MStar Semiconductor Inc. and be kept in strict confidence
86 // ("MStar Confidential Information") by the recipient.
87 // Any unauthorized act including without limitation unauthorized disclosure,
88 // copying, use, reproduction, sale, distribution, modification, disassembling,
89 // reverse engineering and compiling of the contents of MStar Confidential
90 // Information is unlawful and strictly prohibited. MStar hereby reserves the
91 // rights to any and all damages, losses, costs and expenses resulting therefrom.
92 //
93 ////////////////////////////////////////////////////////////////////////////////
94 #ifndef _APIGOP_PRIV_H_
95 #define _APIGOP_PRIV_H_
96 
97 ///////////////////////////////////////////////////////////////////////////////////////////////////
98 ///
99 /// @file   apiGOP.h
100 /// @brief  MStar Graphics Output Path API
101 /// @author MStar Semiconductor Inc.
102 ///////////////////////////////////////////////////////////////////////////////////////////////////
103 
104 #include "MsTypes.h"
105 #include "MsDevice.h"
106 #include "apiGOP_v2.h"
107 
108 #ifdef __cplusplus
109 extern "C"
110 {
111 #endif
112 
113 //-------------------------------------------------------------------------------------------------
114 //  Macro and Define
115 //-------------------------------------------------------------------------------------------------
116 /// GOP Version
117 /// GOP CMD
118 typedef enum
119 {
120     //gop property
121     MAPI_CMD_GOP_INIT = 0x0,
122     MAPI_CMD_GOP_GET_CHIPCAPS,
123     MAPI_CMD_GOP_SET_CONFIG,
124     MAPI_CMD_GOP_GET_CONFIG,
125     MAPI_CMD_GOP_SET_PROPERTY,
126     MAPI_CMD_GOP_GET_PROPERTY,
127     MAPI_CMD_GOP_SET_DST,
128     MAPI_CMD_GOP_GET_DST,
129     MAPI_CMD_GOP_SET_MUX,
130     MAPI_CMD_GOP_SET_LAYER,
131     MAPI_CMD_GOP_GET_LAYER,
132     MAPI_CMD_GOP_SET_MIRROR,
133     MAPI_CMD_GOP_GET_MIRROR,
134     MAPI_CMD_GOP_GET_STATUS,
135 
136     //Stretch Win
137     MAPI_CMD_GOP_GWIN_SET_STRETCH = 0x100,
138     MAPI_CMD_GOP_GWIN_GET_STRETCH,
139 
140     //GWIN info
141     MAPI_CMD_GOP_GWIN_SET_PROPERTY = 0x200,
142     MAPI_CMD_GOP_GWIN_GET_PROPERTY,
143     MAPI_CMD_GOP_GWIN_MAPFB2WIN,
144     MAPI_CMD_GOP_GWIN_SET_WININFO,
145     MAPI_CMD_GOP_GWIN_GET_WININFO,
146     //MAPI_CMD_GOP_GWIN_ENABLE,
147     MAPI_CMD_GOP_GWIN_SETDISPLAY,
148     MAPI_CMD_GOP_GWIN_DESTROY,
149 
150     //GFLIP
151     MAPI_CMD_GOP_GFLIP_CLEARQUEUE = 0x300,
152     MAPI_CMD_GOP_GFLIP_SWITCHGWIN,
153     MAPI_CMD_GOP_GFLIP_SWITCHMULTIGWIN,
154     MAPI_CMD_GOP_GFLIP_RESTORE_VSYNC_LMT,
155 
156     //PINPON
157     MAPI_CMD_GOP_SET_PINPON  = 0x400,
158 
159     //FB Info
160     MAPI_CMD_GOP_FB_CREATE   = 0x500,
161     MAPI_CMD_GOP_FB_DESTROY,
162     MAPI_CMD_GOP_FB_GETINFO,
163     MAPI_CMD_GOP_FB_SETINFO,
164     MAPI_CMD_GOP_FB_SET_PROPERTY,
165     MAPI_CMD_GOP_FB_GET_PROPERTY,
166     //palette
167     MAPI_CMD_GOP_PALETTE_SET_CONFIG = 0x600,
168     MAPI_CMD_GOP_PALETTE_SET_ENTRY,
169     MAPI_CMD_GOP_PALETTE_GET_ENTRY,
170 
171     //Scroll
172     MAPI_CMD_GOP_SET_SCROLL = 0x700,
173 
174     //FadeInOut
175     MAPI_CMD_GOP_GWIN_SET_FADE = 0x800,
176 
177     //DWIN
178     MAPI_CMD_GOP_DWIN_INIT = 0x900,
179     MAPI_CMD_GOP_DWIN_CAPTURE,
180     MAPI_CMD_GOP_DWIN_INTR,
181     MAPI_CMD_GOP_DWIN_SET_PROPERTY,
182     MAPI_CMD_GOP_DWIN_GET_PROPERTY,
183 
184     //MIXER
185     MAPI_CMD_GOP_MIXER_SET_PROPERTY = 0xA00,
186     MAPI_CMD_GOP_MIXER_GET_PROPERTY,
187 
188     //VE
189     MAPI_CMD_GOP_VE_SET_PROPERTY = 0xB00,
190 
191     //MISC
192     MAPI_CMD_GOP_UPDATE = 0xC00,
193     MAPI_CMD_GOP_REGISTER_CB,
194     MAPI_CMD_GOP_TESTPATTERN,
195     MAPI_CMD_GOP_SELECTION,
196     MAPI_CMD_GOP_MUTEX,
197     MAPI_CMD_GOP_MISC,
198     MAPI_CMD_GOP_RESETPOOL,
199     //LEGACY
200 
201     //POWERSTATE
202     MAPI_CMD_GOP_POWERSTATE =0xD00,
203     //MAPI_CMD_GOP_LEGACY_FUNC,
204     MAPI_CMD_GOP_INTERRUPT,
205 }E_GOP_API_CMD_TYPE;
206 
207 
208 typedef enum
209 {
210     E_GOP_STRETCH_WIN     = 0x1,
211     E_GOP_STRETCH_HSCALE  = 0x2,
212     E_GOP_STRETCH_VSCALE  = 0x4,
213     E_GOP_STRETCH_WIN_POSITION = 0x8,
214     E_GOP_STRETCH_HSTRETCH_MODE = 0x10,
215     E_GOP_STRETCH_VSTRETCH_MODE = 0x20,
216     E_GOP_STRETCH_TRANSPCOLOR_MODE = 0x40,
217 }EN_GOP_STRETCH_TYPE;
218 
219 typedef enum
220 {
221     GOP_DWIN_FMT_UV7Y8 = 0,
222     /// CrYCb domain.
223     GOP_DWIN_FMT_UV8Y8,
224     /// RGB domain (CSC bypass).
225     GOP_DWIN_FMT_ARGB8888,
226     /// RGB domain (CSC bypass).
227     GOP_DWIN_FMT_RGB565,
228 } EN_GOP_DWIN_FMT;
229 
230 /// DWIN source selection
231 typedef enum
232 {
233     /// DWIN OP source
234     GOP_DWIN_SRC_OP   = 0,
235     /// DWIN MVOP source
236     GOP_DWIN_SRC_MVOP = 1,
237     /// DWIN IP source
238     GOP_DWIN_SRC_IP   = 2,
239     /// DWIN OP1 source
240     GOP_DWIN_SRC_OP1 =3,
241     /// DWIN SUB MVOP source
242     GOP_DWIN_SRC_SUBMVOP =4,
243     /// DWIN GOPScaling source
244     GOP_DWIN_SRC_GOPScaling =5,
245 } EN_GOP_DWIN_SRC;
246 
247 typedef enum
248 {
249     E_GOP_SCROLL_CONFIG,
250     E_GOP_SCROLL_RATE,
251 } EN_GOP_SCROLL_TYPE;
252 
253 typedef enum
254 {
255     E_GOP_FADE_CONFIG,
256 } EN_GOP_FADE_SET_TYPE;
257 
258 typedef enum
259 {
260     E_GOP_MISC_ENABLE_T3D,
261     E_GOP_MISC_SET_CAPTURE_CLK,
262     E_GOP_MISC_POWER_OFF,
263     E_GOP_MISC_POWER_ON,
264     E_GOP_MISC_GET_RT_STATUS,
265     E_GOP_MISC_GET_INFO,
266     E_GOP_MISC_AT_EXIT,
267     E_GOP_MISC_OC_FB_INFO,
268     E_GOP_MISC_TESTPATTERN_ALPHA,
269     E_GOP_MISC_DELETE_GWINSIZE,
270     E_GOP_MISC_SET_DBG_LEVEL,
271 } EN_GOP_MISC_TYPE;
272 
273 
274 typedef enum
275 {
276     E_GOP_MIUSEL,
277     E_GOP_CONTRAST,
278     E_GOP_BRIGHTNESS,
279     E_GOP_OUTPUT_COLOR,
280     E_GOP_UV_SWAP,
281     E_GOP_YC_SWAP,
282     E_GOP_HSTART,
283     E_GOP_TRANSCOLOR,
284     E_GOP_PROGRESSIVE,
285     E_GOP_ALPHAINVERSE,
286     E_GOP_PREALPHAMODE,
287     E_GOP_FIELD_INVERSE,
288     E_GOP_HSCALE_RATIO,
289     E_GOP_VSCALE_RATIO,
290     E_GOP_OUTPUT_TIMING,
291     E_GOP_PIXELBASE_ENABLE,
292     E_GOP_CLK,
293     E_GOP_FORCE_WRITE,
294     E_GOP_BANK_FORCE_WRITE,
295     E_GOP_3D_LR_EXCHANGE,
296     E_GOP_VE_OSD,
297     E_GOP_OUTPUT_LAYER_SWITCH,
298     E_GOP_SWAP_OVERLAP_WIN,
299     E_GOP_BW_STRENGTH,
300     E_GOP_LB_COUPLE,
301     E_GOP_YUV,
302     E_GOP_REG_UPDATED,
303     E_GOP_RELATIVE_WIN_PRIO,
304     E_GOP_RESOURCE,
305     E_GOP_MAXFBNUM,
306     E_GOP_MULTI_ALPHA_ENABLE,
307     E_GOP_GWIN_TLB_ENABLE,
308     E_GOP_AFBC_CORE_RESET,
309     E_GOP_AFBC_CORE_ENABLE,
310     E_GOP_NUM_IS_INIT,
311 }EN_GOP_PROPERTY;
312 
313 /// Define GOP gwin fade in/out.
314 typedef enum
315 {
316     /// GOP gwin fade in.
317     E_GOP_GWIN_FADE_TYPE_IN,
318     /// GOP gwin fade out.
319     E_GOP_GWIN_FADE_TYPE_OUT,
320     /// GOP gwin fade unknow type.
321     E_GOP_GWIN_FADE_TYPE_UNKNOWN,
322 } EN_GOP_SET_FADE_TYPE;
323 
324 typedef enum
325 {
326     E_GOP_DWIN_R2Y,
327     E_GOP_DWIN_UV_SWAP,
328     E_GOP_DWIN_UV_SAMPLE,
329     E_GOP_DWIN_SOURCE_SCAN_TYPE,
330     E_GOP_DWIN_ALPHA_VALUE,
331     E_GOP_DWIN_ALPHA_SOURCE,
332     E_GOP_DWIN_ALPHA_INVERSE,
333     E_GOP_DWIN_SKIP_FRAME,
334     E_GOP_DWIN_PINPON,
335     E_GOP_DWIN_INTERRUP_INFO,
336     E_GOP_DWIN_CAPTURE_INFO,
337 }EN_GOP_DWIN_PROPERTY;
338 
339 typedef enum
340 {
341     E_GOP_MIXER_OUTPUT_TIMING,
342     E_GOP_MIXER_TO_OP_OUTPUT_TIMING,
343     E_GOP_MIXER_V_FILTER,
344     E_GOP_MIXER_OLD_BLENDING_MODE,
345 }EN_GOP_MIXER_PROPERTY;
346 
347 typedef enum
348 {
349     E_GOP_VE_OUTPUT_TIMING,
350 }EN_GOP_VE_PROPERTY;
351 
352 typedef enum
353 {
354     E_GOP_SET_PINPON,
355 }EN_GOP_PINPON_PROPERTY;
356 
357 typedef enum
358 {
359     E_GOP_LOCK,
360     E_GOP_UNLOCK,
361 }EN_GOP_MUTEX;
362 
363 typedef enum
364 {
365     E_GOP_GWIN_ENABLE,
366     E_GOP_GWIN_BLENDING,
367     E_GOP_GWIN_NEWAPLHA,
368     E_GOP_GWIN_BLINK,
369     E_GOP_GWIN_SHARE,
370     E_GOP_GWIN_SHARE_CNT,
371     E_GOP_GWIN_SWITCH_2_GWIN,
372     E_GOP_GWIN_3D_MODE,
373     E_GOP_GWIN_EXIST,
374     E_GOP_GWIN_FREE_ID,
375     E_GOP_GWIN_GET_FB,
376     E_GOP_GWIN_GET_GOP,
377     E_GOP_GWIN_GPUTILE,
378 }EN_GOP_GWIN_PROPERTY;
379 
380 typedef enum
381 {
382     E_GOP_FB_POOLID,
383     E_GOP_FB_EXIST,
384     E_GOP_FB_OBTAIN,
385 }EN_GOP_FB_PROPERTY;
386 
387 typedef enum
388 {
389     E_GOP_UPDATE_FORCEWRITE,
390     E_GOP_UPDATE_CURRENT_ONCE,
391     E_GOP_UPDATE_ONCE,
392 }EN_GOP_UPDATE_TYPE;
393 
394 typedef enum
395 {
396     /// DWIN capture type -- default case
397     GOP_API_VER,
398 }EN_GOP_API_TYPE;
399 
400 typedef enum
401 {
402     GOP_CREATE_BUFFER,        //Use GOP allocator
403     GOP_CREATE_BUFFER_BYADDR  //By static addr
404 }EN_GOP_CREATEBUFFER_TYPE;
405 
406 typedef enum
407 {
408     E_GOP_MIRROR_NONE,
409     E_GOP_MIRROR_H_ONLY,
410     E_GOP_MIRROR_V_ONLY,
411     E_GOP_MIRROR_HV,
412     E_GOP_MIRROR_H_NONE,
413     E_GOP_MIRROR_V_NONE,
414 }EN_GOP_MIRROR_TYPE;
415 
416 typedef enum
417 {
418     E_GOP_STATUS_CURRENT_GOP,
419     E_GOP_STATUS_CURRENT_GWIN,
420     E_GOP_STATUS_CURRENT_FBID,
421     E_GOP_STATUS_GOP_MAXNUM,
422     E_GOP_STATUS_GWIN_MAXNUM,
423     E_GOP_STATUS_GWIN_TOTALNUM,
424     E_GOP_STATUS_INIT,
425     E_GOP_STATUS_VERSION,
426     E_GOP_STATUS_MUX,
427 }EN_GOP_STATUS;
428 
429 /// GFlip Switch Gwin
430 typedef enum
431 {
432     GOP_FLIP_BY_ADDR,
433     GOP_FLIP_BY_FBID
434 }EN_GOP_GFLIP_SWITCH_TYPE;
435 
436 typedef enum
437 {
438     E_GOP_DWIN_INTR_CONTROL,
439     E_GOP_DWIN_INTR_GETINFO,
440     E_GOP_DWIN_INTR_GETINFO_TIMEOUT,
441 }EN_GOP_DWIN_INTR;
442 
443 typedef enum _GOP_CB_TYPE
444 {
445    GOP_CB_XC_REDUCE_BW,
446    GOP_CB_XC_INTERLACE,
447    GOP_CB_XC_PANEL_HSTART,
448    GOP_CB_GFX_FBFMT,
449    GOP_CB_EVENT_NOTIFY,
450    GOP_CB_DWIN_INFO,
451 }GOP_CB_TYPE;
452 
453 typedef enum _EN_GOP_SELECT_TYPE
454 {
455    EN_GOP_SEL_GOP,
456    EN_GOP_SEL_GWIN,
457    EN_GOP_SEL_FB,
458 }EN_GOP_SELECT_TYPE;
459 
460 typedef enum _EN_TRANSCLR_PROPERTY
461 {
462     EN_TRANSCLR_SET_COLOR,
463     EN_TRANSCLR_ENABLE,
464 }EN_TRANSCLR_PROPERTY;
465 
466 //-------------------------------------------------------------------------------------------------
467 //  Struct
468 //-------------------------------------------------------------------------------------------------
469 
470 ///the GOP MIXER2OP timing info
471 typedef struct DLL_PACKED
472 {
473     MS_U8 u8GOP;
474     MS_BOOL bEnable;
475 }GOP_MixerOldBlendingMode;
476 
477 typedef struct DLL_PACKED GOP_RECT_T
478 {
479     MS_U32 x;
480     MS_U32 y;
481     MS_U32 w;
482     MS_U32 h;
483 } GOP_RECT;
484 
485 typedef struct DLL_PACKED
486 {
487     MS_U32 gwin;
488     MS_U32 fbid;
489     GOP_GwinInfo gwin_info;
490     GOP_StretchInfo stretch_info;
491     EN_GOP_STRETCH_DIRECTION  dir;
492     GOP_RECT  dst_size;
493 }GOP_GWINDISPLAY_INFO, *PGOP_GWINDISPLAY_INFO;
494 
495 typedef struct DLL_PACKED
496 {
497     EN_GOP_DWIN_SEL dwinsel;   //select the dwin num
498     EN_GOP_DWIN_SRC src;
499     EN_GOP_DWIN_FMT fmt;
500     MS_PHY     addr[DWIN_SUPPORT_BUFFER];  //capture base addr
501     MS_PHY     addr1[DWIN_SUPPORT_BUFFER]; //capture addr bound
502     MS_U32       pitch;
503     GOP_RECT     rect;
504     MS_U16       framecount;
505     MS_BOOL      bInterlace;
506     MS_BOOL      bEn;
507     MS_BOOL      bWait;
508 } GOP_CAPTURE_INFO, *PGOP_CAPTURE_INFO;
509 
510 //Fade
511 typedef struct DLL_PACKED _GOP_FADE_INFO
512 {
513     MS_U32  gwin_idx;
514     MS_BOOL   bEnable;
515     EN_GOP_SET_FADE_TYPE eGwinFadeType;
516     MS_U8   u8FadeRate;
517 }GOP_FADE_INFO, *PGOP_FADE_INFO;
518 
519 /// Capture ring buffer info
520 typedef struct DLL_PACKED _GOP_RINGBUFF_INFO
521 {
522     MS_U16 Gfx_RingBuffCnt;
523     MS_U16 Gfx_CurrentIdx;
524     MS_PHY Gfx_BufAddr[0x20];
525 } GOP_RINGBUFF_INFO, *PGOP_RINGBUFF_INFO;
526 
527 typedef struct DLL_PACKED _GOP_PINPON_INFO
528 {
529     MS_PHY u64Addr0;
530     MS_PHY u64Addr1;
531 } GOP_PINPON_INFO, *PGOP_PINPON_INFO;
532 
533 typedef struct DLL_PACKED _GOP_MIXER_TIMING_INFO
534 {
535     GOP_MIXER_TIMINGTYPE mode;
536     GOP_MixerTiming pMT;
537 } GOP_MIXER_TIMING_INFO, *PGOP_MIXER_TIMING_INFO;
538 
539 typedef struct DLL_PACKED _GOP_VE_TIMING_INFO
540 {
541     GOP_VE_TIMINGTYPE mode;
542 } GOP_VE_TIMING_INFO, *PGOP_VE_TIMING_INFO;
543 
544 typedef struct DLL_PACKED _GOP_PAL_OPT
545 {
546     MS_U32 gop_idx;
547     EN_GOP_PALETTE_READTYPE paltype;
548     EN_GOP_PALETTE palSrc;
549 }GOP_PAL_OPT,*PGOP_PAL_OPT;
550 
551 typedef struct DLL_PACKED _GOP_UPDATE_INFO
552 {
553     MS_U32  gop_idx;
554     EN_GOP_UPDATE_TYPE  update_type;
555     MS_BOOL bEn;
556     MS_BOOL bSync;
557 }GOP_UPDATE_INFO,*PGOP_UPDATE_INFO;
558 
559 typedef struct DLL_PACKED _GOP_OC_FB_INFO
560 {
561     MS_PHY u64Addr;
562     EN_GOP_OC_SEL_TYPE BankMode;
563     MS_U32 enBufSize;
564 }GOP_OC_FB_INFO,*PGOP_OC_FB_INFO;
565 
566 ////////////////////////////
567 /// GOP init
568 ////////////////////////////
569 
570 typedef struct DLL_PACKED _GOP_INIT_PARAM
571 {
572     MS_U32 gop_idx;                       //specify gop init, if gop_idx == max gop , init all gop.
573     MS_U32* pInfo;            //GOP_InitInfo
574     MS_U32 u32Size;
575 }GOP_INIT_PARAM, *PGOP_INIT_PARAM;
576 
577 
578 ////////////////////////////
579 /// GOP caps
580 ////////////////////////////
581 
582 typedef struct DLL_PACKED _GOP_GETCAPS_PARAM
583 {
584     MS_U32 caps;    //EN_GOP_CAPS
585     void* pInfo;  //Return Caps info
586     MS_U32 u32Size; //Corresponding to the require caps structure size
587 }GOP_GETCAPS_PARAM, *PGOP_GETCAPS_PARAM;
588 
589 typedef struct DLL_PACKED _GOP_BUFFER_INFO
590 {
591     MS_PHY addr;
592     GOP_RECT disp_rect;
593     MS_U32   width;
594     MS_U32   height;
595     MS_U32   pitch;
596     MS_U32   fbFmt;
597     EN_GOP_FRAMEBUFFER_STRING FBString;
598 }GOP_BUFFER_INFO, *PGOP_BUFFER_INFO;
599 
600 typedef struct DLL_PACKED _GOP_SETCONFIG_PARAM
601 {
602     EN_GOP_CONFIG_TYPE cfg_type;    //EN_GOP_CONFIG_TYPE
603     void* pCfg;  //Return Caps info
604     MS_U32 u32Size; //Corresponding to the require caps structure size
605 }GOP_SETCONFIG_PARAM, *PGOP_SETCONFIG_PARAM;
606 
607 typedef struct DLL_PACKED _GOP_MISC_PARAM
608 {
609     EN_GOP_MISC_TYPE misc_type;    //EN_GOP_CONFIG_TYPE
610     MS_U32* pMISC;  //Return Caps info
611     MS_U32 u32Size; //Corresponding to the require caps structure size
612 }GOP_MISC_PARAM, *PGOP_MISC_PARAM;
613 
614 
615 ////////////////////////////
616 /// GOP Display
617 ////////////////////////////
618 
619 typedef struct DLL_PACKED _GOP_GWIN_DISPLAY_PARAM
620 {
621     MS_U32 type;                         //API VER TYPE
622     MS_U32 GwinId;                       //specify gwin.
623     MS_U32* pDisplayInfo;                //Gwin display info  - GOP_GWINDISPLAY_INFO
624     MS_U32 u32Size;                      //input param size - for error check.
625 }GOP_GWIN_DISPLAY_PARAM, *PGOP_GWIN_DISPLAY_PARAM;
626 
627 typedef struct DLL_PACKED _GOP_GWIN_BLENDING
628 {
629     MS_U32  Coef;
630     MS_BOOL bEn;
631 }GOP_GWIN_BLENDING, *PGOP_GWIN_BLENDING;
632 
633 typedef struct DLL_PACKED _GOP_GWIN_BLINK
634 {
635     MS_U32  rate;
636     MS_BOOL bEn;
637 }GOP_GWIN_BLINK, *PGOP_GWIN_BLINK;
638 
639 typedef struct DLL_PACKED _GOP_GWIN_3D_MODE
640 {
641     MS_U32 u32MainFBId;
642     MS_U32 u32SubFBId;
643     EN_GOP_3D_MODETYPE en3DMode;
644 }GOP_GWIN_3D_MODE, *PGOP_GWIN_3D_MODE;
645 
646 typedef struct DLL_PACKED _GOP_GWIN_PROPERTY_PARAM
647 {
648     MS_U32 type;                         //API VER TYPE
649     EN_GOP_GWIN_PROPERTY  en_property;
650     MS_U32 GwinId;                       //specify gwin.
651     MS_U32* pSet;                        //reserved - for further use.
652     MS_U32 u32Size;                      //input param size - for error check.
653 }GOP_GWIN_PROPERTY_PARAM, *PGOP_GWIN_PROPERTY_PARAM;
654 
655 
656 typedef struct DLL_PACKED _GOP_GWIN_MAPFBINFO_PARAM
657 {
658     MS_U32 type;                         //API VER TYPE
659     MS_U32 GwinId;                       //specify gwin.
660     MS_U32 fbid;                         //Corresponding frame buffer Id
661     MS_U32* pinfo;                       //reserved - for further use.
662     MS_U32 u32Size;                      //input param size - for error check.
663 }GOP_GWIN_MAPFBINFO_PARAM, *PGOP_GWIN_MAPFBINFO_PARAM;
664 
665 typedef struct DLL_PACKED _GOP_FB_PROPERTY_PARAM
666 {
667     MS_U32 type;                         //API VER TYPE
668     EN_GOP_FB_PROPERTY  en_property;
669     MS_U32 FBId;                       //specify gwin.
670     MS_U32* pSet;                        //reserved - for further use.
671     MS_U32 u32Size;                      //input param size - for error check.
672 }GOP_FB_PROPERTY_PARAM, *PGOP_FB_PROPERTY_PARAM;
673 
674 typedef struct DLL_PACKED _GOP_GWIN_SETWININFO_PARAM
675 {
676     MS_U32 type;                         //API VER TYPE
677     MS_U32 GwinId;                       //specify gwin.
678     MS_U32* pinfo;                       //Gwin mapping frame buffer info  - GOP_BUFFER_INFO
679     MS_U32 u32Size;                      //input param size - for error check.
680 }GOP_GWIN_SETWININFO_PARAM, *PGOP_GWIN_SETWININFO_PARAM;
681 
682 typedef struct DLL_PACKED _GOP_GWIN_WIN_ENABLE_PARAM
683 {
684     MS_U32 type;                         //API VER TYPE
685     MS_U32 GwinId;                       //specify gwin.
686     MS_U32* pEn;                       //Gwin mapping frame buffer info  - GOP_BUFFER_INFO
687     MS_U32 u32Size;                      //input param size - for error check.
688 }GOP_GWIN_WIN_ENABLE_PARAM, *PGOP_GWIN_WIN_ENABLE_PARAM;
689 
690 typedef struct DLL_PACKED _GOP_GWIN_DESTROY_PARAM
691 {
692     MS_U32 type;                         //API VER TYPE
693     MS_U32 GwinId;                       //specify gwin.
694     MS_U32* ptr;                          //reserved
695     MS_U32 u32Size;                      //reserved - input param size - for error check.
696 }GOP_GWIN_DESTROY_PARAM, *PGOP_GWIN_DESTROY_PARAM;
697 
698 ////////////////////////////
699 /// GOP Fade
700 ////////////////////////////
701 
702 typedef struct DLL_PACKED _GOP_SET_FADE_PARAM
703 {
704     MS_U32  type;      //API VER TYPE
705     EN_GOP_FADE_SET_TYPE en_type;
706     MS_U32* pSetting;
707     MS_U32 u32Size;   //Size check for different input structure.
708 }GOP_SET_FADE_PARAM, *PGOP_SET_FADE_PARAM;
709 
710 ////////////////////////////
711 /// GOP Frame Buffer
712 ////////////////////////////
713 
714 typedef struct DLL_PACKED _GOP_CREATE_BUFFER_PARAM
715 {
716     MS_U32  type;  //API VER TYPE
717     EN_GOP_CREATEBUFFER_TYPE fb_type;
718     MS_U32  fbid;
719     MS_U32* pBufInfo;
720     MS_U32 u32Size;
721 }GOP_CREATE_BUFFER_PARAM, *PGOP_CREATE_BUFFER_PARAM;
722 
723 typedef struct DLL_PACKED _GOP_DELETE_BUFFER_PARAM
724 {
725     MS_U32  type;  //API VER TYPE
726     MS_U32* pBufId;
727     MS_U32 u32Size;
728 }GOP_DELETE_BUFFER_PARAM, *PGOP_DELETE_BUFFER_PARAM;
729 
730 typedef struct DLL_PACKED _GOP_FB_INFO_PARAM
731 {
732     MS_U32  type;  //API VER TYPE
733     MS_U32  fbid;
734     MS_U32* pBufInfo;
735     MS_U32  u32Size;
736 }GOP_FB_INFO_PARAM, *PGOP_FB_INFO_PARAM;
737 
738 
739 typedef struct DLL_PACKED _GOP_CONTRAST
740 {
741     MS_U32 y;  //R - if rgb format
742     MS_U32 u;  //G - if rgb format
743     MS_U32 v;  //B - if rgb format
744 }GOP_CONTRAST, *PGOP_CONTRAST;
745 
746 typedef struct _GOP_BRIGHTNESS
747 {
748     MS_BOOL bMSB;  //Y - if yuv format
749     MS_U32  Brightness;
750 }GOP_BRIGHTNESS, *PGOP_BRIGHTNESS;
751 
752 typedef struct DLL_PACKED _GOP_TRANSCOLOR
753 {
754     EN_GOP_TRANSCLR_FMT fmt;
755     MS_U32              color;
756     MS_BOOL             bEn;
757     EN_TRANSCLR_PROPERTY transclr_property;
758 }GOP_TRANSCOLOR, *PGOP_TRANSCOLOR;
759 
760 
761 typedef struct DLL_PACKED _GOP_SET_PROPERTY_PARAM
762 {
763     MS_U32  type;      //API VER TYPE
764     EN_GOP_PROPERTY  en_pro;
765     MS_U32  gop_idx;
766     void* pSetting;
767     MS_U32 u32Size;   //Size check for different input structure.
768 }GOP_SET_PROPERTY_PARAM, *PGOP_SET_PROPERTY_PARAM;
769 
770 
771 typedef struct DLL_PACKED _GOP_SETDST_PARAM
772 {
773     MS_U32  type;      //API VER TYPE
774     MS_U32  gop_idx;
775     EN_GOP_DST_TYPE  en_dst;
776     MS_U32* pDst;      //Reserved for furthur usage
777     MS_U32 u32Size;
778 }GOP_SETDST_PARAM, *PGOP_SETDST_PARAM;
779 
780 typedef struct DLL_PACKED _GOP_GETDST_PARAM
781 {
782     MS_U32  type;      //API VER TYPE
783     MS_U32  gop_idx;
784     MS_U32* pDst;      //Reserved for furthur usage
785     MS_U32 u32Size;
786 }GOP_GETDST_PARAM, *PGOP_GETDST_PARAM;
787 
788 ///the GOP and mux setting info for utopia2.0
789 typedef struct DLL_PACKED _GOP_SETMUX
790 {
791     MS_U32 MuxCount;
792     MS_U32 gop[0xF];
793     MS_U32 mux[0xF];
794 }GOP_SETMUX, *PGOP_SETMUX;
795 
796 ///the GOP and Layer setting info for utopia2.0
797 typedef struct DLL_PACKED _GOP_SETLayer
798 {
799     MS_U32 u32LayerCount;
800     MS_U32 u32Gop[0xF];
801     MS_U32 u32Layer[0xF];
802 }GOP_SETLayer, *PGOP_SETLayer;
803 
804 typedef struct DLL_PACKED _GOP_SETMUX_PARAM
805 {
806     MS_U32  type;      //API VER TYPE
807     MS_U32* pMuxInfo;  //GOP_MuxConfig
808     MS_U32 u32Size;
809 }GOP_SETMUX_PARAM, *PGOP_SETMUX_PARAM;
810 
811 typedef struct DLL_PACKED _GOP_SETLAYER_PARAM
812 {
813     MS_U32  type;      //API VER TYPE
814     MS_U32* pLayerInfo;  //GOP_SETLayer
815     MS_U32 u32Size;
816 }GOP_SETLAYER_PARAM, *PGOP_SETLAYER_PARAM;
817 
818 typedef struct DLL_PACKED _GOP_SETMIRROR_PARAM
819 {
820     MS_U32  type;      //API VER TYPE
821     MS_U32  gop_idx;  //GOP_MuxConfig
822     EN_GOP_MIRROR_TYPE  dir;  //Mirror type
823     MS_U32  u32Size;
824 }GOP_SETMIRROR_PARAM, *PGOP_SETMIRROR_PARAM;
825 
826 typedef struct DLL_PACKED _GOP_GETMIRROR_PARAM
827 {
828     MS_U32  type;             //API VER TYPE
829     MS_U32  gop_idx;
830     EN_GOP_MIRROR_TYPE*  pdir;  //Mirror type
831     MS_U32  u32Size;
832 }GOP_GETMIRROR_PARAM, *PGOP_GETMIRROR_PARAM;
833 
834 typedef struct DLL_PACKED _GOP_TLB_Enable
835 {
836     MS_U8   gop_idx;  //GOP number
837     MS_BOOL bEn;  //enable
838     MS_PHY  u64TLBAddr;
839 }GOP_TLB_Enable, *PGOP_TLB_Enable;
840 
841 typedef struct DLL_PACKED _GOP_INIT_STATUS
842 {
843     MS_U32 gop_idx;  //In
844     MS_BOOL bInit;   //gop_idx has init or not.
845 }GOP_INIT_STATUS,*PGOP_INIT_STATUS;
846 
847 typedef struct DLL_PACKED _GOP_GWIN_NUM
848 {
849     MS_U32 gop_idx;  //In
850     MS_U32 gwin_num;   //gop_idx has init or not.
851 }GOP_GWIN_NUM,*PGOP_GWIN_NUM;
852 
853 
854 typedef struct DLL_PACKED _GOP_GET_STATUS_PARAM
855 {
856     MS_U32  type;      //API VER TYPE
857     EN_GOP_STATUS  en_status;
858     MS_U32* pStatus;      //Out - return value for input query
859     MS_U32  u32Size;
860 }GOP_GET_STATUS_PARAM, *PGOP_GET_STATUS_PARAM;
861 
862 typedef struct DLL_PACKED _GOP_MUTEX_PARAM
863 {
864     MS_U32 gop_idx;
865     EN_GOP_MUTEX en_mutex;
866     MS_U32* pSet;                        //reserved - for further use.
867     MS_U32 u32Size;
868 }GOP_MUTEX_PARAM, *PGOP_MUTEX_PARAM;
869 
870 typedef struct DLL_PACKED _GOP_SET_PINPON_PARAM
871 {
872     EN_GOP_PINPON_PROPERTY  en_pro;
873     MS_U32* pSetting;
874     MS_U32 u32Size;   //Size check for different input structure.
875 }GOP_SET_PINPON_PARAM, *PGOP_SET_PINPON_PARAM;
876 
877 ////////////////////////////
878 /// GOP Test Pattern
879 ////////////////////////////
880 typedef struct DLL_PACKED _GOP_TEST_PATTERN_PARAM
881 {
882     MS_U32 gop_idx;
883     EN_GOP_TST_PATTERN TestPatternType;
884     MS_U32 u32ARGB;
885     MS_U32 u32Size;
886 }GOP_TEST_PATTERN_PARAM, *PGOP_TEST_PATTERN_PARAM;
887 
888 typedef struct DLL_PACKED
889 {
890     MS_U32 u32GOP_idx;
891     MS_U32 u32HSize;
892     MS_U32 u32VSize;
893 }GOP_DeleteWinSize_PARAM;
894 
895 ////////////////////////////
896 /// GOP Stretch
897 ////////////////////////////
898 
899 typedef struct DLL_PACKED _GOP_STRETCH_INFO
900 {
901     GOP_RECT SrcRect;
902     GOP_RECT DstRect;
903     EN_GOP_STRETCH_HMODE enHMode;
904     EN_GOP_STRETCH_VMODE enVMode;
905     EN_GOP_STRCH_TRANSPCOLORMODE  enTColorMode;
906 }GOP_STRETCH_INFO, *PGOP_STRETCH_INFO;
907 
908 typedef struct DLL_PACKED _GOP_STRETCH_SET_PARAM
909 {
910     MS_U32 type;
911     EN_GOP_STRETCH_TYPE  enStrtchType;
912     MS_U32 gop_idx;
913     MS_U32* pStretch;   //stretch win info  - PGOP_STRETCH_INFO
914     MS_U32 u32Size;    // input structure size
915 }GOP_STRETCH_SET_PARAM, *PGOP_STRETCH_SET_PARAM;
916 
917 
918 ////////////////////////////
919 /// GFlip Clear Queue
920 ////////////////////////////
921 typedef struct DLL_PACKED _GOP_GWIN_CLEARQUEUE_INFO
922 {
923     MS_U32 GwinId;                       //specify gwin.
924 //    MS_U32* pInfo;                       //Gwin display info  - GOP_GWINDISPLAY_INFO
925 }GOP_GWIN_CLEARQUEUE_INFO,*PGOP_GWIN_CLEARQUEUE_INFO;
926 
927 
928 typedef struct DLL_PACKED _GOP_GWIN_CLEARQUEUE_PARAM
929 {
930     MS_U32 type;                         //API VER TYPE
931     MS_U32* pClearInfo;                  //GOP_GWIN_CLEARQUEUE_INFO
932     MS_U32 u32Size;                      //input param size - for error check.
933 }GOP_GWIN_CLEARQUEUE_PARAM, *PGOP_GWIN_CLEARQUEUE_PARAM;
934 
935 typedef struct DLL_PACKED _GOP_GWIN_FLIP_WIN_INFO
936 {
937     EN_GOP_GFLIP_SWITCH_TYPE enFlip;
938     MS_U32  GwinId;                       //specify gwin.
939     MS_U32  FbId;
940     MS_U32  SubFbId;
941     MS_PHY  FlipAddr;
942     MS_PHY  SubFlipAddr;
943     MS_U32  WaitTagID;
944     MS_U32* pQueueCnt;
945     MS_BOOL b3DEnable;
946 }GOP_GWIN_FLIP_WIN_INFO,*PGOP_GWIN_FLIP_WIN_INFO;
947 
948 typedef struct DLL_PACKED _GOP_GWIN_FLIP_MULTI_WIN_INFO
949 {
950     MS_U8 u8InfoCnt;
951     GOP_GWIN_FLIP_WIN_INFO FlipInfo[GOP_MULTIINFO_NUM];
952 }GOP_GWIN_FLIP_MULTI_WIN_INFO,*PGOP_GWIN_FLIP_MULTI_WIN_INFO;
953 
954 typedef struct DLL_PACKED _GOP_GWIN_GFLIP_SWITCH_GWIN_PARAM
955 {
956     MS_U32 type;                         //API VER TYPE
957     void* pFlipInfo;                  //GOP_GWIN_CLEARQUEUE_INFO
958     MS_U32 u32Size;                      //input param size - for error check.
959 }GOP_GWIN_GFLIP_SWITCH_GWIN_PARAM, *PGOP_GWIN_GFLIP_SWITCH_GWIN_PARAM;
960 
961 typedef struct DLL_PACKED _GOP_GWIN_GFLIP_SWITCH_MULTI_GWIN_PARAM
962 {
963     MS_U32 type;                         //API VER TYPE
964     void* pMultiFlipInfo;                  //GOP_GWIN_CLEARQUEUE_INFO
965     MS_U32 u32Size;                      //input param size - for error check.
966 }GOP_GWIN_GFLIP_SWITCH_MULTI_GWIN_PARAM, *PGOP_GWIN_GFLIP_SWITCH_MULTI_GWIN_PARAM;
967 
968 ////////////////////////////
969 /// GOP PINPON
970 ////////////////////////////
971 typedef struct DLL_PACKED _GOP_SET_PINPON_INFO
972 {
973     MS_U8  GwinId;
974     MS_BOOL bEnable;
975     EN_GOP_PINPON_MODE mode;
976 }GOP_SET_PINPON_INFO,*PGOP_SET_PINPON_INFO;
977 
978 ////////////////////////////
979 /// GOP Palette
980 ////////////////////////////
981 
982 typedef struct DLL_PACKED _GOP_PALETTE_CONFIG_PARAM
983 {
984     MS_U32  type;
985     MS_U32  gop_idx;
986     MS_U32* pPaletteInfo;
987     MS_U32  u32Size;
988 }GOP_PALETTE_CONFIG_PARAM, *PGOP_PALETTE_CONFIG_PARAM;
989 
990 /// GOP Palette Entry Set
991 typedef struct DLL_PACKED _GOP_PALETTE_ENTRY
992 {
993     MS_U32 gop_idx; // specify gop to update palette
994     MS_U32 start;   // start point
995     MS_U32 end;     // end point
996     MS_U32* pClut;  // Color look up table
997     EN_GOP_PALETTE_TYPE palType; //input structure size
998     EN_GOP_PALETTE palSrc;
999 }GOP_PALETTE_ENTRY, *PGOP_PALETTE_ENTRY;
1000 
1001 typedef struct DLL_PACKED _GOP_PALETTE_SET_PARAM
1002 {
1003     MS_U32 type;
1004     void* pClut;   //color look up table
1005     MS_U32 u32Size; // input structure size
1006 }GOP_PALETTE_SET_PARAM, *PGOP_PALETTE_SET_PARAM;
1007 
1008 
1009 ////////////////////////////
1010 /// GOP Dwin Capture
1011 ////////////////////////////
1012 
1013 typedef struct DLL_PACKED _GOP_DWIN_CAPTURE_PARAM
1014 {
1015     MS_U32  type;  //API VER TYPE
1016     MS_U32* pDwin;
1017     MS_U32 u32Size;
1018 }GOP_DWIN_CAPTURE_PARAM, *PGOP_DWIN_CAPTURE_PARAM;
1019 
1020 typedef struct DLL_PACKED _GOP_DWIN_CAPTURE_RINGBUFF_INFO_PARAM
1021 {
1022     MS_U32  type;  //API VER TYPE
1023     MS_U32* pRingInfo;
1024     MS_U32 u32Size;
1025 }GOP_DWIN_CAPTURE_RINGBUFF_INFO_PARAM, *PGOP_DWIN_CAPTURE_RINGBUFF_INFO_PARAM;
1026 
1027 typedef struct DLL_PACKED _GOP_DWIN_PROPERTY_PARAM
1028 {
1029     MS_U32  type;  //API VER TYPE
1030     EN_GOP_DWIN_PROPERTY  en_dwin_property;
1031     MS_U32* pDwinProp;
1032     MS_U32 u32Size;
1033 }GOP_DWIN_PROPERTY_PARAM, *PGOP_DWIN_PROPERTY_PARAM;
1034 
1035 typedef struct DLL_PACKED _GOP_MIXER_PROPERTY_PARAM
1036 {
1037     MS_U32  type;  //API VER TYPE
1038     EN_GOP_MIXER_PROPERTY  en_mixer_property;
1039     MS_U32* pMixerProp;
1040     MS_U32 u32Size;
1041 }GOP_MIXER_PROPERTY_PARAM, *PGOP_MIXER_PROPERTY_PARAM;
1042 
1043 typedef struct DLL_PACKED _GOP_VE_PROPERTY_PARAM
1044 {
1045     MS_U32  type;  //API VER TYPE
1046     EN_GOP_VE_PROPERTY  en_ve_property;
1047     MS_U32* pVEProp;
1048     MS_U32 u32Size;
1049 }GOP_VE_PROPERTY_PARAM, *PGOP_VE_PROPERTY_PARAM;
1050 
1051 typedef struct DLL_PACKED _GOP_DWIN_INTR_CTRL
1052 {
1053     MS_U32 mask;
1054     MS_U32 intrEn;
1055 }GOP_DWIN_INTR_CTRL, *PGOP_DWIN_INTR_CTRL;
1056 
1057 typedef struct DLL_PACKED _GOP_DWIN_INTR_TIME_OUT
1058 {
1059     GOP_DWinIntInfo DWinIntInfo;
1060     MS_U32 u32Timeout;
1061 }GOP_DWIN_INTR_TIME_OUT, *PGOP_DWIN_INTR_TIME_OUT;
1062 
1063 
1064 typedef struct DLL_PACKED _GOP_DWIN_INTR_STATUS_PARAM
1065 {
1066     MS_U32  type;  //API VER TYPE
1067     EN_GOP_DWIN_INTR  intr_type;
1068     MS_U32* pIntrInfo;
1069     MS_U32 u32Size;
1070 }GOP_DWIN_INTR_STATUS_PARAM, *PGOP_DWIN_INTR_STATUS_PARAM;
1071 
1072 typedef struct DLL_PACKED _GOP_SCROLL_INFO
1073 {
1074     MS_U8 u8WinId;
1075     GOP_SCROLL_TYPE type;
1076     MS_U16 u16Offset;
1077     MS_BOOL bEnable;
1078 }GOP_SCROLL_INFO, *PGOP_SCROLL_INFO;
1079 
1080 typedef struct DLL_PACKED
1081 {
1082     EN_GOP_SCROLL_TYPE scroll_type;    //EN_GOP_CONFIG_TYPE
1083     MS_U32* pCfg;  //Return Caps info
1084     MS_U32 u32Size; //Corresponding to the require caps structure size
1085 } GOP_SCROLL_PARAM, *PGOP_SCROLL_PARAM;
1086 
1087 ////////////////////////////
1088 /// GOP Write Ack Update
1089 ////////////////////////////
1090 typedef struct DLL_PACKED _GOP_UPDATE_PARAM
1091 {
1092     MS_U32  type;           //API VER TYPE
1093     MS_U32* pUpdateInfo;    //GOP_UPDATE_INFO
1094     MS_U32 u32Size;
1095 }GOP_UPDATE_PARAM, *PGOP_UPDATE_PARAM;
1096 
1097 
1098 ////////////////////////////
1099 /// GOP register call back
1100 ////////////////////////////
1101 
1102 typedef struct DLL_PACKED _GOP_REGISTER_CB_PARAM
1103 {
1104     MS_U32  type;           //API VER TYPE
1105     GOP_CB_TYPE  cb_type;   //GOP_CB_TYPE
1106     void* pCB;              //Call back pointer
1107     MS_U32 u32Size;         //reserved for error check size
1108 }GOP_REGISTER_CB_PARAM, *PGOP_REGISTER_CB_PARAM;
1109 
1110 typedef struct DLL_PACKED _GOP_SELECTION_PROPERTY_PARAM
1111 {
1112     MS_U32 type;                         //API VER TYPE
1113     EN_GOP_SELECT_TYPE sel_type;         //select gop / gwin or fb.
1114     MS_U32  id;                          //Corresponding GOP/Gwin/FB Id
1115     MS_U32* pinfo;                       //reserved - for further use.
1116     MS_U32 u32Size;                      //input param size - for error check.
1117 }GOP_SELECTION_PROPERTY_PARAM, *PGOP_SELECTION_PROPERTY_PARAM;
1118 
1119 typedef struct DLL_PACKED
1120 {
1121     MS_U32  type;           //API VER TYPE
1122     void*   pInfo;
1123     MS_U32  u32Size;         //reserved for error check size
1124 }GOP_POWERSTATE_PARAM, *PGOP_POWERSTATE_PARAM;
1125 
1126 typedef struct DLL_PACKED
1127 {
1128     MS_PHY u64Addr;
1129     MS_U16 u16Pitch;
1130     MS_U16 u16Fmt;
1131 }GOP_CBFmtInfo, *PGOP_CBFmtInfo;
1132 
1133 typedef struct DLL_PACKED
1134 {
1135     MS_U32  type;      //API VER TYPE
1136     MS_U32  gop_idx;
1137     MS_U32* pSetting;
1138     MS_U32 u32Size;   //Size check for different input structure.
1139 }GOP_INTERRUPT_PARAM, *PGOP_INTERRUPT_PARAM;
1140 //-------------------------------------------------------------------------------------------------
1141 //  Function and Variable
1142 //-------------------------------------------------------------------------------------------------
1143 //======================================================================================
1144 //  GOP Common utility
1145 //======================================================================================
1146 
1147 //======================================================================================
1148 //  GOP GWIN APIs
1149 //======================================================================================
1150 
1151 
1152 //======================================================================================
1153 //  GOP FB management
1154 //======================================================================================
1155 
1156 //======================================================================================
1157 //  GOP  CallBack Functions
1158 //======================================================================================
1159 
1160 //======================================================================================
1161 //  OC
1162 //======================================================================================
1163 
1164 //======================================================================================
1165 //  MISC
1166 //======================================================================================
1167 void Ioctl_GOP_AtExit(void* pInstance);
1168 #ifdef __cplusplus
1169 }
1170 #endif
1171 
1172 #endif
1173