ScriptSpot

Forum topic · General Scripting

Change map property to entire scene

By xathletic01x · 2014-06-26

Description

Hello - I want to be able to change values such as below to the entire scene. I use VRay materials. It would be nice if it can do it for every types of materials.

1- texmap diffuse filtering to the entire scene. There are three options.

Pyramidal .texmap_diffuse.filtering = 0
Summed Area .texmap_diffuse.filtering = 1
None .texmap_diffuse.filtering = 2

2- Change blur of ONLY diffuse maps to value I set.

.texmap_diffuse.coords.blur = (value i set)

3- Change Gamma on the map to value i define.

tmap.bitmap.inputGamma

Comments (5)

Selected objects/materials only?

Stenrik · 2018-09-17

This is helpful, Pixamoon - thanks.

Now I'd like to apply this setting change ONLY to the materials of selected objects, and/or only highlighted materials in the editor. Is there an easy way to do this?

jahman · 2018-09-20

..

set filtering to none for entire scene

Cabbage · 2015-07-03

can anyone post a some code i can make a button out of to set all scene bitmaps to none filtering?

`

pixamoon · 2015-07-08

sure, this will change bitmap filtering to None in entire scene

for o in getClassInstances BitmapTexture do o.filtering = 2

gamma setting

pixamoon · 2015-07-08

Hi,

To change filtering for all bitmap in entire scene:


for o in getclassinstances BitmapTexture do o.filtering = 0

to change blur only in diffuse of VRayMtl:


for o in getclassinstances VRayMtl where o.texmap_diffuse != undefined and classof o.texmap_diffuse == bitmaptexture do 
o.texmap_diffuse.coords.blur = 1

But it works only if bitmap is just in diffuse slot. If its deeper (for eg in mix) it wont work anymore.

Similar to other types of materials (Standard, CoronaMtl etc)

To read gamma is easy but to change more complicated. But you can change gamma with my Bitmap Tracking/Resizing....
http://www.scriptspot.com/3ds-max/scripts/bitmap-tracking-resizing

Hope it helps,
Pixamoon