MrVR

Members
  • Content Count

    152
  • Joined

  • Last visited

Everything posted by MrVR

  1. I see, yeah all gets written in the .babylon metadata file, but I see what you mean, I was thinking about it as well cause I was planning to load my scenes using angularjs and I try to access the properties calling the class but I run into the same issue, lets ask @MackeyK24 about it...???? and see what he thinks. is this the only way ?? mesh.metadata.components[0].properties.rotationSpeedY = 1;
  2. Hey @ragingclaw, I think understand your question and if I may answer, to change the properties of an attribute at run time you have to invoke the this.findCompoent() function. In the video there is a sample where you access properties from one component to another, using a custom public class to access the private property; in the example he created the rotate() function is the component MyRotateY see VIDEO minute 50 there is a sample, you can create a class that access this porperties a run time trigger by an event such as a click event in the user interface (splash screen or control panel etc..) or some other event. I hope it helps
  3. Hi @dbawel, Thanks for the reply, I have issues getting the character directly from Motion Builder to Babylon. when I try to export this are my options The in BlenderI get this erros I will keep trying using a third software to convert my MoionBuilder rigged FBX to a version babylon acepts, or do you have any other suggestions?
  4. HI Mr @dbawel I have been trying to animate characters coming from Iclone-6 (for months already ), I read your motion builder post last night and I got motion-builder to rig a G6 character here is the video I used for that, Once I process my FBX (scii or binary I use 3dExchange to convert into FBX for MB or unity3d) I'm currently installing 3D-smax-2016 because I try 3Ds-max-2017 but export plugin dos not work I get an error after I drop the files in the assemblies folder. HERE is a LINK with the FBX files already rigged. The first one is in motion builder with the animation. The other 2 are ready to be imported into unity, blender, 3dsmax. Can you please point me in the right direction to export and play the character animation, I try with the new UNITY exporter and I have some errors already; @MackeyK24 is the author of the new exportation toolkit, I want to find the way to export from unity and play the animations on an scene controller script UPDATE QUESTION BLENDER EXPORT EXPERIMENT On blender I export my BJS file with the animation here is a link for the export log and files; this process took 1 hour approx to create the file. The file I created is too big like 600000 lines of code, I will remove the head bones and some unused bones to lower the files size. And here is an animation url that works exported from blender and the file is here at this link you can dump the file at http://www.jsoneditoronline.org/ to see on tree mode the structure. ---BLENDER UPDATE SMALLER BJS FILE NOW ANIMATING I rigged a simpler one with babylon less bones and vertices, you can see the animation frames attached in the sharky.babylon file Im trying to use this code below to make the animation run but i dont find the bones when Im debugging but if you drop the file inside http://babylonjs.com/sandbox/ you will see the motion BABYLON.SceneLoader.ImportMesh("sharky", "Scenes/", "sharky.babylon", this.scene, function (newMeshes, particleSystems, skeletons) { var dude = newMeshes[0]; skeletons[0].beginAnimation("Shark_01|Shark_FastSwim",true, .5); }); UNITY EXPORT For unity I created an non standard Please download the rigged character unity package---> (susan.unitypackage). I get errors after the export in the console here is the unity package. BJS - [14:59:11]: Babylon.js engine (v2.5) launched babylon.js:3 BJS - [14:59:14]: Unable to compile effect: t._ErrorEnabled @ babylon.js:3 babylon.js:3 BJS - [14:59:14]: Defines: #define ALBEDO #define REFLECTIVITY #define BUMP #define UV1 #define UV2 #define NUM_BONE_INFLUENCERS 4 #define BonesPerMesh 64 #define MICROSURFACEFROMREFLECTIVITYMAP #define EMISSIVEASILLUMINATION #define USEPHYSICALLIGHTFALLOFF #define RADIANCEOVERALPHA t._ErrorEnabled babylon.js:3 BJS - [14:59:14]: Error: ERROR: too many uniforms BJS - [14:59:14]: Vertex shader:pbrt._ErrorEnabled BJS - [14:59:14]: Fragment shader:pbrt._ErrorEnabled BJS - [14:59:14]: Trying next fallback. Please let me know what do you think thank you
  5. Ok @MackeyK24 I PM you the .dds files let me now if you can download them , and now I replacing the ones .dds on the scenes to png, also is jpg ok as well ?
  6. HI @MackeyK24 I put together an couple of SCENE1(volumetric light 36 FPS), SCEN1(non-volummetric light 60-PFS) , SCENE-2 (particules) with the unity exporter (no too much code only exporter options), can you please take a look, it loads slow if you have .dds images as textures, take very long to be download specially in mobile. DO you know how can I improve it to work on mobile or have some other version of the files depending on the device? below an image of the network download time you can see for yourself on the links above .
  7. NIce on the clone shot (run-time prefab cloning in the scene, can this be use for loading multiple prefabs at run time?). About the PBR I know it can be configured further but I thought it would be a nice addition to make those options available as well on the unity IU. OK I understand your taking a different approach on the engine but isn't the basic animation API a nice core feature to add on the unity exporter .
  8. Hi Master @MackeyK24 its all working awesome je je, I wish you a Happy New Year.Thanks for all the support. I will post some scenes I'm currently working on (testing PBR, Shaders particules, PBR etc). just a few points I would like to know. - Its there a way to export the unity skyboxes, I saw in the scene controller we have an sky-box option export but its not exporting any. - I have characters already rigged in unity, is it possible to export those animations or it need to be re-code in JavaScript it in order to work, please let me know where to start if you know about this this has been the most frustrating part. SO CAN YOU PLEASE TAKE A LOOK OF THIS MODEL (if you have porblem getting let me know) - ON the PBR options, I saw there are a lot of other options I dont see on the PBR shader, for example just to mention some like the camera exposure, and contrast, reflective color, micro-surface. var pbr = new BABYLON.PBRMaterial("pbr", scene); pbr.albedoColor = new BABYLON.Color3(0.2, 0.9, 1.0); pbr.reflectivityColor = new BABYLON.Color3(reflectivity, reflectivity, reflectivity); materialSphere.microSurface = microSurface; pbr.cameraExposure = 0.66; pbr.cameraContrast = 1.66; Also overlodadedAlbedo, averloadedAlbeidoIntensity, Reflexion Texture (I guess this is the specular), useMicroSurfaceFromReflectivityMapAlpha , var materialSphere = new BABYLON.PBRMaterial("Material_" + j, scene); materialSphere.albedoTexture = new BABYLON.Texture("Textures/Amiga"); materialSphere.overloadedAlbedo = new BABYLON.Color3(0, 0, 1); materialSphere.overloadedAlbedoIntensity = overloadedIntensity; OR for glass is missing these options I think, let me know what do you think or maybe I'm lost je je I'm gonna keep working on the PBR guide var glass = new BABYLON.PBRMaterial("glass", scene); glass.reflectionTexture = hdrTexture; glass.refractionTexture = hdrTexture; glass.linkRefractionWithTransparency = true; glass.indexOfRefraction = 0.52; glass.alpha = 0; // Fully refractive material
  9. Hi @MackeyK24 I'm having a weird behavior today, my animations dont work only when I resize the chrome browser I can see the flare system and the animation running other wise is stuck in the same frame here is a VIDEO showing what I mean UPDATE (I think is the my chrome browser I TEST the scene in internet explorer edge and it works perfect please let me know if it works on your chrome browser I try two different computers and still in one frame) for now using IE edge for testing instead chrome here is my version When adding a particles system I get this error sometimes and its so annoying, my work around its to change the flare image sometimes it works sometimes I get the error and I have to change image and deploy again UnauthorizedAccessException: Access to the path "Assets/Materials/Textures/Flares/Elements/Light_Pair.png" or "C:/Users/cvega.BI/Desktop/MACKEY24/SHADER/SHADER/Project/Scenes\Light_Pair.png" is denied. System.IO.File.Copy (System.String sourceFileName, System.String destFileName, Boolean overwrite) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/File.cs:124) BabylonExport.Entities.BabylonScene.AddTexture (System.String texture) Unity3D2Babylon.SceneBuilder.CopyTexture (System.String texturePath, UnityEngine.Texture2D texture2D, BabylonExport.Entities.BabylonTexture babylonTexture, Boolean isLightmap) (at Assets/Babylon/Source/SceneBuilder.Materials.cs:274) Unity3D2Babylon.SceneBuilder.ParseParticleSystems (UnityEngine.GameObject gameObject, System.String emitterId, System.Collections.Generic.List`1& particles) (at Assets/Babylon/Source/SceneBuilder.cs:888) Unity3D2Babylon.SceneBuilder.ConvertUnityMeshToBabylon (UnityEngine.Mesh mesh, UnityEngine.Transform transform, UnityEngine.GameObject gameObject, Single progress, UnityEditor.UnityMetaData& metaData, System.Collections.Generic.List`1& particleSystems, System.Collections.Generic.List`1& lensFlares, System.String& componentTags, BabylonExport.Entities.BabylonMesh collisionMesh, UnityEngine.Collider collider) (at Assets/Babylon/Source/SceneBuilder.Meshes.cs:371) Unity3D2Babylon.SceneBuilder.ConvertFromUnity () (at Assets/Babylon/Source/SceneBuilder.cs:604) UnityEngine.Debug:LogException(Exception) Unity3D2Babylon.SceneBuilder:ConvertFromUnity() (at Assets/Babylon/Source/SceneBuilder.cs:813) Unity3D2Babylon.ExporterWindow:Export(Boolean) (at Assets/Babylon/Source/ExporterWindow.cs:747) Unity3D2Babylon.ExporterWindow:OnGUI() (at Assets/Babylon/Source/ExporterWindow.cs:584) UnityEditor.DockArea:OnGUI() ON THE SHADER REPORT I remove the pass{} from the shader and it works but when I try to do a different one I dont get the results expected here is the result with the original program; so far I was able to // so far i was able to replicate the black and white, phong, discard, cell shader, spherical reflection, fresnel and the wavesahder which its not updating or waving here is a link with all shaders code below fresnel, spherical reflection and wave shaders applied
  10. Hi @MackeyK24 I was trying to use the shader program but i get this error and I can not find my shader under the babylon menu, please let me know what Im doing wrong Shader "BabylonJS/myShader" { Properties { _Color ("Color", Color) = (1,1,1,1) _Brightness ("Intensity", Range(1.0, 10.0)) = 1.0 [NoScaleOffset] _MainTex ("Albedo (RGB)", 2D) = "white" {} _ScaleX ("Scale Factor X", Range (0.0, 10.0)) = 1.0 _ScaleY ("Scale Factor Y", Range (0.0, 10.0)) = 1.0 _Metallic ("Metallic", Range(0,1)) = 0.0 _Glossiness ("Smoothness", Range(0,1)) = 0.5 [ToggleOff] _NeedsAlphaTesting ("Needs Alpha Testing", Int) = 0 [ToggleOff] _NeedsAlphaBlending ("Needs Alpha Blending", Int) = 0 [Enum(Disable,0,Additive,1,Combine,2,Subtract,3,Multiply,4,Maximized,5,OneOne,6)] _AlphaMode ("Alpha Blending Mode", int) = 2 } SubShader { Tags { "RenderType"="Opaque" } Pass { CGPROGRAM ////////////////////////////////////////////////////////// // BABYLON WEBGL RUNTIME SHADER PROGRAM SECTIONS (GLSL) // ////////////////////////////////////////////////////////// #ifdef BABYLON attributes: ["position", "normal", "uv"] uniforms: ["worldViewProjection, _Color, _Brightness, _Glossiness, _Metallic, _ScaleX, _ScaleY"] samplers: [] defines: [] #endif //BABYLON-END #ifdef VERTEX attribute vec3 position; attribute vec3 normal; attribute vec2 uv; uniform mat4 worldViewProjection; precision highp float; varying vec2 vUV; void main(void) { gl_Position = worldViewProjection * vec4(position, 1.0); vUV = uv; } #endif //VERTEX-END #ifdef FRAGMENT precision highp float; varying vec2 vUV; uniform vec4 _Color; uniform float _Brightness; uniform float _Glossiness; uniform float _Metallic; uniform float _ScaleX; uniform float _ScaleY; uniform sampler2D _MainTex; void main(void) { gl_FragColor = texture2D(_MainTex, vec2(vUV.x * _ScaleX, vUV.y * _ScaleY)) * _Color * _Brightness; } #endif //FRAGMENT-END //////////////////////////////////////////////////////// // DEFAULT UNITY EDITOR SHADER PROGRAM SECTION (HLSL) // //////////////////////////////////////////////////////// #pragma exclude_renderers d3d11 xbox360 gles #pragma surface surf Standard fullforwardshadows #pragma target 3.0 sampler2D _MainTex; struct Input { float2 uv_MainTex; }; half _Brightness; half _Glossiness; half _Metallic; half _ScaleX; half _ScaleY; fixed4 _Color; void surf (Input IN, inout SurfaceOutputStandard o) { // Albedo comes from a texture tinted by color float2 vUV = IN.uv_MainTex; fixed4 c = tex2D (_MainTex, float2(vUV.x * _ScaleX, vUV.y * _ScaleY)) * _Color * _Brightness; o.Albedo = c.rgb; // Metallic and smoothness come from slider variables o.Metallic = _Metallic; o.Smoothness = _Glossiness; o.Alpha = c.a; } ENDCG } } FallBack "Diffuse" }
  11. Hey @TonikCG check your TSC path I think you have it wrong one by default, that is maybe why the tsc compiler is not compiling the typescript here is my root path to the tsc compiler I have Windows 10 just in case you are in Linux or mac the path slash is the opposite Also dont forget to set up the empty game object as your scene controller(see in video )and add the SceneController component to hook all the TS code TSC : C:\Users\USER-NAME\AppData\Roaming\npm\node_modules\typescript\bin\tsc NODE: C:\Program Files\nodejs\node.exe
  12. @TonikCG Let me try myself later or tomorrow I'm not sure what is going on with that, I get back to you later , I'm almost done with the baking playing with all settings, Im doing many different baking with many lights so see the differences below some screen shots .. so far I use one light source then I disable the baking, then I change the color of the directional light , then with directional and spot light together, the frame rate is very low I wonder why. Two spot lights baked
  13. DO it like I do, just start a regular project then import a new custom package FROM a new exporter unity package I download all babylonjs git hub then I load the package , then will import it all then you can follow the first video let me know if that helps
  14. Hi @TonikCG did you try the way @MackeyK24 does it on the VIDEO-LINK minute 16 ? check when he creates the amiga shader .. I hope this helps, I'm currently texting the baking with simple mesh (cube planes.. ) the I will do it for bigger scenes and report my findings.
  15. Hey @TonikCG let me know how it goes with the shader, I will tray to use this later, for now I'm testing the other features
  16. Hi @MackeyK24 I hope you had a great Christmas.. OK, I will check on these 3 types of collision, I just want to put it all together with particles and some other features I build in other scenes. then I will send you the link to download package. thanks
  17. HI @MackeyK24 I Im working with a terrain and a ship and they are going trough each other, can you please explain how to make them collide so my ship goes on the surface of my terrain? Thank you.. TERRAIN SETUP BOAT SETUP
  18. Ok I see @MackeyK24 hey check this video we should create some PBR Shaders for an scene like this what do you think @chloridrik
  19. its almost there so the lights are baked on the Babylon picture, is there an external light source or juts the baked mesh ? @chloridrik
  20. @MackeyK24 nice I will use the update button later from the Babylon unity tab tool ,thanks @chloridrik, I made a small menu for the API video so is easier to follow while the docs are ready API-VIDEO • 0:00 min Setting the babylo.js exporter tabs • 12:00 min Create playground scene • 17:00 min Building a Babylon component • 18:30 min Audio, Flare, Particles components overview • 20:00 min Creating a Tester Class with the Babylon script component • 22:00 min Mesh component explained • 24:00 min How to create component type script and its GUI C# class back end • 26:48 min Scene builder class get component property values explained • 30:11 min inline JavaScript insertion • 33:10 min Mesh component script class • 35:08 min Encapsulation • 38:00 min Baking class component explained • 39:30 min Unity game object layering and tagging system over view • 41:00 min Metadata explained • 47:00 min MyRotateX script component class • 49:45 min Accessing components from another component • 54:30 min Creating scene controller • 60:30 min Accessing camera, Lights, mesh components • 63:40 min Babylon loader overview, scene manager components and objects • 66:25 min Unity game object • 66:41 min Scene manager class explained • 74:30 min GUI html markup ‘hello world’
  21. I'm testing light baking today @chloridrik let me know if you have any luck...
  22. Terrain export works works amazing and easy to use here is an scene in vr but takes time to load just be patient I will fix it later to load faster here is the link, tomorrow I will work on the game-pads MrVR out!!!
  23. It worked I added your code and I call it in the initUpdate() function with this Tools.EnableRemoteCertificates(); [MenuItem("BabylonJS/Update Libraries", false, 2)] public static void InitUpdate() { Tools.EnableRemoteCertificates(); string prodVersion = ExporterWindow.exportationOptions.ProductionVersion.ToString(); if (prodVersion.IndexOf(".", StringComparison.OrdinalIgnoreCase) < 0) { prodVersion += ".0"; } ......
  24. I Agree @Deltakosh is a lot of features to be covered @MackeyK24 About the game-pad, I will test tonight at home cause my work computer dont have Bluetooth for my controller I have to get an adapter. but will create the support for the game pad Stratus XL For the docs and videos Im going over the API video, I wish I can put time editing it but for now I can provide a time line, (working in progress ), from the video so we can navigate easy where you talk about different features while the documentation is build. I was working this morning with the particles system and I get this error every time I change something in the script component for the the particle system I have to add the texture for the flare again every time something change. I will create another projects to test and make sure I get this error every-time or not any ways just changing the particle image fix it for now UnauthorizedAccessException: Access to the path "Assets/Resources/Optical Flares Textures/Elements/Light_Glass.png" or "C:/Users/cvega.BI/Desktop/MACKEY24/MACKEY24/Mackey24/Project/Scenes\Light_Glass.png" is denied. Then When I try to do the update for the libraries I get this error warning Failed to download: https://raw.githubusercontent.com/BabylonJS/Babylon.js/master/dist/cannon.js - Error getting response stream (Write: The authentication or decryption has failed.): SendFailure UnityEngine.Debug:LogWarning(Object) Unity3D2Babylon.Tools:DownloadFile(String, String) (at Assets/Babylon/Source/Tools.cs:250) Unity3D2Babylon.ExporterWindow:InitUpdate() (at Assets/Babylon/Source/ExporterWindow.cs:124) I debugged a little bit and I get this message from VSudio2015 "System.Net.WebException: Error getting response stream (Write: The authentication or decryption has failed.): SendFailure ---> System.IO.IOException: The authentication or decryption has failed. ---> Mono.Security.Protocol.Tls.TlsException: Invalid certificate received from server. Error code: 0xffffffff800b010a\r\n at Mono.Security.Protocol.Tls.Handshake.Client.TlsServerCertificate.validateCertificates (Mono.Security.X509.X509CertificateCollection certificates) [0x00000] in <filename unknown>:0 \r\n at Mono.Security.Protocol.Tls.Handshake.Client.TlsServerCertificate.ProcessAsTls1 () [0x00000] in <filename unknown>:0 \r\n at Mono.Security.Protocol.Tls.Handshake.HandshakeMessage.Process () [0x00000] in <filename unknown>:0 \r\n at (wrapper remoting-invoke-with-check) Mono.Security.Protocol.Tls.Handshake.HandshakeMessage:Process ()\r\n at Mono.Security.Protocol.Tls.ClientRecordProtocol.ProcessHandshakeMessage (Mono.Security.Protocol.Tls.TlsStream handMsg) [0x00000] in <filename unknown>:0 \r\n at Mono.Security.Protocol.Tls.RecordProtocol.InternalReceiveRecordCallback (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 \r\n --- End of inner exception stack trace ---\r\n at Mono.Security.Protocol.Tls.SslStreamBase.AsyncHandshakeCallback (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 \r\n --- End of inner exception stack trace ---\r\n at System.Net.HttpWebRequest.EndGetResponse (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 \r\n at System.Net.HttpWebRequest.GetResponse () [0x00000] in <filename unknown>:0 \r\n at System.Net.WebClient.GetWebResponse (System.Net.WebRequest request) [0x00000] in <filename unknown>:0 \r\n at System.Net.WebClient.DownloadFileCore (System.Uri address, System.String fileName, System.Object userToken) [0x00000] in <filename unknown>:0 \r\n at System.Net.WebClient.DownloadFile (System.Uri address, System.String fileName) [0x00000] in <filename unknown>:0 "