PDA

View Full Version : Grabviewport 2.5 New Release


Ravenslayer
01-01-2012, 01:05 PM
hey guys, first of all happy newyear
i'm glad to say i have a holiday present for you :)


http://leslievdb.com/GV_images/Title.png


http://leslievdb.com/GV_images/fullUI.png



Grabviewport is a FREE MaxScript that enables you to take High Resolution Screenshots of your 3ds Max Viewport.
It also offers you the options to capture animations as well as multiple passes that can later be used for compositing your final presentation image.
http://leslievdb.com/GV_images/moreinfo_button.png (http://leslievdb.com/grabviewport.htm)

Nysuatro
01-01-2012, 01:59 PM
Sexy stuff mate, will try it out soon.

Ravenslayer
01-02-2012, 03:35 AM
tnx Nysuatro ^^

For the people who already downloaded the script

Did a very minor tweak to the script so it doesn't show the gizmo anymore when in zdepth mode. This seemed to be a problem in some max versions.

Updated Script available here (http://leslievdb.com/grabviewport.htm)

mLichy
01-02-2012, 07:22 AM
Works good :). Awesome work

However, shouldn't the zdepth be greyscale? At least, thats how I've always seen it/used it.

Ravenslayer
01-02-2012, 07:42 AM
tnx
This should be the result of the zdepth, but i think i already know why your result is different. Do you have a scene with objects that don't have any materials applied to them?

http://leslievdb.com/GV_images/Passes_Zdepth.png

already updated the script so also objects without materials showup properly

cptSwing
01-02-2012, 08:10 AM
will post some feedback here once i've used it again. thanks for the new release! :)

mLichy
01-02-2012, 11:33 AM
Awesome. Yeah, had no materials

Computron
01-02-2012, 09:05 PM
How do I uninstall my old version? Couldn't find anything regarding this or any auto-update feature on the site.

Ravenslayer
01-02-2012, 11:39 PM
tnx guys

Computron: delete the old macro in the following folder
\Users\Username\AppData\Local\Autodesk\3dsmax\MAXV ERSION\enu\UI\usermacros

TonyClifton
01-03-2012, 04:10 PM
Thanks for sharing, Ravenslayer!

Ravenslayer
01-04-2012, 09:59 AM
glad it's useful tony :)

Kovac
01-04-2012, 10:15 AM
Hey Raven,
This is an awesome tool, thanks a bunch for the work put in! Have you happened to have any luck with saving out batch images instead of an AVI sequence? Quite a few projects I'm working on involve getting an alpha'd object image sequence (30 frame rotation,etc) and require bringing them into After Effects afterwards. Using this in the past I'd have to render this out frame by frame.

Excellent work!

Ravenslayer
01-04-2012, 01:14 PM
hey Kovac,

You can save the animations as image sequences PNG TGA and BMP
i just updated the script so it includes the alpha inside the basecapture if you save your animation as PNG's .

Kovac
01-04-2012, 01:31 PM
Awesome Ravenslayer, thanks a bunch!

Kovac
01-04-2012, 01:41 PM
I've tested the latest download on the site and cannot seem to get the PNG to export out that information.

Additionally, since anti aliasing options are no longer available once Animation is selected, the quality is drastically lower than that of the original.

Any ideas?

http://dl.dropbox.com/u/3025312/test001.jpg

Ravenslayer
01-04-2012, 01:51 PM
hmm that's really odd, so you selected png and enabled the alpha checkbox while setting the mode to animation.

also i'm not getting such lowres results over here, why is the extension on your image jpg btw?

Kovac
01-04-2012, 02:00 PM
Sorry that was just for quick uploading purposes. I found that the default resolution was creating the artifacts and setting it to square fixed it just fine.

I tested the alpha again and correct, while using Animation the alpha is not stored directly in the PNG file. It does work, however, when I save it out as an individual frame. I'll see if I notice any obvious differences taking place during the saving process between the two.

