Log in

View Full Version : PPI/AScope radar displays


Maurox
12-16-13, 05:44 AM
OK, so after searching for two days (and learning that most of the links here are dead BTW) and not finding any answers I thought I might just ask:

Was ANYONE able to find out which file is responsible for the masks at the radar displays? The bearing lines and range scale in PPI and AScope respectively? I'd appreciate it if someone could point me in the right direction :/

aanker
12-16-13, 11:45 AM
RFB incorporates a realistic display. I'm too lazy to verify whose mod idea they used. TMO 2.5 may also use it although I'm not sure. So nice and he poured months of work into it!

I never bothered to search for the files because I was relatively satisfied until I installed RFB, then Wow! sorry I can't be of more help.

Happy Hunting!

CapnScurvy
12-16-13, 11:45 AM
OK, so after searching for two days (and learning that most of the links here are dead BTW) and not finding any answers I thought I might just ask:

Was ANYONE able to find out which file is responsible for the masks at the radar displays? The bearing lines and range scale in PPI and AScope respectively? I'd appreciate it if someone could point me in the right direction :/

First off........Welcome to SubSim Maurox!!

The bearing lines of the PPI display are found as an Alpha Channel in the image files of "Data/Misc/ppiCircles.dds". The A-Scope uses a different way of producing the lines entirely.

If Alpha Channel, .tga, .dds descriptions are sounding like "Greek" to you, then you've got a learning curve ahead of you to master. Not to mention that the stock game didn't do us any favors by employing their values of radar accuracy into the game. The way I'd describe what they did was provide "eye candy" with the radar.....nothing more than fluff......it looks pretty, the line spins around on the PPI screen .....but that's about all you have! No accuracy....no intention of having one!

In order to have accurate line measurements, you'll need to make the radar units "scaled" to the proper size the "masks" are made for. Like I said, the A-Scope doesn't use a mask for producing its inaccurate lines (so you'll have to add one to the game). The "ppiCircles.dds" will have to have them scaled for the three different distances the radar uses. All in all, a pretty large project.

May I suggest you try Optical Targeting Correction (http://www.subsim.com/radioroom/showthread.php?t=181172)....its already fixed the stock radar by making scope overlays for both A-Scope and PPI screens, and reworked the specific radar parameters to have them correctly show targets at accurate distances and power settings.

Here's what the A-Scope station looks like:

http://i175.photobucket.com/albums/w132/crawlee/USAscopeStation.jpg


Below is a zoomed view of the screen......Yes, this is how the screen will look, I added a feature to zoom-in on the screen when at the two radar stations (giving you a better view to make a range determination).

http://i175.photobucket.com/albums/w132/crawlee/USA-Scope.jpg


If the radar distance switch were set to the Low Power\4000 yard setting.....the above target spike would be read on the lower line scale....at 3000 yards distance from the sub. The three power settings of the OTC A-Scope are 4000 yards, 32,000 yards and 60,000 yards.

As a side note, the smaller line at the bottom of the screen is the stock game line that I can't remove from the game (its encoded in files we can't get to, nor change to make it more accurate). I can make it smaller, but I can't get rid of it. Notice the scale...it also reads 4000, but look at where the spike shows the target.....by having to guess the reading, its somewhere around 27-2800. Not at all accurate for reading a target that I know is at 3000 yards distance from the sub (I know because I'm using a test mission I made specific to "test" radar range).

Below is the PPI screen from the Optical Targeting Correction mod:

http://i175.photobucket.com/albums/w132/crawlee/USPPI.jpg


The range scales are different for the PPI station. The Low Power covers 8,000 yard range, Medium Power is 32,000, High Power is 80,000 yards range. Again, if the same target is at the same distance as the A-Scope target....the above target "Blip" is read on the Low Power scale (the scale that's shared with the High Power scale....on the left) and read at 3000 yards distance, on a relative bearing of about 10 degree's. If the blip were found on the same line as above, yet you've set the radar power switch to the Medium setting of 32,000 yards....the accurate range of the target would be read from the right hand scale (near where the "blip" is positioned)....the range to target would be 12,000 yards.

I'm not trying to deter you from learning how to mod, but for the stock radar, a better experience can be found with OTC.

Maurox
12-16-13, 12:27 PM
Thanks for the welcome! :D

Let me start by saying that I actually do have some experience with DDS as
a) I've always been a tinkerer of sorts and I always try to make some little changes to the games I play
b) I've got a bit of history with FSX repaints (since my main area of... let's say "expertise" is aviation ;) But subs proved to be plenty of fun as well, in their own way - though I'm far from playing on 100% realism settings, so far I'm content with manual targeting xD)

