Graphics Enhancement Pack

Old topic!
The last post in this thread is over 60 days old. Posting in this thread will be considered a bump, so please make an attempt to be courteous if you go ahead with it.

If the last post is over 6 months old, it may instead be a better idea to start a new topic. If you aren't sure about what to do, feel free to ask a staff member for help, or try to locate a 'general questions'-type thread if it exists in this (sub-)forum.
Jun 27, 2017 at 11:06 PM
Okay I give up... for now
"What is a man!? A miserable pile of secrets! But enough talk, have at you!"
Join Date: Dec 31, 2011
Location: United States
Posts: 1834
Age: 24
Not to be a tease, but I do have an experimental Borderless Fullscreen implementation in the works. I have a video of it in-use here.


Not only does it make it easier to change between windows while playing - as you'd expect from borderless-fullscreen - but it even fixes the blurry filtering you'd see in the original fullscreen mode. That might vary depending on the PC running it though; I've only tested it on this machine.
Whoa, that's really interesting, playing the game way zoomed out. You're really manipulating this view all the way. I'll be interested to see what comes of this.
 
Jun 27, 2017 at 11:17 PM
Part-Time Perfectionist
CS Beta Content Discord Admin
"Bleep, Bloop, Bleep, Bloop"
Join Date: Dec 26, 2014
Location: the back of their own hand.
Posts: 1599
Age: 120
Whoa, that's really interesting, playing the game way zoomed out. You're really manipulating this view all the way. I'll be interested to see what comes of this.
Problem with that is it breaks things like the Iron Head fight, and things like those beetle's placements.
 
