SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > Silent Hunter 3 - 4 - 5 > SHIII Mods Workshop
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 12-29-13, 01:56 PM   #16
Seeadler
Pacific Aces Dev Team
 
Join Date: Mar 2001
Location: Northern Germany
Posts: 1,096
Downloads: 169
Uploads: 0


Default

Quote:
Originally Posted by radcapricorn View Post
This leads me to believe that this page is handled elsewhere (i.e. game code). If not completely, then at least item positions, material references and Crop parameters are ought to be changed by the game in order to display this page correctly for every type of U-boat.
Here you run into the same problems as me during the creation of my own widescreen gui. It's the barracks page and the damage control page onboard which are handled in parts elsewhere ...I suppose in the SH3.exe.
Seeadler is offline   Reply With Quote
Old 01-02-14, 09:11 AM   #17
radcapricorn
Helmsman
 
Join Date: Jun 2011
Posts: 105
Downloads: 181
Uploads: 0
Default

Thanks, Seeadler. So it seems this behavior is not that widespread among pages. That's good to know.

Now to some more fiddling. I've been investigating the various Display types for images, which included reading the existing guides and good old "see for yourself" method. Here's what I came up with regarding this parameter (warning, image with white font on transparent background):



That's how a source image (32x32 pixels) looks like in a 128x64 menu item in various Display modes. I've intentionally left the yellow selection border to better visualize the item's bounding rectangle.

