[X3D-Ecosystem] PhysicalMaterial test case

Vincent Marchetti vmarchetti at kshell.com
Tue Dec 9 03:27:17 PST 2025


Michalis

Thank you for the links and the suggestions.

I have tried the route

Blender material  -- (Blender glb export) --> glb file -- (castle viewer import ) --> Castle Scene -- (castle "Save As" X3D ) --> X3D file

on that dimpled_brass example and got a X3D file that gave good visual results in:
-- Castle Model Viewer (to be expected, given the way the X3D file was created!)
-- X_ITE
-- X3DOM (once the X3D PhysicalMaterial attributes were renamed for the X3DOM node signature)

I hope to have this result available for public viewing by the next WG call.

I do want to be sure that we don't limit our examples to Blender materials that are generated by the Blender glTF extension, although if it turns out that those Blender materials are the only ones relevant to X3D content authors, then an automated version of the "Blender through Castle Model Viewer" path might meet the users' needs.

Vince Marchetti


> On Dec 8, 2025, at 8:11 AM, Michalis Kamburelis <michalis at castle-engine.io> wrote:
> 
> You can use some existing Castle Game Engine or Khronos glTF testcases:
> 
> metallic_roughness.blend, monkeys.blend from https://github.com/castle-engine/demo-models/tree/master/blender/simple . There are Blender input files, and glTF outputs. If you convert the glTF to X3D using Castle Model Viewer, you get a representation of Blender material as X3D PhysicalMaterial.
> 
> Khronos sample glTF assets from https://github.com/KhronosGroup/glTF-Sample-Assets/ can be used for this too. You can import them into Blender, the glTF->Blender importer will usually do a proper job and express the material as Blender PBR material (and can be exported back to glTF for the same result). And then, you can convert glTF->X3D using Castle Model Viewer to get X3D PhysicalMaterial expressing the same thing. E.g. see https://github.com/KhronosGroup/glTF-Sample-Assets/tree/main/Models/DamagedHelmet , https://github.com/KhronosGroup/glTF-Sample-Assets/tree/main/Models/FlightHelmet .
> 
> I know this is not directly what you asked for, I hope to have time to prepare more tests :) But the above is what I have "already available" :)
> 
> Regards,
> Michalis
> On Sunday, December 7th, 2025 at 22:29, Vincent Marchetti via X3D-Ecosystem <x3d-ecosystem at web3d.org> wrote:
>> I am following up on my previous proposal (to this mailing list, 4 Dec 2025) to start some examples of material examples based on Blender shader nodes that could (or should, or might be) expressed in X3D PhysicalMaterial node and rendered in the latest viewers.
>> 
>> I've prepared a Blender file name "dimpled-brass...", it's intended to be colored  reminiscent of brass, with suitable shininess and roughness factors, and a normal map - texture that's supposed to make you think of rivet heads. In the blender file this material is just applied to a very simple rectangular plane mesh.
>> 
>> I'm posing a challenge open to all to convert this to X3D as a fast, one-off effort; prepare the PhysicalMaterial node  by hand, use some existing conversion chain, or ask Grok to do it. The results will provide a good starting point to prepare an in-Blender conversion script that will handle more than just this simple case.
>> 
>> Please don't submit blender or texture files to the mailing list; give links to a Google folder, or send them to me individually (at vmarchetti at kshell.com ) and I'll make them accessible to all.
>> 
>> Any additional ideas or examples of materials from Blender to add are welcome as well, though I would recommend that we keep the geometry simple in these examples.
>> 
>> 
>> The example files are in the Google Drive folder at https://drive.google.com/drive/folders/1Trd4gJXfO680eNJOna33d89KgyfK5Zqb?usp=sharing containing:
>> 
>> dimpled_brass.blend
>> textures/normal_map_dimples.png. — image used In blend file as source for a normal map textures.
>> material_swatch_template — an X3D file with a mesh definined by a IndexedFaceSet that defines geometric and texture coordinates apprpriate for rendering the PhysicalMaterial in x3d
>> 
>> 
>> [the textures file containing the image must be downloaded to the same local file folder as the .blend file]
>> 
>> 
>> 
>> 
>> Screen shot: Blender Viewport rendering of material.
>> 
>> <utf-8Screenshot 2025-12-07 at 3.00.29 PM.png>
>> 
>> Vince Marchetti
>> 
>> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-ecosystem_web3d.org/attachments/20251209/dc8876e1/attachment-0001.html>


More information about the X3D-Ecosystem mailing list