Fully unlimited GTA2 window resizing and positioning

Anything to do with GTA1/GTA2 modding (tools, scripts and more).
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Fully unlimited GTA2 window resizing and positioning

Post by elypter »

This could be interesting for all widescreen monitor users:

this commandline tool combines the advantage of optimal screen usage in fullscreen while keeping 4:3 ratio(But you can choose any size and position) and having fast access to the desktop during game.

usage:
-select window mode in gta manager or by presssing ALT+Enter
-copy this tool to a folder of your choice (eg: <gta-folder>\extras\ )
-create a shortcut to your desktop
-edit the shortcut execution target to in one of the ways below (rightclick properties and modify the line i selected on the screenshot)
-have the script running while playing gta2 (only once preferably)

weitblick.exe : resize window to approximately full screen height keeping 4:3 ratio and position it in the screen center
weitblick.exe transp : set window transparency
weitblick.exe width height : set window size
weitblick.exe width height transp : set window size and transparency
weitblick.exe width height posx posy : set window size and position
weitblick.exe width height posx posy transp : set window size, position and transparency

notes:
transp: 0-255 (0=invisible) doesn't seem to work on winxp (i guess aero is required)
width&height: ~0 - very much
posx&posy: can also be negative
multimonitor: without arguments the window is positioned in the middle of the complete desktop resolution.
also works under linux with wine (tested ubuntu 10.4 & wine 1.3.34)

example usage:
weitblick.exe 500 500 10 10 220

suggested values:
1280x1024 win7 default_theme: 1296 1031 -8 -30 (hide borders and caption but display taskbar)

download
http://gta2dare.omnitude.net/_game/11_e ... tblick.exe
Attachments
screenshot on my 1280x1024 zalman
screenshot on my 1280x1024 zalman
windowed_fullscreen.jpg (61.14 KiB) Viewed 40073 times
shortcut editing window
shortcut editing window
shortcut.jpg (87.5 KiB) Viewed 40073 times
Last edited by elypter on 11 Jan 2011, 18:58, edited 5 times in total.
yur sa'nok ngeyä
BenMillard
Immortal
Posts: 889
Joined: 16 May 2009, 06:14
GH nick: BenMillard
Location: London, UK
Contact:

Re: Fully unlimited GTA2 window resizing and positioning

Post by BenMillard »

A screenshot showing how to edit the Target part of a Windows Shortcut would probably help everyone who tries this. Only myself, you, Sektor and Vike are likely to have done this in the past.

Well, us and anyone people who's used the Profile Manager in Firefox.
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

i hope everybody understands this now
yur sa'nok ngeyä
Razor
Lunatic
Lunatic
Posts: 456
Joined: 19 Jul 2008, 14:14
GH nick: Razor, R
Location: Poland / Szczecin
Contact:

Re: Fully unlimited GTA2 window resizing and positioning

Post by Razor »

refreshing sux :)
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

you mean that the program tries to keep the window in position and shape? thats required, at least to some extent, because windows or gta is trying to move or resize the window when clicking on it or on other occasions. You could try what happens when you close the script. And is it happening continuously? it should only update when something is different.
yur sa'nok ngeyä
BenMillard
Immortal
Posts: 889
Joined: 16 May 2009, 06:14
GH nick: BenMillard
Location: London, UK
Contact:

Re: Fully unlimited GTA2 window resizing and positioning

Post by BenMillard »

Haven't tried it out but I support this work. Widescreens are normal for laptops and the more media-centric PCs.

Might even be worth Vike looking into making the EXE itself support more resolutions? I imagine it's already on his list but less of a priority over fundamental things, like the super-lame newbie experience with ports and compatibility.

I agree with the game itself staying at 4:3 aspect ratio even on wide screens, so everyone sees the same area.
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

directly implemented positioning resizing would be cool. I also think of a caption and borderless mode like it is possible with all hl2 engine games. I was able to remove the captionbar but not the oversized frames of win7.

seing the same area is not the most important problem afaik. I would also agree with it but isn't it impossible to select a widescreen resolution i gta? i never saw one in gta manager. I always had to play with a 4:3 gta stretched to 16:9 which looks really bad and is confusing.
yur sa'nok ngeyä
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

i updated it. now it doesn't crash anymore after closing gta2.
yur sa'nok ngeyä
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

