Comments (2)
Oh, I missed that multiple ParticleData
instances can have the same particleIndex
, so it's all still one particle. I'll have to dig deeper.
from away3d.
The reason for this subdivision is mainly so multiple materials can be used within a single Mesh.
So the reason to preserve a particle's subgeometries is to allow you to set multiple materials later on. Interesting.
Edit:
When drawing objects, the gpu needs to be told to use a different program every time for every material. Unfortunately, this switch is typically very expensive and something you’d want to prevent as much as possible. To this end, Away3D sorts all the objects that need to be rendered (the so called “renderables”) primarily according to their materials so all objects with the same material will be rendered consecutively. If you’re using different material instances for things that look exactly the same, it means more programs need to be switched needlessly.
Maybe ParticleGeometryHelper
should sort the subgeometries it creates, so Away3D doesn't have to.
from away3d.
Related Issues (20)
- Please publish a new version to Haxelib HOT 1
- Problem with MD2Parser HOT 4
- Add Missing MouseEvent3D Events
- View3D project bug in shareContext HOT 2
- Bug in OrthographicLens.hx HOT 1
- How to play animation in Dae format? HOT 9
- How to lower screen resolution on mobile to render app faster? HOT 4
- Parallax Mapping. Possible? HOT 2
- FBX support? HOT 2
- [HTML5] shared context with starling doesn't work, if starling contain masks HOT 1
- [HTML5] Stage resizing issues with shared context
- Object3D.pivotPoint (bug) HOT 1
- If _billboardAxis is not null in ParticleBillboardState, the display object will disappear.
- Memory leak: material.lightPicker
- lime test flash fails HOT 1
- Starling/Away3D interoperability is broken HOT 1
- error on view3D.dispose() (i now provided my code) HOT 12
- Plans to add Away3D 4.2 Changes?
- View3D.hx - onScenePartitionChanged (scene -> should be _scene)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from away3d.