Open
Description
I made a asp.net (dotnet 8) web app to convert a ifc file to gltf but when deployed to azure (standard winx64 dotnet appservice plan) it generates a gltf with missing geometry. I tried all sort of combinations, self-contained single file, x64, x86, and the default dotnet 8 runtime.
There are no errors and I exhausted all possible deployment configuration options.
I'm using the latest stable releases:
<PackageReference Include="Xbim.Essentials" Version="6.0.445" />
<PackageReference Include="Xbim.Geometry" Version="5.1.541" />
<PackageReference Include="Xbim.Gltf.IO" Version="5.1.120" />
This is the main code snipped that generates the gltf:
public static byte[] CreateGltf(Stream ifcFileStream)
{
using var ifcStore = IfcStore.Open(ifcFileStream,
Xbim.IO.StorageType.Ifc,
Xbim.Common.Step21.XbimSchemaVersion.Ifc2X3,
Xbim.IO.XbimModelType.MemoryModel);
var context3DModel = new Xbim3DModelContext(ifcStore);
context3DModel.CreateContext(null, false);
var sceneBuilder = new Builder();
var gltf = sceneBuilder.BuildInstancedScene(ifcStore, XbimMatrix3D.Identity, new List<Type>
{
typeof(IIfcSpace),
typeof(IIfcFeatureElement)
});
using (var memoryStream = new MemoryStream())
{
Interface.SaveModel(gltf, memoryStream);
return memoryStream.ToArray();
}
}
I would love to find out how to fix this issue, in theory there should be no difference between my dotnet runtime and the one on azure. Could this be a floating point precision issue?