| 1 | #ifndef __DST_COMMON_API_H__ |
|---|
| 2 | #define __DST_COMMON_API_H__ |
|---|
| 3 | |
|---|
| 4 | #include "DST_Common.h" |
|---|
| 5 | #include "DST_WindowType.h" |
|---|
| 6 | #include "DST_WindowEvent.h" |
|---|
| 7 | #include "sqlite3.h" |
|---|
| 8 | |
|---|
| 9 | #if 0 |
|---|
| 10 | ____Channel_APIs___() |
|---|
| 11 | #endif |
|---|
| 12 | |
|---|
| 13 | // ÇöÀç ä³ÎÀÇ DB »óÀÇ À§Ä¡¸¦ ¹ÝȯÇÑ´Ù. |
|---|
| 14 | // ½ÇÆÐÇϸé -1 ¼º°øÇϸé 0ÀÌ»óÀÇ ¼ö¸¦ °¡Áø´Ù. |
|---|
| 15 | int DST_GetCurrentChannelIndex(void); |
|---|
| 16 | |
|---|
| 17 | // ä³ÎÀÇ µðºñ »óÀÇ À§Ä¡¸¦ °¡Á®¿Â´Ù. |
|---|
| 18 | // ½ÇÆÐÇϸé -1 ¼º°øÇϸé 0ÀÌ»óÀÇ ¼ö¸¦ °¡Áø´Ù. |
|---|
| 19 | int DST_GetChannelIndex(DS_U8 RF, DS_U16 Minor, bool b1Seg); |
|---|
| 20 | int DST_GetChannelIndex(DS_U8 RF, DS_U16 SourceID); |
|---|
| 21 | |
|---|
| 22 | // °¡Àå ³·Àº Á֯ļö ¹øÈ£ |
|---|
| 23 | DS_U8 DST_MinRF(); |
|---|
| 24 | |
|---|
| 25 | // °¡Àå ³ôÀº Á֯ļö ¹øÈ£ |
|---|
| 26 | DS_U8 DST_MaxRF(); |
|---|
| 27 | |
|---|
| 28 | // ÇöÀçä³ÎÀÌ ¸®¸ðÄÜÀ¸·Î Á¢±Ù °¡´ÉÇÑ ´ëÇ¥ ä³ÎÀÎÁö? |
|---|
| 29 | //bool DST_IsPrimaryChannel(); |
|---|
| 30 | //bool DST_IsPrimaryChannel(DS_U8 RF, DS_U8 Minor); |
|---|
| 31 | |
|---|
| 32 | #if 0 |
|---|
| 33 | ____Image_APIs___() |
|---|
| 34 | #endif |
|---|
| 35 | |
|---|
| 36 | // À̹ÌÁöÀÇ ÆøÀ» °¡Á®¿Â´Ù. |
|---|
| 37 | int DST_GetImageWidth(DS_U8 *Image); |
|---|
| 38 | |
|---|
| 39 | // À̹ÌÁöÀÇ ³ôÀ̸¦ °¡Á®¿Â´Ù. |
|---|
| 40 | int DST_GetImageHeight(DS_U8 *Image); |
|---|
| 41 | |
|---|
| 42 | #if 0 |
|---|
| 43 | ____EPG_APIs___() |
|---|
| 44 | #endif |
|---|
| 45 | |
|---|
| 46 | // ½Ã°£ ¹üÀ§¸¦ ³ªÅ¸³»´Â ¹®ÀÚ¿À» °¡Á®¿Â´Ù. |
|---|
| 47 | int DST_GetTimeDurationString(int date, int start, DS_U32 duration, DS_U16* strText); |
|---|
| 48 | |
|---|
| 49 | // ½Ã°£À» ³ªÅ³»´Â ¹®ÀÚ¿À» °¡Á®¿Â´Ù. |
|---|
| 50 | //int DST_GetTimeString(int start, DS_U32 duration, DS_U16* strText); |
|---|
| 51 | |
|---|
| 52 | // ÇöÀç ¹æ¼ÛÁßÀÎ ÇÁ·Î±×·¥ÀÇ À̸§°ú ŸÀӵ෹À̼ÇÀ» ¹®ÀÚ¿·Î °¡Á®¿Â´Ù. |
|---|
| 53 | //void DST_GetProgramInfoString(DS_U8 *cur_info, DS_U16 *duration); |
|---|
| 54 | |
|---|
| 55 | #if 0 |
|---|
| 56 | ____Aspect_APIs___() |
|---|
| 57 | #endif |
|---|
| 58 | |
|---|
| 59 | // ÇöÀç ÇØ»óµµ Á¤º¸¸¦ °¡Á®¿Â´Ù. |
|---|
| 60 | // ¹Ýȯ°ªÀÌ 0À̸é ÇØ»óµµ Á¤º¸ ¾øÀ½ |
|---|
| 61 | int DST_GetResolutionInfo(); |
|---|
| 62 | |
|---|
| 63 | // ÇöÀç ºñµð¿À°¡ Ç÷¡ÀÌ ÁßÀÎÁö ¹ÝȯÇÑ´Ù. |
|---|
| 64 | bool DST_IsVideoPlay(); |
|---|
| 65 | |
|---|
| 66 | // ÇöÀç ¹æ¼ÛÁßÀÎ ºñµð¿À°¡ HD ¹æ¼ÛÀΰ¡? |
|---|
| 67 | bool DST_GetHDInfo(); |
|---|
| 68 | |
|---|
| 69 | #if 0 |
|---|
| 70 | ____CC_APIs___() |
|---|
| 71 | #endif |
|---|
| 72 | |
|---|
| 73 | // ÇöÀç CC º¸¿©ÁֱⰡ °¡´ÉÇѰ¡? |
|---|
| 74 | bool DST_GetCCInfo(); |
|---|
| 75 | |
|---|
| 76 | #if 0 |
|---|
| 77 | ____Date_Time_APIs___() |
|---|
| 78 | #endif |
|---|
| 79 | |
|---|
| 80 | // ¿äÀÏ ¹®ÀÚ¿À» °¡Á®¿Â´Ù. |
|---|
| 81 | // 0(ÀÏ¿äÀÏ)-6(Åä¿äÀ×) |
|---|
| 82 | DS_U16 *DST_GetDayOfWeakString(int nDayOfWeak); |
|---|
| 83 | |
|---|
| 84 | // °¢ ´ÞÀÇ À̸§À» °¡Á®¿Â´Ù. |
|---|
| 85 | // 1-12 |
|---|
| 86 | DS_U16 *DST_GetMonthOfYearString(int nMonthOfYear); |
|---|
| 87 | |
|---|
| 88 | #if 0 |
|---|
| 89 | ____Brightness_APIs___() |
|---|
| 90 | #endif |
|---|
| 91 | |
|---|
| 92 | // ¹à±â ¼³Á¤À» ÇÑ´Ù. |
|---|
| 93 | // 0(20) 1(40) 2(60) 3(80) 4(100) |
|---|
| 94 | void DST_SetBrightness(DS_U8 value); |
|---|
| 95 | |
|---|
| 96 | #if 0 |
|---|
| 97 | ____Power_APIs___() |
|---|
| 98 | #endif |
|---|
| 99 | |
|---|
| 100 | void DST_PowerDown(void); |
|---|
| 101 | |
|---|
| 102 | #if 0 |
|---|
| 103 | ____Country_APIs___() |
|---|
| 104 | #endif |
|---|
| 105 | // ±¹°¡Äڵ带 ¹®ÀÚ¿·Î ¹ÝȯÇÑ´Ù. |
|---|
| 106 | DS_U16* DST_GetISOLanguageName(DS_U8 nNumber); |
|---|
| 107 | // 32ºñÆ® ±¹°¡¸¦ 8ºñÆ® ±¹°¡ÄÚµå·Î º¯È¯ÇÑ´Ù. |
|---|
| 108 | DS_U8 DST_GetLangCodeFromISO639String(char* code); |
|---|
| 109 | DS_U8 DST_GetLangCodeFromISO639(DS_U32 iso639); |
|---|
| 110 | |
|---|
| 111 | #if 0 |
|---|
| 112 | ____String_APIs___() |
|---|
| 113 | #endif |
|---|
| 114 | |
|---|
| 115 | void strcpy16(DS_U16* des, DS_U16* src); |
|---|
| 116 | |
|---|
| 117 | int strcmp16(DS_U16* des, DS_U16* src); |
|---|
| 118 | |
|---|
| 119 | void strcpy32(DS_U32* des, DS_U32* src); |
|---|
| 120 | |
|---|
| 121 | unsigned strlen16(DS_U16 *str); |
|---|
| 122 | |
|---|
| 123 | unsigned strlen32(DS_U32 *str); |
|---|
| 124 | |
|---|
| 125 | void str2uni(DS_U16* des, char* src); |
|---|
| 126 | |
|---|
| 127 | void str232(DS_U32* des, char* src); |
|---|
| 128 | |
|---|
| 129 | void uni232(DS_U32* des, DS_U16* src); |
|---|
| 130 | |
|---|
| 131 | void strcat16(DS_U16* des, DS_U16* src); |
|---|
| 132 | void strcat16(DS_U16* des, char* src); |
|---|
| 133 | |
|---|
| 134 | #if 0 |
|---|
| 135 | ____Reset_APIs___() |
|---|
| 136 | #endif |
|---|
| 137 | #define RESET_NO 0 |
|---|
| 138 | #define RESET_USER 1 |
|---|
| 139 | |
|---|
| 140 | void DST_Reset(const char * function); |
|---|
| 141 | |
|---|
| 142 | #if 0 |
|---|
| 143 | ____Item_Scroll_APIs____() |
|---|
| 144 | #endif |
|---|
| 145 | void InitItemValues(DS_U16 listNum, DS_U16 select, DS_U16 *start, DS_U16 *cursor); |
|---|
| 146 | void ItemDecrease(DS_U16 itemNum, DS_U16 listNum, DS_U16 *start, DS_U16 *select, DS_U16 *cursor, DS_U16 step=1); |
|---|
| 147 | void ItemIncrease(DS_U16 itemNum, DS_U16 listNum, DS_U16 *start, DS_U16 *select, DS_U16 *cursor, DS_U16 step=1); |
|---|
| 148 | |
|---|
| 149 | |
|---|
| 150 | #if 0 |
|---|
| 151 | ____SQLITE___() |
|---|
| 152 | #endif |
|---|
| 153 | |
|---|
| 154 | #define USED_DB 0 |
|---|
| 155 | |
|---|
| 156 | extern char *DEFAULT_DB; |
|---|
| 157 | extern sqlite3 *DST_DB; |
|---|
| 158 | bool DST_OpenDB(sqlite3 **db, char *path); |
|---|
| 159 | int DST_GetTable(sqlite3 *db, char *query, char ***resultTable, int *col_count, int *row_count); |
|---|
| 160 | void DST_GetFieldValue(char **resultTable, int row, int totalColNum, const char* field, char **returnValue); |
|---|
| 161 | |
|---|
| 162 | |
|---|
| 163 | DS_U32 crc32 (DS_U8 *data, int len); |
|---|
| 164 | |
|---|
| 165 | #endif // __DST_COMMON_API_H__ |
|---|