FE2D.cpp 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390
  1. #include <arm_neon.h>
  2. #include "FE2D.h"
  3. #include "FTT2D.h"
  4. #include "XMATH.h"
  5. #include "CPartAdditive2dShader.h"
  6. #include "CPolaroid2dShader.h"
  7. #include "CSheen2dShader.h"
  8. #include "CBlurVShader.h"
  9. #include "CSDFFontVisFBShader.h"
  10. #include "CKitGenShader.h"
  11. #include "CFTTCamera.h"
  12. #include "CFTTTime.h"
  13. #include "CKitGenShader.h"
  14. #include "CFTTMaterialManager.h"
  15. #include "CFTTVector32x4.h"
  16. int FE2D_iMaterialPartAdditive = -1; //003365A4
  17. int FE2D_iMaterialSDFFontVisFB = -1; //003365A8
  18. int FE2D_iMaterialSheenEffect = -1; //003365AC
  19. int FE2D_iMaterialPolaroidFade = -1; //003365B0
  20. int FE2D_iMaterialBlurVariable = -1; //003365B4
  21. int FE2D_iMaterialKitGen = -1; //003365B8
  22. //-------------------------------------------------------------------------------------------------
  23. //00148B34 //^_^
  24. void FE2D_DrawRectCol(float f0, float f1, float f2, float f3, uint a4) {
  25. LOGI("FE2D_DrawRectCol 00148B34 end");
  26. }
  27. //-------------------------------------------------------------------------------------------------
  28. //00148B6C //^_^0023A4D8
  29. void FE2D_DrawRectCol(float f0, float f1, float f2, float f3,
  30. uint a4, uint a5, uint a6, uint a7) {
  31. }
  32. //-------------------------------------------------------------------------------------------------
  33. //00148BB4 //^_^
  34. void FE2D_DrawTriangle(float f0, float f1, float f2, float f3, float f4,
  35. float f5, bool b6, uint a7) {
  36. }
  37. //-------------------------------------------------------------------------------------------------
  38. //00148BF0 //^_^
  39. void FE2D_DrawRectColRot(float f0, float f1, float f2, float f3,
  40. uint a4,
  41. float f5, float f6, float f7) {
  42. LOGI("FE2D_DrawRectColRot 00148BF0 end");
  43. }
  44. //-------------------------------------------------------------------------------------------------
  45. //00148C14 //^_^
  46. void FE2D_DrawRectColRot(float f0, float f1, float f2, float f3,
  47. uint a4, uint a5, uint a6, uint a7,
  48. float f8, float f9, float f10) {
  49. }
  50. //-------------------------------------------------------------------------------------------------
  51. //00148C38 //^_^
  52. void FE2D_DrawRectColRotAA(float f0, float f1, float f2, float f3,
  53. uint a4,
  54. float f5, float f6, float f7,
  55. TImage *pImage) {
  56. }
  57. //-------------------------------------------------------------------------------------------------
  58. //00148CE8 //^_^
  59. void FE2D_DrawTexScaleColCropRot(TImage *pImage,
  60. float f1, float f2, float f3, float f4,
  61. uint a5,
  62. float fx6, float fy7, float fWidth8, float fHeight9,
  63. float f10, float f11, float f12) {
  64. }
  65. //-------------------------------------------------------------------------------------------------
  66. //00148D44 //^_^
  67. void FE2D_DrawTex(CFTTTexture *pTexture, float f1, float f2) {
  68. }
  69. //-------------------------------------------------------------------------------------------------
  70. //00148D90 //^_^
  71. void FE2D_DrawTex(TImage *pImage, float f1, float f2) {
  72. LOGI("FE2D_DrawTex 00148D90 end");
  73. }
  74. //-------------------------------------------------------------------------------------------------
  75. //00148DD4 //^_^
  76. void FE2D_SetValidImage(TImage *pImage) {
  77. LOGI("FE2D_SetValidImage entry");
  78. LOGI("FE2D_SetValidImage end");
  79. }
  80. //-------------------------------------------------------------------------------------------------
  81. //00148DF4 //^_^
  82. void FE2D_DrawTexScale(CFTTTexture *pTexture, float f1, float f2, float f3, float f4) {
  83. }
  84. //-------------------------------------------------------------------------------------------------
  85. //00148E28 //^_^
  86. void FE2D_DrawTexScale(TImage *pImage, float f1, float f2, float f3, float f4) {
  87. LOGI("FE2D_DrawTexScale 00148E28 entry %p %.4f %.4f %.4f %.4f", pImage, f1, f2, f3, f4);
  88. LOGI("FE2D_DrawTexScale 00148E28 end");
  89. }
  90. //-------------------------------------------------------------------------------------------------
  91. //00148E58
  92. void FE2D_DrawTexCol(CFTTTexture *pTexture, float f1, float f2, uint a3) {
  93. }
  94. //-------------------------------------------------------------------------------------------------
  95. //00148EA8
  96. void FE2D_DrawTexCol(TImage *pImage, float f1, float f2, uint a3) {
  97. }
  98. //-------------------------------------------------------------------------------------------------
  99. //00148EEC
  100. void FE2D_DrawTexScaleCol(CFTTTexture *a1, float a2, float a3, float a4,
  101. float a5, uint a6) {
  102. srand(time(NULL));
  103. int ret = rand();
  104. printf("%d%d%d%d%d%d%d", a1, ret, a2, a3, a4, a5, a6);
  105. }
  106. //-------------------------------------------------------------------------------------------------
  107. //00148F20
  108. void FE2D_DrawTexScaleCol(TImage *pImage, float f1, float f2, float f3, float f4, uint a5) {
  109. }
  110. //-------------------------------------------------------------------------------------------------
  111. //00148F4C //^_^
  112. void FE2D_DrawTexScaleCol(TImage *pImage,
  113. float f1, float f2, float f3, float f4,
  114. uint a5, uint a6, uint a7, uint a8) {
  115. LOGI("FE2D_DrawTexScaleCol 00148F4C entry %p %.4f %.4f %.4f %.4f %x %x %x %x", pImage, f1, f2, f3, f4, a5, a6, a7, a8);
  116. LOGI("FE2D_DrawTexScaleCol 00148F4C end");
  117. }
  118. //-------------------------------------------------------------------------------------------------
  119. //00148F88
  120. void FE2D_DrawTexScaleCrop(CFTTTexture *pTexture,
  121. float f1, float f2, float f3, float f4,
  122. float f5, float f6, float f7, float f8) {
  123. }
  124. //-------------------------------------------------------------------------------------------------
  125. //00148FE0 //^_^
  126. void FE2D_DrawTexScaleCrop(TImage *pImage,
  127. float f1, float f2, float f3, float f4,
  128. float f5, float f6, float f7, float f8) {
  129. LOGI("FE2D_DrawTexScaleCrop 00148FE0 entry %p %.4f %.4f %.4f %.4f %.4f %.4f %.4f %.4f", pImage, f1, f2, f3, f4, f5, f6, f7, f8);
  130. LOGI("FE2D_DrawTexScaleCrop 00148FE0 end");
  131. }
  132. //-------------------------------------------------------------------------------------------------
  133. //00149034 //^_^
  134. void FE2D_SetValidImage(TImage *pImage, CFTT2D_TextureUV *pUV) {
  135. }
  136. //-------------------------------------------------------------------------------------------------
  137. //00149054
  138. void FE2D_DrawTexScaleRot(CFTTTexture *pTexture,
  139. float f1, float f2, float f3, float f4,
  140. float f5, float f6, float f7) {
  141. }
  142. //-------------------------------------------------------------------------------------------------
  143. //0014908E //^_^
  144. void FE2D_DrawTexScaleRot(TImage *pImage,
  145. float f1, float f2, float f3, float f4,
  146. float f5, float f6, float f7) {
  147. }
  148. //-------------------------------------------------------------------------------------------------
  149. //001490C8
  150. void FE2D_DrawTexColCrop(CFTTTexture *pTexture,
  151. float f1, float f2,
  152. uint a3,
  153. float f4, float f5, float f6, float f7) {
  154. }
  155. //-------------------------------------------------------------------------------------------------
  156. //00149124
  157. void FE2D_DrawTexColCrop(TImage *pImage,
  158. float f1, float f2,
  159. uint a3,
  160. float f4, float f5, float f6, float f7) {
  161. }
  162. //-------------------------------------------------------------------------------------------------
  163. //0014917C
  164. void FE2D_DrawTexScaleColCrop(CFTTTexture *pTexture,
  165. float f1, float f2, float f3, float f4,
  166. uint a5,
  167. float f6, float f7, float f8, float f9) {
  168. }
  169. //-------------------------------------------------------------------------------------------------
  170. //001491D0 //^_^
  171. void FE2D_DrawTexScaleColCrop(TImage *pImage,
  172. float f1, float f2, float f3, float f4,
  173. uint a5,
  174. float f6, float f7, float f8, float f9) {
  175. }
  176. //-------------------------------------------------------------------------------------------------
  177. //00149224
  178. void FE2D_DrawTexScaleColCrop(CFTTTexture *pTexture,
  179. float f1, float f2, float f3, float f4,
  180. uint a5, uint a6, uint a7, uint a8,
  181. float f9, float f10, float f11, float f12) {
  182. }
  183. //-------------------------------------------------------------------------------------------------
  184. //0014928C
  185. void FE2D_DrawTexScaleColCrop(TImage *pImage,
  186. float f1, float f2, float f3, float f4,
  187. uint a5, uint a6, uint a7, uint a8,
  188. float f9, float f10, float f11, float f12) {
  189. }
  190. //-------------------------------------------------------------------------------------------------
  191. //001492EC
  192. void FE2D_DrawTexScaleColRot(CFTTTexture *pTexture,
  193. float f1, float f2, float f3, float f4,
  194. uint a5,
  195. float f6, float f7, float f8) {
  196. LOGI("FE2D_DrawTexScaleColRot 001492EC entry");
  197. }
  198. //-------------------------------------------------------------------------------------------------
  199. //00149324 //^_^
  200. void FE2D_DrawTexScaleColRot(TImage *pImage, float f1, float f2, float f3, float f4, uint a5, float f6, float f7, float f8) {
  201. LOGI("FE2D_DrawTexScaleColRot 00149324 entry");
  202. }
  203. //-------------------------------------------------------------------------------------------------
  204. //0014935A //^_^
  205. void FE2D_DrawTexScaleColCropRot(TImage *pImage,
  206. float f1,
  207. float f2,
  208. float f3,
  209. float f4,
  210. uint a5,
  211. uint a6,
  212. uint a7,
  213. uint a8,
  214. float f9,
  215. float f10,
  216. float f11,
  217. float f12,
  218. float f13,
  219. float f14,
  220. float f15) {
  221. }
  222. //-------------------------------------------------------------------------------------------------
  223. //001493C4
  224. void FE2D_DrawTexScaleColCropRot(CFTTTexture *pTexture,
  225. float f1, float f2, float f3, float f4,
  226. uint a5,
  227. float f6, float f7, float f8,
  228. float f9, float f10, float f11, float f12) {
  229. }
  230. //-------------------------------------------------------------------------------------------------
  231. //00149422
  232. void FE2D_DrawLineCol(float f0, float f1, float f2, float f3, uint a4, bool b5) {
  233. FTT2D_DrawLineCol(f0, f1, f2, f3, a4);
  234. }
  235. //-------------------------------------------------------------------------------------------------
  236. //00149428
  237. void FE2D_DrawLineColX(float f0, float f1, float f2, float f3, float f4, uint a5, TImage *pImage6) {
  238. // loc_14951E
  239. }
  240. //-------------------------------------------------------------------------------------------------
  241. //00149528
  242. void FE2D_DrawDottedLineColX(float f0, float f1, float f2, float f3, float f4, float f5, uint a6) {
  243. }
  244. //-------------------------------------------------------------------------------------------------
  245. //00149628
  246. void FE2D_DrawDottedCurveLineCol(float f0, float f1, float f2, float f3, float f4, float f5, float f6, uint a7) {
  247. FE2D_DrawDottedCurveLineColX(f0, f1, f2, f3,
  248. (f0 + ((f2 - f0) * 0.5)) - ((f3 - f1) * f4),
  249. (f1 + ((f3 - f1) * 0.5)) + ((f2 - f0) * f4),
  250. f5, f6, a7);
  251. }
  252. //-------------------------------------------------------------------------------------------------
  253. //00149684
  254. void FE2D_DrawDottedCurveLineColX(float f0, float f1, float f2, float f3,
  255. float f4, float f5, float f6, float f7,
  256. uint a8) {
  257. }
  258. //-------------------------------------------------------------------------------------------------
  259. //00149788
  260. void FE2D_DrawDottedCurveLineColXS(float f0, float f1, float f2, float f3, float f4, float f5, float f6, float f7, uint a8, TImage *pImage9) {
  261. }
  262. //-------------------------------------------------------------------------------------------------
  263. //001497F0
  264. void FE2D_DrawDottedCurveLineColXXS(float f0, float f1, float f2, float f3, float f4, float f5, float f6, float f7, float f8, uint a9, TImage *pImage9) {
  265. }
  266. //-------------------------------------------------------------------------------------------------
  267. //00149A40
  268. void FE2D_DrawStarburst(float f0, float f1, int i3, float const *pf4, int const *pi5, float const *pf6, uint const *pi7) {
  269. LOGI("FE2D_DrawStarburst %.2f %.2f %d %p %p %p %p ", f0, f1, i3, pf4, pi5, pf6, pi7);
  270. }
  271. //-------------------------------------------------------------------------------------------------
  272. //00149C24
  273. void FE2D_SetBlendPartAdditive() {
  274. }
  275. //-------------------------------------------------------------------------------------------------
  276. //00149C34 //^_^
  277. void FE2D_SetBlendModulate() {
  278. }
  279. //-------------------------------------------------------------------------------------------------
  280. //00149C48
  281. void FE2D_DrawUnfilledRect(float f0, float f1, float f2, float f3,
  282. uint a4,
  283. float f5, float f6, float f7) {
  284. FTT2D_DrawUnfilledRect(f0, f1, f2, f3, a4, f5, f6, f7);
  285. }
  286. //-------------------------------------------------------------------------------------------------
  287. //00149C4C
  288. void FE2D_DrawBox(float f0, float f1, float f2, float f3, uint a4) {
  289. //00149C7C
  290. }
  291. //-------------------------------------------------------------------------------------------------
  292. //00149CF0
  293. void FE2D_DrawShadowBG(float f0, float f1, float f2, float f3,
  294. float f4,
  295. uint argb5, uint argb6) {
  296. }
  297. //-------------------------------------------------------------------------------------------------
  298. //00149DD0 //^_- 经过单元测试,功能正常
  299. void FE2D_Init() {
  300. LOGI("FE2D_Init: entry");
  301. LOGI("FE2D_Init: end");
  302. }
  303. //-------------------------------------------------------------------------------------------------
  304. //00149E98
  305. void FE2D_Shutdown() {
  306. }
  307. //-------------------------------------------------------------------------------------------------
  308. //00149F90
  309. void FE2D_SetBlendMat(int a0) {
  310. FTT2D_SetMaterial(a0);
  311. }
  312. //-------------------------------------------------------------------------------------------------
  313. //00149F94
  314. void FE2D_SetBlendAdditive() {
  315. }
  316. //-------------------------------------------------------------------------------------------------
  317. //00149FA8
  318. void FE2D_SetBlendAdditiveSimple() {
  319. }
  320. //-------------------------------------------------------------------------------------------------
  321. //00149FBC
  322. void FE2D_SetBlendSubtractiveSimple() {
  323. }
  324. //-------------------------------------------------------------------------------------------------
  325. //00149FD0
  326. void FE2D_SetBlendSubtractive() {
  327. }
  328. //-------------------------------------------------------------------------------------------------
  329. //00149FE4
  330. void FE2D_SetBlendRTTAlphaAccum() {
  331. }
  332. //-------------------------------------------------------------------------------------------------
  333. //00149FF8
  334. void FE2D_SetBlendOff() {
  335. FTT2D_SetMaterial(-1);
  336. FTT2D_SetDefaultMatBlend(EFTT2D_Blend_0);
  337. }
  338. //-------------------------------------------------------------------------------------------------
  339. //0014A00C
  340. void FE2D_SetBlendJustAlpha() {
  341. FTT2D_SetMaterial(-1);
  342. FTT2D_SetDefaultMatBlend(EFTT2D_Blend_10);
  343. }
  344. //-------------------------------------------------------------------------------------------------
  345. //0014A020
  346. void FE2D_SetBlendMultiply() {
  347. FTT2D_SetMaterial(-1);
  348. FTT2D_SetDefaultMatBlend(EFTT2D_Blend_7);
  349. }
  350. //-------------------------------------------------------------------------------------------------
  351. //0014A034
  352. void FE2D_SetBlendMultiply2x() {
  353. FTT2D_SetMaterial(-1);
  354. FTT2D_SetDefaultMatBlend(EFTT2D_Blend_9);
  355. }
  356. //-------------------------------------------------------------------------------------------------
  357. //0014A048 //^_-
  358. void FE2D_SetBlendSheenEffect() {
  359. LOGI("FE2D_SetBlendSheenEffect entry %lld", CFTTTime::s_uUnscaledTime);
  360. LOGI("FE2D_SetBlendSheenEffect end");
  361. }
  362. //-------------------------------------------------------------------------------------------------
  363. //0014A104
  364. void FE2D_SetBlendBlurVariable(float f0,
  365. float f1,
  366. EBlurVShader_Mode eMode2,
  367. CFTTTexture *pTex3) {
  368. }
  369. //-------------------------------------------------------------------------------------------------
  370. //0014A1A4
  371. void FE2D_SetBlendKitGen() {
  372. FTT2D_SetMaterial(FE2D_iMaterialKitGen);
  373. }
  374. //-------------------------------------------------------------------------------------------------
  375. //002A42A0 int64_to_float_2A42A0
  376. //第一个界面,不需要这儿的函数