Commit Graph

126 Commits

Author SHA1 Message Date
Santy-Wang 23455e75c6 sync v3.6.2 to develop
* when checking useSystemFont, the fontFamily should appear (#12684)

Co-authored-by: zhangmingzhen <mingzhen.zhang@cocos.com>

* remove rebundant useLocalData (#12640)

(cherry picked from commit 7cca98171d765a32e8732ad01b994bc10e861314)

Co-authored-by: zhangmingzhen <mingzhen.zhang@cocos.com>

* Modify version number (#12726)

Co-authored-by: liuyi <liuyi@cocos.com>

* fix builtin asset hot-reload (#12736)

* improve: move xr init to infrastructure (#12765)

* improve: move xr init to infrastructure

* fix: move initxr, before gfx

* fix: format warning

* [Feature] build template add config file (#12701)

* part of build template add config json for creating build templates and version checks for each platform

* update default template version

* add RenderQueue custom ability to classic pipeline (#12760)

* Wgpu 3.6.2 WGPU_CI_ON  (#12731)

* fix okhttp onClosing not call close (#12783)

* fix transparency, emissive and  specularfactor with dcc effects (#12798)

* reverse occlusion parameter in effects (#12795)

* [native] Fix getting wrong value of globals.ambient.skyLightingColor (#12810)

* refine:  remove unneeded code (#12808)

* feat: update meta files (#12807)

* middleware2d components rendering in native mode (#12788)

* middleware2d components rendering in native mode

* support spine/dragonbones set enable batch

* support spine rendering in batching mode

* get batcher2d instance from root

* process about with type conversion

* fix some code style

* use material hash to merge draw batch

* deal with fill z

* fix dragonbones fill z

* remove some code no used any more

* refactoring some code

* modify some code

* add free memory

* fix clang-tidy

* delete mesh-buffer-layout in destructor

* byte alignment

* [ci skip][AUTO]: Automated code generating update: 88c3a7ffdd8f95cd2c7776d6d3d6a8e36862d0bf  (#12788) (#12818)

Co-authored-by: cocos-robot <cocos-robot@cocos.com>

* simplify (#12782)

* [code] move decode32 to unpack.chunk (#12823)

* [Optimize] Cache current time for audio player in minigame. (#12814)

* Cache current time for minigames

* Save current time as private member

* Make cache time changed in callback

* update cache time to abort middle state for seek

* LogRemote upgrade configuration protocol (#12833)

* update config

* Update LogRemote.cpp

* update default_skybox and sun direction (#12811)

* fix submeshes have different instancing options (#12786)

* [ci skip][AUTO]: Automated code generating update: 3200403d155bbfbdef67440c48febc087ac1f0e5  (#12786) (#12871)

Co-authored-by: cocos-robot <cocos-robot@cocos.com>

* spine/dragonbones support batch mode in web platform (#12847)

* spine/dragonbones support batch mode in web platform

* set data hash 0 in commitMiddleware

* optimizate merge draw batch for middleware

* keep commitIA in batcher2d

* modify deprecated about commitIA

* feat: support webgpu on build-engine (#12627)

* feat: support webgpu

* build-engine-feat: support building external asset

* update

* Publish @cocos/build-engine@4.4.0-webgpu.0

* fix tiled merge draw call with sprite (#12877)

* fix:CC_ASSERT(!_currentApp.expired()); (#12844)

application has destroyed when WebSocketServer process callback in game thread

* [Bug fix] remove the player of the audio source when its clip is set to null  (#12865)

* remove player when the audio source's clip is set to null

* fix binary format spine load crash (#12894)

* wgpu: remove reinit on same object (#12799)

* add i18n for skybox (#12899)

* 3.6.2 fix android orientation crash (#12885)

* do not cache argument in global space

* add doc

* add a comment for readAttachment (#12902)

* If it is preview, replace overrideUuid  directly (#12905)

* sort the attributes (#12904)

Co-authored-by: zhangmingzhen <mingzhen.zhang@cocos.com>

* add i18n for shadow (#12906)

* update default-skybox and sun direction (#12917)

* fix:WebSocket connection to 'ws://XXXX/' failed: A server must not mask any frames that it sends to the client. (#12882)

* remove USE_BATCHING (#12892)

* fix a native middleware blend problem (#12914)

* migrated remove USE_BATCHING (#12895)

* [feature] support output bullet.wasm on  runtime based platform which the using of wasm api is more similar with weixin (#12881)

* V3.6.2 fix particle crash (#12913)

* fix native crash

* revert to pointer

* revert

* do not use reference

* if PREVIEW load cce scripts before loadProjectBundles (#12916)

* If it is preview, replace overrideUuid  directly

* load cce scripts before loadProjectBundles

* Update game.ts

* Update game.ts

* Update game.ts

* Update game.ts

* fix download url request not encode space (#12826)

* Export texture info for wgpu WGPU_CI_ON (#12926)

* export texture info for wgpu

* missing js file

* update external config

Co-authored-by: Zeqiang Li <zeqiang-li@outlook.com.com>

* fix: build-engine (#12929)

* richtext addChild optimization (#12928)

* 1. remove rebundant invoking
2. ttf canvas texture resizes to width and height as (1,1)

* remove start() and move it to onLoad()

Co-authored-by: zhangmingzhen <mingzhen.zhang@cocos.com>

* fix animation asset on inspector preview bug (#12900)

* optimize label component editing

* fix animation asset on inspector preview bug

* optimize i18n break words

* update node-executable by env (#12930)

* Fix: toDataURL is not supported for this content on iPhone 7p (#12830)

* Fix: toDataURL is not supported for this content on iPhone 7p

* Add srgb transform. (#12873)

* add localCfg.cmake (#12932)

* _loadCCEScripts  will be browser-preview only  (#12925)

* _loadCCEScripts  will be browser-preview only

* add comment

* a compatible way of data copy & default buffer size for uniform buffer (#12935)

* a compatible way of data copy & default buffer size for uniform buffer

* update external config

* [fix] default scene ambient and dirlight color (#12955)

* sync readme for wgpu (#12966)

* [fix] specularIntensity is invalid with builtin-standard (#12971)

* [native] type2writer:add FLOAT3 to Color case for compatiblity (#12962)

* V3.6.2 format return null error fix (#12973)

* add i18n for model (#12985)

* fix potential mem leak (#12995)

* [fix] camera clear flag is skybox but skybox is disabled #13589 (#12964)

* [fix] shader compilation error with CC_DEVICE_SUPPORT_FLOAT_TEXTURE=0 (#13015)

* fix import

* sync tojs to swig about middleware and 2d module (#4)

* sync tojs to swig about scene module (#5)

* remove Model::getInstancedAttributeBlock

Co-authored-by: Zhang mingzhen <32831993+Zhmz@users.noreply.github.com>
Co-authored-by: zhangmingzhen <mingzhen.zhang@cocos.com>
Co-authored-by: LIUYIa <102024185+LIUYIa@users.noreply.github.com>
Co-authored-by: liuyi <liuyi@cocos.com>
Co-authored-by: fqamic <fqamic@vip.qq.com>
Co-authored-by: minggo <nudtzxm@gmail.com>
Co-authored-by: changhua <39176194+changhua0118@users.noreply.github.com>
Co-authored-by: hyde zhou <zlzhou.sh@outlook.com>
Co-authored-by: Zeqiang Li <zeqiang-li@outlook.com>
Co-authored-by: mmyduckx <308303735@qq.com>
Co-authored-by: 徐兵 <49358166+xubing0906@users.noreply.github.com>
Co-authored-by: James Chen <dumganhar@gmail.com>
Co-authored-by: bofeng-song <bofeng.song@chukong-inc.com>
Co-authored-by: 袁炜海 <35713518+dogodo-cc@users.noreply.github.com>
Co-authored-by: zhakesi <liqiao@cocos.com>
Co-authored-by: Cocos Robot <48829427+cocos-robot@users.noreply.github.com>
Co-authored-by: cocos-robot <cocos-robot@cocos.com>
Co-authored-by: 江战 <40414978+PatriceJiang@users.noreply.github.com>
Co-authored-by: jk20012001 <jkregister@163.com>
Co-authored-by: timlyeee <43355299+timlyeee@users.noreply.github.com>
Co-authored-by: PP <chinese1236@qq.com>
Co-authored-by: oahc09 <oahc09@gmail.com>
Co-authored-by: zhangxin <59186205+chichinohaha@users.noreply.github.com>
Co-authored-by: troublemaker52025 <troublemaker52025@outlook.com>
Co-authored-by: CC9701 <73738313+CC9701@users.noreply.github.com>
Co-authored-by: zxx43 <zxx43@hotmail.com>
Co-authored-by: Zeqiang Li <zeqiang-li@outlook.com.com>
Co-authored-by: 黄森斌 <arsen2010@126.com>
Co-authored-by: ycg <1670543365@qq.com>
Co-authored-by: AFeiYA <386665678@qq.com>
Co-authored-by: zhakesi <zhakesi@foxmail.com>
2022-10-12 16:56:06 +08:00
林玮 85708b98d2 bugfix: crash when resizing on MacOS (#12816)
* fix: setCursorEnabled crash

* fix: crash when resize on MacOS
2022-09-20 14:13:39 +08:00
林玮 785fd91511 Add multi-windows support (#12243)
Co-authored-by: bofeng.song <bofeng.song@chukong-inc.com>
2022-09-15 14:55:44 +08:00
王凯鹏 902413646a Feature:add prefabInstance to prefab when it's instantiated in Editor dynamiclly (#12630)
* Feature:add prefabInstance info to prefab node when it's instantiated it in Editor dynamiclly

* fix error when editor not support addPrefabInstance
2022-09-02 10:11:47 +08:00
QingliWang 6a8f53b186 Add features for XR developement. (#12413)
* Change Android mainloop, add global config and template projects for XR.

* Change gfx/gles device's process flow for XR, working with other PRs, waiting.

* Change gfx/Vulkan device's process flow for XR, working with other PRs, waiting.

* Change render process for XR.

* Develop XR input and events.

* Develop 3D feature of UI widgets and raycast effect for XR.

Co-authored-by: fqamic <fqamic@vip.qq.com>
2022-08-22 16:34:45 +08:00
timlyeee fc4f024327 update documentations of reflection, bridge and jsbBridgeWrapper (#12097) 2022-07-21 18:31:30 +08:00
minggo 3c264e53ac Revert "V3.6.0 reflection refact (#12096)" (#12102)
This reverts commit 5b9b98f759.
2022-07-20 17:02:17 +08:00
timlyeee 5b9b98f759 V3.6.0 reflection refact (#12096)
* Move reflection and bridge implementation from jsb to native

* remove from jsb.d.ts

* remove jss
2022-07-20 15:32:15 +08:00
qiuguohua e2a7c0a1df move FileUtils namespace from jsb to native & refine doc (#11830) 2022-07-04 17:52:41 +08:00
Santy-Wang 7bc135e1c7 adjust initialization process (#11143)
* adjust init process

* fix bugs

* restructure

* tweak

* delete useless code

* fix ci

* support more platform and fix some bugs

* mark internal

* tweak

* add docs

* add docs and little adjustment

* fix bugs

* adjust decorator execute order

fix mesh error

* fix bugs

* revert some change

* revert auto-generated code

* revert auto-generated code
2022-07-03 21:16:09 +08:00
PP 1fccb90926 support audio PCMData and sampleRate getter (#11470)
* support audio buffer and sampleRate getter

update comment

update interface

update

update comment

update jsb.d.ts

update

* support getPCMData

update

support on native

support on miningame

update

* update comment

* add example doc
2022-06-29 13:39:05 +08:00
timlyeee 23e10124ef V3.6.0 get pcm buffer from audio (#11521) 2022-06-24 09:39:13 +08:00
mmyduckx ac87775262 move Downloader&zipUtils namespace from jsb to native & refine doc. (#11619)
* move namespace from jsb to native & refine doc.
2022-06-22 09:51:41 +08:00
qiuguohua 295e327e85 The FileUtils module adds exported interfaces and removes unexported … (#11282) 2022-06-17 11:09:46 +08:00
Santy-Wang e87910e851 support get component with abstract class (#11561) 2022-06-16 20:28:55 +08:00
PP 4531e180b2 publish build-engine 4.3.10 (#11478)
* publish build-engine 4.3.9 && support native API docs

update lock

update

* publish 3.4.10: fix generating comment on top level of namespace

* fix test CI
2022-06-14 22:31:51 +08:00
PP 1c737b91fd optimize Constants in engine (#11464)
* publish build-engine 4.3.5

* update build-engine deps

* remove default-constants.ts

ds

remove de

* delete consts.d.ts

* support build-const workflow

* remove EXPORT_TO_GLOBAL

* update comment

* fix interface-check

* update comment
2022-06-14 16:14:34 +08:00
PP e5511822eb support game.end() on Minigame (#11473) 2022-06-14 16:13:51 +08:00
PP d0bd6b7376 support input dispatch event for Editor (#11471)
* support input dispatch event for Editor

* update internal

* fix eslint

* fix bug

* update
2022-06-14 16:10:18 +08:00
mmyduckx 36f9f2f7a0 add comment for jsb.Downlader & jsb.zipUtils (#11185) 2022-05-24 10:19:14 +08:00
minggo 84c27e7f71 Merge branch 'v3.5.0' into v3.6.0_merge_v3.5 2022-04-24 13:41:27 +08:00
PP a3f997dfda optimize text baseline on runtime platform (#10751)
* optimize text baseline on runtime platform

* move into minigame module
2022-04-14 16:42:40 +08:00
mmyduckx 92ac6f3019 Unzip binding (#10270)
* add zipUtils manual bindings
2022-03-14 15:10:40 +08:00
pandamicro 1446db89e7 Merge branch 'v3.4.2' into v3.5.0
# Conflicts:
#	cocos/2d/components/sprite.ts
#	cocos/2d/framework/ui-transform.ts
#	cocos/2d/renderer/render-uniform-buffer.ts
#	cocos/core/builtin/effects.ts
#	cocos/core/builtin/shader-sources/glsl1.ts
#	cocos/core/builtin/shader-sources/glsl3.ts
#	cocos/core/builtin/shader-sources/glsl4.ts
#	cocos/dragon-bones/ArmatureDisplay.ts
#	cocos/spine/skeleton.ts
#	editor/assets/chunks/cc-sprite-fs-gpu.chunk
#	editor/assets/chunks/cc-sprite-fs-gpu.chunk.meta
#	editor/assets/chunks/cc-sprite-vs-gpu.chunk
#	editor/assets/chunks/cc-sprite-vs-gpu.chunk.meta
#	editor/assets/default_skybox.meta
#	editor/assets/effects/builtin-sprite-gpu.effect.meta
2022-02-28 17:24:02 +08:00
ChiaNing 8f87cbd483 useless UI_GPU code delete (#10048) 2022-01-25 19:14:41 +08:00
santy-wang 995f5b2d41 Merge branch 'v3.4.2' of https://gitlab.cocos.net/publics/engine into v3.5-merge 2022-01-24 15:56:49 +08:00
timlyeee 1ffe722c4c Rename JsbBridgeWrapper API (#9923) 2022-01-07 17:43:25 +08:00
santy-wang 7ffe1bc031 Merge branch 'v3.4.1' of https://gitlab.cocos.net/publics/engine into v3.5.0 2022-01-06 14:41:28 +08:00
timlyeee f5a6a64372 Jsb-event-handler for event dispatch (#9879) 2022-01-04 13:37:44 +08:00
PP 1f58fbff6c cache systemInfo on Cocos Play platform (#9856)
* cache systemInfo on Cocos Play platform

* resize swapChain
2021-12-23 11:40:00 +08:00
santy-wang 6cde877e5b Merge branch 'v3.4.0' of https://gitlab.cocos.net/publics/engine into v3.5.0 2021-11-24 14:23:21 +08:00
PP 1abbc90c23 compability for PROPORTIONAL_TO_FRAME container strategy (#9642)
* support isProportionalToFrame field on screen-adapter

update

stash

* rename _setupContainer to _setupCanvas

* optimize view.setResolutionPolicy()

* remove TIME_OUT to handle resize event

* compability for PROPORTIONAL_TO_FRAME container strategy

comp

update

* add NOTE

* optimize 'window-resize'

resize

* deprecate game.frame && game.container

deprecate

game

* close screen.resolutionScale interface

close

* fix npm test

* fix view unit test

* space
2021-11-11 19:24:39 +08:00
Yun Hsiao Wu c4827857ad gfx: import from pal/system-info directly (#9595) 2021-11-03 13:49:32 +08:00
PP 51989a1b76 get exactFitScreen option from game initialization (#9594)
* get exactFitScreen option from game initialization

* set HTML5 as true by default

* optimize editor scene resize
2021-11-02 10:25:49 +08:00
PP 1ed2a9833e optimize screen adaption on Web platform (#9580)
* optimize screen._init

* support WindowType on Web platform

* optimize fullscreen adaption

* optimize frame resize

update

* set timeout to handle screen event

* fix esLint

* fix esLint

* fix spelling

* fix number type

* EVENT_TIMEOUT

* fix esLint

* revert naming 'OrientationMap'
2021-11-01 00:01:49 +08:00
Yun Hsiao Wu 3669d5e00a clean up gfx module for independent compilation (#9573) 2021-10-30 22:03:17 +08:00
PP f5511f4c87 Revert "Revert "optimize interface in screen module (#9176)"" (#9490)
This reverts commit b88d4845cc.
2021-10-15 10:21:04 +08:00
pandamicro b88d4845cc Revert "optimize interface in screen module (#9176)"
This reverts commit 4735476945.
2021-10-14 23:07:23 +08:00
PP 4735476945 optimize interface in screen module (#9176)
* optimize interface in screen module

* remove DPR calculating

* update screen-adapter init

* set screen.resolutionScale as 1 by default

* remove pixelRatio getter in system-info

* remove sys.windowPixelRatio access

* optimize screen.windowSize

update

* convertToCocosScreenSpace

* change resolution-change to window-resize

* fix native UI

update

update UI

update UI

* optimize screen init

* fix subContextView

* fix root resize

* fix precision issue on Metal render end

* sys.windowPixelRatio

* use warnID

* remove screen.convertToCocosScreenSpace

* put private property and method together after public ones

* warnID

* fix landScape on CocosPlay

* fix DPR on vivo platform

* fix CI
2021-10-14 22:16:34 +08:00
PP f433551d1d support system feature query (#9428)
* support feature query in pal/system-info

* support sys.hasFeature and deprecate sys.capabilities

* remove deprecated usage

* support input feature query

update

* IMAGE_BITMAP

* INPUT_TOUCH

* WEBGL

* support WEB_VIEW, VIDEO_PLAYER, SAFE_AREA query

* rename INPUT_XXX  to EVENT_XXX

* support device-manager

update

update

update

* add NOTE

* export deviceManager from gfx

* fix circular dependency

* fix wechat devtools

update

* Revert "fix circular dependency"

This reverts commit ba8a6c0e2e4fa6b2015ae438a4c9a5da94b9bf46.

* Revert "export deviceManager from gfx"

This reverts commit 14b26ca0e3f6e0dce32c37bd668c65193dbd366f.

* Revert "support device-manager"

This reverts commit 010a910e56e1ee2fe9726629fca163fc24ed5b37.

# Conflicts:
#	pal/system-info/enum-type/feature.ts

* update

update

* use INPUT_TOUCH for sys.capabilities

* update
2021-10-14 10:29:36 +08:00
ChiaNing 24fe3ff784 UI GPU dirven add (#9378)
* uniform

* uniform buffer add

* add dummy IA

* first working version

* misc & data structure optimize

* fix webGL1 bug

* rebase on 3.3

* add maxQuadPerDrawcall by device
现在每个DC能绘制的数量由设备返回的 uniform 数量上限决定

* add index

* index bug fix

* sliced ia add(Not finish)

* change mat4 to vec4

* change stride num

* new vec4PreUI finish

* misc fix

* size & anchor dirty add

* bug fix

* add UICapacityDirty

(cherry picked from commit 417e10c8d3422363d80828539b110b93ee4d3cb1)

* static buffer cache version

(cherry picked from commit 1ffe7e7943cdf9af085aeda5ca218c3442fa9119)

* static buffer update version

(cherry picked from commit 964d9cb5b3230963b2a535acac99a34cde7eb63c)

* cache localbuffer

(cherry picked from commit 641b956def64023e0d47be66bc0c0a37ef1e9791)

* fix setPosition event & fix DS release

* weak sliced & filp tiled mode add

* fix tiled y

* fix sliced bug

* ugly but work filled type add

* update effect

* filled mode effect

* shader fix

* RenderData dirty for render data update

* revert fillbuffer

* misc fix

* support label bmfont by meshBuffer

* fix sliced bug & commit Model

* fixed some render dirty flag bug

* cut code by macro.UI_GPU_DRIVEN

* cut code by UI_GPU_DRIVEN Macro on build

* cut file by UI_GPU_DRIVEN

* I-batcher interface add

* remove render queue cache

* file name change

* file name change

* after merge

* fix for v3.4

* useless remove

* fix texture rotation

* fix sliced when atlas rotation

* useless code remove

* native bind

* update effect

* fix DynamicOffsets bind bug

* PR review fix

* effect encapsulation

* change chunk

* update effect

* update shader

* remove color in fs

* move code

* fix UBO buffer bug

* fix ubo count to 10

* fix vk bind
2021-09-29 22:32:33 +08:00
timlyeee 1c437eb87e js invoke JAVA and OSX function without reflection (#9344)
Co-authored-by: LX <codingboeuf@jizamaoxuewangdeMacBook-Air.local>
2021-09-29 14:18:35 +08:00
PP 81fdaf346d support input module (#9327)
* support input module

* don't export eventManager
2021-09-18 19:25:08 +08:00
PP ccd505ad14 migrate Engine Input Event into PAL (#9320)
* optimize input module

* rename

* fix CI

* update input-box.d.ts
2021-09-15 13:51:38 +08:00
PP 8188d27405 fix npm install (#9315) 2021-09-10 16:35:04 +08:00
Yun Hsiao Wu 79f6ec1fcf handle swapchain resize event (#9305)
* swapchain resize accept surface transform

* rt attachment should support read back
2021-09-09 16:00:02 +08:00
PP 97b3657549 migrate input module out of platform (#9296)
* migrate input module out of platform

* revert EventKeyboard.isPressed deprecation

* fix CI
2021-09-07 15:24:43 +08:00
Yun Hsiao Wu 4cf1350fe0 gfx: swapchain refactor (#9030)
* update effect.hideInEditor

* swapchain refactor

* webgl multi draw

* implicit depth/stencil format

* native adapt

* explicit resizable texture

* DrawInfo in InputAssembler

* device cached states

* sync defines

* gfx: empty backend

* update playground

* remove profiler camera

* update effect types

* fix pass.resetUniform
2021-08-31 19:40:50 +08:00
PP fcb1792ba2 fix NATIVE undefined in module 'cc/env' (#9023) 2021-07-21 09:47:57 +08:00
PP 5a4bed2379 support inputManager.frameDispatchEvents() in main loop (#8954)
* support pollEvent() API on pal/input

update

update pal

* support inputManager.frameDispatchEvents() in main loop

* remove event-manager module

* fix CI

* fix _glView

* fix CI

* fix director pause

* update for
2021-07-16 13:45:01 +08:00