Solved

Retrieve Texture Name

  • 12 January 2023
  • 4 replies
  • 24 views

Badge +1

I have FBX files with various textured 3D objects.

The FBX includes file names for these texture files, eg. "textures\\asphalt2.jpg" and when FME loads the FBX, those textures are created as local JPG files in a folder .fbm.

 

Essentially I need the texture name (filename) within FME. I can pull the individual textures as rasters as per the attached, but they dont have a name, specifically the filename.

 

The closest I can find is the ShareItemID for each texture. How can I link the SharedItemID to the texture filename?

 

Example attached.

icon

Best answer by daveatsafe 17 January 2023, 00:03

View original

4 replies

Userlevel 2
Badge +17

Hi @kelvin.jenkins​,

The texture image file names are not retained by the FBX reader, but you can derive this info by using the logic in the attached workspace.

Screen Shot 2023-01-16 at 2.59.13 PM

Badge +1

Hi @kelvin.jenkins​,

The texture image file names are not retained by the FBX reader, but you can derive this info by using the logic in the attached workspace.

Screen Shot 2023-01-16 at 2.59.13 PM

Legend!

Thanks so much

Badge +1

Legend!

Thanks so much

Thanks again @daveatsafe​ 

Is there a way to run this process on FME server? I'm getting errors saying it can't find the .FBM folder.

Does server Cache texture files elsewhere?

 

From the Log, it reads the FBX:

1002023-1-25 11:19:43 | R_2: Closing FBX dataset 'C:\\ProgramData\\Safe Software\\FME Server\\resources\\system\\temp\\upload\\KLJ_Test\\Infraworks Drafter Mapping.fmw\\984af7c4-437b-9dc8-ab90-9c812769161d\\ground_small.fbx'

 

Then queries the expected directory:

2023-1-25 11:19:43 | Performing query against JPEG dataset `""C:\\ProgramData\\Safe Software\\FME Server\\resources\\system\\temp\\upload\\KLJ_Test\\Infraworks Drafter Mapping.fmw\\984af7c4-437b-9dc8-ab90-9c812769161d\\ground_small.fbm\\*'

 

But finds no files:

2023-1-25 11:19:43 | JPEG reader: file '""C:\\ProgramData\\Safe Software\\FME Server\\resources\\system\\temp\\upload\\KLJ_Test\\Infraworks Drafter Mapping.fmw\\984af7c4-437b-9dc8-ab90-9c812769161d\\ground_small.fbm\\*' cannot be located. Please ensure the file exists and is accessible

Userlevel 2
Badge +17

Legend!

Thanks so much

HI @kelvin.jenkins​,

I seem to have two FBX readers in the workspace. Please delete the first one, then republish the workspace and see if the problem continues.

Reply