How to get Material Edit Window position (UI)/ How to update hardware maps

It´s 2 questions.

i tryed everywhere to find my self the anwswer but im stuck…

first is:

There is a way to find the material editor window position (ui) and it scale (height/width). like… i tryed looking at UIAccessor. but no get position in documentation.

I saw a way to get that from unrwap window (Ex.:<Unwrap_UVW>.getWindowX()) but its strictly to Unwrap window.

I want a script to stack right next to material window (follow it around with a fixed off set)

second is:

i want to execute a update textures in viewport for hardware maps (like once u change a normal map, for exemple, it update the viewport (right now i need to clic in disable material in viewport and turn it on again… must say that .showInViewport or .enabled didnt make the trick )

Thanks in advance

About the material editor, you can probably get/ser the position off the ini file:

setIniSetting ((getDir #maxdata) + "3dsmax.ini") "MtlEditorPosition" "MainWindow" width height posX posY

What type of hardware shaders, directx material or scripted dx material?

how are you changing the normal map, by script or the ui?

I would mess with the options in your drivers first, they should update.

Sometimes I’ve had max refuse to change a texture no matter what though!

KIT , tks ill try that (need check if it update the position if user move window around).

mikiex, This screenshot shows what im using to preview Normal Map in 3Dmax viewport, its not a custom DX shader just the regular material option.


I want to reproduce what u get if u double clic this button (disable->enable)

i tryed .showInViewport or .enabled but it dosent reproduce exaclty what it should (the double clic can reload the texture in someway i didnt found yeat.)

ill check my drive options also, tks…

Rly tks for both replies

KIT, it dosent Update (with user moving it around) but it save everytime u close the windows (i guess u all new that already). im using that so if u close or open again the material window it update the mydialog relative position … so it works. =)

Yhea I guess that’s the best you can do. AFAIK the UIAccesor has no method for returning window position/size.