retrieving original path of missing bitmap

 
mat = $.mat
 
for prop in (getPropNames mat) do 
(
	if (superclassof (getProperty mat prop)) == texturemap do 
	(
		tex = (getProperty mat prop)
		for item in (getPropNames tex) do 
		(
			if item == #filename do
			(
				print (getProperty tex item)
			)
		)
	)
 
)

Running this code, I can get a list of bitmap files used for the selected object.
But how can I get their paths, also if them are missing?

Thanks,
David

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
barigazy's picture

...

Look at my last post on this thread http://www.scriptspot.com/forums/3ds-max/general-scripting/get-classinst...
With this recursive fn you can collect all maps, and then just check filepaths using "doesFileExist " ei replace commented line with this

for i in mapsArr where not doesFileExist i.filename do print i.filename

barigazy

David_Lee's picture

seems not work here...

Thanks for your help barigazy, but it returns only the filename, not his original path :(

barigazy's picture

...

You can't find original path with mxs.

barigazy

David_Lee's picture

another reason to hate Max...

another reason to hate Max... -.-'

barigazy's picture

...

I not know how other 3D package solve this problem, but max is very limited

barigazy

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.