Pcbnew: VRML Export: Footprint-relative 3D Models

CHANGED: Provide the footprint base path as the working directory to the
3D shape cache such that 3D models relative to the footprint may be
correctly resolved when exporting a PCB as VRML.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14505
This commit is contained in:
Brian Lu
2025-04-10 06:55:26 -07:00
committed by Seth Hillbrand
parent 65a49cc3ba
commit ea4b2b73bb
+1 -1
View File
@@ -1110,7 +1110,7 @@ void EXPORTER_PCB_VRML::ExportVrmlFootprint( FOOTPRINT* aFootprint, std::ostream
aOutputFile->precision( m_precision );
wxFileName srcFile =
m_Cache3Dmodels->GetResolver()->ResolvePath( sM->m_Filename, wxEmptyString, aFootprint );
m_Cache3Dmodels->GetResolver()->ResolvePath( sM->m_Filename, footprintBasePath, aFootprint );
wxFileName dstFile;
dstFile.SetPath( m_Subdir3DFpModels );
dstFile.SetName( srcFile.GetName() );