We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

web

Forum Replies Created

Viewing 15 posts - 46 through 60 (of 213 total)
  • Author
    Posts
  • in reply to: Replace all textures on runtime #37943
    web
    Customer

    hey gliftek,
    wasn’t very active here the last weeks. I’m not really sure what you want to achieve. I was just trying to create a function which switches all the textures in the scene on load.

    This is the function I’ve written for that purpose:

            function loadFullResTextures(imageformat){
                setTimeout(function(){ 
                    app.scene.traverse(function(obj){
                        if(obj.material && obj.material.type == 'MeshNodeMaterial'){
                            var mat = obj.material;
                            
                            for (var i_index in mat.nodeTextures){
                                var imageSrc = mat.nodeTextures[i_index].image.src;
                                var imageFilename = imageSrc.split('\\').pop().split('/').pop();
                                var imageFilenameNoSuffix = imageFilename.split('.').slice(0, -1).join('.');
                        
                                var loader = new v3d.ImageLoader();
                                loader.setCrossOrigin('Anonymous');
                     
                                loader.load(url + '/assets/full/' + imageFilenameNoSuffix + imageformat, function(texture) { 
                                    mat.nodeTextures[i_index].image = texture;
                                    mat.nodeTextures[i_index].format = v3d.RGBFormat;
                                    mat.nodeTextures[i_index].needsUpdate = true;
                                })
                     
                            }
                        }
                    });
                }, 2000);
            }

    You need to pass the filetype when executing the function.
    loadFullResTextures('.jpg');
    or
    loadFullResTextures('.webp');

    For my purpose its working good. This way I can have low res textures which are getting loaded by v3d by default and execute that function to load the full res versions afterwards. This speeds up the whole loading time for the app. You can also alter the function to add more variables, and do different loading as needed. For example different textures for different devices.

    in reply to: Blurry Shadow #36755
    web
    Customer

    It did help a tiny bit, but not that much.

    But if there is currently no way to get sharp shadows in such a scene, so be it. :)

    in reply to: Lookat constraint – Keep offset being ignored #36560
    web
    Customer

    Is it possible to implement that option in future versions?

    Is there any other option, maybe with the constrain puzzles from verge? I’m trying to recreate the slight rotation effect when you move the cursor. So that the geometry is always facing to the mouse cursor with a slight delay.


    @psedlacek

    Yeah, I already thought about constraining the object and then rotating the pivot so that its facing the correct way, just a bit tedious.

    in reply to: Verge3D 3.6 pre1 available! #36479
    web
    Customer

    Is it possible that 3dsMax constrains arent working anymore in 3.6pre1? I got a simple scene with a group constrained with a lookat to a dummy object. In max when I move that dummy object, the group is rotating based on the dummy position. But in verge nothing is happening, no matter if I move the dummy via verge or I export the glft with keyframe animation to the dummy.
    Never mind, seems I got some issues with the scene I’m working with. In a new one its working as expected.

    in reply to: Verge3D 3.6 pre1 available! #36472
    web
    Customer

    Max restart worked.

    in reply to: Verge3D 3.6 pre1 available! #36392
    web
    Customer

    Got one error exporting in a pretty simple scene. Got the same error with version 3.5:

    -- Error occurred in anonymous codeblock; filename: C:\Users\user\verge3d_max\max_plugin\verge3d.ms; position: 22793; line: 596
    -- MAXScript MacroScript Error Exception:
    -- Runtime error: 
    Traceback (most recent call last):
      File "<input>", line 1
      File "C:\Users\user\verge3d_max\max_plugin\__init__.py", line 183, in 'exportCleanup' function
    AttributeError: 'pymxs.MXSWrapperBase' object has no attribute 'V3DExportSettingsData'
    
    -- MAXScript callstack:
    --	thread data: threadID:28432
    --	------------------------------------------------------
    --	[stack level: 0]
    --	In sneakPeek(); filename: C:\Users\user\verge3d_max\max_plugin\verge3d.ms; position: 22794; line: 596
    --	member of: StructDef:V3DManagerStruct
    --		Locals:
    --		Externals:
    --			owner: (V3DManagerStruct V3D_MENU_CONTEXT:3.82914e+09 autoAssignAttrs:false settingsFile:"$userscripts/Verge3D/settings.ini" debug:false hasInitiated:true smeClock:dotNetObject:System.Windows.Forms.Timer)
    --			importPython: Struct member:importPython : V3DManagerStruct.importPython()
    --	------------------------------------------------------
    --	[stack level: 1]
    --	called from codeblock macroScript: Verge3D_sneakPeek; filename: C:\Users\user\verge3d_max\max_plugin\verge3d.ms; position: 501; line: 26
    --		Locals:
    --		Externals:
    --	------------------------------------------------------
    --	[stack level: 2]
    --	called from top-level

    Could fix the first issue, with copying the objects to a new scene. Dont know what the issue with the old scene. Even with all objects deleted from the scene I got the above error.

    But now I got a new one, which seems to be related to 3.6 pre1. I can no longer export with compression enabled. As soon as I’m trying to export I get this error:

    V3D-INFO: Exporting glTF 2.0 asset (ASCII)
    V3D-INFO: Generating default light
    V3D-INFO: Generating default light node
    V3D-INFO: Compressing file: W:\assets\test02.gltf
    -- Error occurred in anonymous codeblock; filename: C:\Users\user\verge3d_max\max_plugin\verge3d.ms; position: 21812; line: 558
    -- MAXScript MacroScript Error Exception:
    -- Runtime error: 
    Traceback (most recent call last):
      File "<input>", line 1
      File "C:\Users\user\verge3d_max\max_plugin\__init__.py", line 99, in 'exportGLTF' function
      File "C:\Users\user\verge3d_max\max_plugin\__init__.py", line 147, in 'exportGLTFPath' function
      File "C:\Users\user\verge3d_max\max_plugin\generate.py", line 1653, in 'save' function
      File "C:\Users\user\verge3d_max\max_plugin\generate.py", line 1632, in 'compressLZMA' function
      File "C:\Users\user\verge3d_max\max_plugin\..\python\pluginUtils\manager.py", line 91, in 'compressLZMA' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\http\client.py", line 1252, in 'request' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\http\client.py", line 1298, in '_send_request' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\http\client.py", line 1247, in 'endheaders' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\http\client.py", line 1026, in '_send_output' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\http\client.py", line 966, in 'send' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\http\client.py", line 938, in 'connect' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\socket.py", line 728, in 'create_connection' function
      File "C:\Program Files\Autodesk\3ds Max 2021\Python37\lib\socket.py", line 716, in 'create_connection' function
    ConnectionRefusedError: [WinError 10061] Es konnte keine Verbindung hergestellt werden, da der Zielcomputer die Verbindung verweigerte
    
    -- MAXScript callstack:
    --	thread data: threadID:4476
    --	------------------------------------------------------
    --	[stack level: 0]
    --	In exportGLTF(); filename: C:\Users\user\verge3d_max\max_plugin\verge3d.ms; position: 21813; line: 558
    --	member of: StructDef:V3DManagerStruct
    --		Locals:
    --		Externals:
    --			owner: (V3DManagerStruct V3D_MENU_CONTEXT:3.82914e+09 autoAssignAttrs:false settingsFile:"$userscripts/Verge3D/settings.ini" debug:false hasInitiated:true smeClock:dotNetObject:System.Windows.Forms.Timer)
    --			importPython: Struct member:importPython : V3DManagerStruct.importPython()
    --	------------------------------------------------------
    --	[stack level: 1]
    --	called from codeblock macroScript: Verge3D_exportGLTF; filename: C:\Users\user\verge3d_max\max_plugin\verge3d.ms; position: 277; line: 11
    --		Locals:
    --		Externals:
    --	------------------------------------------------------
    --	[stack level: 2]
    --	called from top-level
    in reply to: Verge3D 3.6 pre1 available! #36366
    web
    Customer

    I’m already using it as standard for all projects. Was just hoping to reduce file size even more. Or doesnt the instancing with file compression enabled reducing the file size even further?

    in reply to: Verge3D 3.6 pre1 available! #36356
    web
    Customer

    As usual, great work guys :good:

    Will the missing geometry instancing for 3dsMax be implemented in 3.6?

    in reply to: Verge3D 3.5 pre4 available! #35529
    web
    Customer

    Not sure about 3.5 but this task has been given a high priority

    Great news, really looking forward to this. Cause we using forest pack in many project and also many ouf our normal geometries are instances. Should really see a performance and file size improvement when this is enabled.

    Regarding the car game demo:
    Tested it on a S10, works so far. Only glitch I have that when I accelerate and steer together I’m zooming in our out. He detects the two finger as pinch-to-zoom.

    in reply to: Verge3D 3.5 pre4 available! #35489
    web
    Customer

    Great additions :good:

    Any chance that geometry instancing for 3dsMax will make it way into the final 3.5 build?
    See question here:

    geometry instancing

    in reply to: assign materials with JSfunction #35252
    web
    Customer

    Just a question. But why are you going the Javascript way if you are not a coder, when you have puzzles? They should do the job quite easy for someone without that coding knowledge.

    in reply to: Outline effect jagged #35146
    web
    Customer

    Ah okay. Is WebGL 1.0 forced when you enable outlines?

    Can you enable FXAA via JavaScript? Couldnt find the option in the Api documentation.

    Would it be possible to implement a search option in the Api documentation? Many times i dont really know, where a option is set and just clicking around to find it.

    in reply to: geometry instancing #35085
    web
    Customer

    I would also up this question. How can we achieve geometry instancing via 3dsMax?

    web
    Customer

    This is because of the verge params which getting added for every object created by default. To fix this you can uncheck “auto assign …” in the verge3d dropdown.

    In order to remove these params in a already “present” scene. You can go to “Utilities” -> “Max Script” -> “Verge3D”. There you have the option to delete all verge params. Just select all objects in the scene and click the “remove verge3d params” button.

    in reply to: Hover intent functionality #35061
    web
    Customer

    Yeah, you can achieve that functionality with simple timeout functions. This is how I got it running in my current setup. But I think it would be great to implement this as a standard in the hoverPuzzle.

    I can see atleast no drawbacks in setting this as a standard behaviour.

Viewing 15 posts - 46 through 60 (of 213 total)