Option "prefer dds texture" problem
#1
Posted 19 January 2018 - 02:06 PM
The option "Prefer dds texture if available" doesn't work with night textures. Some of my newer houses for my route have only dds textures in the normal folder and in the SNOW and NIGHT folders. In daytime everything works, but in the night all the houses with dds textures are gray.
Did I misunderstand anything or is it a bug?
#2
Posted 20 January 2018 - 11:24 AM
Edward K.
#3
Posted 20 January 2018 - 01:01 PM
I also recall the gray issue you mentioned. This will happen if there is not enough memory. The use of the .dds texture file at night as an option is a bug.
Edward K.
#4
Posted 20 January 2018 - 02:27 PM
#5
Posted 20 January 2018 - 05:43 PM
In hindsight I can't say it was a comprehensive test but what I saw was enough for me to not want to use .dds files until such time things like bump maps and surface normals were enabled in OR.
#6
Posted 20 January 2018 - 09:35 PM
Edward K.
#7
Posted 21 January 2018 - 12:58 AM
#8
Posted 27 January 2018 - 09:02 AM
Edit: If you do work with dds files and have other issues such as winter. Let me know. Dave mentioned that dds files use more memory, but I have to wonder how the use of the files works under the Monogame version.
Edit2: As a reminder, if the shape file has been modified to use dds files, make sure the usage is for the shape file and the option to use dds files does not have to be checked. If the shape file is using a dds file, the file would have to be located in the main texture directory as well as the night directory.
I also realized the action of removing the post was not necessary. I should have removed the attached files.
Edward K.
Attached File(s)
-
Runactivity_X4045.zip (656.37K)
Number of downloads: 463
#9
Posted 04 February 2018 - 01:38 AM
edwardk, on 27 January 2018 - 09:02 AM, said:
Edit: If you do work with dds files and have other issues such as winter. Let me know. Dave mentioned that dds files use more memory, but I have to wonder how the use of the files works under the Monogame version.
Edit2: As a reminder, if the shape file has been modified to use dds files, make sure the usage is for the shape file and the option to use dds files does not have to be checked. If the shape file is using a dds file, the file would have to be located in the main texture directory as well as the night directory.
The code changes in X4052 for this fix have a few unnecessary changes I'd like you to undo:
- All the changes in the "SceneryMaterial" constructor are unnecessary and will complicate maintenance by duplicating code from elsewhere - "Viewer.TextureManager.Get" already does the correct loading operation based on file type.
- The change from "Simulator" to "Viewer" in the signature of "GetNightTextureFile" is unnecessary - please use "simulator.Settings" instead.
#10
Posted 04 February 2018 - 03:10 PM
Your message box must be full because I was unable to send you a message so here it is below.
I read your post and the first change was easy enough. I would have kept "Viewer.Simulator" if I found "Viewer.Simulator.Settings". The second issue needs more clarification. The changes I made in Materials.cs is based on the changes found at line #68.
Any ideas as to how I can improve the change since this is handling night textures? The changes in Helper is already passing back the ace file or dds file. The only catch is that the dds files needs this process.("DDSLib.DDSFromFile(nightTexturePath, viewer.GraphicsDevice, true, out NightTexture);") This means we still need to test if its either a dds file or ace file.
Edit: There are only 2 areas in Materials.cs that processes dds files. The first is in the area of line #68 and the area starting at #690 that handles night textures.
Edward K.