Now, coming back to the topic:
I've already tried a few mods, but here is the thing: I have v 1.5 with U-Boot mission campaign and after trying the very same mods you mentioned, I still have the large lines with numbers on the PPI screen (https://dl.dropboxusercontent.com/u/35434187/SH4Img%402013-12-15_22.23.59_576.jpg) and AScope remains completely unchanged.

Now, it could be because I haven't really applied the mod altogether, only the shader and *.dds/*.tga files, but from some of the posts I got the idea that somewhere along the way developers changed something in the files and those lines and numbers on the screen appeared to be somehow hard-coded into the display (though what little experience I have tells me this is not very probable, if at all possible)

One reason why I don't want to install the entire OTC is that I already have a couple of mods that I want to keep and I would need to play with the files to join them together... Which I might do sometime in the future, but right now I wanted to edit just the radar screens. ATM I'm using my own mask for the smaller lines (different from the one posted above), but the numbers and lines located on the screenshot are still there. Any way to remove them?

CapnScurvy
12-16-13, 06:03 PM
Ok, I see what you're getting at.

I already mentioned you can't do much with the games original numerical additions they have added to several of the screens. You can make them smaller, or move them out of the way, but you can't get rid of them (least I don't know how). Both radar screens have them "magicly" appear (so does the German periscope view with the numbers and the two perpendicular lines drawn on the scope view).

As memory serves me, changing the parameters in the Shaders\Radar\ASCOPERadarPS.fx, and Shaders\Radar\PPIRadarPS.fx (use NotePad to open these files) will change the settings for these number placements. Maybe these files make more sense to you, they don't to me. For me, I know "when to leave sleeping dogs lie"

With the PPI screen, I actually made the Alpha Channel "mask" smaller, to cover over the bearing numbers the game puts on the screen. In the below image, I've got the Alpha Channel for OTC's PPI screen:

http://i175.photobucket.com/albums/w132/crawlee/RadarScreen002_zpsc46e86c0.jpg


Notice where the pointer is located on the top/center of the alpha channel.

In the following "regular" image of the PPI screen, this same spot is about where the mouse pointer is located:

http://i175.photobucket.com/albums/w132/crawlee/RadarScreen001_zps99940206.jpg


I got around having the games stock relative bearing numbers show by simply covering them up. Their still there, just covered up with my screens relative bearing compass being larger than the Alpha Channel rim. :88)

Maurox
12-17-13, 02:18 AM
So no one figured out how to remove them... Well, thanks for trying to help anyway :)

Though if I may ask - do people edit the shaders (*.fx) with some program or just notepad(++ ;))? I would play around with them, but if possible I want as little trial-and-error process as possible due to obvious reasons (^_^')

CapnScurvy
12-17-13, 07:11 AM
NotePad is what you'll use to open\save, making changes in that kind of file.

The question is......what changes do you make??? Unless you've got some idea of what to do, trial and error is the only way.

Maurox
12-17-13, 07:33 AM
Hell, 90% of the time I have no idea what I'm doing xD Thank God for backups. I don't know if I will be able to accomplish anything, but if I manage to do something about them I'll keep you updated.

//EDIT:

In this topic:
http://www.subsim.com/radioroom/showthread.php?t=115207&highlight=radar

Mraah mentions that an edited SHController.act file removed a "RANGE" text from the PPI - was it on the display? If so, then can anyone tell me what is that *.ACT file and what should I open it with? Does Anvart still visit this forum? Since he was the one to edit the file, he should know if it makes any sense to play with it...

aanker
12-17-13, 12:16 PM
Hell, 90% of the time I have no idea what I'm doing xD Thank God for backups. I don't know if I will be able to accomplish anything, but if I manage to do something about them I'll keep you updated.

//EDIT:

In this topic:
http://www.subsim.com/radioroom/showthread.php?t=115207&highlight=radar

Mraah mentions that an edited SHController.act file removed a "RANGE" text from the PPI - was it on the display? If so, then can anyone tell me what is that *.ACT file and what should I open it with? Does Anvart still visit this forum? Since he was the one to edit the file, he should know if it makes any sense to play with it...
He probably used a hex editor to edit out the words from SHController.ACT.

I use Frhed however other people use different editors - whatever you're used to.

Happy CapnScurvy jumped in, you're getting a tutorial from the Guru himself..... and I mean that in the kindest and most sincere way.

Happy Hunting!

Maurox
12-17-13, 01:15 PM
OK, well this complicates things :hmmm: mostly because I have no experience nor knowledge of editing hex whatsoever... Would you happen to have the files from that topic? Last I checked the links were all dead, and the files aren't on this site - unless I missed them, if so then just pointing me in the right direction would be enough...

And the way you mentioned Capn reminds me of how in the movies sailors talk about their captain with this affection and respect :) I guess I should feel honored then.

aanker
12-17-13, 04:07 PM
OK, well this complicates things :hmmm: mostly because I have no experience nor knowledge of editing hex whatsoever... Would you happen to have the files from that topic? Last I checked the links were all dead, and the files aren't on this site - unless I missed them, if so then just pointing me in the right direction would be enough...

