Search the Community

Showing results for tags 'blender'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Coding and Game Design
  • Frameworks
    • Phaser 3
    • Phaser 2
    • Pixi.js
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • 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 329 results

  1. This is probably more specifically directed at JCPalmer. I have a few features I would like to see in the blender exporter TOB, most of which I am willing to try add myself, although I thought it might be a good idea to have a discussion first to see if some of the ideas are possible, worth doing and in line with what TOB might aiming for. export should also create html's so output can be run straight away.(for beginners and quick testing)might also be handy to run and handle a python httpd servermake more use of blender data(might make more sense to use 'blender game' render engine as the settings will be more appropriate) rather than creating own ui from which to collect data ie shadow casting, shadow receiving, collision check etc.live streaming from blender so you can see updates in the browser in realtime.this one is a bit more open ended by my intention is to allow for full development of the webgl app inside of blender including logic coding(straight javascript or maybe even some sort of logic node system visual and non visual)Would be handy to know your thoughts and plans.
  2. jeromechoain

    WebGL optimization for 3D online chess

    Hi everyone, we’ve been working hard on optimization for the king of the games: chess. It has been 100% revisited. We shared about our technical researches. We are talking about Low Poly Retopology and 3D normal maps: http://www.jocly.com/node/374 About the game, here is a presentation video: If you want to give it a try you can play here: http://www.jocly.com/#/play/classic-chess Includes basic jocly features: - play vs computer, friends or other jocly users - chat room - video chat (WebRTC) - recorded games for replay - embedding tools - development tools Feedback very welcome Thanks. jerome
  3. hello ! I have exported a scene from blender it's working fine in web . But i want to change its texture and color dynamically . e.g. Suppose i have a bag object i have exported it from blender its name is test.babylon it has a texture name base.jpg. But i have have 3 another textures . i have create a dropdownlist in my html page. So i want to if i have selected red/black/purple from dropdownlist bag texture should be change . Please do help me out . Thanks in advance .
  4. Blender man

    Blend4Web 14.08 Available

    Our development team proudly presents the new release of Blend4Web - the open source framework for creating interactive 3D web applications. In this release: a new demo scene, improved animation, particle system and geometry procedural generation. Detailed info: We've created a new audiovisual scene - Azure Grotto. The demo includes the latest results of our efforts in the field of rendering, animation and physics. The combined effect of sophisticated lighting, dynamic reflection and refraction brings the user a unique and immersive experience. Significant improvements of the animation engine. Now it's possible to apply up to 8 different types of animation to an object. Among them: object, skeletal and vertex animation, emission of particles and parametrization of speaker parameters. It's also possible now to control the speed and direction of animation (e.g. forward/backward play). Extended capabilities of emission and transformation in the particle system. Such params as size, initial velocity and count can be changed though the API. This new functionality gives a wide range of effects (for example lighting a fire, correctly displaying smoke trail from the exaust pipe etc). The button for automatic searching and removing of unused vertex groups has been added to the Blender's interface panel. Extended functionality and improved performance for node materials. New Combine HSV and Separate HSV have been implemented. By using vector arithmetics we managed to considerably decrease the number of shader instructions. Also the range of supported hardware has been increased (e.g improved support for iOS devices). Node groups have been implemented to allow multiple usage of shader blocks. The refraction effect is now possible for any materials (earlier it could be used only for water). To implement this feature a special REFRACTION node has been introduced which also contains some settings to tweak the final result. Low-level APIs have been added to manipulate the geometry in run-time. This feature allows to procedurally generate meshes of any complexity level (e.g. to create constructions à la Minecraft). We have issued a number of new tutorials on how to use the engine in web development and creating constructor applications. Dynamic reflections are now supported for node materials as well. The level of detail (LOD) system has been improved. We added a parameter for specifying the overlapping distance for adjacent LOD objects in order to smooth transitions between them. We re-ordered the external APIs. Now it's necessary to explicitly link the modules with b4w.require() instead of the b4w methods used earlier. The addons are now included into the "full" engine version b4w.full.min.js. Users that don't need addons can use a more light-weight version - b4w.min.js. We also made it possible to compile the engine and applications together using the so called extern files of Closure Compiler. Various corrections and improvements. We implemented a workaround for the Chrome bug related to the local storage when the app is running inside an iframe. Now we can handle the situations when the material parameters are set up incorrectly. The web player now supports physics (but not in the self-contained HTML files). The problem with exporting from read-only directories is now solved, we have also forbidden the exporting to another disk (under Windows). Some graphics improvements for the demos. The documentation has been updated and supplemented.
  5. Greetings to everyone, I've been using BabylonJs and Blender for a while but a i can't use the parent relationship between a camera and another mesh. Here is the code: // Load the .babylon fileBABYLON.SceneLoader.Load("./", "parent2.babylon", engine, function(newScene) { scene = newScene; scene.executeWhenReady(function() { var myCam = scene.activeCamera; myCam.ellipsoid = new BABYLON.Vector3(1, 1.5, 1); myCam.checkCollisions = true; myCam.applyGravity = true; myCam.attachControl(canvas); scene.activeCamera = myCam; var ground = BABYLON.Mesh.CreatePlane("ground", 60.0, scene); var materialPlan = new BABYLON.StandardMaterial("texturePlane", scene); materialPlan.diffuseTexture = new BABYLON.Texture("baldosa.jpg", scene); materialPlan.diffuseTexture.uScale = 5.0; materialPlan.diffuseTexture.vScale = 5.0; materialPlan.backFaceCulling = false; ground.material = materialPlan; ground.position = new BABYLON.Vector3(0, 0, 0); ground.rotation = new BABYLON.Vector3(Math.PI / 2, 0, 0); ground.checkCollisions = true; scene.collisionsEnabled = true; scene.gravity = new BABYLON.Vector3(0, -9.81, 0);Here you can see an example: http://192.241.181.27/parent/index2.html Here you can check all the files: http://192.241.181.27/parent/ I also try to use this, but it fails. http://www.html5gamedevs.com/topic/7985-babylonjs-tutorials-learn-by-creating-a-complete-game/?p=49241
  6. Hello again.... i tried to make a simple animation in Blender to understand how skeletons/bones work in Babylon... and of course, the bottom fell out. it's just a drop dead simple bending cylinder with two bones and three key frames. i can't understand why it doesn't render correctly. i believe it's just me and my lack of knowledge, but nevertheless, i need some guidance. here's the animation: http://aeon3d.fi/test/anitest1.html it's just a simple dual viewport scene, one camera set up at left and second cam at front of the model. everything loads & works ok, no errors and such -- but the animation just looks substantially different than in the original blender file: http://aeon3d.fi/test/mdl/items/bend.blend would be nice to know what's going on.
  7. Good evening everyone, I'm currently importing a lot of meshes to my project (blender), although everyting is looking fine in blender, in Babylon things get weird. I'm pretty sure i'm missing something (probably something really basic). I'll leave the printscreens has example. (sorry for the big images, didn't thought printscreen would cache the other monitor ). The first image is what is happening in the game, and the second image his the result that I want, and is what blender shows.
  8. Hello everyone, I had no problem on importing a blender mesh into the scene. But I'm not beeing able to make it move. I've created a class, so that you can easily instantiate one object in the scene. But since the Babylon.ImportMesh is a callback method, I'm not beeing able to access the object position in the loop method. Help Plz Thanks in advance, Kilombo.
  9. Hi everyone! I need you again ! So my problem : I have a scene (and a dream too...but it's not the question actualy... ....) Here, a .gif of my scene : Like you can see, I play animations of basics meshes on html select onchange event without difficulties...But when I try to play a skeleton animation with the last select html tag with the onchange event, I get an error in console like this : If I play my animation in the callback function parameter of the "Scene.Loader.ImportMesh(...)" function, there is no problem....I tried to create a "homemade" callback function but I had the same result... Here my scene code : 'use strict';// A voir pour popup patiente//var canvas = document.getElementById('myCanvas');//var context = canvas.getContext('2d');//var imageObj = new Image();////imageObj.onload = function() {//context.drawImage(imageObj, 69, 50);//};//imageObj.src = 'http://www.html5canvastutorials.com/demos/assets/darth-vader.jpg';var scene;var engine;var posXSkel = 0;var posYSkel = -3;var posZSkel = 5;var objBrasSqueletteSupportExterne;var objBrasSqueletteSupportInterne;var objBrasSquelette;var objBrasProgramationSupportExterne;var objBrasProgramationSupportInterne;var objBrasProgramation;var objBrasPieceSupportExterne;var objBrasPieceSupportInterne;var objBrasPieceSupport;var objBrasPieceOutil;var objCapot;var objTrappeContour;var drapAnimationStart; var nameLastSkelAtelier;var tabMeshImportes = [];var tabSkelImportes = [];var tabAnimationSquelette = [];var tabAnimationPiece = [];var objAnimTest;//Start the demofunction runVisuAtelier(canvasId,listeParamsSkel) { var canvas = document.getElementById(canvasId); engine = new BABYLON.Engine(canvas, true); nameLastSkelAtelier = ""; scene = new BABYLON.Scene(engine); BABYLON.SceneLoader.Load("", "SceneAtelier.babylon", engine, function (newScene) { // Wait for textures and shaders to be ready //newScene.executeWhenReady(function () { // Attach camera to canvas inputs newScene.activeCamera.attachControl(canvas); // Get the scene's objects objCapot = newScene.getMeshByName("MeshCapotTrappeAtelier"); objBrasSqueletteSupportExterne = newScene.getMeshByName("MeshSupportExterneBrasSkeletteAtelier"); objBrasSqueletteSupportInterne = newScene.getMeshByName("MeshSupportInterneBrasSkeletteAtelier"); objBrasSquelette = newScene.getMeshByName("MeshAimantBrasSkeletteAtelier"); objBrasProgramationSupportExterne = newScene.getMeshByName("MeshSupportExterneBrasProgramationAtelier"); objBrasProgramationSupportInterne = newScene.getMeshByName("MeshSupportInterneBrasProgrammationAtelier"); objBrasProgramation = newScene.getMeshByName("MeshCasqueProgramationAtelier"); objBrasPieceSupportExterne = newScene.getMeshByName("MeshSupportExterneBrasPieceAtelier"); objBrasPieceSupportInterne = newScene.getMeshByName("MeshSupportInterneBrasPieceAtelier"); objBrasPieceSupport = newScene.getMeshByName("MeshBrasPieceSupportAtelier"); objBrasPieceOutil = newScene.getMeshByName("MeshBrasPieceOutilsAtelier"); objTrappeContour = newScene.getMeshByName("MeshContourCapotAtelier"); // In default, the scene plays all animations newScene.stopAnimation(objCapot); newScene.stopAnimation(objBrasSqueletteSupportExterne); newScene.stopAnimation(objBrasSqueletteSupportInterne); newScene.stopAnimation(objBrasSquelette); newScene.stopAnimation(objBrasProgramationSupportExterne); newScene.stopAnimation(objBrasProgramationSupportInterne); newScene.stopAnimation(objBrasProgramation); newScene.stopAnimation(objBrasPieceSupportExterne); newScene.stopAnimation(objBrasPieceSupportInterne); newScene.stopAnimation(objBrasPieceSupport); newScene.stopAnimation(objBrasPieceOutil); newScene.stopAnimation(objTrappeContour); // Set up the select tag initSelectPackPiecesAte(); initSelectAnimaSkelAte(); initSelectAnimaPackPieceAte(); //scene.beginAnimation(target, from, to, loop, speedRatio, onAnimationEnd) //newScene.beginAnimation(objCapot, 140, 160, true, 1.0, function(){}); scene = newScene; createSkybox(); createAllSkeletons(listeParamsSkel); drapAnimationStart = false; // Once the scene is loaded, just register a render loop to render it engine.runRenderLoop(function() { scene.render(); }); //}); });}//Create the skyboxfunction createSkybox() { var sMaterial = new BABYLON.StandardMaterial("skyboxMaterialMagasin", scene); sMaterial.backFaceCulling = false; //sMaterial.reflectionTexture = new BABYLON.CubeTexture("images/skybox/skybox", scene); sMaterial.reflectionTexture = new BABYLON.CubeTexture("../../Bll/MoteurJeu/Img/IMG_Decor/Skybox/skyboxArene", scene); sMaterial.reflectionTexture.coordinatesMode = BABYLON.Texture.SKYBOX_MODE; var skybox = BABYLON.Mesh.CreateBox("SkyboxMagasin", 50, scene); skybox.material = sMaterial; skybox.checkCollisions = true; }// Set the position of meshfunction setupMeshWithPosFix(obj,meshes,posX,posY,posZ){ obj = meshes[0]; obj.position = new BABYLON.Vector3(posX,posY,posZ); return obj;}// Create the skeleton into the cylinderfunction createSkeleAtelier(tabParamsSkel){ if(tabParamsSkel != null) { var skelAtelier; var nomSkelAtelier = tabParamsSkel[0].NomBlender; //var chemVersFichierSkelAtelier = tabParamsSkel[0].ChemVersFichier; //var nomFichierSkelAtelier = tabParamsSkel[0].NomFichier; if(nameLastSkelAtelier != "") { skelAtelier = scene.getMeshByID(nameLastSkelAtelier); if(skelAtelier != null) { scene.beginAnimation(objCapot, 500, 540, false, 1.0, function(){}); skelAtelier.position = new BABYLON.Vector3(posXSkel, posYSkel-10, posZSkel-2.0); if(tabMeshImportes.length > 0) { var i = 0; var nbMeshesImportes = tabMeshImportes.length; for(i=0;i<nbMeshesImportes;i++) { var mesh = scene.getMeshByID(tabMeshImportes[i]); mesh.position = new BABYLON.Vector3(posXSkel, posYSkel-10, posZSkel-2.0); } } } } // Charger le squelette de démo pour l'aperçu de la pièce //skelAtelier = scene.getMeshByName(nameLastSkelAtelier); //skelAtelier = scene.getMeshByName(nomSkelAtelier); //skelAtelier = scene.getSkeletonByName("Armature"); //skelAtelier = scene.getSkeletonById(nomSkelAtelier); skelAtelier = scene.getMeshByID(nomSkelAtelier); // If mesh already exists if(skelAtelier != null) { // Jouer l'animation d'entrée du squelette scene.beginAnimation(objBrasSqueletteSupportExterne, 0, 100, false, 1.0, function(){}); scene.beginAnimation(objBrasSqueletteSupportInterne, 0, 100, false, 1.0, function(){}); scene.beginAnimation(objBrasSquelette, 0, 100, false, 1.0, function(){}); scene.beginAnimation(objTrappeContour, 0, 100, false, 1.0, function(){ scene.beginAnimation(objTrappeContour, 100, 190, false, 1.0, function(){}); scene.beginAnimation(objBrasSquelette, 100, 190, false, 1.0, function(){}); scene.beginAnimation(objBrasSqueletteSupportInterne, 100, 190, false, 1.0, function(){}); scene.beginAnimation(objBrasSqueletteSupportExterne, 100, 190, false, 1.0, function(){}); skelAtelier.position = new BABYLON.Vector3(posXSkel, posYSkel+3.5, posZSkel-2.0); }); } nameLastSkelAtelier = nomSkelAtelier; }}// Load all of the skeleton at the beginning of in the scenefunction createAllSkeletons(listeParamsSkel){ var tabParamsSkel = eval(listeParamsSkel); if(tabParamsSkel != null) { var i; for (i=0;i<tabParamsSkel.length;i++) //for (i=0;i<1;i++) // for test the first skeleton only { var skelAtelier; var nomSkelAtelier = tabParamsSkel[i].NomBlender; var chemVersFichierSkelAtelier = tabParamsSkel[i].ChemVersFichier; var nomFichierSkelAtelier = tabParamsSkel[i].NomFichier; BABYLON.SceneLoader.ImportMesh(nomSkelAtelier, "../../Bll/MoteurJeu/" + chemVersFichierSkelAtelier, nomFichierSkelAtelier, scene, function (newMeshesSkel,particleSystems, skeletons) { // -10 in y to load the skeleton under the floor and +3.5 in final position skelAtelier = setupMeshWithPosFix(skelAtelier,newMeshesSkel,posXSkel, posYSkel-10, posZSkel-2.0); //skelAtelier = setupMeshWithPosFix(skelAtelier,newMeshesSkel,skeletons,posXSkel, posYSkel+3.5, posZSkel-2.0); // Animation of skeleton is good here !!!! //objAnimTest = scene.beginAnimation(skeletons[0], 10, 55, true, 1.0, function(){}); //objAnimTest.stop(); }); tabSkelImportes.push(tabParamsSkel[i]); } }}// Create the device on the robotfunction createPieceAtelier(tabParamsPiece){ if(tabParamsPiece != null) { // Play the scene animations... scene.beginAnimation(objBrasPieceSupportExterne, 200, 270, false, 1.0, function(){}); scene.beginAnimation(objBrasPieceSupportInterne, 200, 270, false, 1.0, function(){}); scene.beginAnimation(objBrasPieceSupport, 200, 270, false, 1.0, function(){}); scene.beginAnimation(objBrasPieceOutil, 200, 270, false, 1.0, function(){ var i; var nbPieces = tabParamsPiece.length; for(i=0;i<nbPieces;i++) { var nomBlenderPiece = tabParamsPiece[i].NomBlender; var chemVersFichierPiece = tabParamsPiece[i].ChemVersFichier; var nomFichierPiece = tabParamsPiece[i].NomFichier; var piece; var pos = tabMeshImportes.indexOf(nomBlenderPiece); if(pos == -1) { // Import the mesh BABYLON.SceneLoader.ImportMesh(nomBlenderPiece, "../../Bll/MoteurJeu/" + chemVersFichierPiece, nomFichierPiece, scene, function (newMeshes) { piece = setupMeshWithPosFix(piece,newMeshes,posXSkel, posYSkel+3.5, posZSkel-2.0); piece.name = nomBlenderPiece; }); tabMeshImportes.push(nomBlenderPiece); } else { var mesh = scene.getMeshByID(tabMeshImportes[pos]); if(mesh != null) mesh.position = new BABYLON.Vector3(posXSkel, posYSkel+3.5, posZSkel-2.0); } } scene.beginAnimation(objBrasPieceOutil, 270, 340, false, 1.0, function(){}); scene.beginAnimation(objBrasPieceSupport, 270, 340, false, 1.0, function(){}); scene.beginAnimation(objBrasPieceSupportInterne, 270, 340, false, 1.0, function(){}); scene.beginAnimation(objBrasPieceSupportExterne, 270, 340, false, 1.0, function(){}); }); }}// Create the animation of the skeletonfunction createAnimation(idSkel,idAnimationSkel){ if(!drapAnimationStart) { var i = 0; var skelAtelier; var keyDeb; var keyFin; var nbSkel = tabSkelImportes.length; for(i=0;i<nbSkel;i++) { if(tabSkelImportes[i].ID == idSkel) { var nomSkel = tabSkelImportes[i].NomBlender; skelAtelier = scene.getMeshByID(nomSkel); if(skelAtelier != null) { // Find keyframes of the animation var j = 0; var nbAnimsSkel = tabAnimationSquelette.length; for(j=0;j<nbAnimsSkel;j++) { if(tabAnimationSquelette[j].ID == idAnimationSkel) { keyDeb = tabAnimationSquelette[j].KeyFrameDeb; keyFin = tabAnimationSquelette[j].KeyFrameFin; } } } } } if(!drapAnimationStart) { var objAnim = scene.beginAnimation(skelAtelier.skeleton, keyDeb, keyFin , false, 1.0, function(){ drapAnimationStart = false; }); drapAnimationStart = true; } //objAnimTest.restart(); //skelAtelier = scene.getSkeletonByName("Armature"); /* var objAnim = scene.beginAnimation(skelAtelier.skeleton, keyDeb, keyFin , false, 1.0, function(){ drapAnimationStart = false; }); drapAnimationStart = true; */ //test(retour2,skelAtelier.skeleton, keyDeb, keyFin ); // affiche 'Retour 2' //scene.render(); //scene.unregisterBeforeRender(function(){ //}); //scene.registerBeforeRender(function(){ /* if(!drapAnimationStart) { var objAnim = scene.beginAnimation(skelAtelier.skeleton, keyDeb, keyFin , false, 1.0, function(){ drapAnimationStart = false; }); drapAnimationStart = true; } */ //}); } }function addInTabAnimationSquelette(animationSkel){ tabAnimationSquelette.push(animationSkel);}function addInTabAnimationPiece(animationPiece){ tabAnimationPiece.push(animationPiece);}// Test of callback functionfunction retour2(lObjSkel,lImgeDeb,lImgeFin) { //alert('Retour 2'); if(!drapAnimationStart) { var objAnim = scene.beginAnimation(lObjSkel, lImgeDeb, lImgeFin, false, 1.0, function(){ drapAnimationStart = false; }); drapAnimationStart = true; } }function test(fct_retour,objSkel,imgDeb,imgFin) { fct_retour(objSkel,imgDeb,imgFin); // appel de la fonction} and here my onchange event function of the html select "Liste des Ids des packs de pieces" : function getValComboAnimationSkelAtelier(idDeComboSkel,idDeCombo){ // Get the skeleton var selectBox = document.getElementById(idDeComboSkel); var txtCombo = selectBox.options[selectBox.selectedIndex].textContent; var posBal = txtCombo.indexOf(':'); var idSkelStr = txtCombo.substr(0,posBal); // Get the num skeleton selectBox = document.getElementById(idDeCombo); txtCombo = selectBox.options[selectBox.selectedIndex].textContent; posBal = txtCombo.indexOf(':'); var idAnimationStr = txtCombo.substr(0,posBal); if(idAnimationStr != "") { createAnimation(idSkelStr.trim(),idAnimationStr.trim()); } }Anyone has an idea ??? Thanks !! Zino
  10. Blender man

    Making a Game. Part 5: Dangerous World

    The 5-th Blend4Web gamedev tutorial has been published: Dangerous World. We continue the exciting process of creating a mini Blend4Web game. Now we'll introduce some gameplay elements: red-hot rocks which fall from the sky and damage the character. Direct link to the game (Warning: this link URL may change). [Edit] Updated the link
  11. Hello, decided that something talked about at the end of another thread was best addressed in its own thread. As intro (gryff correct as needed) Blender allows for meshes to deformed without the use of bones. This could used for animation. Not having a skeleton seems easier to do than bones in Blender to me, and the results can be way beyond them as well. Copied link from prior thread: . Question is: Is there even any hope that this could be exportable from Blender to BabylonJS? Gryff also provided a .blend, copied link Cloth Animation2 .Load it up in blender, and hit the play button, '>', in the bottom middle of the window. What I have done is run this blend through a Babylon export script with extra stuff added to find & for now write extra lines into the log file which describes the data for shape keys. FYI, the Blender doc I got my info from is at http://www.blender.org/documentation/blender_python_api_2_70_release/bpy.types.Key.html#bpy.types.Key It seems that shape keys can be shared across meshes, so I added this code to reference them this way in the main loop & a ShapeKey class because it seems the data structure is recursive: # Shape Keys from the main loopfor key in bpy.data.shape_keys: ShapeKey(key, 1)) ...class ShapeKey: def __init__(self, key, level): TowerOfBabel.log('processing begun of shape : ' + key.name, level) if hasattr(key, 'eval_time' ): TowerOfBabel.log('eval time: ' + str(key.eval_time), level + 1) if hasattr(key, 'slurph' ): TowerOfBabel.log('slurph: ' + str(key.slurph ), level + 1) if hasattr(key, 'use_relative'): TowerOfBabel.log('use relative: ' + format_bool(key.use_relative), level + 1) if hasattr(key, 'animation_data'): TowerOfBabel.log('animation_data:', level + 1) for fcurve in key.animation_data.action.fcurves: TowerOfBabel.log('fcurve.data_path:' + fcurve.data_path, level + 2) # recursion, oh crap if hasattr(key, 'key_blocks'): for block in key.key_blocks: ShapeKey(block, level + 1)This produced this output (probably a dead end from this angle): processing begun of shape : Key eval time: 0.0 slurph: 0 use relative: true animation_data: fcurve.data_path:key_blocks["Draped"].value processing begun of shape : Basis processing begun of shape : DrapedIn the processing of a mesh I added the following code if shape keys were associated: # shape keys for mesh if object.data.shape_keys: TowerOfBabel.log('Shape Key found in mesh: ' + object.data.shape_keys.name, 2) keyBlocks = object.data.shape_keys.key_blocks for block in keyBlocks: TowerOfBabel.log('Block Name: ' + block.name + ', num vertices:' + str(len(block.data)), 3) for data in block.data: vertex = data.co TowerOfBabel.log('x: ' + str(vertex.x) + ', y: '+ str(vertex.y) + ', z: ' + str(vertex.z), 4)This produced a lot of output, here is a shortened version of the log for the mesh with the shape key: processing begun of mesh: Cloth, using base class: BABYLON.Mesh WARNING: No materials have been assigned: num positions : 1156 num normals : 1156 num uvs : 0 num uvs2 : 0 num colors : 0 num indices : 6534 Shape Key found in mesh: Key Block Name: Basis, num vertices:1156 x: 1.0, y: -1.0, z: 0.0 x: -1.0, y: -1.0, z: 0.0 x: 1.0, y: 1.0, z: 0.0 x: -1.0, y: 1.0, z: 0.0 x: 0.8181818127632141, y: -1.0, z: 0.0 x: 0.6363636255264282, y: -1.0, z: 0.0 x: 0.45454543828964233, y: -1.0, z: 0.0 x: 0.27272725105285645, y: -1.0, z: 0.0 x: 0.09090906381607056, y: -1.0, z: 0.0 x: -0.09090910851955414, y: -1.0, z: 0.0 x: -0.27272728085517883, y: -1.0, z: 0.0 x: -0.4545454680919647, y: -1.0, z: 0.0 x: -0.6363636255264282, y: -1.0, z: 0.0 x: -0.8181818127632141, y: -1.0, z: 0.0 x: 0.8181818127632141, y: 1.0, z: 0.0 x: 0.6363636255264282, y: 1.0, z: 0.0 x: 0.45454543828964233, y: 1.0, z: 0.0 x: 0.27272725105285645, y: 1.0, z: 0.0 x: 0.09090906381607056, y: 1.0, z: 0.0 x: -0.09090910851955414, y: 1.0, z: 0.0 x: -0.27272728085517883, y: 1.0, z: 0.0 x: -0.4545454680919647, y: 1.0, z: 0.0 x: -0.6363636255264282, y: 1.0, z: 0.0 x: -0.8181818127632141, y: 1.0, z: 0.0 x: -1.0, y: 0.8181818127632141, z: 0.0 . . . x: 0.8787878751754761, y: 0.7575757503509521, z: 0.0 x: 0.939393937587738, y: 0.6969696879386902, z: 0.0 x: 0.939393937587738, y: 0.7575757503509521, z: 0.0 Block Name: Draped, num vertices:1156 x: 0.42931264638900757, y: -0.532781720161438, z: -0.8952973484992981 x: -0.4533596634864807, y: -0.5035873055458069, z: -0.9059669375419617 x: 0.5022068023681641, y: 0.5161137580871582, z: -0.9113012552261353 x: -0.5195051431655884, y: 0.592650294303894, z: -0.846235990524292 x: 0.315280556678772, y: -0.4323137700557709, z: -0.8073179721832275 x: 0.23072978854179382, y: -0.5339680314064026, z: -0.7025083899497986 x: 0.12728682160377502, y: -0.45900893211364746, z: -0.6225178241729736 x: 0.2509845793247223, y: -0.36435461044311523, z: -0.6379876732826233 x: 0.09559790790081024, y: -0.3883511424064636, z: -0.6364848017692566 x: -0.08387131989002228, y: -0.38822996616363525, z: -0.6374479532241821 x: -0.24025821685791016, y: -0.39399784803390503, z: -0.637752115726471 x: -0.25066906213760376, y: -0.34393423795700073, z: -0.22135230898857117 x: -0.2696780264377594, y: -0.3371814489364624, z: 0.011421998962759972 x: 0.43590784072875977, y: 0.1628814935684204, z: -0.566344141960144 x: 0.45525118708610535, y: 0.22023046016693115, z: -0.5630139708518982 x: 0.3902812600135803, y: 0.21390795707702637, z: -0.5098786950111389 x: 0.4428275227546692, y: 0.1841123402118683, z: -0.5045356154441833 x: 0.3944912552833557, y: 0.2104395627975464, z: -0.5703118443489075 x: 0.4410724639892578, y: 0.17216885089874268, z: -0.5640472173690796 x: 0.5403734445571899, y: 0.24221545457839966, z: -0.5275962352752686 x: 0.5631066560745239, y: 0.2916404604911804, z: -0.5530022382736206 x: 0.548436164855957, y: 0.2113366574048996, z: -0.5791581273078918 . . . x: 0.5152558088302612, y: 0.40521472692489624, z: -0.6688541769981384 x: 0.5745273232460022, y: 0.3480875492095947, z: -0.6703621745109558 x: 0.5555965900421143, y: 0.3864023685455322, z: -0.7100901007652283Now I recognize some of this code, but I do not know what is going on yet. If someone can enlighten me on what I might try next, I would be grateful. Jeff
  12. The readme for the blender exporter says that it exports reflection textures. How do you add them in blender? Is it with an environment map texture? http://www.html5gamedevs.com/topic/2112-how-to-make-reflection-or-mirror-in-blender/ This topic seems to say that they must be added in javascript, but maybe I read it wrong.
  13. I can set textures to repeat in javascript using uscale and vscale, but I can't figure out which texture options in blender set uscale and vscale. (I'm using the babylon.js exporter). Can someone tell me?
  14. Hi all, Firstly - a quick howzi from a newbie!!! - just moving over from Three'js and experimenting with Babylon, lovin it so far... I'm havin a small issue getting my blender export to listen to scaling and position commands. var newMeshes = []; function importedMeshes(mesh) { mesh.position = new BABYLON.Vector3(-10, 0, 0); mesh.scaling = new BABYLON.Vector3(19.025, 19.025, 19.025); } BABYLON.SceneLoader.ImportMesh("", "GalleryAssets/room/", "Room2.babylon", scene, function (newMeshes) { importedMeshes(newMeshes[0]); }); Room2 is appearing but won't resize or listen to any postioning commands. It was originally a 3DS file that I imported to blender and exported to Babylon (long winded but worked kind of ok for my Three.js project.) ( i tested an import from my three.js (Json) file into blender and then exported for babylon - THAT responded to the above code for scaling and positioning, BUT lost all info (meshes etc and just showed black walls in the correct shape and position) Anyone see anything I'm doing wrong? Is it something I need to do in Blender first? Thanks and kind Eegards
  15. A Series of Blend4Web Gamedev Tutorials has been published. http://www.blend4web.com/en/article/38 From their blog: Lets set up the gameplay. The player - a brave warrior - moves around a limited number of platforms. Melting hot stones keep falling on him from the sky; the stones should be avoided. Their number increases with time. Different bonuses which give various advantages appear on the location from time to time. The player's goal is to stay alive as long as possible. Later we'll add some other interesting features but for now we'll stick to these. This small game will have a third-person view. In the future, the game will support mobile devices and a score system. And now we'll create the app, load the scene and add the keyboard controls for the animated character. Lets start!
  16. I everyone, Does anyone imported meshes from blender (in .babylon format) with success while running in localhost? If so. Please tell me how, I'm not having succeding on this. Thanks in advance.
  17. Good morning everyone, i'm having a problem with the plugin exporter for blender. It's returning a syntax error and is not working. Any ideas for why this is happening? The error occurs in <!DOCTYPE html> in line 6 (in the io_export_babylon.py, located in my user\appdata folder). My current blender version is 2.70. Thanks in advance.
  18. how to add event listeners for objects in scene loaded from blender
  19. I have a problem with babylon.js. I can't load the texture ground in this scene: and I get this error in Firefox and Midory: [23:24:40.378] "Valid manifest file not found. Scene & textures will be loaded directly from the web server." This is my code html5 : <!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml" lang="es"><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <title>Using babylon.js - How to load a scene</title> <script src="babylon.1.9.0.js"></script> <script src="hand-1.3.7.js"></script> <style> html, body { width: 100%; height: 100%; padding: 0; margin: 0; overflow: hidden; } #renderCanvas { width: 100%; height: 100%; } </style></head><body> <canvas id="renderCanvas"></canvas> </body></html> <script> if (BABYLON.Engine.isSupported()) { var canvas = document.getElementById("renderCanvas"); var engine = new BABYLON.Engine(canvas, true); BABYLON.SceneLoader.Load("", "/scenes/suelo.babylon", engine, function (newScene) { // Wait for textures and shaders to be ready newScene.executeWhenReady(function () { // Attach camera to canvas inputs newScene.activeCamera.attachControl(canvas); // Once the scene is loaded, just register a render loop to render it engine.runRenderLoop(function() { newScene.render(); }); }); }, function (progress) { // To do: give progress feedback to user }); }</script>and this an image of my scene in blender:
  20. Hi gentlemen ! I need your help again... Like the title sai it... i would like import a mesh from Blender in Babylon.js with uv mapping. But with the material and texture, the mesh doesn't appear... and of course without the material and texture, the mesh appears correctly. I see that Blender have two kind of material options : "Data" and "Object".In first, I tried to create the material and texture with the option "Data" only, after with the option "Object" only and to finish with the two options but always nothing in Babylon.js... To create this material and texture, I took my inspiration of the exemple made by Deltakosh here : http://blogs.msdn.com/b/eternalcoding/archive/2013/06/28/babylon-js-how-to-load-a-babylon-file-produced-with-blender.aspx?PageIndex=2 But i don't see that I made wrong... because except the option "Use alpha" and "Diffuse", all of the checkbox are uncheked... I tried to chek many option at random but nothing better... So my request... Is it possible to have an exemple of mesh creation with uv mapping to import in Babylon.js from Blender? After my job, I will post my file or screeshot of my material and texture set up... Thanks you for your help !!
  21. Hi guys, I'm new to Babylon.js and I've just started with the Blender Exporter. So here is my question: Is it possible to "execute" an action created in Blender with Babylon? Thanks, jlaur
  22. Shivaan Keldon

    Animation from Blender

    Hi, I try, since yesterday, to start an animation loaded from Blender, but nothing appens. All my scene is loaded from blender. There's camera, lights, walls, a character with its rig, and an animation set for "walk". After reading this tutorial (https://github.com/BabylonJS/Babylon.js/wiki/How-to-use-bones-and-skeletons), I decided to loop manually into scene.meshes to retreive the character, and attach the scene.skeleton[0] to it. I've checked that all vertex groups are ok in Blender, and that each vertex has maximum 4 bones influence (not so easy). The mesh _vertexBuffer has only color, normal and position, but doesn't have matrices weight or matrice indices. Is it the problem ? How can I generate this values ? Is there something to do in Blender to import them automatically ? Here's the light version of my code : <script>var canvas, engine, scene, player;function render(){ scene.render();}window.onload = function(){ canvas = document.getElementById("renderCanvas"); engine = new BABYLON.Engine(canvas, true); BABYLON.SceneLoader.Load("", "testroom.babylon", engine, function (nscene) { scene = nscene; scene.executeWhenReady(function () { for(var i=0,n=scene.meshes.length; i<n; i++) { if(scene.meshes[i].name=="player"){ player = scene.meshes[i]; player.skeleton = scene.skeletons[0]; } } scene.beginAnimation(player.skeleton,0,60,true,1.0); engine.runRenderLoop(render); }); });};</script>Thanks PS: Babylon is really great and has a good render engine. But it could be great to have an API and more examples when building a game from Blender. But well, it's still young and I think it will come after ^^
  23. Hi guys ! On the advice of Gwenael, I write this topic for my question... As the title say it, how can I modify a part or many parts of a mesh imported in Babylon.js linked to a skeleton with an another mesh without bone? An example ? Ok ... I have this mesh in Blender v2.67 : You can see the mesh linked to a skeleton composed of 3 bones... As you see it, the mesh moves with the skeleton... until this, all is ok ^^ ! Now an another mesh like this for example : A basic mesh without animation, nothing to say... So in my Babylon scene, I have this... (after import of my 2 files.babylon of course) And the result that I would like will be anything like this : I saw in tutorial that a skeleton have a bone array and a bone can "access" to his mesh linked...Gwenael talks me about "submeshes" too... but a example made by a competent person like ProfessorF, Gwenael or DeltaKosh will be more evident to understand I think : ) Thanks you for your help. P.S : If anyone want my Blender or Babylon files to go quickly in this research, I will send them.
  24. Hi everyone, First, thanks to Babylon.js!It has many potential! Now, my problem... I'm a programmer and I try to create a 3D game with Babylon.js on a wamp server and Blender v2.67. I'm learning how to create basic mesh and animation and how export it into Babylon.js. When I import a basic mesh (like a cube...) linked to many rotation keyframes (in blender...), there is no problem when playing animation in Blender and Babylon.The mesh spins well to the center of the mesh... See the files RotaInBlender.gif and RotaInBabylon.gif... In Blender : In Babylon : When I import the same mesh linked to a skeleton and repeat the process of the creation of the rotation keyframes (linked to the skeleton this time...),there is no problem in Blender but the animation in Babylon.js is not the same... See the files RotaInBlenderWithSkel.gif and RotaInBabylonWithSkel.gif... In Blender : In Babylon : It's like the mesh doesn't spin but turn around a new offset center but I don't understand because the center of the bone is the same that the mesh center in Blender! I see many options to repeat the process of the creation of the rotation keyframes in Blender with different properties "Rotation Mode" like : XYZ Euler, Axis, Quaternion(WXYZ)... but always the same result. What i'm doing wrong please ? I can send file .blend or .babylon if anyone want help me. Thanks you for your help, i real need it! PS : Sorry for my bad english, i'm French and it's my first forum...
  25. darkecho

    Blender export

    Hi guys i have little problem here, when i try to load my own exported mesh from blender with textures into babylon, i allways get "Error: WebGL: A texture is going to be rendered as if it were black, as per the OpenGL ES 2.0.24 spec section 3.8.2, because it is a 2D texture, with a minification filter requiring a mipmap, and is not mipmap complete (as defined in section 3.7.10)." and model is ofc without texture where is the problem? I tried almost every option. Downloaded models works fine, so i guess its in my models. Thanks to everyone.