Corona Renderer Forum

Corona Renderer for 3ds Max => [Max] General Discussion => Topic started by: Polymax on 2013-09-21, 22:26:29

Title: Warning!!! Disable bitmap paging!
Post by: Polymax on 2013-09-21, 22:26:29
This must be uncheck, otherwise you will receive a slowdown render to 3-4 times! Need to restart 3dsMax or save and reopen the scene after uncheck!
Title: Re: warning!!!
Post by: maru on 2013-09-22, 10:04:56
Interesting, I never knew such window existed. :) This might explain a lot!
Title: Re: warning!!!
Post by: Ludvik Koutny on 2013-09-22, 10:33:37
Yes, please everyone check for bitmap paging. You should always have it disabled.
Title: Re: warning!!!
Post by: lacilaci on 2013-09-22, 11:05:02
Somehow I thought this bitmap paging applies only to mental ray or scanline, how come it affects corona aswell? :D
Title: Re: warning!!!
Post by: Ondra on 2013-09-22, 12:58:57
Somehow I thought this bitmap paging applies only to mental ray or scanline, how come it affects corona aswell? :D
because all CPU renderers use the same texmap interface of 3dsmax. Texmaps are evaluated in 3dsmax, not in renderer.
Title: Re: warning!!!
Post by: Polymax on 2013-09-22, 13:10:50
This option (Page tex) is enabled globally by 3dsmax scene and 3ds max does not warn about it.
Ie if you open another scene in which this parameter is on, then you will remain constantly active, even after rebooting 3dsmax.
I think this is a BIG BUG of the 3dsMax.

Return unto me several people with the problem of very long render simple scenes, and after 4 hours of searching I managed to find the cause.
Title: Re: warning!!!
Post by: hglr123 on 2013-09-24, 18:42:40
Just create maxstart.max file and you will be fine. :)
Title: Script for startup scripts folder
Post by: 3dwannab on 2015-01-16, 23:29:28
Only seeing this now, cheers Pmax :).

In maxscript. Type this into listener or you can place this in a file with .ms extention (attached) or better yet place it in your directory - bold text differs: C:\Users\user\AppData\Local\Autodesk\3dsMax\2014 - 64bit\ENU\scripts\startup

This will run on every existing file opened from here on in.

Code inside .ms file attached.
Code: [Select]
if IBitmapPager.enabled == true do IBitmapPager.enabled = false
Title: Re: warning!!!
Post by: DeadClown on 2015-01-16, 23:35:29
Don't forget that you have to save and reopen the scene, otherwise this ms command won't have any effect.
Title: Re: warning!!!
Post by: 3dwannab on 2015-01-16, 23:44:11
Sorry, missed that in the maxscript help. http://bit.ly/1E8dzQT

Quote
This value does not take effect until the scene is reloaded!  The value can be modified superficially at any time. The value is written to the file upon file save. However, disk paging never becomes enabled or disabled except when a scene is loaded, so changes to the value do not take effect unless the scene is saved and then reloaded!
Title: Re: warning!!!
Post by: 3dwannab on 2015-01-17, 03:33:00
Don't forget that you have to save and reopen the scene, otherwise this ms command won't have any effect.
I've been toying around with some maxscript and I've done up this code.

Code: [Select]
         on chk_ibitmappager changed state do
        if state then
            (
                IBitmapPager.enabled = true
                chk_ibitmappager.text = "!"
                chk_ibitmappager.state = on               
                if querybox "BitmapPager is enabled !\n\nThis script will save and reload the file for you, do you want to do this now ?\n\n\nThis enabled will slow down render times !" title:"Save and Reopen file?"   
                then
                    (
                        if maxFilename == "" then getSaveFileName() else
                        file = (maxFilePath + maxFilename)
                            if file == undefined then messagebox "Output file not set, try again !" title:"RegionRender V2.0 by 3dwannab (◣_◢)"  beep:true
                                else
                                (
                                --saveNodes #() file quiet:on                                   
                                checkForSave()
                                saveMaxFile file quiet:on
                                loadMaxFile file quiet:on   
                                )
                    )
                    else
                    (
                    -- nada
                    )
            )
        else
            (
            IBitmapPager.enabled = false
            chk_ibitmappager.text = "☻"
            chk_ibitmappager.state = off
                if querybox "BitmapPager is disabled !\n\nThis script will save and reload the file for you, do you want to do this now ?\n\n\nYour render times should x3 to x4 times faster now !" title:"Save and Reopen file?"   
                then
                    (
                        if maxFilename == "" then getSaveFileName() else
                        file = (maxFilePath + maxFilename)
                            if file == undefined then messagebox "Output file not set, try again !" title:"RegionRender V2.0 by 3dwannab (◣_◢)"  beep:true
                                else
                                (
                                --saveNodes #() file quiet:on
                                checkForSave()
                                saveMaxFile file quiet:on
                                loadMaxFile file quiet:on   
                                )
                    )
                    else
                    (
                    -- nada
                    )
            )

The above can be mapped to a button called 'chk_ibitmappager'. I've a script out called RegionRender and I'll be putting this in it. If you find this useful for your converter script Deadclown by all means go ahead and use the code.

There's only mainly 4 important lines in here anyway:
 
Code: [Select]
--saveNodes #() file quiet:on
                                checkForSave()
                                saveMaxFile file quiet:on
                                loadMaxFile file quiet:on 

I'm not sure if the saveNodes function is required but I read somewhere that it was (I've disabled it here). But this bit of code will load the max file as silently as possible without any need to do anything in one click. (Well two)
Title: Re: warning!!!
Post by: DeadClown on 2015-01-17, 12:25:36
"saveNodes" is equal to the save selected function in max, you just save the selected objects / an array of nodes as a new max file.

I thought about implementing some "typical problems" checks, but I'm not sure yet how or if I'm going to do that.
Title: Re: warning!!!
Post by: 3dwannab on 2015-01-17, 13:20:24
Thanks, what typical problem checks should I look out for.