Is the Flat import flawed?

Discuss modding questions and implementation details.
User avatar
King of Worms
Posts: 249
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Is the Flat import flawed?

Postby King of Worms » Wed Dec 06, 2017 5:26 pm

Hi all! Help!! :oops:

I face strange behavior of DFU engine when Im importing the up-scaled flats.
It seems like there is some hidden mechanics I fail to understand.

So please guys, lets solve this riddle so I can continue my work, I know u can do it! :twisted:

In-game settings to minimize any possible interference and variables:
- point filtering
- all mods off (support for them is ON)

1st IMG:
- original look without any imported texture
1.jpg
1.jpg (190.44 KiB) Viewed 157 times

2nd IMG:
- same view with all textures imported BUT the one we facing now (statue flat is not imported)
- here we can see, that by importing the other textures, the ORIGINAL flat gets down-scaled SUBSTANTIALLY
- that alone is a sign something strange is happening here, right?
2.jpg
2.jpg (161.4 KiB) Viewed 157 times

3rd IMG:
- now lets try to import ONLY the UP-SCALED Statue flat! So just ONE texture is in the streaming assets now.
- we get perfect result, this is EXACTLY the resolution of a new flat I placed into the streaming assets! Great!
3.jpg
3.jpg (206.98 KiB) Viewed 157 times

Lets continue in a next post please!
Last edited by King of Worms on Wed Dec 06, 2017 7:16 pm, edited 12 times in total.
User avatar
King of Worms
Posts: 249
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Re: Is the Flat import flawed?

Postby King of Worms » Wed Dec 06, 2017 5:27 pm

4th IMG:
- now I have enabled all the textures in the pack!
As we can expect , there will be the same behavior as in the 2nd IMG = the resolution of this flat will get REDUCED.
And that is exactly what is happening here. The resolution of the upscalled flat is reduced.
4.jpg
4.jpg (227.07 KiB) Viewed 156 times

So there is some hidden co-dependence of the resolution between the imported Flats. I think this is LIMITED to the flats only - so this problem does NOT manifest on the standard textures on the buildings etc. Only on flats.

- What am I missing here?
- What should I do to prevent this from happening?
- Is it something in the code which will need adjustment?


I must add that SOME of the up-scaled flats have high resolution, the biggest one is 2816 x 2048 , yes, that is high. But because its just 890kb, I do not see any problem there. Why so high resolution? Because I need to use some standardized up-scaling method, and this method has the best results. 90% of the flats are sub Full-HD resolution...

Thanks guys, I pray now! As I cant solve this on my own. Fingers crossed!
User avatar
TheLacus
Posts: 442
Joined: Wed Sep 14, 2016 6:22 pm
Contact:

Re: Is the Flat import flawed?

Postby TheLacus » Wed Dec 06, 2017 8:14 pm

Hi King of Worms!

Exteriors billboards textures are merged in an atlas of size 4096×4096 for each archive. If the total area of your textures exceeds the atlas capability the latest textures added are not shown correctly. I assume this is what's happening with the second image if you are using textures as big as you said in the last post.

The difference between the 3rd and 4th images is not resolution, looks like different filters. If you're sure point filter is enabled for both these screenshots, it may be some other material property. Please upload the sprite and tell me a location where you can find it, i'll check what's wrong when i have the time :)
User avatar
King of Worms
Posts: 249
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Re: Is the Flat import flawed?

Postby King of Worms » Wed Dec 06, 2017 8:52 pm

TheLacus wrote:Hi King of Worms!

Exteriors billboards textures are merged in an atlas of size 4096×4096 for each archive. If the total area of your textures exceeds the atlas capability the latest textures added are not shown correctly. I assume this is what's happening with the second image if you are using textures as big as you said in the last post.

The difference between the 3rd and 4th images is not resolution, looks like different filters. If you're sure point filter is enabled for both these screenshots, it may be some other material property. Please upload the sprite and tell me a location where you can find it, i'll check what's wrong when i have the time :)




Hi, thanks for a fast reply!

Im 100% sure in IMG 4 the filtering is the same, look at the ground etc - everything is the same in all the pictures. Only thing I did was adding the rest of the flats to the streaming assets - and that resulted in the resolution decrease. Its the same principle as in the IMG1 to IMG2, but now its happening in the high res flat, so its not THAT much visible.

Anyway, I see now that theres a reason behind this - all the images from a archive must fit into 4096x4096 frame, right?
Can we increase that frame than? Because thats not much, considering some archives like the trees for each region have 10s of quite big flats in it...

Btw wrote PM to interkarma and he said to contact you anyway :)
He also mentioned "Are you also providing the XML file to handle flat scaling?" which I dont have a clue about.


Thanks a lot for your time!

EDIT/UPDATE: Its deffinitely a atlas overflow. I tested it with ONE single archive of statues I link bellow. If I use ONLY the green refference statue 097_13-0.png everything is in order, when I add the rest of the statues, we get the atlas overflow and the resolution of the statue drops! So that is the reason, nice! Now how to solve it :) Can we increase the atlas size? Or do we really need to fit in that small atlas? That would be sad, I believe in you! :)


LOCATION:
DAGGERFALL CITY
BY THE CASTLE
daggerfall.jpg
daggerfall.jpg (171.06 KiB) Viewed 112 times


ALL STATUE SPRITES FROM THE ARCHIVE 097
https://files.fm/u/vyrw2zp2

SPRITE 097_13-0.png
097_13-0.png
097_13-0.png (239.62 KiB) Viewed 112 times

Return to “Modder Discussion”

Who is online

Users browsing this forum: Bing [Bot] and 2 guests