Ravenslayer
01-04-2012, 02:08 PM
oh oke i'm going to check that quality loss problem.

could you for all safety please redownload (http://www.leslievdb.com/Grabviewport2.rar)the script and install it?

Kovac
01-04-2012, 02:15 PM
I don't see how it's bypassing the check you have for PNG alpha when running an animation vs an image :X.

I've deleted my previous files and have tested it again; still no luck, unfortunately.

General process:
Load max file
Open GrabViewport
Select frame range x to y
Check Alpha
Choose Animation
Change format to PNG

Thanks again for the assistance!

Ravenslayer
01-04-2012, 02:32 PM
lol damn sorry. i feel stupid, for some reason it didn't overwrite the script properly so it was still the old version.

please download it again, should work now

Kovac
01-04-2012, 02:42 PM
WinMerge is saying the latest version on your server and my previous versions are all identical; is there anyway you could try a new file name for testing this?

Thanks

Ravenslayer
01-04-2012, 02:48 PM
i'm sure it's the right one on the server right now, try to open the script and look for "AlphaToAnim" if that's in there it's the right one.

there's a direct link to the mcr on scriptspot too http://www.scriptspot.com/3ds-max/scripts/grabviewport-0

Kovac
01-04-2012, 02:56 PM
The latest version works like a charm, Ravenslayer! Thanks a bunch for taking the time to look into this, it's a huge help on my end!

Ravenslayer
01-04-2012, 02:58 PM
np , i'm glad it works. :)

jeremiah_bigley
01-05-2012, 02:38 AM
Holy crap! I love you man! You just made my year! lol

Anti-Aliasing = Win!
Element Pass = Win!
AO = You have outdone yourself sir!

You made my life SOO much easier.

Haven't tested it yet, but it came just in time for a character I just started texturing. :D

garriola83
01-05-2012, 03:45 PM
love the script, but i do have a question: does it always constrain its proportions to a square when i change it? im trying to get it to render out at 1440x900 and its always 1440^2 or 900^2...or did i just miss something? thanks man!

Ravenslayer
01-06-2012, 07:35 AM
i'm going to look into this problem since some max setups seem to do this, could you perhaps tell me what max version you are running and if you have any special UI setup like the ribbon docket to the side of your screen or something?

Ravenslayer
01-06-2012, 08:32 AM
i found the problem (float to integer convertion always outputted one as ratio)
You can download the adjusted script on the site (http://leslievdb.com/grabviewport.htm)or scriptspot (http://www.scriptspot.com/3ds-max/scripts/grabviewport-0)

tnx for reporting btw :)

SideEffect
01-06-2012, 12:26 PM
I'm loving the script man! Thanks so much

I ran into an error trying to render out my image sequences with alphas.
It renders the first pass fine but it stops at the very first frame on the alpha pass and gives this error:

http://sideeffect.cgclay.com/forum/gv2error.jpg

garriola83
01-06-2012, 03:49 PM
thanks a lot for addressing the issue! sorry i couldnt be more informative sooner

Ravenslayer
01-06-2012, 05:48 PM
np garriola83.

SideEffect: looks like the filenameparsing isn't working for some reason, could you try to uncomment that messagebox line ,run the script again with the same settings and tell me what the messagebox outputs? Also could you tell me the full path+name of your baseimage that he saved

tnx

SideEffect
01-06-2012, 06:31 PM
The path is:

"C:\Users\SideEffect\Desktop\bluefor"


named it "bluefor" like in the above pic
first file in the sequence comes out as "bluefor0000.PNG"

messagebox:

"C:\Users\SideEffect\Desktop\bluefor\bluefor0000.PN G"


hit ok

messagebox:

"C:\Users\SideEffect\Desktop\bluefor\bluefor0160.PN G"


hit ok

get the same boxes as in the above pic

SideEffect
01-06-2012, 06:40 PM
On another note if I tick
"From To" in the Animation Range
and go from 0-100

run it again it gives me a message box for every frame in the sequence (0001-0100) everytime I hit ok.

Ravenslayer
01-06-2012, 06:43 PM
messagebox:
"C: \Users\SideEffect\Desktop\bluefor\bluefor0160.P NG"

is the second frame he wants to add the alpha to or the 160th?
also is that space in the .P NG there in the messagebox?

SideEffect
01-06-2012, 06:52 PM
No the space wasn't there thats just the messageboard glitching it
I edited my post after

Yes for

"C:\Users\SideEffect\Desktop\bluefor\bluefor0160.PN G"

That happens on frame 1
(sequence starts at frame 0)

Ravenslayer
01-07-2012, 03:15 AM
found the problem, when using "Active Range" he was getting 1f instead of just 1 so it resulted in a integer convertion of 116

anyway i updated the script so this shouldn't be a problem any more :)
tnx again for taking the time

SideEffect
01-07-2012, 11:08 AM
no, thank you man! :D

works perfect now

also the new crop feature is amazing :)

