I want to upscale the vanilla sky textures

Discuss modding questions and implementation details.
User avatar
emmathepony
Posts: 248
Joined: Sat Jun 29, 2019 5:26 pm

I want to upscale the vanilla sky textures

Post by emmathepony »

Image

As seen in the above, I want to upscale the skyboxes that are present in the top image. I found the files with Dagger Imaging 2 and they are formatted as .dat files and consist of multi-part images making up an animation. I have the means to upscale images but I know nothing about DFU modding.

What is the easiest way to go about importing these into DFU so the game reads them?

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: I want to upscale the vanilla sky textures

Post by Interkarma »

You can use Daggerfall Imaging 2 to export each sky archive to PNG images. Click the "export" button on the toolbar to open the controls.

You can read more about texture modding on below page. At this time replacement of sky textures is not supported.

https://www.dfworkshop.net/projects/dag ... /textures/

But if you were able to put together some killer HD sky upscales, I'm sure we can get this support into a future update. :)

User avatar
emmathepony
Posts: 248
Joined: Sat Jun 29, 2019 5:26 pm

Re: I want to upscale the vanilla sky textures

Post by emmathepony »

Thanks, I had briefly read about that Streaming\Textures folder but I wasn't sure if Unity would read the .png to convert back into .dat. I guess it's good to know skies aren't moddable but possibly can be. I might have something to show soon to get the ball rolling!

UPDATE: This is a rough conversion as to what you can expect if all the skies were upscaled.
Spoiler!
Image

I could do touch-ups such as more noise to make it sharper.

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: I want to upscale the vanilla sky textures

Post by Interkarma »

No need to convert back into DAT files, DFU can take straight PNG files either loose or packed into a .dfmod file. The latter is preferred as it's smaller and faster. Just sky replacements aren't supported in either system yet. This will first need to go through the hands of our mod system overseer TheLacus.

When upscaling and sharpening, keep in mind that skies are stored in east-west pairs and after midday the sky records are flipped around (so east becomes west) and animated in reverse for the setting sun. Then flipped again at dawn and played forwards for rising sun.

This means the record frame pair must seamlessly tile on both sides. For example, record 0 frame 20 must tile seamlessly on either side of record 1 frame 20, otherwise player will see that seam as they look around. I've composed an example below so you can see how the stitched skies look in one panorama of a single sky frame from either side of pair.

stitched-skies.png
stitched-skies.png (34.54 KiB) Viewed 3174 times

User avatar
emmathepony
Posts: 248
Joined: Sat Jun 29, 2019 5:26 pm

Re: I want to upscale the vanilla sky textures

Post by emmathepony »

Interkarma wrote: Sat Jul 06, 2019 11:54 pm When upscaling and sharpening, keep in mind that skies are stored in east-west pairs and after midday the sky records are flipped around (so east becomes west) and animated in reverse for the setting sun. Then flipped again at dawn and played forwards for rising sun.

This means the record frame pair must seamlessly tile on both sides. For example, record 0 frame 20 must tile seamlessly on either side of record 1 frame 20, otherwise player will see that seam as they look around. I've composed an example below so you can see how the stitched skies look in one panorama of a single sky frame from either side of pair.
Right, got it. Simple upscaling shouldn't be an issue since it's literally just upscaling but with restored detail using my software. I've made attachment samples in this post, think it's worth making this into a mod? I don't wanna upscale all these skies only for DFU to not support them...
Attachments
[UPSCALED[ red sky - night - mountains.png
[UPSCALED[ red sky - night - mountains.png (1.87 MiB) Viewed 3170 times
[ORIGINAL] red sky - night - mountains.png
[ORIGINAL] red sky - night - mountains.png (25.02 KiB) Viewed 3170 times

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: I want to upscale the vanilla sky textures

Post by Interkarma »

If you want to mod the classic sky images specifically, then you need to equally observe the mechanical and engineering aspects involved in addition to the artistic elements. This is how classic Daggerfall does skies, so modding those images will bind your art to the same mechanical requirements. It's not really a matter of DFU supporting or not - that's just how classic skies work. :)

Alternatively, you could go the route of Enhanced Sky and replace the classic sky altogether with a system of your choosing. Then you could use a more standard skybox/skydome with HD painterly textures that fit the classic look. You might even be able to manipulate the classic sky images fit into a skybox texture (i.e a cubemap) with some distortion.

The source code for Enhanced Sky is maintained by Nystul here if you want to see how other modders replace the sky system entirely with a custom setup and script it all.

User avatar
emmathepony
Posts: 248
Joined: Sat Jun 29, 2019 5:26 pm

Re: I want to upscale the vanilla sky textures

Post by emmathepony »

Unfortunately, modding isn't my forte at all and wouldn't know where to even begin with it all, but your explanation of how classic DF does its sky system makes sense.

For now, I'll keep ahold of the upscaled images and maybe one day they can be used for an eventual identical system.

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: I want to upscale the vanilla sky textures

Post by Interkarma »

Happy to help. Good luck!

BansheeXYZ
Posts: 555
Joined: Fri Oct 23, 2015 8:19 pm

Re: I want to upscale the vanilla sky textures

Post by BansheeXYZ »

I highly recommend not drawing landscapes (mountains, trees) on sky texture replacements. Classic did this to give the illusion of distance because it couldn't render distant terrain. Now that we're able to render real distance, the fake horizons drawn into the sky textures haven't aged well.

Take this example image, you'll see trees on the horizon that are much smaller than ones purportedly much farther away in the sky texture.
horizon1.png
horizon1.png (459.38 KiB) Viewed 3133 times

User avatar
jayhova
Posts: 923
Joined: Wed Jul 19, 2017 7:54 pm
Contact:

Re: I want to upscale the vanilla sky textures

Post by jayhova »

It seems like one of the things you might want to do is simply shrink the original down and push it further back. That way you don't actually need to upscale the image you just take the same image and paste it into a bigger skybox. Take the same image and multiply it by 4x or 6x and you have it about right. Of course you will need to try and make the horizon a bit more random than simply repeating it 4x over. You could make several sets of these at 1x, 2x, 4x, 8x. People could then choose the look they want. If you wished to play at 640x480 the 2x would give a classic feel. At high resolutions 6x or 8x might be okay.
Remember always 'What would Julian Do?'.

Post Reply