Jun 28, 2017 at 1:44 AM
Okay I give up... for now
"What is a man!? A miserable pile of secrets! But enough talk, have at you!"
Join Date: Dec 31, 2011
Location: United States
Posts: 1834
Age: 24
Problem with that is it breaks things like the Iron Head fight, and things like those beetle's placements.
Are you saying this theoretically, or because you actually tried it (I didn't notice a download link for this patch in particular)? If the former, it seems like the game would just be centered or to the right, but still functional. Also, whether or not the beetles would get messed up depends on whether they react to the player's movement, or to the camera. If it is the camera that determines how the beetles react, then that might pose a problem, but it if's just in response to the player getting within proximity, then it shouldn't be much of a problem.
 
Jun 28, 2017 at 2:18 AM
Part-Time Perfectionist
CS Beta Content Discord Admin
"Bleep, Bloop, Bleep, Bloop"
Join Date: Dec 26, 2014
Location: the back of their own hand.
Posts: 1599
Age: 120
Are you saying this theoretically, or because you actually tried it (I didn't notice a download link for this patch in particular)? If the former, it seems like the game would just be centered or to the right, but still functional. Also, whether or not the beetles would get messed up depends on whether they react to the player's movement, or to the camera. If it is the camera that determines how the beetles react, then that might pose a problem, but it if's just in response to the player getting within proximity, then it shouldn't be much of a problem.
I saw that the beetles still come in from the left or right of the screen when triggered, even though the screen is so large that they'll be too far away from the player to reach them as fast as they usually can. And with the Iron Head fight, you can see the sides of the map. (with the Ikachan thing) Also the motion walls end before then, so there are gaps in them. Also there are situations with things like the Undead Core, where you can see them being loaded in when you hit an H/V trigger because you're not supposed to be able to see that far.
 
Jun 28, 2017 at 2:54 AM
Okay I give up... for now
"What is a man!? A miserable pile of secrets! But enough talk, have at you!"
Join Date: Dec 31, 2011
Location: United States
Posts: 1834
Age: 24
I saw that the beetles still come in from the left or right of the screen when triggered, even though the screen is so large that they'll be too far away from the player to reach them as fast as they usually can. And with the Iron Head fight, you can see the sides of the map. (with the Ikachan thing) Also the motion walls end before then, so there are gaps in them. Also there are situations with things like the Undead Core, where you can see them being loaded in when you hit an H/V trigger because you're not supposed to be able to see that far.
You are correct that a lot of things in the game would look really weird with this mod if the maps were left unchanged; if that's all that you were saying, then forgive me for misunderstanding you. At first I thought you were implying that the actual behavior of the entities in the game would be different within the regular view of the camera, but I see what you're saying now.
 
Jun 28, 2017 at 2:56 AM
Senior Member
CSE Discord Admin
"Fly, Fly, Fly!"
Join Date: Jan 13, 2016
Location:
Posts: 127
Yep, those beetles have been annoying me for a while. If I remember right, in 21:9, they spawn inside the Igor boss arena. I've been keeping track of things like these on GitHub's issue tracker.

The Ironhead thing was particularly tricky: for the longest time, I had an unfinished conversion of the boss, that would work at whatever ratio you were playing at, but I realised that the chemistry of the fight was completely dependant on being in a 4:3 box. Imagine Ironhead at 8:1, like that video; it simply wouldn't work. Instead, I replaced it with blacks bars, making it appear like any other small room.

I already have an idea on how to fix the beetle spawning, but it's pretty low on my list because of how much more work it requires than other widescreen fixes.

Stuff like Undead Core, I've also been keeping track of, but those are even lower on my list because they're map/TSC-based fixes. I could probably count the number of times I've opened a Cave Story level editor on one hand, no joke.
 
Last edited:
Jun 28, 2017 at 3:50 AM
Part-Time Perfectionist
CS Beta Content Discord Admin
"Bleep, Bloop, Bleep, Bloop"
Join Date: Dec 26, 2014
Location: the back of their own hand.
Posts: 1599
Age: 120
Stuff like Undead Core, I've also been keeping track of, but those are even lower on my list because they're map/TSC-based fixes. I could probably count the number of times I've opened a Cave Story level editor on one hand, no joke.
I wouldn't mind helping if you can't do it. You basically just need to put whatever script the H/V trigger activates in the fade in event, if I'm correct.
 
Jun 29, 2017 at 11:59 AM
Junior Member
"Fresh from the Bakery"
Join Date: Dec 7, 2014
Location:
Posts: 10
I have an idea to fix all or most of the character spawning / despawning on screen during cutscenes:
put black bands on the screen to simulate the 4/3 resolution during cutscenes.
That could look cool too, like the letterbox effect in other games (https://i.ytimg.com/vi/JhFMyxL6JVI/maxresdefault.jpg) even though the letterbox is supposed to be used on the top and bottom of the screen.
The only problem with that would be the HUD: either hide it or make sure it's always fully covered by the black bands.
 
Jun 29, 2017 at 12:22 PM
Senior Member
CSE Discord Admin
"Fly, Fly, Fly!"
Join Date: Jan 13, 2016
Location:
Posts: 127
I dunno, I'd rather fix the cutscenes directly, whenever I get around to it. Forcing bars on every cutscene seems like a cheap hack.
 
Jun 29, 2017 at 4:03 PM
Junior Member
"Fresh from the Bakery"
Join Date: Dec 7, 2014
Location:
Posts: 10
But if you fix each cutscene individually you risk breaking other things in mods that don't use the same cutscenes.
 
Jun 29, 2017 at 4:38 PM
Senior Member
CSE Discord Admin
"Fly, Fly, Fly!"
Join Date: Jan 13, 2016
Location:
Posts: 127
That's not an issue if the mod in question is built around widescreen. I don't really intend for this modhack to be applied to mods that weren't designed to use it in the first place. Vanilla Cave Story is just an exception.

I'm not the most familiar with TSC, but wouldn't it be difficult to detect when an actual cutscene is occurring anyway? I mean, don't opening chests trigger TSC scripts? If I were to apply black bars whenever a TSC script is being ran, then they'd be appearing all the time, usually for no reason.
 
Jun 29, 2017 at 5:48 PM
Junior Member
"Fresh from the Bakery"
Join Date: Dec 7, 2014
Location:
Posts: 10
I never modded. But I guess it wouldn't bother me when opening a chest or obtaining a life capsule.
 
Jun 29, 2017 at 5:59 PM
In my body, in my head
Forum Moderator
"Life begins and ends with Nu."
Join Date: Aug 28, 2009
Location: The Purple Zone
Posts: 6000
I never modded. But I guess it wouldn't bother me when opening a chest or obtaining a life capsule.
you underestimate how pervasive scripts are
 
Jul 27, 2017 at 12:45 AM
Senior Member
CSE Discord Admin
"Fly, Fly, Fly!"
Join Date: Jan 13, 2016
Location:
Posts: 127
v1.3

Alright, here's a new update:
  • Added Borderless Fullscreen
  • Fixed font upscaling with higher window sizes
  • Fixed FPS location in widescreen
  • Disabled window.rect
  • Fixed the Ironhead fight by adding black bars
Borderless fullscreen is the new replacement for Cave Story's built-in fullscreen. It has some benefits, like working properly with widescreen, better support for alt-tabbing, and not blurring everything (EDIT: turns out this depends on your drivers). You can enable borderless fullscreen by just selecting any of the three fullscreen options in DoConfig.

Also added are some new settings.txt options:
  • 'disable_ironhead_black_bars' - Disables the black bars in room 0x1F (the Ironhead arena in the vanilla game). May be useful for mods that use the room for something else.
  • 'borderless_fullscreen' - Replaces Cave Story's fullscreen mode with a borderless fullscreen implementation.
  • 'borderless_fullscreen_auto_aspect_ratio' - When in borderless fullscreen, the game auto-detects your monitor's resolution, and chooses the most appropriate aspect ratio (overrides the above 'aspect_ratio_x' and 'aspect_ratio_y' settings).
  • 'borderless_fullscreen_auto_window_upscale' - Like the previous option, this one automatically chooses the highest-resolution window for your monitor, improving font smoothness (overrides 'window_upscale').
They are simple 'true'/'false' settings.
 
Last edited:
Jul 27, 2017 at 1:59 AM
bored to death
Bobomb says: "I need a hug!"
Join Date: Oct 7, 2011
Location: elsewhere
Posts: 754
Age: 20
I'm noticing a slight delay whenever music (both org and ogg) is loaded with this new update
EDIT: This seems to be caused by the new version of the ogg player
 
Last edited:
Aug 1, 2017 at 7:47 AM
gigantic immortal dog...?
"That dog!"
Join Date: Apr 18, 2006
Location: Forever wandering the tower...!
Posts: 1746
Loving the full screen feature.

Looks like Kazuma has to squint to see Curly...
Just playing around with 4k settings again lol.  Would be fun to really fill in the detail though... like Wonder Boy 3's recent remake.
And switching graphics and music on the fly is really neat...

Anyway, fun fact:  Resizing the bmps for 4k turned a 2 meg game into a 1.1 Gig game; not including ogg music... Yikes!
And as a side note, the full screen change made it compatible  with the DXGL ddraw.dll ... which means I can run Steam overlay as well. (with resolutions under 4k, otherwise it seems to crash on start while using the ddraw.dll.)
Again, thanks for making this!!
 
Mar 7, 2018 at 2:09 AM
Senior Member
CSE Discord Admin
"Fly, Fly, Fly!"
Join Date: Jan 13, 2016
Location:
Posts: 127
I think I can dub this 'the smoothness update'.

First and foremost, there's a new setting called 'remove_sprite_alignment'. Sprite alignment is an aesthetic choice in the original game: to accurately imitate a 320x240 display, the game artificially forces all sprites to a grid, even when you're playing in fullscreen on a HD monitor. This becomes a problem when you start using higher-resolution sprite sets, as suddenly sprites can only seem to move two or more pixels at a time.

How much difference does removing this make?



In this example, the background and Gaudi are still aligned to the grid, while the foreground isn't. As you can see, while the foreground moves smoothly, the Gaudi and background visibly jitter.

The other big change is that exclusive fullscreen has been restored, and with it I've added V-Sync. V-Sync is meant to address the issue of Cave Story's frame output being pretty unstable. Normally it skips a lot of frames. The machine in Malco's room is a pretty good example of this: in-game it visibly hangs on several frames, when in reality it's meant to be extremely rapid.

Of course, this synchronises the game with your monitor's refresh rate, so if it's 100Hz, the game will run at 100FPS. Theoretically, if your monitor's refresh rate is high enough, you shouldn't have dropped frames anyway, so you don't need V-Sync in the first place.

V-Sync will not work in windowed or borderless fullscreen mode.

The 60FPS mod has also been merged with this mod. In addition, I've adjusted it to actually make the game run at 60 frames a second, rather than 59. Instead of waiting 17 milliseconds every frame, it now waits 16 milliseconds every third frame.

Link to latest version here.
 
Last edited:
Jul 20, 2018 at 12:57 AM
Senior Member
CSE Discord Admin
"Fly, Fly, Fly!"
Join Date: Jan 13, 2016
Location:
Posts: 127
So much for 'the smoothness update'. That thing was all kinds of janky thanks to a nasty oversight.

So, for those who haven't seen my rant on Discord, have you ever noticed how, with my remove-sprite-alignment patch, sometimes Quote would 'desyncronise' with the level? Like, as the camera slowly comes to a crawl, Quote would sometimes move by a pixel before the level does? Well, that's because of silly subpixel quirks. The original game divided the coordinates of both Quote and the camera individually before adding them together. My DLL didn't. The problem with that is the subpixel values of each coordinate could allow the result to overflow by 1, causing the desync effect. Anyway this update's got a fix for that, along with some other features:

1.5
  • (Sprite resolution) Change resolution of Resource bitmaps as well
  • (Fullscreen) Made V-Sync disable itself if it detects the monitor is not 60Hz
  • (Fullscreen) Fixed fullscreen not working if the modder renamed Config.dat
  • (Fullscreen) Added fullscreen integer scale setting
  • (Remove sprite alignment) Fixed screen flash not appearing
  • (Remove sprite alignment) Overhauled mod to fix sprite/level desync
  • (Widescreen) Apply widescreen background patches to the opening cutscene
  • (Widescreen) Fixed some Sand Zone enemies activating on-screen
  • (Widescreen) Fixed Egg Corridor's enemies, Beetle and Basu
  • (Widescreen) Tried to make fading take the same time as 4:3
I think the integer fullscreen thing's worth talking about here: by default, fullscreen mode would try to fill your entire screen by zooming-in. But this would naturally introduce some blurriness in most cases. I did have this one trick, where if I disabled the auto settings, and set aspect_ratio_x to my monitor's width, and aspect_ratio_y to any multiple of 240, I'd get pixel-perfect output with no blurriness. Turns out this doesn't always work though, depending on your monitor's size (1366x768 doesn't work, for example).

So, I added a setting to force fullscreen to display the game at its native resolution, with no zooming at all. auto_window_upscale and auto_aspect_ratio now get the fullscreen window to be the closest fit possible, without breaking that integer-scale limit. As you can guess, this introduces black bars along the top and bottom of the screen, so this is disabled by default.

Beetle and Basu have been a nightmare to deal with since I started the widescreen patch. The way they work is downright bizarre: they're not like the Sand Zone enemies, which spawn inactive, and only become active when you come within a certain range of them. No, they start off as little spawner objects, which then turn themselves into a Beetle or Basu when you walk over them.

The idea is that when you cross these spawners, a Beetle/Basu will appear off the side of the screen. You can probably guess why this is an issue for widescreen. Previously, I've just settled for spawning them further away from their spawner, so they still appear off-screen, but if your screen is wide enough, this can cause the enemies to spawn inside places like the Igor arena, where they're absolutely not meant to appear. I've tried making it so the spawner hitboxes are wider, so they technically spawn in the same place as in 4:3, but that doesn't fix the ones that spawn behind you.

I'm pretty sure it's impossible to get accurate behaviour from those enemies in widescreen. So instead, I've just tried to make things more presentable. So now, when they spawn on-screen, they're accompanied by a small explosion effect to make it look like they teleported in (which, to be fair, they did).

Download link here.
 
Last edited:
Aug 6, 2018 at 7:24 PM
Senior Member
"Master using it, and you can have this!"
Join Date: Oct 24, 2016
Location:
Posts: 70
Age: 28
Cool Idea!
Zoom on Buttons!
1234567890
100%
50%
25%
12,5%
6,25%
3,425%
=)
 
Top