Xoliul
01-09-2012, 04:55 PM
Hey man, been using this script for my dozer captures, should be on a DVD cover soon ;) Thanks for preventing me from having to resort to renders, with the soft shadows it's just perfect!

One thing I noticed: at huge grabs, it tends to crash Max on the second attempt, highlighting the "ForceRedraw()" line. Im probably really pushing it with my resolutions (I got It to render pure black for a grab that was 13megapixels...), but I do notice you are always saving to 16bit PNG's. I don't think there's any benefit from that, as I'm pretty sure what you get from the viewport is just going to be output in 8bit before you grab it. So best to save some memory by just saving out 8bit images, as 16bit is quite a bit heavier to work with...

Ravenslayer
01-10-2012, 01:21 PM
tnx guys ^^

xoliul: good point ,i'm going to look into that and see what else can be optimized in the process

S_ource
01-14-2012, 01:41 PM
Seames like a good script....when it works got this error. And no image.:)
http://img18.mediafire.com/155737af7c725ce3920f53d4620df80f2e9241e71b26f6edd5 01f39c945e8fda5g.jpg

Ravenslayer
01-14-2012, 02:23 PM
hey S_ource what version of max are you using? i'm guessing something before 2010?
could you also give me the number of the line of code it goes to when that error pops up
tnx

S_ource
01-14-2012, 02:28 PM
Im using 2009 64
It goes to 1035

MAXScript Rollout Handler Exception
---------------------------
-- Unknown property: "getViewportShadingSettings" in <Interface:maxOps>

Hope it helps.

Ravenslayer
01-14-2012, 02:51 PM
tnx, i updated the script you shouldn't get that error any longer

cptSwing
01-14-2012, 05:15 PM
worked flawlessly (if a little slow) just the other day :)

I did get the impression that there might be a memory leak, at least i had to restart my computer after a dozen or so screengrabs - but that might be due to a hundred different factors!

Firebert
01-15-2012, 10:27 AM
I get this noise after installing and trying to use. (setting hotkey or toolbar button)
Max 2011 64 (tried running as admin and not as admin)
win7
computer made of sauerkraut sandwiches
:(

http://dl.dropbox.com/u/1446578/grabview2_error.jpg

Thanks sexy :)

Ravenslayer
01-15-2012, 10:52 AM
cptswing: tnx i'm going to look into that and make sure i'm cleaning everything up after each capture

firebert:
strange :s i use the exact same setup for testing the script.

could you go into the listener and type this line

getdir #Scene

and tell me what directory it outputs?
tnx

Firebert
01-15-2012, 10:56 AM
It lists whatever dir I have set as my project folder. I work on secondary drives and my primary drive is my OS.

in this case it lists F:\3D\project_name\project

Ravenslayer
01-15-2012, 11:14 AM
aha yeah i didn't take that into account. I tried to find a unified directory so people running multiple versions of max would get the last saved settings in all versions. But since i never really setup a different project folder inside max itself it's always the standard one

