Reply
Reply
 
Thread Tools Display Modes
himadri_sm's Avatar
Old (#1)
i am using max & i have a scene that has a lot of objects & all of them have smoothing groups.manually i'll have to select each object & remove the smoothing groups one by one.is there any script or plugin that will help me get rid of all the smoothing groups from all the objects together. removing them individually per object is really time consuming. thanx.
View my Portfolio here- Pixels and Polygons

On Linkedin

Demoreel on Youtube

Vimeo

Available for freelance. PM me for details.
Online , spline, 163 Posts, Join Date Aug 2009, Location mumbai, india  
   Reply With Quote

Xoliul's Avatar
Old (#2)
Select all, add "Smooth" modifier ?
Offline , card carrying polycounter, 2,426 Posts, Join Date Oct 2008, Location London, UK Send a message via MSN to Xoliul  
   Reply With Quote

dtschultz's Avatar
Old (#3)
Or just select all and add an edit poly modifier. Then remove all smoothing groups. Collapse stack.
Offline , triangle, 467 Posts, Join Date Jun 2007, Location Durham, NC  
   Reply With Quote

Mark Dygert's Avatar
Old (#4)
by watching the MaxScript Listener Window you can probably come up with quick script that applies a smooth modifier and removes all smoothing, then collapses.

I cover watching it and writing a simple script in this post:
http://www.polycount.com/forum/showthread.php?t=78992
(AKA Vig) Portfolio | Lab | Brawl | Decker |
Offline , Polycount.com Editor, 13,900 Posts, Join Date Oct 2004, Location Seattle, Wa Send a message via MSN to Mark Dygert  
   Reply With Quote

Bigjohn's Avatar
Old (#5)
Quote:
Originally Posted by Xoliul View Post
Select all, add "Smooth" modifier ?
Yes, this is by far the easiest way to do it if you have a bunch of objects.

Also, I love this script:
http://www.scriptspot.com/3ds-max/sc...moothing-group

I have it assigned to a key, and it makes it real easy to maintain smoothing groups when working on a mesh. Especially when you extrude and whatnot and it resets the smoothing groups for the new polys. Also, in Max2011 you can bind a key to a popup window with the smoothing groups selection box.
Offline , card carrying polycounter, 1,932 Posts, Join Date May 2010, Location Los Angeles Send a message via AIM to Bigjohn Send a message via MSN to Bigjohn  
   Reply With Quote

cw's Avatar
Old (#6)
here you go

Code:
macroScript cw_all1smooth
category:"CWtools"
tooltip:"cw_all1smooth"
(
-- set all selected to 1 smooth group

fn all1smooth sel=
(
	for a in sel do
	(
		if classof a == editable_poly then
		(
			polyop.setFaceSmoothGroup a #all 13
		)
	)

)

all1smooth (selection as array)

)

macroScript cw_allnosmooth
category:"CWtools"
tooltip:"cw_allnosmooth"
(
-- set all selected to no smooth group

fn allnosmooth sel=
(
	for a in sel do
	(
		if classof a == editable_poly then
		(
			polyop.setFaceSmoothGroup a #all 0
		)
	)

)

allnosmooth (selection as array)

)
Offline , polycounter, 776 Posts, Join Date Jan 2006, Location UK  
   Reply With Quote

Jonathan's Avatar
Old (#7)
And a second option if you'd like.

Feel free to ask for new stuff. Maxscript is fun.


http://3dfergy.net/__oneclick_upload...othshop3df.zip

Last edited by Jonathan; 12-23-2010 at 08:51 AM..
Offline , triangle, 362 Posts, Join Date Feb 2008, Location Cary, NC  
   Reply With Quote

himadri_sm's Avatar
Old (#8)
thanx a lot for the great help guys...actually the easiest way is to add just a smooth modifier & collapse.i went with that.

Last edited by himadri_sm; 12-23-2010 at 12:49 PM..
View my Portfolio here- Pixels and Polygons

On Linkedin

Demoreel on Youtube

Vimeo

Available for freelance. PM me for details.
Online , spline, 163 Posts, Join Date Aug 2009, Location mumbai, india  
   Reply With Quote

Jonathan's Avatar
Old (#9)
Yeah, that's sorta like what this one does, as normally using Max modifiers allow less memory usage and faster performance as it access the functions from the C++ core, IIRC,

Code:
--UI, function stuff, etc. removed to show the main example
--snip
		if selection.count >= 1 then
		(
			local polycountSmoothModi = (Smooth autosmooth: FacetdFaces threshold: smoothAngle name: ("SmoothBy" + (smoothAngle as string)))
			for o in selection do if  superClassOf  o == geometryClass do
			(	
				addModifier o polycountSmoothModi
				if (cnvToP) then 
				(
					convertToPoly o
				)
			)
		)
		
		else
		(
			messageBox "No objects selected.  Please select at least one object." beep:false
		)
	)
	
--snip
You can use polyOp and meshOp operations, but in the tests I've run, they're 30% slower, but either way, whatever gets the job done.

Last edited by Jonathan; 12-24-2010 at 01:36 AM..
Offline , triangle, 362 Posts, Join Date Feb 2008, Location Cary, NC  
   Reply With Quote

cw's Avatar
Old (#10)
Heh heh nice stuff Jonathan. For me, 30% of a few miliseconds is bearable overhead. I should look more into using the stack. SOmetimes it's much neater way to achieve necessary results.

You're right though, scripting is kind of fun. Especially when it saves time longer term.
Offline , polycounter, 776 Posts, Join Date Jan 2006, Location UK  
   Reply With Quote

Jonathan's Avatar
Old (#11)
Yeah, there's like 10 ways to do everything in Max due to "legacy support", so sometimes it's cool to see all the various ways people solve problems in Max.

Offline , triangle, 362 Posts, Join Date Feb 2008, Location Cary, NC  
   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Copyright 1998-2012 A. Risch