@tig said:
The API code does allow you to change the two values of the texture size - in just the same as you can do manually - the default size is 10" (254mm).
I don't see how you can do it 'on the fly' as you make materials [you could simply adjust the size anyway - as you ought], but it'd be quite possible to write some code to change all textured materials to a different fixed size, and also use a default texture image on any untextured materials, also to that fixed size too. It'd then run the exporter, so that the external file matches these settings; on completion it could then do an 'abort_operation' to revert all of the materials as they were, leaving the external export-file unaffected. Alternatively it could change all of the texture sizes permanently and just use the temp-texture for non-textured materials for the export part, reverting those materials to be 'plain' afterwards...
If you manually ad a texture, resize it then remove the texture does the 'plain' material export with different mapping info ? e.g. it's previous texture size is remembered ? I've not tested this, if it does then you could temporarily add a texture to each untextured material, resize it and then remove the texture ?
Hi there TIG!
This thread is kind of old, but I would still be neat to know if it's possible to change the default tile size, so thanks for answering there. More precisely: I don't need to change any preexisting materials "on the fly" and I don't need to change the sizes for materials with textures. What would be handy is changing the default UV tile size in material properties, globally, for every material SketchUp is creating.
That would be a very useful safeguard feature for newbies not yet fully utilizing materials (no matter if they won't use placeholder materials and size values, their models will have reasonable UV sizes and will look decent with various in-engine materials). Or a neat help, for example, for level designers quickly prototyping geometry under strict deadlines: they will be able to slap several material types to separate a scene as needed, then replace these fills with suitable materials (like various concrete types) in the engine afterwards. All and all, having 10x10cm as default UV tile size is impractical.
The idea of assigning a placeholder texture to every untextured material, changing then available size values and disabling the texture after that sounds practical. Unfortunately, if I remember correctly, removing a texture removes tile size values from a material too, so these changes will be immediately lost.