i fixed it by saving the ini file in the max scripts folder if it returns an undefined.
you can download the updated script :)

tnx for pointing this out

Firebert
01-15-2012, 11:19 AM
U make me all warm and fuzzy :)

Ravenslayer
01-15-2012, 11:24 AM
that's my job :P , just like santa only less bearded

cptSwing
01-15-2012, 12:30 PM
:thumbup:

Teessider
01-18-2012, 05:48 AM
This script is awesome! However I keep getting errors with it:

--Runtime Error: Attempt to access deleted scene object
Line 226 is highlighted

I'm using 3ds Max 2012 sp2 with Xoliul's Viewport Shader 2.0 (which is also awesome). I thought I got it because I had hidden objects in the scene but I got it even with no hidden objects in the scene.

Any ideas?

Saman
01-18-2012, 08:44 PM
Very nice! Thanks a lot!

papagersi
01-19-2012, 04:21 AM
it really works well so far and I like it!!! thanks a lot!!!

Ravenslayer
01-19-2012, 04:54 AM
np guys,

teessider: i'm going to try and reproduce that error here, do you have any special objects in your scene? or a special material on one of them

Hazardous
01-19-2012, 05:03 AM
Awesome! Just found this - I used the old one all the time!!

Mio
01-20-2012, 12:06 AM
awesome share! :D

garriola83
01-20-2012, 06:12 AM
hey man, its me again. im getting this error when i grab it with the SSAO and zdepth turned on. i believe i dont get this error when i only grab a vanilla viewport grab. it seems like its making a material for the other 2 passes but its not deleting them and my model ends up looking darker than it should afterwards. then i have to reset everytime. but the thing is...it actually saves the grabs. so it works it just messes up my materials on the model. help, please, thank you again very much.
http://farm8.staticflickr.com/7168/6730563081_5420df8e58_b.jpg

Ravenslayer
01-20-2012, 09:51 AM
tnx guys,

hey garriola

could you do me a favor and try adding the following line just above that line it crashes on

if isvalidnode m_scenematarr[i]._object then

then press ctrl+e to evaluate the script and try capturing again.
I'm sure it won't popup that error any longer but i'm curious if it restores your scene the right way.

tnx

garriola83
01-20-2012, 10:41 AM
it actually restores my scene materials, thanks!

BUT then i get this...
http://farm8.staticflickr.com/7152/6731666873_114f032dda_b.jpg

and it still saves my grabs so it still works, just the error is inconvenient. thanks again man!

Ravenslayer
01-20-2012, 02:29 PM
ah great that's all i needed to know i updated the script so that last error won't popup either. Max must be cleaning up some stuff behind my back in some versions.

you can download the updated script on the site.
Teessider: this also fixes your problem

tnx guys

garriola83
01-20-2012, 03:04 PM
thank you thank you, ravenslayer, works like a charm. you are a crazy magician man! thanks a million!

pixelDomain
01-26-2012, 05:12 PM
What a great script, thanks for taking the time to make it AND maintain it!

I found one issue that I'm hoping is an easy fix:

When I render a single PNG image, the screen grab looks perfect, however, if I render a PNG animation sequence, the PNG images get much darker. Any thoughts?

Ravenslayer
01-28-2012, 12:49 PM
tnx guys

pixelDomain: that's really odd, is it the entire png? and are you using crop on it?

pixelDomain
01-28-2012, 09:37 PM
Ok, after doing a little experimentation, I found that a PNG image sequence with alpha on makes the image really dark. When I turned off alpha, the PNG looked perfect. I tried the other image formats and found that only the PNGs had this issue when using alpha during an animation sequence.

I'm wondering if it's just me or if others had this same issue?

Thanks!

edit: Crop on or off had no effect.

