FETU.cpp 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291
  1. #include <arm_neon.h>
  2. #include <arm_acle.h>
  3. #include "FETU.h"
  4. #include "CFE.h"
  5. #include "CFEImages.h"
  6. #include "CFTTTextureCache.h"
  7. #include "CMyProfile.h"
  8. #include "FE2D.h"
  9. #include "SYSCORE.h"
  10. #include "CUITileManager.h"
  11. #include "CFTTTexLoadOptions.h"
  12. #include "CFTTTextureManager.h"
  13. #include "CFTTGraphicsDevice.h"
  14. #include "CFTTColour.h"
  15. #include "CGraphicsTexLoadOptions.h"
  16. #include "FEU.h"
  17. #include "CFTTColour.h"
  18. #include "FTT2D.h"
  19. float float_35408C = 0.0;
  20. float float_354090 = 0.0;
  21. //-------------------------------------------------------------------------------------------------
  22. //0014E0B0 //^_^
  23. bool GetAtlasData(TAtlasData *pAtlasData, char const *pName) {
  24. return true;
  25. }
  26. //-------------------------------------------------------------------------------------------------
  27. //0014E008 //^_^ 单元测试通过
  28. void FETU_GetImage(TImage*a1, char const*a2, bool a3, EFTTTexFormat a4, bool a5, bool a6, bool a7)
  29. {
  30. srand(time(NULL));
  31. int ret = rand();
  32. printf("%x%x%s%x%x%x%x%x", ret, a1, a2, a3, a4, a5, a6, a7);
  33. return;
  34. }
  35. //-------------------------------------------------------------------------------------------------
  36. //0014E0C6
  37. float FETU_GetWidth(CFTTAtlasTileData *pData) {
  38. return 0.0f;
  39. }
  40. //-------------------------------------------------------------------------------------------------
  41. //0014E0D4
  42. float FETU_GetHeight(CFTTAtlasTileData *pData) {
  43. return 0.0f;
  44. }
  45. //-------------------------------------------------------------------------------------------------
  46. //0014E0E2
  47. float FETU_GetWidth(CFTTTexture *pTexture) {
  48. return 0.0f;
  49. }
  50. //-------------------------------------------------------------------------------------------------
  51. //0014E0F2
  52. float FETU_GetHeight(CFTTTexture *pTexture) {
  53. return 0.0f;
  54. }
  55. //-------------------------------------------------------------------------------------------------
  56. //0014E102 //^_^ 经过单元测试,功能正常
  57. void FETU_GetStoryImage(TImage *pImage, EStoryImage e) {
  58. LOGI("FETU_GetStoryImage 0014E102 entry");
  59. }
  60. //-------------------------------------------------------------------------------------------------
  61. //0014E124 //^_- 经过单元测试,功能正常
  62. const char *FETU_GetStoryImage(EStoryImage e, int i1) {
  63. LOGI("FETU_GetStoryImage 0014E124 %d", e);
  64. return 0;
  65. }
  66. //-------------------------------------------------------------------------------------------------
  67. //0014E244
  68. TFLCache FETU_tFLCache[40];
  69. CFTTTexture *FETU_CheckFLCache(int a1, uint a2, uint a3, bool b4, EFTTTexFormat e, TFLCache **ppCache) {
  70. LOGI("FETU_CheckFLCache 0014E244 entry");
  71. return nullptr;
  72. }
  73. //-------------------------------------------------------------------------------------------------
  74. //0014E2F0
  75. void FETU_DrawFlagCol(uint a1, uint a2, float f3, float f4, float f5, float f6) {
  76. }
  77. //-------------------------------------------------------------------------------------------------
  78. //0014E450
  79. TKitCache FETU_tKitCache[40];
  80. CFTTTexture *FETU_CheckKitCache(int a1, uint *pa2, TKitCache **ppKitCache) {
  81. LOGI("FETU_CheckKitCache 0014E450 entry");
  82. // memset(FETU_tKitCache, 0, 0x820u);
  83. return nullptr;
  84. }
  85. //-------------------------------------------------------------------------------------------------
  86. //0014E4C4
  87. CFTTTexture *FETU_GetKit(int a1, uint *pa2) {
  88. LOGI("FETU_GetKit 0014E4C4 entey");
  89. return 0;
  90. }
  91. //-------------------------------------------------------------------------------------------------
  92. //0014E508
  93. CFTTTexture *FETU_CreateKitIcon(int a1, uint *list_argb) {
  94. LOGI("FETU_CreateKitIcon 0014E508 entry");
  95. return 0;
  96. }
  97. //-------------------------------------------------------------------------------------------------
  98. //0014E7E0
  99. void FETU_BlitTextureCol(CFTTTexture *pTexture1, CFTTTexture *pTexture2,
  100. int a3, int a4, int a5, int a6,
  101. int a7, int a8, uint argb9) {
  102. LOGI("FETU_BlitTextureCol entry");
  103. // loc_14E96A
  104. }
  105. //-------------------------------------------------------------------------------------------------
  106. //0014E974
  107. CFTTTexture *FETU_CreateFlagTexture(int i0, uint u1, uint u2, EFTTTexFormat e3) {
  108. LOGI("FETU_CreateFlagTexture 0014E974 %d %d %d %d ", i0, u2, u2, e3);
  109. return nullptr;
  110. }
  111. //-------------------------------------------------------------------------------------------------
  112. //0014EA40
  113. CFTTTexture *FETU_GetFlag(int r0_ai, uint r1_ai, uint r2_au, bool r3_b, EFTTTexFormat eFormat) {
  114. //???
  115. LOGI("FETU_GetFlag 0014EA40 %d %d %d %d %d", r0_ai, r1_ai, r2_au, r3_b, eFormat);
  116. return nullptr;
  117. }
  118. //-------------------------------------------------------------------------------------------------
  119. //0014EB24
  120. CFTTTexture *FETU_GetFlag(CTeam *r0_pTeam, bool r1_b, EFTTTexFormat r2_efromat) {
  121. return FETU_GetFlag(r0_pTeam->sIndex_0, r0_pTeam->field_1C8, r0_pTeam->field_1CC, r1_b, r2_efromat);
  122. }
  123. //-------------------------------------------------------------------------------------------------
  124. //0014EB40
  125. void FETU_ClearKitCache() {
  126. LOGI("FETU_ClearKitCache 0014EB40 entry");
  127. }
  128. //-------------------------------------------------------------------------------------------------
  129. //0014EB6C
  130. void FETU_ClearFlagCache() {
  131. LOGI("FETU_ClearFlagCache 0014EB6C entry");
  132. }
  133. //-------------------------------------------------------------------------------------------------
  134. //0014EB94 //^_^
  135. void FETU_InitKitCache() {
  136. memset(FETU_tKitCache, 0, sizeof(TKitCache) * 40);
  137. }
  138. //-------------------------------------------------------------------------------------------------
  139. //0014EBAC //^_^
  140. void FETU_InitFlagCache() {
  141. memset(FETU_tFLCache, 0, sizeof(TFLCache) * 40);
  142. }
  143. //-------------------------------------------------------------------------------------------------
  144. //0014EBC4
  145. void FETU_DrawWoodBox(float f0, float f1, float f2, float f3, int d4, float f5, float f6, float f7) {
  146. LOGI("FETU_DrawWoodBox 0014EBC4 entry");
  147. }
  148. //-------------------------------------------------------------------------------------------------
  149. //0014EE08
  150. void FETU_DrawButton(float f0, float f1, float f2, float f3, int d4, float f5, float f6, float f7) {
  151. //0014EE30
  152. LOGI("FETU_DrawButton 0014EE08 entry");
  153. }
  154. //-------------------------------------------------------------------------------------------------
  155. //0014F06C
  156. void FETU_DrawBoxText(char const *pFileName, float f1, float f2, float f3, float f4, int d5, float f6, float f7, float f8) {
  157. LOGI("FETU_DrawBoxText 0014F06C %s", pFileName);
  158. }
  159. //-------------------------------------------------------------------------------------------------
  160. //0014F2B4
  161. void FETU_DrawBoxRed(float f0, float f1, float f2, float f3, int d4, float f5, float f6, float f7) {
  162. }
  163. //-------------------------------------------------------------------------------------------------
  164. //0014F2F0
  165. void FETU_DrawBoxBlue(float f0, float f1, float f2, float f3, int d4, float f5, float f6, float f7) {
  166. }
  167. //-------------------------------------------------------------------------------------------------
  168. //0014F32C
  169. void FETU_DrawBoxGreen(float f0, float f1, float f2, float f3, int d4, float f5, float f6, float f7) {
  170. }
  171. //-------------------------------------------------------------------------------------------------
  172. //0014F368 //^_- 经过单元测试,功能正常
  173. void FETU_DrawBoxRounded(float a1, float a2, float a3, float a4, int a5, float a6, float a7, float a8, int a9)
  174. {
  175. srand(time(NULL));
  176. int ret = rand();
  177. printf("%x%x%x%x%x%x%x%x%x%x", ret, a1, a2, a3, a4, a5, a6, a7, a8, a9);
  178. return;
  179. }
  180. //-------------------------------------------------------------------------------------------------
  181. //001500D8 //^_- 经过单元测试,功能正常
  182. void FETU_DrawBoxRoundedOutline(float a1, float a2, float a3, float a4, int a5,
  183. float a6, float a7, float a8, int a9) {
  184. srand(time(NULL));
  185. int ret = rand();
  186. printf("%x%x%x%x%x%x%x%x%x%x", ret, a1, a2, a3, a4, a5, a6, a7, a8, a9);
  187. return;
  188. }
  189. //-------------------------------------------------------------------------------------------------
  190. //001504F0
  191. void FETU_DrawLoadingArrow(float a1, float a2, float a3) {
  192. LOGI("FETU_DrawLoadingArrow 001504F0 entry");
  193. }
  194. //-------------------------------------------------------------------------------------------------
  195. //0015058C 经过单元测试,功能正常
  196. // 开始界面上下草坪图
  197. void FETU_RenderPitch(int i0, uint u1, int i2, bool b3) {
  198. LOGI("FETU_RenderPitch entry %d %x %d %d %d", i0, u1, i2, b3, SCR_WID);
  199. // ret_1511F0 return
  200. LOGI("FETU_RenderPitch end");
  201. }
  202. //-------------------------------------------------------------------------------------------------
  203. //0015124C
  204. void FETU_GetTeamLogo(CFTTTexture **ppTexture,
  205. int dPNGIndex,
  206. int a2_unuse,
  207. EFTTTexFormat eFormat3,
  208. CFTTTexLoadOptions const *pOption4) {
  209. LOGI("FETU_GetTeamLogo 0015124C entry");
  210. }
  211. //-------------------------------------------------------------------------------------------------
  212. //001512C4
  213. void FETU_GetTeamLogo(TImage *pImage, int a2) {
  214. }
  215. //-------------------------------------------------------------------------------------------------
  216. //00151314
  217. void FETU_DrawLevelNumberBackground(float f0, float f1, float f2, float f3,
  218. int a4, int a5,
  219. float f6, float f7, float f8,
  220. bool b9, uint a10, float f11) {
  221. }
  222. //-------------------------------------------------------------------------------------------------
  223. //00151324
  224. void FETU_DrawLevelNumber(float f0, float f1, float f2, float f3, int i4, int i5, float f6, float f7, float f8, bool b9, uint u10, TRect rect11) {
  225. LOGI("FETU_DrawLevelNumber %.2f %.2f %.2f %.2f %d %d %.2f %.2f %.2f %d %d %.2f %.2f %.2f %.2f",
  226. f0, f1, f2, f3,
  227. i4, i5,
  228. f6, f7, f8, b9,
  229. u10,
  230. rect11.fx_0, rect11.fy_4, rect11.fWidth_8, rect11.fHeight_C);
  231. }
  232. //-------------------------------------------------------------------------------------------------
  233. //00151770
  234. void FETU_DrawObjectiveBox(float f0, float f1, float f2, float f3, int i4, int i5, int *pi6, float f7, float f8, float f9, float f10, bool b11, EMedal_Type e11) {
  235. LOGI("FETU_DrawObjectiveBox 00151770 %.2f %.2f %.2f %.2f %d %d %p %.2f %.2f %.2f %.2f %d %d",
  236. f0, f1, f2, f3, i4, i5, pi6, f7, f8, f9, f10, b11, e11);
  237. }
  238. //-------------------------------------------------------------------------------------------------
  239. //00151E98
  240. void FETU_DrawSingleMedal(float f0, float f1, float f2, EMedal_Type e3, bool b4, bool b5, uint u6, int i7, float f8, bool b9) {
  241. LOGI("FETU_DrawSingleMedal 00151E98 %.2f %.2f %.2f %d %d %d %d %d %.2f %d",
  242. f0, f1, f2, e3, b4, b5, u6, i7, f8, b9);
  243. }
  244. //-------------------------------------------------------------------------------------------------
  245. //00152194
  246. void FETU_DrawClock(float f0, float f1, float f2, bool b3, bool b4) {
  247. LOGI("FETU_DrawClock %.2f %.2f %.2f", f0, f1, f2);
  248. }
  249. //-------------------------------------------------------------------------------------------------
  250. /*
  251. 19, 0x76655b94 in ?? () 0014EB94 FETU_InitKitCache()
  252. 20, 0x76655bac in ?? () 0014EBAC FETU_InitFlagCache()
  253. 1, 0x76655008 in ?? () 0014E008 FETU_GetImage(TImage *,char const*,bool,EFTTTexFormat,bool,bool,bool)
  254. 30, 0x7665758c in ?? () 0015058C FETU_RenderPitch(int,uint,int,bool)
  255. 0014e7e0 FETU_BlitTextureCo
  256. 0014e244 FETU_CheckFLCach
  257. 0014e450 FETU_CheckKitCach
  258. 0014eb6c FETU_ClearFlagCach
  259. 0014eb40 FETU_ClearKitCach
  260. 0014e974 FETU_CreateFlagTexture
  261. 0014e508 FETU_CreateKitIco
  262. 0014f368 FETU_DrawBoxRounded
  263. 001500d8 FETU_DrawBoxRoundedOutline
  264. 00152194 FETU_DrawClock
  265. 00151324 FETU_DrawLevelNumber
  266. 001504f0 FETU_DrawLoadingArro
  267. 00151770 FETU_DrawObjectiveBox
  268. 00151e98 FETU_DrawSingleMedal
  269. 0014ebc4 FETU_DrawWoodBo
  270. 0014ea40 FETU_GetFlag
  271. 0014e008 FETU_GetImag
  272. 0014e4c4 FETU_GetKi
  273. 0014e102 FETU_GetStoryImag
  274. 0014e124 FETU_GetStoryImage
  275. 0015124c FETU_GetTeamLog
  276. 0015058c FETU_RenderPitch
  277. 0014ebac FETU_InitFlagCach
  278. 0014eb94 FETU_InitKitCach
  279. */