Commit Graph

270 Commits

Author SHA1 Message Date
dogeFu 09e000266d feature : add EDITOR_NOT_IN_PREVIEW marco (#15354)
* feature : add marco for editor preview and refactor code with new marco

* refactor: replace GAME_VIEW with EDITOR_PREVIEW

* Revert "refactor: replace GAME_VIEW with EDITOR_PREVIEW"

This reverts commit e28953e9e7acbb49dc5bdc650b2ff65510d4b084.

* update cc config json

* refactor code

* remove uselese parentheses

* set ccglobal to be false

* skip global variable test case
2023-06-07 17:52:51 +08:00
zxx43 db625b6eac add reset function to call when start play (#15217)
* add reset function to call when start play

* remove clear

* reset when stop emitting

* rename param & reuse position

* call reset in stop
2023-06-02 11:53:40 +08:00
zxx43 8c7f7c8fe2 remove indirect buffer (#15227) 2023-05-30 15:45:21 +08:00
Santy-Wang d3a9b5a8b8 gradient misc optimization and add some helpful function (#15032)
* gradient misc optimization and add some helpful function

* keep old version and add new interface

* missing .

* mark as engineInternal
2023-05-24 13:59:29 +08:00
zxx43 02e092b3d9 add line positions type (#15089) 2023-05-17 17:58:02 +08:00
zxx43 98a6965042 fix particle buffer update (#14978) 2023-05-10 14:29:52 +08:00
zxx43 ff93d985b0 change bindModule to private (#14588) 2023-05-09 17:40:45 +08:00
minggo a22d16bbe6 Merge branch 'v3.7.3' into merge_v3.7.3 2023-04-24 11:26:58 +08:00
zxx43 fbbdab53a4 use getSharedMaterial to replace getMaterial (#14814)
* use getSharedMaterial to replace getMaterial

* call getSharedMaterial directly

* modify note
2023-04-19 11:07:46 +08:00
zxx43 aad941159e Fix gradient sample value when ratio is one (#14538)
* fix gradient value issue https://github.com/cocos/cocos-engine/issues/14534

* use last color when last time

* add EPSILON when repeat

* use epsilon to check last frame

* use approx

* modify input parameters
2023-04-19 10:37:25 +08:00
zxx43 ef8863e512 fix gpu particle sampling issue (#14827)
* fix gpu particle sampling issue

* revert interval

* add EPSILON to uv
2023-04-18 15:01:57 +08:00
pandamicro d9772b03c3 Merge pull request #14724 from cocos/v3.7.2
V3.7.2
2023-04-06 14:03:27 +08:00
minggo bcc581dfd7 Merge branch 'v3.7.3' into develop_merge_v3.7.3 2023-03-24 10:57:28 +08:00
PP fa51b804b5 remove and ban @ts-expect-error (#14572)
* remove ts-expect-error usage in engine

* deprecate Scheduler interface

* remove JavaScriptCore

* set some engineInternal public property as getter setter

* fix build-declaration

* fix releaseManager export name conflict

* update scriptEngineType

* fix and update some comment

* remove  w_mat, w_pos, w_rot, w_scale

* update renderer

* fix setRootBufferDirty not binding on native

* optimize floatToHashString

* mark NOTE
2023-03-20 13:48:26 +08:00
zxx43 27267a78bf check processor (#14585) 2023-03-15 15:22:33 +08:00
zxx43 687876b05c remove radian range (#14560) 2023-03-15 13:49:01 +08:00
santy-wang 0a81bf445e Merge branch 'develop' of github.com:cocos-creator/engine into v3.7.2 2023-03-13 16:51:47 +08:00
PP 386ec2895a [cherry-pick] AOT-3: optimize uinstrict code (#14315) (#14523)
* AOT: optimize uinstrict code

- mark some unstrict code as TODO
- remove some unstrict code

* update comment

* remove ts-check
# Conflicts:
#	cocos/2d/framework/deprecated.ts
#	cocos/asset/assets/image-asset.jsb.ts
#	cocos/asset/assets/texture-base.ts
#	cocos/core/assets/image-asset.ts
#	cocos/core/math/rect.ts
#	cocos/core/scene-graph/scene-globals.jsb.ts
#	cocos/native-binding/impl.ts
#	cocos/scene-graph/node-dev.ts
#	cocos/scene-graph/scene-globals.ts
#	exports/sorting.ts
2023-03-10 13:36:45 +08:00
zxx43 017b8c8667 copy old material data (#14417)
* copy old material data

* copy parameter

* just set old material to new

* remove duplicate statement
2023-03-01 16:48:07 +08:00
zxx43 c87671a5e2 Line material fix (#14118)
* remove some duplicated parameters and fix custom material of line component

* remove unused parameter

* change line extends ModelRenderer

* remove log

* remove unnecessary statements

* modify set material

* modify set material

* add @deprecated

* remove sharedMaterial type

* use getter setter instead of update

* add note

* update notes

* refine notes

* do not copy material

* add texture deprecated

* set texture

* add deprecated

* add custom material option

* set all option visible

* set tile offset value when init
2023-03-01 10:07:49 +08:00
zxx43 ae19b52072 revert rate range to infinity (#14378) 2023-02-27 18:57:55 +08:00
zxx43 360e8c54d5 V3.7.0 Particle system apis (#13952)
* add some English api

* add particle module api

* add api for particle modules

* add noise api

* add api for particle system

* add some particle system apis

* fix some apis

* modify some particle apis

* modify some api docs

* modify english translation
2023-02-02 11:41:48 +08:00
pandamicro c8d1c8e927 Improve camera API doc and fix some range declarations (#14088)
* Improve API doc for camera

* Improve inspector range declarations

* Fix typo
2023-01-18 16:14:21 +08:00
zxx43 dd0d4da609 no need to check visible for start rotation z (#14052) 2023-01-13 10:34:42 +08:00
zxx43 1136bff769 Optimize cpu calculation and remove curve gettor setter (#14008)
* optimize cpu calculation and remove curve getter setter

* revert curve

* revert rate over distance calculation
2023-01-06 11:42:38 +08:00
pandamicro afd22296b4 MIT license update and to new year 2023 (#13927)
* Cpp MIT license update and to date
* TS MIT license update and to date
2022-12-28 11:25:12 +08:00
zxx43 eb359b4667 adjust particle shader layout to avoid uniform collapsing 2022-12-13 11:12:11 +08:00
James Chen 96f17ed5ab [cpu particle] Fix passing defines with null value to material (#13780) 2022-12-09 16:56:47 +08:00
James Chen 2b4806f696 [gpu particle] Fix passing defines with null value to material (#13775) 2022-12-09 15:40:23 +08:00
iwae d74e6998e3 optimize particle and improve its performance (#13718)
* optimize particle and improve its performance

optimize particle and improve its performance

* Update particle-utils.ts

fix circulance

* fix  Circular dependency

fix  Circular dependency

* fix PR conflict

fix PR conflict
2022-12-09 10:00:22 +08:00
iwae a60a6dab6e Update Particle and Improve Performance (#13705)
add use gravity condition to improve the particle's performance
2022-12-08 11:30:29 +08:00
iwae 6d916d61a7 Update curve-range.ts (#13638)
Only create RealCurves in Editor, in order to show the Splines in Editor,
        in RunTime the RealCurves will only be created when it is in Curve mode
2022-12-06 11:23:54 +08:00
zxx43 11b201080b fix particle range (#13602)
* change some range

* change module range

* change other module range
2022-12-05 16:08:21 +08:00
zxx43 c0760f710b Particle buffer fix (#13632)
* clear buffers before create

* set length 0 to clear
2022-12-05 13:32:56 +08:00
ChiaNing 6ad7106279 fix particle system instance count when not in scene (#13616) 2022-12-02 11:41:32 +08:00
iwae 9566f88ba5 Update particle-system.ts (#13615)
Even if the rateOverDistance is 0, it will still get the world position and calculate the distance, which is waste. To improve performance, only if the rateOverDistance is above 0, it would get the world position and calculate the distance
2022-12-01 14:43:41 +08:00
zxx43 16137f0541 V3.6.2 add particle api (#13091)
* add particle api

* Apply suggestions from code review

Co-authored-by: pandamicro <lphuabin@gmail.com>
2022-11-23 19:50:05 +08:00
zxx43 10997a9bb7 init trail when enabled & fix gl error (#13397) 2022-11-23 19:38:07 +08:00
zxx43 56ce48abf8 fix limit velocity error (#13417) 2022-11-23 17:17:29 +08:00
zxx43 fe692c829f V3.6.2 gravity fix (#13092)
* fix particle gravity bug just consider node rotation

* remove statement

* use world rotation
2022-11-15 13:56:43 +08:00
minggo 7294de16f6 Adjust core import (#13230)
* fix import style of core module
* fix decorator usage
2022-11-07 15:01:31 +08:00
minggo 2e29bce9c3 Adjust serialization (#13201)
* move serialization related file into cocos/serialization
2022-11-01 17:10:12 +08:00
minggo 95a76235b6 Adjust some files (#12910)
`cocos/core` should not depend other modules, so move some files out of `cocos/core`:
- move some files from `cocos/core` to `cocos/game`
  - director.ts
  - splash-screen.ts
  - game.ts
 - move `cocos/core/root.ts` to `cocos/root.ts` as there is not better module to contain `root.ts`.
 - move `cocos/core/platform/view.ts` to `cocos/ui/view.ts` as screen related logic is moved to `cocos/core/platform/screen.ts`
2022-09-28 09:34:35 +08:00
minggo 0d7c5c8f56 move cocos/core/scene-graph to cocos/scene-graph (#12868)
* move `cocos/core/scene-graph` to `cocos/scene-graph`
* move some files in `cocos/core/components` to `cocos/scene-graph`:
  - component.ts
  - component-event-handler.ts
  - component-event-handler-schema.ts
* move some files in `cocos/core/components` to `cocos/misc`: 
  - missing-script.ts
  - model-renderer.ts
  - renderer.ts
  - camera-component.ts
* move  `cocos/core/components/system.ts` to ``cocos/core/system.ts``
2022-09-26 11:02:22 +08:00
santy-wang 7bbad4a0a4 Merge branch 'develop' of github.com:cocos-creator/engine into v3.6.1-sync 2022-09-14 11:47:58 +08:00
minggo 4261ccae76 move cocos/core/renderer to cocos/render-scene (#12729)
* move cocos/core/renderer to cocos/render-scene

* fix compiling error on native
2022-09-09 18:19:06 +08:00
zxx43 a6f7d1d2f1 V3.6.1 do gravity transform only if open gravityFactor (#12696)
* calculate gravity if have gravityFactor

* use EPSILON instead

* use approx instead
2022-09-08 10:54:19 +08:00
zxx43 9795785786 check gpu material if use cpu particle (#12707) 2022-09-08 10:15:26 +08:00
minggo 2f10f48c15 adjust some folders (#12712)
move cocos/core/asset-manager to cocos/asset/asset-manager
move cocos/core/assets to cocos/asset/assets
merge cocos/core/builtin to cocos/asset/asset-manager
2022-09-07 18:45:54 +08:00
minggo aba9fdb63f Merge branch 'v3.6.1' into merge_v3.6.1 2022-09-02 20:08:18 +08:00