Home » MODDING HQ 1.13 » v1.13 General Development Talk » TEASER: Enhanced Stock Animations (Regular Male)
TEASER: Enhanced Stock Animations (Regular Male)[message #278538] Mon, 25 April 2011 10:25 Go to next message
Bio

 
Messages:63
Registered:April 2009
Location: Rhineland-Palatinate/Germ...
First off, sry if this is a little unstructured. I'm a bit light-headed since I worked on LOBOT/JADES for like 30 hours straight.

I put in a lot of hours the last week and a half and I'm quite happy with the results (though it took substantially more time than anticipated).

I managed to implement all features I wanted to add. Fixed all the bugs that I was aware of (safe for one in the BARE scripts). Everything appears to be quite stable indeed and I will be able to release both the first beta version of LOBOT (based on the MT development branch from a couple weeks ago, which should be reasonably stable) and also the first pack of finished and useable content (as part of the JADES project) for LOBOT.

This post is about that content pack and I would like to give a little preview before I'm off to get some sleep.

Comparison of new enhanced regular male animations against the stock regular male animations:
http://m.uploadedit.com/b92/96600041.gif

The first pack of fully usable logical bodytypes for LOBOT is an improved and more dynamic version of the regular male stock model. There are no new layers compared to the stock animations. Although the shadow is an actual separate layer. The pack consists basically of 4 sti files for every stock sti file. 1 sti file for the rgb channels and one for the alpha channel and that for the two layers (body, shadow). All animations currently in the game have been generated (I only tested a relatively small sample of these - there probably still are some problems to be encountered).

That alone of course would not add much to the game. However I also added a set of different statures for the stock bodytype. I already hinted to that in the alpha blending thread. I defined 5 statures to be generated (the process for generating the content is fully automatic and the stature configuration could easily be altered and the body type re-generated):

Short - scaled to 90% of the default animations
Below average - scaled to 95% of the default animations
Average - not scaled
Above average - scaled to 105%
Tall - scaled to 110%

If we assume that the average height is round about 178 cm (5'10) this spread gives us a range of 160 cm to 196 cm that can be represented in-game.

The size of this content pack is substantial. There are 1761 sti files total with a total size of over 120 MB. The generation of equivalent packs for the female and big male models will boost that to well over 350 MB.

I improved the quality of the scaled animations a great deal in comparison to the last screen shots I posted. I like the result a lot. The animations look crisp, there is very little blurring.

http://m.uploadedit.com/b92/1749802.gif

Note that the palette I used did not have the fixed colors used in the stock versions for the shoes, so shades of gray were used instead. I consider that a blessing in disguise as the darker shoes look much better in my opinion. (or maybe they are dynamic after-all, in that case I should re-generate with an appropriate palette).

Note that the alpha blending is best visible when comparing the shadows of the enhanced versions to the stock ones (smoother edges, also made the shadow a little lighter as in the stock animations - like it better that way).

Note that the average stature (the one in the middle) is not scaled. It is identical to the stock one (save for the colors of the shoes). The animations were at different frames when the screen shots were made, but the two animations are actually congruent (except for the shadow since that is in a separate layer). There is no alpha blending done for the body and the shadow (actually, technically there is for the shadow, but no smoothing).

All 5 new statures in a combat setting:
http://m.uploadedit.com/b92/78373479.gif

One more thing. I used one-pass resizing with the catrom filter. My script supports up 2 two passes (with different filter settings) with the image from the 2nd pass blended upon the first one. There are loads of possibilities to optimize the re-sized animations. But as it stands the one pass catrom is already looking very serviceable to me.

[Updated on: Mon, 25 April 2011 10:31] by Moderator

Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278539] Mon, 25 April 2011 10:33 Go to previous messageGo to next message
DepressivesBrot

 
Messages:3809
Registered:July 2009
That's just awesome! Great work Bio
:bow:


Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278542] Mon, 25 April 2011 10:52 Go to previous messageGo to next message
Logisteric

 
Messages:3395
Registered:December 2008
Location: B
i want fat bodytypes for meltdown, hitman and nails

looks great
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278543] Mon, 25 April 2011 11:37 Go to previous messageGo to next message
lockie

 
Messages:3929
Registered:February 2006
Location: Scotland
Will these anims be 'attached' to certain mercs or randomly produced for militia etc ?


Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278547] Mon, 25 April 2011 12:20 Go to previous messageGo to next message
Off_Topic

 
Messages:1038
Registered:January 2009
That's pretty cool Bio, should add even more individuality to Mercs.

Is it feasible to add new shirt types, long sleeved for example?