another update:
-no unneeded repositioning and resizing anymore (this should eliminate lags on wine).
-resizing is indicated by a decent beep.
yur sa'nok ngeyä
BenMillard
Immortal
Posts: 889
Joined: 16 May 2009, 06:14
GH nick: BenMillard
Location: London, UK
Contact:

Re: Fully unlimited GTA2 window resizing and positioning

Post by BenMillard »

My laptop hs 1600x900 desktop size. By editing the registry and never using GTA2 Manager, I can play fullscreen at 1200x900 and in window mode at 1080x800. I use Play Alone and press Alt+Enter to switch modes, to avoid lagging multiplayer games.

To Set Custom Display Modes in GTA2
Press Windows+R to get the Run box. Then type regedit and press Return. That displays the Registry Editor window. In there, navigate to:

HKEY_CURRENT_USER > Software > DMA Design Ltd > GTA2 > screen

Double-click each of these settings and set it to the bold value - they are hexadecimal. (The normal decimal value is given in brackets at the end - do not type that value.)
  • full_height = 384 (900)
  • full_width = 4b0 (1200)
  • window_height = 32a (810)
  • window_width = 438 (1080)
1200x900 is not a standard resolution but it matches the height of my laptop screen. This screen automatically creates a letterbox effect down the left and right, so the picture is exactly how GTA2 renders it. (No additional stretching by the screen.)

1080x810 is vertically halfway between 720p and 1200x900. It's not a standard resolution it fits perfectly above single-row taskbar when the game starts centred on the screen in window mode.
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

if your graphic card allows that custom resolutions its always a good choice to use them. unluckily not many laptops and drivers are compatible. so your gta will crash if the resolution is not valid.

have you tried if recording with fraps works with that resolution?
yur sa'nok ngeyä
User avatar
Salamander
Janitor
Janitor
Posts: 145
Joined: 01 Apr 2009, 20:38
GH nick: Salamander
KingSalamander
Sally
[00]
Contact:

Re: Fully unlimited GTA2 window resizing and positioning

Post by Salamander »

By recording anything other than 640x480 you are wasting disk space and very likely getting an inferior result, as anything over 640x480 is stretched using algorithms that are meant to be fast at the cost of low quality. There really is no point doing that as far as GTA2 is concerned. More so, as you're capturing larger images, not only is your computer busy stretching each frame, it also has to pump more data to read each frame from the framebuffer, to compress it using the fraps codec and finally to write it to disk, so the chance of the recording jerking is higher.

Record at 640x480. You might also be excused for running GTA2 windowed at 960x720 for youtube reasons, but anything other than that is pointless.
User avatar
Pyro
Immortal
Posts: 414
Joined: 17 Mar 2010, 04:07
GH nick: Pyro
Location: Wales, UK

Re: Fully unlimited GTA2 window resizing and positioning

Post by Pyro »

Unless you have a dinosaur of a computer you're very unlikely to get jerky frames anyway. Not like you're trying to record a high texture and resolution game with Fraps here :P

Then again I don't record GTA2 and my PC is pretty good anyway.
User avatar
elypter
Immortal
Posts: 1120
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Fully unlimited GTA2 window resizing and positioning

Post by elypter »

you would be the first person that is able to record gta2 properly with fraps. i wouldn't be that sure before trying it.
yur sa'nok ngeyä
User avatar
Pyro
Immortal
Posts: 414
Joined: 17 Mar 2010, 04:07
GH nick: Pyro
Location: Wales, UK

Re: Fully unlimited GTA2 window resizing and positioning

Post by Pyro »

I can think of better things to record than GTA2 :P

If I can record games like Crysis at 1680x1050 (highest my monitor will go) at max settings at a decent rate, you'd think GTA2 would be a walk in the park in comparison unless it's really screwed up. Just for reference I have AMD 2.6GHz quad-core, nVidia GTX 460 with 1GB GDDR5, 4GB DDR3 RAM, Windows 7 Ultimate 64-bit and two SATA 2 drives in RAID setup. Not like GTA2 even cares for all that :P
BenMillard
Immortal
Posts: 889
Joined: 16 May 2009, 06:14
GH nick: BenMillard
Location: London, UK
Contact:

Re: Fully unlimited GTA2 window resizing and positioning

Post by BenMillard »

Your hardcore hard drives are probably what enable you to record at that rate. Sadly my compact laptop drive can barely manage half-resolution capture, 10fps with GTA2 running 640x480. (The rest of your specs are the same league as this Dell Inspiron N7010 laptop.)

