Commit Graph

71 Commits

Author SHA1 Message Date
Cocos Robot 2cfc659779 [ci skip][AUTO]: Automated clang-format update: dc993f3861cb486d66fd4de1de2bf861b0d97b96 (#10211) (#10222)
Co-authored-by: cocos-robot <cocos-robot@cocos.com>
2022-03-02 10:17:46 +08:00
bofeng-song 141128f148 refine context2d, reduce call from native to js (#10211)
* reduce c++ callback to js
2022-03-02 09:56:00 +08:00
minggo f08555248f fix conflict 2022-01-24 17:23:03 +08:00
Yun Hsiao Wu 14a17c9d22 license upgrade (#4210) 2022-01-24 17:18:47 +08:00
minggo 1552345596 Merge branch 'v3.4.2' into v3.5.0_merge_v3.4.2
Conflicts:
	cocos/platform/android/jni/JniCocosActivity.cpp
	cocos/platform/apple/JsbBridgeWrapper.mm
	cocos/platform/ohos/jni/JniCocosAbility.cpp
	cocos/renderer/gfx-metal/MTLCommandBuffer.mm
	external/config.json
2022-01-24 15:01:01 +08:00
timlyeee 952f646bc1 remove unnecessary include (#4153) 2022-01-10 17:26:21 +08:00
minggo c4714ac283 fix compiling error 2022-01-08 11:12:16 +08:00
minggo c0bdd3c0d8 Merge branch 'v3.4.1' into merge_v3.4.1
Conflicts:
	cocos/bindings/event/EventDispatcher.cpp
	cocos/platform/android/jni/JniCocosActivity.cpp
	cocos/platform/apple/JsbBridge.mm
	cocos/platform/java/jni/JniCocosOrientationHelper.cpp
	cocos/platform/win32/CanvasRenderingContext2D-win32.cpp
2022-01-07 18:36:14 +08:00
timlyeee b54225e433 Rename JsbBridgeWrapper API (#4130) 2022-01-06 16:58:37 +08:00
timlyeee b5c40837c8 add JsbBridgeWrapper(#4125) 2022-01-04 13:38:23 +08:00
qiuguohua eeb9d5c689 Merge the code of v3.3.1 platform adaptation layer into the development branch (#3958)
* 1、Merge platform adaptation layer code into the development branch
2、It passed the test in windows and ohos system

* 1、Merge platform adaptation layer code into the development branch
2、It passed the test in windows and ohos system

* 1、Fix github compile windows error

* 1、Fix github compile windows error

* 1. Adjust the code format;
2. Fix js automatic generation binding
3. Adjust github CI compilation

* 1. Adjust the code format;
2. Fix js automatic generation binding
3. Adjust github CI compilation

* Solve mac and ios compilation failure

* Fix the problem of compilation of Windows-side simulator

* 1. Adapt the simulator to a new adaptation layer;
2. Fix the compilation warning of ios, and the implicit conversion failed;
3. Fix the mac compilation error, due to the problem of adding the link identification -all_load;

* 1.Add the isDisplayStats and setDisplayStats method to the screen interface

* Fix clang-tidy compilation warning

* Fix clang-tidy compilation warning

* Repair the emulator, compatible with mac and win

* 1、Repair detailed errors, including name modification and calling method modification
2、Delete redundant files in the template directory
3、Change the vibrate interface to vibrator
4、Fix word spelling errors

* Rename interfaces to modules

* Replace CC_ASSERT with CCASSERT

* Replace CC_ASSERT with CCASSERT

Co-authored-by: qiuguohua <>
2021-10-27 10:51:02 +08:00
timlyeee 85c52544a5 message channel between Native and JS (#3900)
* Invoke Native Function in JS
* Invoke JS function in Native
Co-authored-by: LX <codingboeuf@jizamaoxuewangdeMacBook-Air.local>
2021-09-29 14:16:30 +08:00
minggo 785b29bc0d upgrade unzip (#3679) 2021-07-02 13:57:37 +08:00
minggo 2ebe3260b4 fix clang tidy 2021-06-24 09:34:19 +08:00
minggo d8824f8a11 fix coding style (#3371) 2021-04-02 09:55:12 +08:00
Yun Hsiao Wu e0fdfef054 license upgrader 2021-02-05 14:08:22 +08:00
minggo 826babfa64 Format code (#3217) 2021-01-13 14:49:32 +08:00
kenshin 0837535633 Solve iOS14 Stroke Not Showing Problem. (#3059) 2020-11-25 09:39:53 +08:00
minggo 8a1a318893 fix iOS resolution issue (#3066) 2020-11-24 19:03:32 +08:00
cary 4db4163110 Fix text baseline on mac. (#3051) 2020-11-19 18:59:39 +08:00
cary 835b0bbb07 Fix the text baseline on native platform. (#3043) 2020-11-19 13:47:12 +08:00
minggo 74e8fb9084 cache properties of CanvasRenderingContext2D (#3007)
* cache properties of CanvasRenderingContext2D

* update data after setting callback

* do not set width/height if the value is not changed
2020-11-11 09:48:21 +08:00
coulsonwang 78a39e014a fix viewport (#2955) 2020-10-28 18:24:17 +08:00
江战 346ff97f80 [bugfix] correct utf8 encoding (#2394) (#2846)
* add UTF8LooseFix

* fix include
2020-09-28 09:39:35 +08:00
coulsonwang 995b491392 fix metal bindless texture (#2789) 2020-09-15 22:23:10 +08:00
minggo 9d9c79012b change file path (#2733) 2020-09-10 09:51:24 +08:00
minggo b08407c501 remove CC/cc prefix for file names (#2728) 2020-08-28 15:23:29 +08:00
minggo 6a17148d40 use .cpp/.h for source file suffix (#2654) 2020-07-22 15:00:28 +08:00
minggo 7efee066fd Remove duplicate (#2597) 2020-06-19 11:07:21 +08:00
minggo d381a16142 change namespace from cocos2d to cc (#2572) 2020-06-16 14:34:46 +08:00
Arnold 79fc8353d1 3dgfx add CI & cmake (#2350)
* use-cmake

* revert: enable gles3 for android

* compile with cmake only
2020-04-14 13:58:45 +08:00
minggo 9e7717c1c3 improve metal implementation (#2354) 2020-04-07 15:52:01 +08:00
coulsonwang 45ebc21ee8 add getWindow to fetch NSWindow on mac 2020-03-17 14:42:41 +08:00
coulsonwang bef04c6fc3 fix device pixel ratio (#2269)
* set device pixel ratio

* fix

* fix devicePixelRatio

* update review

* fix dpr

* remove unneeded code

* remove unneeed code

* fix

* remove getScrenScale
2020-03-17 11:29:48 +08:00
minggo b879561220 fix typo (#2266) 2020-03-11 10:21:45 +08:00
minggo 743f91a3a8 remove some unneed codes (#2182) 2020-02-25 18:33:41 +08:00
minggo 1bb0c717d0 fix macro redefine warning of platform defination (#2099) 2020-01-20 15:12:49 +08:00
Yun Hsiao Wu 5c797d64c1 fix text positioning (#2031)
* fix android text positioning

* fix windows text positioning

* fix Mac/iOS text positioning
2019-12-30 17:48:09 +08:00
minggo 66735ce3c8 fix issue that label is blurred on iOS/mac os (#1775) 2019-07-20 15:21:07 +08:00
minggo 2801316866 fix accuracy of RGB value (#1773)
* fix accuracy of RGB value

* don't have to check less than 0
2019-07-16 17:45:41 +08:00
minggo bbbe7f0b84 revert refactor of fillText and strokeTest (#1767) 2019-07-08 13:57:07 +08:00
minggo 875acde984 native returns unpremultiplied data (#1765)
* unpremultiply alpha on ios/mac

* unpremultiply alpha on Android and windows
2019-07-02 15:00:15 +08:00
Jare Guo 9eb2af918f improve convert draw y point calculate for 2d-tasks/issues/1378 (#1739) (#1764)
* improve convert draw y point calculate for 2d-tasks/issues/1378

* update comment

* improve convert draw y point calculate for android

* improve convert draw y point calculate for win32
2019-07-01 15:11:44 +08:00
Knox b8a774f018 fix outline display error (#1748) 2019-05-27 15:31:01 +08:00
leda 3944c338ec fix fillRect issues for iOS & macOS (#1682) 2019-02-20 16:16:25 +08:00
leda 1a024ce8a4 add empty Impl lineCap/setLineJoin on win32/apple (#1572) 2018-10-30 17:50:30 +08:00
leda 7c93a11905 runtime require: add context2d fill/rect method for android (#1561)
* add context2d fill & rect method for android

* workaround: draw a hairline to cover the border

* fix clear&fillrect parameter error

* add empty impl on Apple

* add empty Imple in win32

* enable "SUBPIXEL_TEXT_FLAG" flag to make the text more clear on Android

* move putImageData impl to native

* add empty _fillImageData impl on win32 & apple
2018-10-26 13:44:03 +08:00
leda ef4b74ee1e support parse font size with float value (#1543) 2018-10-12 11:49:07 +08:00
leda 19ab61b252 refine TODO & FIXME flag (#1450)
* change TODO to REFINE

* change REFINE:cjh to REFINE

* change FIXME to IDEA

* improve format
2018-08-10 12:52:00 +08:00
leda 9b775e711d fix catch font name error when ttf font name with space (#1423)
* support catch fontName with space when canvas set font

* do same above on android

* improve regex

* add empty loadFont impl for win32 platform

* correct win32 parse font info regex on win32

* add win32 support ttf when font name = font face name

* another space line for win32 platforms

* improve regex when parse font name

* fix regex error

* correct typo
2018-07-26 17:57:25 +08:00