Popular Content

Showing content with the highest reputation on 09/17/16 in all areas

  1. 1 point

    "blend" overlapping light?

    hi i think this is right result http://www.babylonjs-playground.com/#1WARHD#5 when you look that with natural texture that is write but if you wanna correct i thing you most be normalize last result of Light vec4 final = normalize(light1+light2+light3); http://www.babylonjs-playground.com/#1WARHD#10 http://www.babylonjs-playground.com/#1WARHD#9
  2. 1 point
    Since fun parameter is specified as any I'm pretty sure this wouldn't throw any errors: Func(fun: any): BABYLONX.ShaderBuilder { return fun(Shader.Me); } or at least you should be able to cast it with no problems: Func(fun: any): BABYLONX.ShaderBuilder { return <BABYLONX.ShaderBuilder> fun(Shader.Me); } With that said, is there a reason you're not doing something like that? Func(fun: any): BABYLONX.ShaderBuilder { fun(Shader.Me) return Shader.Me; } I'd even create an interface for the fun parameter as follows: Func(fun: (me: BABYLONX.ShaderBuilder) => void): BABYLONX.ShaderBuilder { fun(Shader.Me) return Shader.Me; }
  3. 1 point
    I know, but the return type is not specified in the .ts file so it defaults to "any" Func(fun: any) { return fun(Shader.Me); }
  4. 1 point
    I guess so, you waste a bit of time and memory. But it's pretty small.
  5. 1 point
    Oh I see, we aren't telling you which touch caused the interaction, so you don't know which touch is operating. I would open an issue for this on the github so we can track it.
  6. 1 point

    Animate ArcRotate Camera Position

    Woot ty for the easing mate, didn't knew that was so easy in BJS. I keep that for later if i have time to add it everywhere for a more "polished" result.
  7. 1 point

    ambientColor Does nothing?

    Your a boss https://pryme8.github.io/NeatFlax/Tutorial_2/ ambient Color is fixed. now if I can figure out the Canvas2d stuff >_<.
  8. 1 point

    Edit vertices of loaded mesh

    Hello, This is possible (You will learn that everything is possible with Babylon.js). here is an example: http://www.babylonjs-playground.com/#16NCF0#8 (See line 71)
  9. 1 point
    Want to try another one, @Luaacro? http://playground.babylonjs.com/#2L5DBX I believe that, once upon a time, these particles produced godrays (emitting from each particle). Maybe your excellent eyes can spot what I need to update. Any help (by anyone) would be appreciated. Sorry for the messy playground. The rad1 radiator is created near the top, and the particleSystem and godrays... near the bottom. Sorry Luaacro... I have SOME comments in PM, and some in public forum. I'm just all over the place, today.
  10. 1 point

    Low fps makes unplayable level

    Are you serious? That totally wasted my time! You could have done this in the update loop or everywhere else but not in the phaser file where nobody expect it. Really.. The icon is the Stock Browser from Android. In early versions not the best browser as far as I know. The first thing I would do: Find ways to optimize your graphics so the GPU is happy. Do you use the power of spritesheets? If yes check their dimensions. If they are larger than 512x512 you could try to split them in multiple spritesheets. And please don't put everything in a spritesheet- a large background is better loaded for itself. Do you use Canvas or WebGL ? WebGL has a bad performance on most mobiles- if available at all. Try to force Canvas. And no panic, I'm not one of the guys who tell you to use a app wrapper. I hate those backseat drivers. Sorry I can't give you more help in this topic. It's quite extensive so I hope you win some FPS somewhere. Regards George