pixelDomain
02-03-2012, 02:31 PM
So no one else had issues with a dark PNG image sequence with alpha pass checked? If it's on my end I can try to figure it out. I could really use this on a project I'm working on, as it stands now, I have to render 72 frames as an image file...ugh....

Regardless, great script!

C86G
02-06-2012, 02:21 PM
So... I finally finished my first proper model using the Xoliul Shader. So far everything is fine.
Now I want to take some nice screenshots with a bit of AA. Ihave no idea how to get that, but the Grabviewport script seems to take screenshots with AA.

I opened Max, created a some standard geometry and tried to take a screenshot. I did NOT customize anything but the path for the images.When I click the save buton, I get this:

http://666kb.com/i/c11b92xzqb0cjayyj.png

Looks like other people get same errors, but I didnīt change anything, itīs just a standard scene : (

What am I doing wrong? It is Max 2009.

Thanks in advance.

ikonane
02-12-2012, 08:15 AM
I get a bluescreen when I try to take a photo. Don't know why. I am simply trying to make a picture at 2x AA. When I try 4x AA I get an error in the script.

I use 3Ds Max 2012, xp, latest drivers (nvidia quadro FX 2700m).
Any idea why?

Xoliul
02-12-2012, 10:41 AM
QuadroFX drivers are probably the culprit...

Ravenslayer
02-18-2012, 12:47 PM
oops kind of lost track of this srry guys.

The darkening png i can't seem to reproduce over here
c86g: i'll fix that tonight! tnx

mikezoo
03-01-2012, 05:48 PM
Hey, curious if anybody has run across an issue when when trying to open the grabviewport menu. Whenever I open it though a menu or a hotkey it always freezes max. :(

ikonane
03-09-2012, 05:06 AM
I have installed Windows 7 instead of XP now and I get this error, probably a pretty common problem? How do I solve it? It doesnt matter what is in the scene I always get this error:
"Unknown system exception"
http://i9.photobucket.com/albums/a99/k0nane/3D_GrabViewport_25_1.jpg

Thanks

Teessider
03-28-2012, 07:43 PM
ah great that's all i needed to know i updated the script so that last error won't popup either. Max must be cleaning up some stuff behind my back in some versions.

you can download the updated script on the site.
Teessider: this also fixes your problem

tnx guys

hey ravenslayer again.....sorry for the late reply but thanks (for the reply and making it) :)

it worked until today when I tried to use your script again (using 3ds Max 2012 with Xoliul's Viewport Shader 2.0) and I got exactly the same error as before on exactly the same line (226)

Also my actual PNG came up black and yet the rest of the passes (AO, Colour, Wire etc) came out as they should be. I've tried changing the size of the capture but it hasn't made a difference unfortunately :(

Once again thanks! :thumbup:

PS i tried your suggestion (with adding the extra line)...it didn't work :(

jeremiah_bigley
03-28-2012, 09:57 PM
Just thought I would bring something to your attention. I got a chance to try it out for my backpack turntable and I have to say I loved it. However when I setup a scene I usually create a camera and lock it for the view I want. When tweaking the ZDepth (I believe) it deletes my camera when I am done.

When I am not using a camera it creates one and then deletes it, which makes since. Works for me... but it would be awesome if it could pull out of a camera currently in use, create one, tweak the settings, and delete the newly created one.

Not sure if anyone else was having this problem but, it was the only issue I had :)

Ravenslayer
03-31-2012, 03:12 AM
Hey guys tnx for the patience and reporting the errors,

jeremiah: i managed to fix the camera deletion and that should be working fine now with premade cameras .

Teessider: judging from the code it wasn't the latest version, try the new one i uploaded, it should take care of that error

c86g: stupid mistake i made but it should be fixed now

Pixeldomain: the png blackening is something i'm looking into. I think it has something to do with the dotnet image filtering i'm using but i'm not sure.

Ikonane: very strange i'm running the same setup, the error shown doesn't tell me anything about what could be wrong. It just stops at a default maxscript function so i'm afraid i can't do something about that. is there any more info in your maxscript listener?

Ravenslayer
03-31-2012, 08:45 AM
Since i had this open anyway i decided to add a No dialog option. If you shift click your grabviewport button it wil start saving your images using the last saved settings

So make sure you download the latest version if you want to use this.

C86G
05-01-2012, 09:14 AM
I got the problem that Grabviewport is not including/saving the viewport shadows.
I works till ~1000x1000 pixels. If i increase the resolution, it saves everything fine but without shadows.
Is my system (graphic card) too weak? Is there a way to get my images with shadows?

Ravenslayer
05-25-2012, 12:36 PM
what type of graphicscard are you using? 1000x1000 seems very small to be your max reso

Hazardous
07-06-2012, 12:29 AM
Hey man,

Heres the issue im getting now :)

http://i47.tinypic.com/nvw0mc.jpg

It seems to capture one time just fine, but I get this error which closes max from then after. Its like im good for one shot only haha!

Xoliul
07-06-2012, 03:29 AM
I get that too sometimes. It's basically when you push your computer too hard...

Hazardous
07-06-2012, 03:52 AM
damn..........okay ill dial the graphics back to 8 instead of 19! :D

Ravenslayer
07-06-2012, 09:18 AM
yeah especially if you put the AA to 4x it will basically try to capture it 4x the size you entered as resolution

Hazardous
07-06-2012, 02:55 PM
Hmmm, the AA is on 'none' I am only grabbing at 5000 wide. But np, I'll see if its better when I reduce the size.

Checko
08-31-2012, 11:05 AM
So no one else had issues with a dark PNG image sequence with alpha pass checked? If it's on my end I can try to figure it out. I could really use this on a project I'm working on, as it stands now, I have to render 72 frames as an image file...ugh....

Regardless, great script!


I have to agree, Great Script. I am having a problem however when I render out anything other then an image with anti aliasing set to 0, the result is a darkened screen grab. This happens when grabbing animations, or adjusting anti alias settings... Pretty much anytime anything other then a straight image with nothing else adjusted. I think this might be the same problem pixelDomain was mentioning.

garriola83
02-20-2013, 12:59 AM
hey man, was wondering if you can help me out
http://farm9.staticflickr.com/8371/8491849104_1034ea74c8_h.jpg

lean
04-01-2013, 10:44 PM
hi!, thanks for such a useful script!

I made a thread about a problem i'm having with it, though... but I think I might get answered faster here, so sorry about crossposting:
if I check x2 antialiasing, the final rendered picture ends up with the correct dimensions but noticeable shrinked horizontally, and if I try to render without antialiasing the result is a smaller (at least proportional) image than the size I specify.
For example, if I set the size to 1920x888 I get a 1215x504 image. I tried using "crop", I tried saving to a different image type, and that dind't change the situation.
I'm using 3ds max 2011.

polyquestions
04-16-2013, 02:04 PM
Hi I am using 3ds MAX 2013 and the script opened up fine on the first go and was able to output a simple image. However proceeding tries after that result in an error: "-- Unknown property: "filename" in undefined" highlighting the line of code: m_viewportbmp.filename = m_bmpname

I would really appreciate any help as this would be extremely helpful to use. I've also tried reinstalling 3ds max and deleting and reinstalling the script files in both appdata and the main script folders. It is odd that the script doesn't even work any more on a reinstall of max. Please help!

AstraZeroZak
04-26-2013, 07:49 AM
Hi I am using 3ds MAX 2013 and the script opened up fine on the first go and was able to output a simple image. However proceeding tries after that result in an error: "-- Unknown property: "filename" in undefined" highlighting the line of code: m_viewportbmp.filename = m_bmpname

I would really appreciate any help as this would be extremely helpful to use. I've also tried reinstalling 3ds max and deleting and reinstalling the script files in both appdata and the main script folders. It is odd that the script doesn't even work any more on a reinstall of max. Please help!
+1