If this was implemented, you could mess around with each Merc's field of view.


Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278571] Mon, 25 April 2011 19:04 Go to previous messageGo to next message
Bio

 
Messages:63
Registered:April 2009
Location: Rhineland-Palatinate/Germ...
Logisteric
i want fat bodytypes for meltdown, hitman and nails

looks great


guess I could play around with different aspect ratios and see how it would look if the width would be increased slightly.
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278572] Mon, 25 April 2011 19:06 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1542
Registered:March 2009
Location: Broadwurschd-City
an some mercs from JA1
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278573] Mon, 25 April 2011 19:13 Go to previous messageGo to next message
Bio

 
Messages:63
Registered:April 2009
Location: Rhineland-Palatinate/Germ...
lockie
Will these anims be 'attached' to certain mercs or randomly produced for militia etc ?


LOBOT has an extensive filter system. One could easily define filters that would utilize already existing randomized attributes (strength, agility come to mind) to choose a stature. Guess it would have the drawback that if they got hit and lose strength or agility their bodytype would change Wink (can you actually lose strength when hit?).
I guess for that reason it is not the right approach for mercs, since their strength will often tend to improve over the course of a game and it would be silly to change their height according to this. So for mercs you'd probably want to define filters matching against the names.
The alternative would be to introduce new attributes (height and while you're at it weight as well - would also add a nice rpg touch to display these stats in the aim profile etc. - in that case one should also add age) and match against that. Then you would only need one filter and you could then randomize said attribute for soldiers/militia and set it to static values for mercs to get the desired stature.

Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278574] Mon, 25 April 2011 19:16 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1542
Registered:March 2009
Location: Broadwurschd-City
I'ld prefer to set it by hand for all R/npcs
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278575] Mon, 25 April 2011 19:22 Go to previous messageGo to next message
Bio

 
Messages:63
Registered:April 2009
Location: Rhineland-Palatinate/Germ...
Off_Topic
That's pretty cool Bio, should add even more individuality to Mercs.

Is it feasible to add new shirt types, long sleeved for example?

If this was implemented, you could mess around with each Merc's field of view.



In fact my plan is to add long sleeves. I plan on using a partial bodytype created by CheKa a while back as a starting point. My idea is to diff his images with the stock ones and save the delta as a new layer. But I'm still unsure, whether long sleeved shirts should be the default or displayed according to some other attribute (unfortunately there is no slot for general clothing and it makes little sense to decide according to the vest slot since there generally will be a vest in there which says nothing about the desired sleeve type).
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278576] Mon, 25 April 2011 19:41 Go to previous messageGo to next message
Off_Topic

 
Messages:1038
Registered:January 2009
Just rereading my badly phrased post, i was referring to the height differences, not the shirt length affecting field of view!

Maybe it could be used in conjunction with the new Kit choices... or a randomly generated feature.

In Legion 2, Jazz managed to have clothing randomly selected;as someone pointed out at the time, Reaper was even more menacing when he turned up for battle dressed in pink.


Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278579] Mon, 25 April 2011 19:51 Go to previous messageGo to next message
lockie

 
Messages:3929
Registered:February 2006
Location: Scotland
Was thinking more of the AIM mercs , will they conform to their attributes , Grunty - small but stocky , Bubba - Biiig , etc ?
And in the interests of equality , we must have a 'fuller figured' female.... :diabolical:


Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278584] Mon, 25 April 2011 20:22 Go to previous messageGo to next message
Gorro der Grüne

 
Messages:1542
Registered:March 2009
Location: Broadwurschd-City
I don't think strength etc should have any impact on bodytypes. This would be totally nuts.

@ Lockie
For me Grunty is 1.78m and has about 80 to 85kg
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278596] Mon, 25 April 2011 21:51 Go to previous messageGo to next message
lockie

 
Messages:3929
Registered:February 2006
Location: Scotland
Cool ! :ok:


Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278597] Mon, 25 April 2011 22:15 Go to previous messageGo to next message
Bio

 
Messages:63
Registered:April 2009
Location: Rhineland-Palatinate/Germ...
To visualize better how such a filter setup looks like I devised one that could be used to match against those soldier instances that are supposed to be rendered as short regular male (note that I didn't test it, so it might not be syntactically correct):

	
	
		
			SOLDIER_CLASS_NONE
			MERC_TYPE__PLAYER_CHARACTER
			MERC_TYPE__AIM_MERC
			MERC_TYPE__MERC
			MERC_TYPE__NPC
			MERC_TYPE__EPC
			MERC_TYPE__NPC_WITH_UNEXTENDABLE_CONTRACT
		
	
	
	
	
		
			REGMALE
			IsRandomizedSoldier
			60
		
	
	
	
		
			Dr. Q
		
	
	
	
		
			IsRegularMaleShortUnnamed
			IsRegularMaleShortNamed
		
	


You would then use "IsRegularMaleShort" as the filter for the short regular male bodytype.

Actually you could do away with "IsRegularMaleShortNamed" and simply list all the named soldiers in the OR block of "IsRegularMaleShort".

For the other statures you would have similar filters (except for IsRandomizedSoldier which would be referenced by all statures).

[Updated on: Mon, 25 April 2011 22:18] by Moderator

Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278616] Tue, 26 April 2011 04:02 Go to previous messageGo to next message
SharkD

 
Messages:358
Registered:July 2003
A criticism: Taller people tend to have proportionately narrower heads/feet/hands compared with short people. Maybe you could try resizing a greater amount vertically or something?? However, the stock art could always be replaced at some time in the future as long as the basic system is in place.