Recording video doesn't care how the game was made. It's just taking a bitmap screenshot once per frame.

Haven't tried disabling AVG resident while recording. That might stop the sequential writes from being sequentially scanned for suspicious activity. I've seen a few other bits of advice but they only make 5-10% difference; I really need 50% better performance.
User avatar
Cuban-Pete
Immortal
Posts: 909
Joined: 29 Jan 2010, 15:03
GH nick: Cuban-Pete

Re: Fully unlimited GTA2 window resizing and positioning

Post by Cuban-Pete »

Just get a SSD - it makes any pc super-god-like-fast.

But if you record - a - lot - it will get expensive. SSD is per GB big bucks.
"Mmmm, your eyes are so beautiful."
User avatar
T.M.
Immortal
Posts: 960
Joined: 29 Jan 2010, 15:00
Location: F21B3EED

Re: Fully unlimited GTA2 window resizing and positioning

Post by T.M. »

I bought SSD once... it was good for a while but then it started to get really super slow (read & write). So i stopped using it and never gonna buy one again, at least not with these prices (30GB/250€) !

SSD's write speed is at the beginning around 30MB/s then it goes quickly down to 5MB/s once you use it a little bit. My HDD has always been (since beginning of times) at least 60MB/s. You would need dozens of SSD's to get any kind of advantage over HDD's, in means of writing.

Now i made a test with my SSD (few weeks used after complete formatting), file size: 2GB:
HDD -> SSD: 7m 48s (4.7MB/s) (as fast as my internet connection! HAHA)
SSD -> HDD: 34s (63.3MB/s) (probably faster to read from SSD, but HDD write speed is just limiting it)

Made test with USB stick too (wow!):
HDD -> USB: 2m 24s (15MB/s)
USB -> HDD: 1m 5s (33MB/s)

SSD's are good only for reading operations, writing is super slow, so dont get hopes up for recording movies faster with SSD's, unless youre a millionaire and you can afford 1000 of them in RAID!

I think i will keep the SSD with only my OS drive, i wont install any programs on that drive since they will hang the whole OS if they start writing something. (experienced that too before, horrible). I think that hanging is because SSD's cant multitask at all: it can only read/write one file at time, while HDD can read multiple files at same time but only slower by reading them sequentially a little bit each time.
User avatar
Cuban-Pete
Immortal
Posts: 909
Joined: 29 Jan 2010, 15:03
GH nick: Cuban-Pete

Re: Fully unlimited GTA2 window resizing and positioning

Post by Cuban-Pete »

Hmm, strange.

Works like a charm here as main drive (OS and programs I often use): http://tweakers.net/pricewatch/282240/c ... -64gb.html

Of course put your important files on a HDD, it's safer. :)
"Mmmm, your eyes are so beautiful."
User avatar
Pyro
Immortal
Posts: 414
Joined: 17 Mar 2010, 04:07
GH nick: Pyro
Location: Wales, UK

Re: Fully unlimited GTA2 window resizing and positioning

Post by Pyro »

BenMillard wrote:The rest of your specs are the same league as this Dell Inspiron N7010 laptop.
Unlikely, but knowing laptops they opt-in for low power stuff or integrated graphics and the like, but since Dell have bought out Alienware some time ago they are actually brining out half decent laptops for a change (still prefer their desktop machines over laptops any day, their monitors are great too). Still, I don't want this comment to become a "my X is better than your Y", I built my PC for media and Blu-ray and (mostly) gaming (wouldn't mind a better monitor though), does the job fine as I'm sure a laptop does for your purposes. 8-)
T.M. wrote:SSD's are good only for reading operations
This pretty much nails it on the head on what SSD's are good for. I'd love one for my games drive but, as pointed out, they are so prohibitively expensive it's far cheaper just to buy normal HDD's and RAID them (well, until Thailand recently had a bit of a water problem and prices went up, some as much as 70%+ :shock: ).

Last time I checked it was roughly about 6p per GB on a 1TB HDD, now it's up to about 8-10p per GB on 1 TB HDD. Compared to SSD's, they are near (average) £1 per GB :shock: Not sure how long it'll be before it's even HALF that price per GB let alone anywhere near 6-10p per GB. Only time will tell but I wish they'd hurry it up :P
Post Reply