Jump to content

Search the Community

Showing results for tags 'sps'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
  • Frameworks
    • Phaser 3
    • Phaser 2
    • Pixi.js
    • Babylon.js
    • Panda 2
    • melonJS
  • General
    • General Talk
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

  1. Hi, People usually love the Solid Particle System (aka SPS). Some of them sometimes ask for new features like the ability to extend it once created (coming soon) or for some extra speed by the ability to disable some computations. I made some study about how things could get faster. The short answer is : go to a lower lever in the implementation (replace the arrays of objects by typed arrays of floats, for instance), then use if possible other processes (GPU or workers). Well, here are the current status of my prototypes, so you can compare on your computer and browser the diffe
  2. When I create a hexagonal prism for SPS, it does not seem to recognize the rotation. I have been rotating the particles en masse after creation, but I gotta believe I am just doing it wrong. https://www.babylonjs-playground.com/#YI6D05#2 The "shapes" have no color. The particles are colored. To save memory, I must have "updatable" set to false. This makes my work-around harder. Advice requested.
  3. Hi Folks, Here's a SPS new feature : the particle parenting. Simple to understand : once a particle has a parent, all its rotation, position and pivot are then expressed in the parent particle local space. Simple to use : sps.initParticles = function() { for (var i = 1; i < sps.nbParticles; i++) { // declare each previous particle as the parent of the current one sps.particles[i].parentId = i - 1; } }; sps.updateParticle = function(p) { // each particle will rotate for +0.001 in the already rotated parent space particle.rotation.z += 0.001
  4. Hi! first of all, sorry if ive posted in the wrong section, but i wasnt sure if this was a bug or user error! http://www.babylonjs-playground.com/#825NJL#1 here is a playground of what im trying to do for work, please excuse the eye as i am unable to use the actual texture. its basically a wake for a boat. in the above playground the wake grows in the y axis. but I additionally need it to grow in the x axis but the buttom two verts at a faster rate than the top two. I created a updateParticleVertex function which worked perfectly using Babylon version 3.0
  5. Hi all, I am revisiting Babylonjs after a long gap. Things have changed drastically in the last year (for good ) and hence I have a newbie question, I am trying to utilise Babylonjs to give visual feedback to the user on his choice of designs. This involves creating a few hole patterns on flat plates based on an algorithm. After going through a few different approaches, I have stumbled upon the solid particle system where I could create cylinders to represent my pattern and display to the users. The cylinder locations are calculated using an external algorithm returned via ajax call and
  6. Hello All, Is it possible to use the EdgesRenderer with the Solid Particle System? I cannot get it to work with a simple box. I'm able to create a box with edges, and a SPS with lots of boxes, but not both at the same time. Any pointers would be appreciated. Here is a small section of my code. The boxes show but without any edges. var box = BABYLON.MeshBuilder.CreateBox("b", options, scene); box.enableEdgesRendering(); box.edgesWidth = 10.0; box.edgesColor = new BABYLON.Color4(0, 0, 1, 1); var mat = new BABYLON.StandardMaterial("mat1", scene); box.material =
  7. Hi folks, Here's a new light feature in the SPS : Solid Particle Pivot It's just a Vector3 (defaut Zero) associated to each solid particle in the SPS. You can set a different value to translate the current particle from its initial local position, then the particle is still rotated around this original point but no longer set on it when rotated. This is the same notion than the Translation Matrix what you could use when defining a Pivot Matrix. Example : http://jerome.bousquie.fr/BJS/test/spsPivot.html 4000 orbiting tetrahedrons around 4000 rotating boxes ... the whole syst
  8. As you know, the SPS is a standard mesh. Applying the transparency to a standard mesh leads to well-known issues ... not when visualizing other opaque or transparent meshes through this current transparent mesh, but when visualizing some parts of this transparent mesh through itself. Indeed, when passing the mesh geometry to the GPU, this one draws the mesh in the order the mesh facets are sorted in the indices array : first triangle, second one, etc ... whatever the position of the camera. The shader only respects the geometry order and this geometry is fixed. As the SPS is a standa
  9. Hi, I have a question about an SPS where not all of the particles are in use. That is, suppose the SPS has 10,000 particles in total, but at the moment only 5,000 of them are visible, and the other 5,000 are inactive, ready to be emitted. At first glance, since setParticles takes "start, end" parameters, it looks like one can save performance by keeping the 5,000 dead particles at the end of the particles array. That way you can call "setParticles(0, 5000)" and the update loop won't have to visit the dead particles. However, if I understand SPS correctly, it doesn't have any mec
  10. Hi peeps, I've already published a similar topic not a while ago, but we couldn't really reach any conclusion: http://www.html5gamedevs.com/topic/32079-sprite-occlusion-for-performance/ I have this demo: http://devel.arinnova.com/tests/3dmaps/babylon_demo/ I'm trying to get a similar forest to this three.js scene: https://www.piste.io/#!/cortina . Notice how the forest is really dense and the FPS are really good. What I've already tried without success: 1) Loading meshes instead of sprites and applying LOD mechanism resulted in very low FPS. 2) Using mesh instances inste
  11. I have a question about using an SPS to manage merged scenery - i.e. trees and bushes and whatnot. To start with, let's say that my scene has 50 trees and 50 bushes. They are all static, so rather than use instances I want to merge them all into one big "scenery" mesh. I'd like to use SPS for this, for convenience so that I don't have to manually mess with vertex lists, etc. So, I create an SPS, call "addShape(tree, 50); addShape(bush, 50);", and then I set each particle position, and I call "buildMesh()". Once created, the scenery is essentially static, so there's no need for any up
  12. Hi team, @jerome @Wingnut I have an question relative to solid particle system (SPS). I need to create a SPS composed with different buildings (.obj files). This is my code but i only can add one of them. How can I solve it? var models = function(edificios_texto) { var t = 0; var loader = new BABYLON.AssetsManager(scene); edificios_texto.forEach(function() { if(edificios_texto[t].length!=2){ return; } var edificio = loader.addMeshTask(t, "","<?=$url?>assets/modelos/",edificios_texto[t]+".obj"); var nM; //mesh of building edificio.onSucce
  13. Hello, Looking into the particle system, http://doc.babylonjs.com/overviews/solid_particle_system, Wondering... Can particles be detected with raycast? When trying this: var hitInfo = ray.intersectsMeshes(particleArray); Gets error: i.getWorldMatrix is not a function, and I see why... Tried: {isPickable: true}, same result. Guess: attempting to draw a line and use intersectsMesh()... Would that be a good approach, or other suggestions? UPDATE: dra
  14. Hi, In my example, I'm creating 1000 spheres (so it may take some seconds to build up): http://www.babylonjs-playground.com/#F0HDSP#1 Now turn the camera to the right ... whoops - balls are away It seems like the "isInFrustrum" function doesn't know the whole mesh but only the left row of the balls. The reason could be that I'm not only building one SPS but two of them where the first SPS is used as a mesh for the second SPS. Or are there any other reasons for that behavior?
  15. Just having a play around with sps, wanted to see if I could come up with a simple collision system from scratch. Only designed to work with spheres. http://www.babylonjs-playground.com/#1C2HFL http://www.babylonjs-playground.com/#1C2HFL#1 less segments http://www.babylonjs-playground.com/#1C2HFL#2 Have a play around with number of particles, size of particles and max speed. Max speed should be less than radius, too big and the particles escape.
  16. Hi all, Some weeks ago i needed to make a large tiled ground, i tried the build-in createTiledGround, but at "just" 50 x 50 tiles (2500), it starts to struggle a bit, even on a rather high-end PC. http://www.babylonjs-playground.com/#1XBLWB#168 So using the SPS and a spritesheet, i created my own; It takes a second to load, but at 500 x 500 tiles, (250.000) it runs smoothly and with 59 / 60 fps on the same PC. tile indexing example, 5x5 (25) tiles; Cols_> 0 1 2 3 4 Rows_V 4 20 21 22 23 24 3 15 16 17 18 19
  17. Hello! New Babylon user here--also new to 3D graphics and visual programming in general. I'm making a 3D visualization in Babylon and am a little stuck. Searched this forum for relevant topics but wasn't really even sure what to look for, tbh. WHAT I HAVE SO FAR A very simple visualization that uses the Solid Particle System. I add 1,000 shapes to it (flat triangles) and arrange them into 10 flat 10x10 (x, z) grids, all at the same initial y coordinate, and all initially invisible. Every few seconds, I take an invisible 10x10 grid make all 100 of its particles visible. My `
  18. Hi all, @jerome I have done a SPS whose some particles have a little transparency and others not. However, I have a problem with particles that I dont want to apply alpha because now they are not solid cube!!. When I enable alpha chanel: #spsArquetas.mesh.hasVertexAlpha = true; for the solid particle I get this result: The result that I want to get is the follow: Thanks!
  19. Hello, Is it possible to use collision detection to have an SPS avoid an area in the scene? Either this, or perhaps a large # of sprites? And @Wingnut - as I mentioned, I have a couple of simple solutions to the dynamic texture text post from more than a wekk ago, but I'm only back on the forum after a stay in the hospital at death's door with salmonella poisioning( as I waited too long for treatment - thank God my Wife is smarter than I am.) I'm pretty much recovered now, however I pretty much wish I were dead for a few days while in treatment. So I expect to finally build a scene t
  20. This topic is only for further research in the forum purpose. Just a link to this post :
  21. Hi beloved Babylonians, Well, I'm not that young compared to many of you and I'm coming straight from the 8-bit era. During this wonderful (to me) period, I spend so many hours playing on Atari Star Raiders and so many money on Star Wars arcade game (note that I could now pilot any space fighter after so much time in learning ). So I wanted to code a playabe BJS demo as a tribute to these fantastic old video games with some constraints : - must be runable in the PG : so the less external assets and only one createScene() method with plenty of comments - must run near 6
  22. Hi, I've ever been wondering if there were a way to implement easily some trailing solid particles. Well, here's a first attempt : http://www.babylonjs-playground.com/#1AGPB1 Of course, we can change the particle model : http://www.babylonjs-playground.com/#1AGPB1#1 This would be probably better done with a shader... but, you know, I'm lazy ... [EDIT] and as usual, some sinus fun : http://www.babylonjs-playground.com/#1AGPB1#3 [EDIT 2] reptilian http://www.babylonjs-playground.com/#1AGPB1#4
  23. Hey guys, I'm looking for some help with my scene, specifically the grass that I am trying to create using the SPS. An example can be found here: https://roberthucks.com/3D/tests/test5/test5.html As you can see, when you move the camera (arrow keys) the grass does not face the camera despite these settings: grassSPS.billboard = true; grassSPS.isAlwaysVisible = true; grassSPS.computeParticleRotation = false; grassSPS.computeParticleColor = false; grassSPS.computeParticleTexture = false; I have an idea as to why, it being that the way in which this project it set up the world is
  24. Little fun for the week-end : http://www.babylonjs-playground.com/#1MURF7 A dynamic texture applied on a SPS composed with many little planes stuck together. Press "SPACE" then ... BOOM The same with an opaque texture to better understand : http://www.babylonjs-playground.com/#1MURF7#1 From the line 32, you can change some parameters. example : http://www.babylonjs-playground.com/#1MURF7#2 or something more dynamic : http://www.babylonjs-playground.com/#1MURF7#4 much more : http://www.babylonjs-playground.com/#1MURF7#5 Just make sure that your mouse pointer i
  25. I have some problems with the z-Values of the faces of a cube when using the "hasVertexAlpha" on the mesh of the SPS. The bottom shows even if alpha is set to 1.0. and the other faces dont seem to be correct too. I created a material for the sps mesh and set backface culling to false. I recreated it in the playground : http://www.babylonjs-playground.com/#1WP9KY#1. Is this a bug? or am I just doing something wrong?
×
×
  • Create New...