Also, the resized sprites look "fuzzy". This is bad, IMO. Maybe you could post a series of sprites using different resizing/interpolation algorithms (Nearest-neighbor/Bilinear/Lanczos/etc.) and we could vote on the results?
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278617] Tue, 26 April 2011 04:19 Go to previous messageGo to next message
Bio

 
Messages:63
Registered:April 2009
Location: Rhineland-Palatinate/Germ...
SharkD
A criticism: taller people tend to have proportionately narrower heads/feet/hands compared with short people. However, the stock art could always be replaced at some time in the future.

Also, the resized sprites look "fuzzy". This is bad, IMO. Maybe you could post a series of sprites using different resizing/interpolation algorithms and we could vote on the results?


Sure will do that, but not right now. My original idea was to do a 2 pass resizing the first with a cubic filter (catrom has the least blurring with imagick), the second with smart pixel resizing (which generally gives good results, but sometimes results in not so pretty artifacts - blocks of 4 pixels of the same color, that stand out a lot) and blend the two together (lay over pixel resized over the other with a visibility of 40%-60%). The idea is to compromise, get some of the smoother edges with alpha information (where the block artifacts occur and are most visible), but also retain most of the sharpness away from the edges.
I did not do that right away, as I found that the catrom looked pretty decent in-game. Keep in mind, that the images posted here are resized to 200% and also reduced to 8bit resolution compared to 16bit in game, which certainly enhances unfavorable blur artifacts. So I'll revisist that, but not right away, looks good enough in-game for now, when the animations are actually moving.

edit: actually the gif files do not amplify any artifacts. While the lower number of colors is easily detectable, the alpha blended/blurred regions are looking not notably worse in the gif files.

[Updated on: Tue, 26 April 2011 09:09] by Moderator

Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278625] Tue, 26 April 2011 10:12 Go to previous messageGo to next message
Deane

 
Messages:62
Registered:January 2010
lockie
Was thinking more of the AIM mercs , will they conform to their attributes , Grunty - small but stocky , Bubba - Biiig , etc ?
And in the interests of equality , we must have a 'fuller figured' female.... :diabolical:


And make Bun hate Fox more? If that even possible Very Happy
Re: TEASER: Enhanced Stock Animations (Regular Male)[message #278659] Tue, 26 April 2011 12:26 Go to previous messageGo to next message
Buns

 
Messages:676
Registered:September 2010
Bio
In fact my plan is to add long sleeves. I plan on using a partial bodytype created by CheKa a while back as a starting point. My idea is to diff his images with the stock ones and save the delta as a new layer. But I'm still unsure, whether long sleeved shirts should be the default or displayed according to some other attribute (unfortunately there is no slot for general clothing and it makes little sense to decide according to the vest slot since there generally will be a vest in there which says nothing about the desired sleeve type).


May be this can be triggered by an additional XML that defines which item should display which part of the body with which kind of model and which color?

For example, T-shirt would be default displaying the merc in the way he is defined by MercProfiles.XML. Giving the merc a "Brown Uniform Jacket", that is defined that way in the new XML, would change his torso to be displayed by the "Combat Jacket" type and color it in brown. Possible?

Re: TEASER: Enhanced Stock Animations (Regular Male)[message #279557] Mon, 09 May 2011 19:22 Go to previous message
Exurok

 
Messages:195
Registered:March 2011
Location: Norway

think they need alittle more work, some looks unsharp compared to the original.
but that aside, great idea and job Wink
Previous Topic: STOMP 1.2: Questionmarks behind Skills/Character/Disability
Next Topic: Questions about different versions
Goto Forum:
  


Current Time: Sun Dec 16 07:54:47 EET 2018

Total time taken to generate the page: 0.01320 seconds