• Content Count

  • Joined

  • Last visited

Everything posted by jellix

  1. Hi, I want to use one mesh several times, so I use instanced meshes of it. Now I want to 'cut' them (by applying a boolean operation 'subtract') in different ways. For that I am using CSG. Do I now have to use clones instead of instances?
  2. Hi, just a question ... isn't TypeScript ECMA 6? As you see a difference there, I seem to get something wrong. So there is 'vanilla JS' (native, simple JavaScript) that is ECMA 5, right? And then we have TypeScript that follows the conventions of ECMA 6, right? I also have heard about babel but didn't use it yet. But I thought that is another pendant to TypeScript that also has to be compiled down to vanilla JS. And I thought that the browsers don't support ECMA6 yet, because JavaScript is still ECMA 5, what is the reason why ES6 has to be compiled. Right? :-)
  3. Hi, In my example, I'm creating 1000 spheres (so it may take some seconds to build up): 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?
  4. Hi, have a look at Here you can see how the cursors position (2D) is transformed into a 3d-vector. Maybe it helps?
  5. Hi, I build up an object that is made of many identical items. Currently I'm merging all the meshes so that I have only a few drawing calls. Instead I could use instances. The advantage would be that the construction can be changed dynamically (add or remove some of the instances) and so the merged mesh doesn't have to be disposed and to be rebuild on every change. So in view of the performance: Is the rendering faster by merging meshes or by using instances?
  6. Hi, I think I've had the message, too a long time ago. Are you using a nightly build of a browser? Do you use a texture thats size aspect ratio is not 1:1 or 1:2?
  7. nice. But aren't some of you core developers working at microsoft? Wouldn't it be a solution that microsoft provides a free webserver to support this cool framework?
  8. Is it the same with cannon.js? Indeed this is a problem of many physic engines. They handle the forces of overlaying boxes like if they fall onto each other although they already are in contact for a while. And due to floatingpoint operations there are always some numbers that had to be shortened, so you get some effects that you don't wanna have. The best would be that the engine recognizes the stable position of the boxes and would then reduce the calculation down to zero until the boxes move again. Don't know if there is an algorithm for that but ... obviously it should give one.
  9. It works, thanks a lot! Excactly what I've needed. So ... how can I mark this thread as solved now? ---- And maybe one more question: Before I've used "var firstAbsolutePoint = myCurve[0].add(myMesh.getAbsolutePosition())" > Why wasn't that the correct way?
  10. Hi, how can I get the absolute positions of points of a curve? I'm getting the curve out of a Path3D Object that is a child of a Mesh. Currently I'm adding the absolute position of the mesh onto the local coordinates of the curve-points. But that's not a cool way, is it? --- Oh, just have to add some info: the mesh that contains the curve is rotated ... Maybe now it's not that easy any more :-)
  11. Good news! Will try it in the office next week (where I have a Vive). Btw.: From the customer's view, the topic 'mirroring' is always a big point. Think of an exhibition where the VR game is displayed to the audience on a second screen. They see both eyes simultaneously next to each other on a flat screen what is not the best viewing experience. So if there would be a way to show the VR-scene as a one-eye view, it would be a huge benefit.
  12. Is there a special kind of reflectivity or glossyness or metalness on it?
  13. Hi, just for the archives, if anybody finds this thread in the future: Of course the 'translate' function of the AbstractMesh-class is exactly what I was looking for. Just didn't find it because I only looked in the Vector3, the Matrix and the Mesh-class.
  14. Great work! Would love to see that as an extension so I could include it when needed. Maybe you know the module 'MoGraph' from the 3D software 'Cinema4D'? This is pretty exactly the concept of your code. And it's very useful! Also a lot of fun. An idea could be to distribute clones on vertices (or face-centers) of a mesh.
  15. When removing a Mesh by using 'dispose' I have to say that textures of the material of the mesh aren't disposed as well. I've had a case where the memory pumped up because of that. So I dispose the textures of the material first, then the material itself and afterwards I dispose the mesh.
  16. Hi, first you should look if the version of the safari browser really supports WebGL. Then to optimise the performance you should generally know how to - merge meshes to reduce the 'drawing calls' - use instances or clones when possible (plz learn about the differences) - clean up the scene: dispose meshes WITH their materials and also their textures.
  17. thanks for your kind words and your playground-links. I absolutely agree to seperate the business logic from the visualisation. That is why I initially only asked for displaying an item at a specific position between two points I'm working as a developer for over 10 years now, started with 'ActionScript1' in macromedia flash, going over to ActionScript3 (then it was Adobe Flash) and finally object oriented programming. So I like TypeScript a lot and use it also for developing the business logic. It's fun to create the classes for the lane. modules, the tray and the overall simulator and so on ... and I would say that this is getting into the right way. But for displaying the trays in the right way I just have to learn a bit more about Vector3- and Matrix-functions and maybe a bit more trigonometry and so on. By the way, the trays don't just move in one direction. There a curves in the lane an kind of Y-modules that are splitting and combining lanes also. And there are kind of 'ramps' so there are also differend y-positions. But that should not be the problem. So get to and end of this thread ... I will try to get a result to the initial question and will have a deeper look to your suggestions. Finally I also want to tell you @Wingnut that you are the guy in this forum who always keeps up the great spirit, so it'salso fun for me to write with you:) Have a nice weekend!
  18. Hey @Wingnut nice post :-) Obiously you're as exited to the task as I am. So thanks for your (very good) questions. I will describe the scenario more precisely so some things will get clear. It is a checkpoint on an airport. Surely you know the lane where you pick up a plastic tray (just a simple box without any electronics inside). There you put in some stuff like mobile phone and so on. Push it manually on the passive rolls onto the first conveyor belt. So here it goes ... straight into the "scanner" whre the tray stips. the scanner looks for some dangerous stuff in your goods. And an operator checks the taken photo for about 15 - 30 seconds while the next tray is already coming. Maybe there are 150 passengers that all have to get their stuff over the lane. and the operator has to hurry up to get everything in flow. So the only information is: - Duration for the tray-movement from one module to the next one (with some random variables). - number of passengers giving trays into the lane (with a given delay) In theroy the simulator knows every module at every time and it could 'think' about the whole scenario. But I would suggest to let every tray act for itself. It just has to know whre it is at the moment and where to go. The simulator (that knows all the modules and trays) handles each tray and looks if the subsequent module is free to let the tray go. So maybe these are some additional infos to my case :-) It is a kind of hobby project at the moment. I just started today. I u want I could push it into my github account. But at the moment there is just the question from my beginning post so I don't know if this would be nessecary.
  19. Hello again ... thanks @Wingnut for asking me to explain my question in a more detailed way. So here is what I am looking for: Let's think of a transportation lane that consists of several different modules with conveyor belts that are running in different speeds. Then there are trays that are moving along that lane. Some modules stop the trays for a short time before they are moving them forward again. And if you give a lot of trays into the lane it could happen that they get stuck because of a "traffic jam". So the goal is to simulate the floating process of the trays within a given time. So the functional requirements of the modules are: - every tray has to know the next module it has to go to. The time for that depends on the current module it is running on. - After it reaches the target it has to go to the subsequent module. - every tray has to look if the target module is free or if there is already another tray. If so it has to wait until the module is free again. Now I want to calculate how many trays can run over the lane within one hour. For that I don't want to watch the lane for an hour in realtime but to simulate the floating in a speeded up version. Because of that I need to have kind of a scrubbing bar like in a videoplayer so that I can jump to minute 45 and see the current state of the overall simulation. Therefore it's important that the animation of every tray is not 'dynamic' and running in realtime but 'predicted' with start and end values where I can jump to timepoints. That is the reason why I have a starting position of my tray and a target position of it and a 'delta'position in between related to a given time. For now I have developed the lane with modules, the trays and a simulator that manages everything. By using TypeScript it's all programmed in a clean OOP way. Actually the current task is to move the trays like written above. Hope that this explanation helps to understand my question.
  20. Hi, I want to move the yellow box towards the white sphere but only by the distance of 8 "meters". It's important that the translation should always have a "stepsize" of e.g. 8 even if I translate the yellow box again towards the white sphere. So it wouldn't be a solution to scale or divide the vectors of the red and the white sphere. Thanks for any hints!
  21. Okay, I'm gonne be more concretely: In a-frame there's a community that is developing many "components" like and It's pretty simple to develop own components and to share them. Every component is pretty well presented by showing animated gifs and nice descriptions. In Babylon I don't find such an "official sharing platform" like that. Probably there could be a documentation of how to contribute "officially" by developing custom extensions (or maybe there is a documentation that I just don't know about). In comparison I would say that babylon is more developed by the core team while a-frame gets a lot of features out of the community. As I see myself as a (very very small) spart of the babylon community, I would also like to contribute by developing some stuff. But to get back to my initial queastion: I wouldn't know how to do that correctly.
  22. Nice to see that you already thought about a teleport-function! And also nice that it will be possible to use own meshes for the controllers. By that it will be possible to play VR-games completely offline. That's pretty important for me. Recently I've build a VR-game (with another framework) where the model of the vive controller was loaded via internet. So I had to tweak the code of the framework to change the path to a locally placed model. After that my customer was able to use the game on his exhibition without the need of an internet-connection. Seems to be a little detail, but in fact it was a BIG problem :-)
  23. Hi, what is the best way to develop features or extensions for Babylon? I've found this link: And there are these extensions: And some snippets: But what is the best way to develop some additional functionality for babylon? Should I write a custom component or a snippet or should I fork the babylon repository and push into a branch?