And the way you mentioned Capn reminds me of how in the movies sailors talk about their captain with this affection and respect :) I guess I should feel honored then.
Those files would be for ver 1.2 it looks like, so you wouldn't want them. You do want an edited SHController.ACT for ver 1.5 that is compatible with your install - the mods you're using.

So far it appears that yours is a stock install with only the graphics - Textures - edited/changed, right?

I can hex edit out RANGE from a stock file. Are you using any mods with that file in them?

You could edit out RANGE from a copy of the file too, just search and try replacing the characters that make the letters with, 00 00 00 00 00 (zero's).

Typically the letters are in the right window and double sets of bits/bytes in the left. It could be your introduction to hex editing....

There are links to popular hex editors used in the stickied topic here in the Mod section.

What do you think?

If you do, make a copy of the file and copy it to your desktop and edit it there so you don't mess up the original. Then also save an an-edited copy in a safe place in case you accidentally copy it over your installed game files - double protection!

Maurox
12-17-13, 05:28 PM
Actually, no, back.

I don't want to edit the RANGE writing itself :) I just wanted to try swapping these files to see if replacing the new file with the old one would get rid of the bearings on current PPI display - because if it wouldn't, there would be no point in changing it any further.

I checked that file with Frhed like you suggested, but I wasn't able to find "270" for example, so it's either some kind of formula that places those numbers or I'm knocking at the wrong door altogether.

Or the number are actually placed somewhere else and SHController just points the game to that location.

I'm saying this because no matter what, something needs to tell that game to show those numbers and those lines, what numbers and how thick the lines are supposed to be, WHERE they are supposed to be and what font to use. It shouldn't be hard-coded into the main code if it was implemented in a patch, so one of the files that got updated with the patch should contain the information about this.

This is why I wanted one of the old radar mods - to see if it would change anything. On the other hand it could be a dead end, or the game could crash, but that's kinda how trial and error works, amirite?

Though it occurred to me just now that I might be making a big deal out of something pretty trivial (Since you can get used to those numbers assuming you make the right mask for the lines), but why the hell not. In worst case scenario people will just stop giving a crap ;P And maybe it'll turn out to be useful to someone.

Oh, and BTW - I tried opening the shaders with various programs but so far I've had no luck. FX Composer doesn't want to start at all at my rig and some other shader program opens the file, but according to it, the PPI Radar shader simply multiplies the image 8 times (there are 12 bearings BTW) and imposes them on each other in a circular pattern, so that one was a no-go as well. Just updating.

aanker
12-17-13, 06:41 PM
Would be easiest to install the complete mod by CapnScurvy and merge the edits from your other mods into it, or install RFB.

Happy Hunting!

Anvart
12-19-13, 09:06 AM
...
Hi, Maurox.

Once Hitman released the mod for A-scope and PPI radars (examples of shaders were written by Anvart and Nisgeis). Screens with similar pictures you can see above (IIRC, colour for PPI was slightly another...). In last versions of the game, lines and numbers for PPI there were hard-coded in files (*.act and, maybe, * .exe). If reverse engineering is available for you - flag to your hands.
All stuffs for this work were losted on my killed HDD.
Screens of Hitman's mod: http://www.subsim.com/radioroom/showthread.php?t=152097&highlight=PPI+radar #32

... and some my old pictures of A-scope.

Super simple version of the shader:

http://imageshack.com/a/img134/2301/hit03.jpg

In contrast of the picture that was shown above #3, this shader was written by me (very clean and stable)... and this shader is better then Hitman's previouse shader (I mean not text) written by other man:

http://imageshack.com/a/img529/7427/ascoped.jpg

CapnScurvy
12-19-13, 11:20 AM
The true "Guru" with this kind of stuff is Anvart!!

His work has allowed many of us to continue our ability to have a better working radar system. Hitman and Nisgeis both made major contributions as well.

My deepest respect goes to them for their fine work! :salute:

aanker
12-19-13, 11:44 AM
The true "Guru" with this kind of stuff is Anvart!!

His work has allowed many of us to continue our ability to have a better working radar system. Hitman and Nisgeis both made major contributions as well.

My deepest respect goes to them for their fine work! :salute:
I concur. ;)

Maurox
12-19-13, 12:51 PM
Well this turned out to be a huge waste of time :(

The reason for that is that I'm not really a programmer, like I said before - I'm a tinkerer, I play with the files that are somehow understandable without too much work decoding, or at least if there are programs able to decode them available... If we're talking about reverse engineering then I'm pretty much useless, so...

Well thanks for your time anyway :) Maybe someone with more programming skills will find this topic useful?

aanker
12-19-13, 04:59 PM
A learning experience for me. Great thread, thanks for starting it.