Jump to content

Search the Community

Showing results for tags 'lights'.

  • 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

Found 23 results

  1. Hi guys, I've been making a game project recently which I wanted to add some relatively basic lighting effects to. I really struggled with anything I found online and basically everything seems broken. After researching alpha masking and texture rendering at runtime I've come up with a demo which finally puts the entire piece together so people can use it. I really hope this makes a difference to peoples learning experience, their games and their appreciation for PixiJS. I welcome any mods to the pen as I'm not the best at writing super hot JS, I just want it to work. The d
  2. Hi, I was doing some tests with BabylonJS and while checking out the lights I found that the spotlight goes through some objects but not others? Is this a bug of babylonjs or something I've done? Example can be seen here, the spotlight hits the top cube/box/rectangle and passes through to the floor and smaller cubes/boxes/rectrangles. http://dev.aftc.co.uk/WebGL/BabylonJS/06_Lights2 Ideas? Thanks D
  3. Hi gang! Here begins the never-ending thread... about babylon.js tutorials. Post freely in here - about any tutorial. Here in the early days of this thread, I would like us to talk mostly about 'the basic series' of tutorials: https://github.com/BabylonJS/Babylon.js/wiki/Tutorials We will need input from everyone. We will be doing test translations. We will be collecting pictures that are perfect for the tutorials. We will be collecting great ideas and always looking for ways to make things clear for all. Comment freely. Here are some early things that we are wanting your commen
  4. Looks like applying the following shadowGenerator.getShadowMap().refreshRate = BABYLON.RenderTargetTexture.REFRESHRATE_RENDER_ONCE; light.autoUpdateExtends = false; in combination with shadowGenerator.useContactHardeningShadow = true; doesn't really do anything: the frame rate drop is massive and remains low. I can't vouch for other properties (e.i. shadowGenerator.usePercentageCloserFiltering) as the frame rate doesn't seem to get affected.
  5. Hey everyone, I'm back with yet another question. I have a scene that contains a labyrinth with walls and ground tiles and a pointLight: //light var light = new BABYLON.PointLight("light", new BABYLON.Vector3(0, 0, 0), scene); light.intensity = 1.9; light.range = 20; light.diffuse = new BABYLON.Color3(150/255,150/255,150/255); light.specular = new BABYLON.Color3(180/255,150/255,100/255); As you'll see in the following screenshot (sorry no playground because I'd have to copy a lot of code from many different files), the light escapes through the walls - planes.
  6. I am trying to find out about the implementation of lights and normal- or bumpmapping in Phaser. I found some older posts here and on other sites about dynamic lighting and bump mapping but if I interpret the information given, the lighting features have been experimented with in earlier features, but were discarded in later versions. Can anyone tell me if dynamic lighting and bumpmapping is on the official Phaser roadmap and when to expect it. I know that Pixijs has a special branch that has lighting features and there is a pixijs plugin for lights. Does anyone know of a Phaser plug
  7. Hi guys. I have a little problem, and I'm confused ) Let me explain what I have to do, and what I did, and please tell me where I wrong. I did a ground with multiple textures, for this, I used a shader. All clear. Now I have to add shadows, but first I tryed to understand how it works lights in shader, and this is almost clear . Here you have a wonderfull playground, where I try to show you what happened to me. The light is draggable. http://www.babylonjs-playground.com/#1TWMLX So I have a light which rays shines the ground, but I want that the darkness of light to be more black. The
  8. How would I reference a light imported from Blender? I'm appending a scene with a directional light (sun) as follows: BABYLON.SceneLoader.Append("", "museumScene.babylon", scene); Now, if I add a "fire when fully imported" function to return the array of lights in the scene, I see my sun in the console just as I'd expect: BABYLON.SceneLoader.Append("", "museumScene.babylon", scene, console.log(scene.lights)); However, if I try to reference the sun in the normal way, I only get null: BABYLON.SceneLoader.Append("", "museumScene.babylon", scene, console.log(scene.getLightByName(
  9. Hey all, Sorry to bother you with yet another shadow related question, but i'v ran into trouble. I'm doing some tests with dynamic world creation and shadows. So i'm using directional light to cast shadows, but for every mesh i import the shadows get more and more "crispy". This is fine as long as i keep light.autoUpdateExtends as false.., BUT i ran into another issue; the "shadow projection" from the light is very slim and parallel with light angle, i simply don't know how to enlarge the shadow projection so it would fit with camera view. Any ideas? - eljuko EDIT: add
  10. Hello, I am developing a 3d page, with babylonjs, I have the scene, that I am modeling and exporting in "blender" to a babylon file. In code I am adding shadows and lights, some of these lights I need turn on an turn off whe the lamp is clicked. I create the lights like this: //Luz global light[0] = new BABYLON.DirectionalLight("LuzGlobal", new BABYLON.Vector3(0, -1, 1), scene); light[0].diffuse = new BABYLON.Color3(1, 1, 1); light[0].specular = new BABYLON.Color3(1, 1, 1); light[0].direction = new BABYLON.Vector3(0, -1, 1); light[0].position.x = 27; light[0].position.y = 28; lig
  11. Hi, I'm new to babylon I am currently facing this situation: I want to display a mesh with a projected shadow on it: to generate the shadow I use a light and another mesh. I change the alpha level of this second mesh and I see no shadow anymore...is there a way to get a shadow from a transparent mesh? I know it will sound strange but I like to get this behaviour.
  12. Hi, after upgrading to 3.0-alpha I see differences in directional light in my scene that I exported from unity. I attached images and babylon file to show the difference. Code for scene is: const canvas = document.querySelector("#renderCanvas") as HTMLCanvasElement; const engine = new BABYLON.Engine(canvas, true); let camera; BABYLON.SceneLoader.ShowLoadingScreen = false; BABYLON.SceneLoader.Load("src/","light-demo.babylon", engine, function(scene) { camera = new BABYLON.ArcRotateCamera("Camera", BABYLON.Tools.ToRadians(180), 0, 3, BABYLON.Vector3.Zero(), scene); scene.addCam
  13. I'm trying to get my head around the functionality that allows lights to only illuminate certain meshes - namely using includedOnlyMeshes and excludedMeshes . And I seem to have run into a problem which hopefully you can see with this playground example Lights The example has two spheres, sphere(centre screen) and sphere2 (right side). Down the script four lights are set up and there are some marked lines of code for "turning off" the red and green lights for the centre sphere. The red light is "turned off" by using this line of code: light0.includedOnlyMeshes = [sphere2];which tells
  14. Well, I've been experimenting with lights and meshes and exporting lights from Blender with includedOnlyMeshes. And I have even created a playground for experimenting with 5lights Playground Basically the scene has 5 lights : a Hemi illuminating everything, and 4 coloured lights each illuminating a single mesh directly below it. I did this using the Blender Babylon Exporter(BBE)'s ability to export includedOnlyMeshes. The scene loads fine into the PG. But I want to change the includedOnlyMeshes for the green light to include the floor mesh and get the scene to look like the imag
  15. Hi, I have a scene where a mesh has a light 10 units away from it with intensity of 1. Id like to know a formula/way of setting lights intensity to such a value, that when it is moved to 20 units away from the mesh, it would still light the mesh as intensely as before. Simply doubling the intensity value doesnt work.
  16. We are currently exploring the possibilities of using the babylon water shader (found here:https://doc.babylonjs.com/extensions/Water ) in one of our projects. However were running into weird issues with the lighting and/or specular properties of the babylon standard shader in our scenes when we activate it. Was kind of frustrating because we spent all day thinking we messed up the rest of our scene, and then we found out it was something in the water shader script itself. To demonstrate the issue, we created a super pared down version of the babylon scene to test with. We created a bran
  17. By chance a few days ago, I was looking at a .babylon file created with 3DMax and noticed this code: [{"name":"Default light","id":"cd9cab9f-3a03-4c2a-a30f-0310239c7ebc","parentId":null,"position":null,"direction":[0.0,1.0,0.0], "type":3,"diffuse":[1.0,1.0,1.0],"specular":[1.0,1.0,1.0],"intensity":1.0,"range":3.40282347E+38,"exponent":0.0,"angle":0.0,"groundColor":[0.0,0.0,0.0], "excludedMeshesIds":null,"includedOnlyMeshesIds":null,"autoAnimate":false,"autoAnimateFrom":0,"autoAnimateTo":0,"autoAnimateLoop":false,"animations":null}], which contains "excludedMeshesIds" and "includedOnlyMe
  18. Anybody like to explain this behaviour. Note: when I say expected result what I mean is the results I expected not necessarily the developers expected results. In this PG http://www.babylonjs-playground.com/#1G708U#165 the 20 small grounds use the default grey material. Lines 22 - 24 light the green ground under the first 5 yellow spheres and lines 39 - 41 light the green ground under the last 5 red spheres as expected. Line 25 lights the grey grounds under the yellow spheres and line 42 lights the grey grounds under the red spheres, this is what is expected. Now comment ou
  19. Hi, i am wondering how many lights our babylonjs support because when i am trying to add more than 5 lights those lights are not shown up in scene. only 4 lights got added. Is there any limitation for number of lights to be used in Babylonjs. http://www.babylonjs-playground.com/#1G708U#16
  20. Hello, I'd like to access the babylonScene.ShadowGeneratorsList that SceneBuilder.Lights.cs uses, but I can't seem to find any variable that doesn't come up as undefined after I've called the SceneLoader.Load private void GenerateShadowsGenerator(Light light) { var generator = new BabylonShadowGenerator { lightId = GetID(light.gameObject), usePoissonSampling = light.shadows == LightShadows.Soft, mapSize = 256 + 256 * QualitySettings.GetQualityLevel(), bias = light.shadowBias / 10.0f,
  21. I've never really looked at/compared the .babylon files produced by the BJS exporters from 3DMax and Blender until the last week. I guess I first noticed a difference when I looked at a 3dMax file that dad72 so generously let me use while I was struggling with the "attachToBone" issue. A couple of differences that I immediately noticed - In 3Dmax Files: 1. Meshes have a "pickable" parameter in 3Dmax files. 2. Lights have "excludedMeshesIds" and "includedOnlyMeshesIds" parameters. 3. Lights and Cameras have a number of "autoAnimate" parameters. So, I am curious about what other features t
  22. Hi, I basically spend all day trying to make a very simple scene with a spinning box that simply casts a shadow >> http://playground.babylonjs.com/#1WTS3Q while doing so I think I found a bug, my original plan was to have a light source pointing straight down so I set the directional lights target parameter to a Vector(0,-1,0) as it is also shown in this example in the tutorials if you look through the source-code of the playground demo I linked above and go and find line 28: dirLight = new BABYLON.DirectionalLight("dirLight", new BABYLON.Vector3(0.1, -1,
  23. I saw that there was some discussion that the limit of four lights was not per scene, but per mesh. Can anyone explain how you'd assign a light to a certain mesh, or a group of meshes and not the scene? Also, is this something that the Blender exporter supports so we can do this without code? Thanks!
×
×
  • Create New...