For all modes except mode 0 (No Stretch), cropping rules apply: source image rectangle is "cut out" from the actual .tga image using first two "Crop" numbers as X,Y coordinates for top-left corner and last two "Crop" numbers as width and height (these numbers are normalized into [0,1] range where 0 means "top" or "left" and 1 means "full width" or "full height".
  • 0 (No Stretch): Crop width and height are ignored, image is sampled from (Crop X, Crop Y) all the way to its edges. Image is not scaled in any way. If it ends up being smaller than the menu item, it is tiled (repeated) until it fills the whole menu item rectangle.
  • 1 (Centered): The cropped rectangle is placed in the center of menu item's rectangle. Image is only scaled down, never up: if menu item's rectangle is shorter and/or more narrow than the source image, the image will be scaled to fit.
  • 2 (Linear) and 5 (Linear&Rotation): Image is stretched to fill the whole menu item rectangle. The quality of resulting image depends on MatFlags (i.e. if flag 0x08 is set, bilinear filtering is used).
  • 3 (Middle): Source is split into two rectangles vertically. Left half is placed (without stretching) in menu item's top-left corner, right half - in menu item's top-right corner. Space in-between is filled with the two-pixels-wide rectangle taken from the center of the source, stretched as needed. This may produce visual artifacts.
  • 4 (All Directions): Source is split into four rectangles, each is placed (without stretching) into corresponding corners of the menu item. Space in-between the corners (i.e item border) is filled with corresponding borders of corner rectangles. Remaining space in the middle of the item is filled with a 2x2 rectangle taken from the center of the source, stretched as needed. This may produce visual artifacts. See for example "Page Message". The background of the message window uses this mode, and it is actually somewhat "uglified" because of that. But to be honest, I never ever noticed that in game until I started fiddling with these parameters

Last edited by radcapricorn; 01-02-14 at 10:35 AM.
radcapricorn is offline   Reply With Quote
Old 01-03-14, 05:35 PM   #18
vanjast
Sea Lord
 
Join Date: Jun 2006
Location: Somewhere else now
Posts: 1,797
Downloads: 1214
Uploads: 4
Default

Just a leetle update..
I've done a major shift and reshuffle to the 'front end'.
This is to allow individual modules (selectable from the green 'toolbar' buttons) to be added when ready.
Another week or two.. then it's back down to the nitty gritty...

I've been poking around a bit where you can add your own images/screen grabs to the background like a screen saver... just an added touch to your personal 'flavour'.
This current pic is a painting from John Hamilton's book 'War at Sea 1939-1945'.

$%&$%*^&*.... how do you display an image from Imageshack or Photobucket... the old way doesn't work any more ??


http://imageshack.com/a/img196/5181/ytim.jpg

Last edited by vanjast; 01-03-14 at 06:38 PM.
vanjast is offline   Reply With Quote
Old 01-04-14, 09:35 AM   #19
radcapricorn
Helmsman
 
Join Date: Jun 2011
Posts: 105
Downloads: 181
Uploads: 0
Default

Quote:
Originally Posted by vanjast View Post
how do you display an image from Imageshack or Photobucket... the old way doesn't work any more ??
Like that? Just wrap the link in [img] block, as usual (imageshack should give it to you this way already) If you edit your post, I'll remove it from here.

radcapricorn is offline   Reply With Quote
Old 01-04-14, 11:55 AM   #20
vanjast
Sea Lord
 
Join Date: Jun 2006
Location: Somewhere else now
Posts: 1,797
Downloads: 1214
Uploads: 4
Default

Thanks, I tried that but it didn't work.
Must be my browser settings.
vanjast is offline   Reply With Quote
Old 01-10-14, 12:51 AM   #21
Consigliere
Watch
 
Join Date: Jun 2011
Location: Moscow, USSR
Posts: 28
Downloads: 153
Uploads: 0
Default

Quote:
Originally Posted by radcapricorn View Post

That's "Page barracks" (G67 or 0x67000000). Note a whole lot of gibberish where the U-boat compartments should be...
This leads me to believe that this page is handled elsewhere (i.e. game code). If not completely, then at least item positions, material references and Crop parameters are ought to be changed by the game in order to display this page correctly for every type of U-boat.
I'm not sure right now how to best deal with this.
Hi, that's really cool that somebody would try to make a graphic menu.ini editor
For the barracs page.
First, it is used in port as barracs page and at sea as damage control & crew page.
Second, it does have "general" positions for compartments (not sure if it correlates with any sub type). And exact positions are indeed hardcoded.
I've wrote that info early here. Check that thread for some info that probably could be usefull for your effort.
__________________
Yoda's modding rules:
- You must unlearn what you have learned.
- Try not. Do... or do not. There is no try.
- Size matters not.
Consigliere is offline   Reply With Quote
Old 01-16-14, 12:25 PM   #22
makman94
Hellas
 
Join Date: Jul 2008
Posts: 2,294
Downloads: 184
Uploads: 7


Default

were have you been all this time guys ? this tool would have been a real treasure and would have save a lot of hours spended on the lines of menu_ini ! but ,as always, better now than...never !
from the pics that you have posted seems that it will be very handy , well done guys !

ps: the sh5 has a menu_ini editor and i think that i read somewhere that it can be used for sh4 and sh3 too. never tried it though but have you guys checked if it can be adjusted to serve the needs of sh3's menu_ini ?
__________________
Knowledge is the only thing that nobody can ever take from you...



Mediafire page:http://www.mediafire.com/folder/da50.../Makman94_Mods
makman94 is offline   Reply With Quote
Old 01-16-14, 05:40 PM   #23
radcapricorn
Helmsman
 
Join Date: Jun 2011
Posts: 105
Downloads: 181
Uploads: 0
Default

Alas, we were elsewhere, makman94 Indeed hopefully such editor would be helpful even now, especially since there seems to be some demand for various resolutions (which are possible thanks to Seeadler's dll), and I can't even begin to imagine editing it all by hand for every possible resolution.

And indeed, sh5 does have a menu editor. A very clumsy and strange one, but nevertheless. As for utilizing it for previous Hunters... I don't know. The one time I tried to switch sh5's Data folder with sh3's one, it crashed as soon as I launched sh5.exe. As it should have. targas instead of dds, different fields in the ini itself... sh4 - maybe, I haven't tried. It *may* work there, because the file format is basically the same between sh4 and sh5 (they've introduced those mad Zones concept to allow for multiresolution support), and sh4 uses dds images as well... Still... sh5 stores each page in a separate file, while sh4 doesn't... In short, I wouldn't hold my breath

Oh, by the way, after a short discussion with vanjast, we've decided to start a separate thread to gather as much info as we can on sh's files, to keep this thread more focused on his tool itself. I'll be doing that sometime soon. Your input will be greately appreciated. And there are some things I have written down somewhere to ask you personally about what and why you did in your mods. But that's for another thread.

@Consigliere: Sorry for the delayed reply. Thanks for your insight. All the little bits count!
radcapricorn is offline   Reply With Quote
Old 01-21-14, 05:29 PM   #24
Hitman
Pacific Aces Dev Team
 
Hitman's Avatar
 
Join Date: Sep 2002
Location: Spain
Posts: 5,991
Downloads: 109
Uploads: 2


Default

Quote:
were have you been all this time guys ? this tool would have been a real treasure and would have save a lot of hours spended on the lines of menu_ini ! but ,as always, better now than...never !
Here, here
__________________
One day I will return to sea ...
Hitman is offline   Reply With Quote
Old 01-23-14, 03:08 PM   #25
vanjast
Sea Lord
 
Join Date: Jun 2006
Location: Somewhere else now
Posts: 1,797
Downloads: 1214
Uploads: 4
Default

My side is going to be delayed a bit.. I have to tackle some RL stuff.
' I'll be baaack '
vanjast is offline   Reply With Quote
Old 08-02-15, 11:26 AM   #26
Meridian
Frogman
 
Join Date: Apr 2005
Location: Kent, UK
Posts: 293
Downloads: 687
Uploads: 0
Default

Did anything come of this or did it get shelved permanently ?
__________________
MAG Z790 Tomahawk, Intel Core i9 12900K, GeForce RTX 5070 OC 12gig, 64.0GB Dual-Channel DDR5.
Meridian is offline   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


All times are GMT -5. The time now is 10:25 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
Copyright © 1995- 2026 Subsim®
"Subsim" is a registered trademark, all rights reserved.