Textures: Altering of the default load behaviour (Test please!)
3 posters
Page 1 of 1
Textures: Altering of the default load behaviour (Test please!)
Today's build (17th January 2017) contains a small change to the way that some textures are loaded into the simulation.
First, a picture from 1.5.0.9:
Second, a picture from today's daily build:
You can hopefully see that in prior builds, there's a visible seam between the different textures on this loco front. (SteveGR's Class 47s)
From my digging, this behaviour appears to have appeared in Michelle's v1.4.0.5, where non-static objects seem to have been changed to force RepeatRepeat as the texture repeat mode, which would appear to me to be a bug.
Testing, I can't see any downsides to the change I've made, but could really do with someone else looking to see if they can see any oddities.
I'd also like someone else to confirm using Steve's 47s (Or anything else that shows this!) that this has vanished for everyone
Specifically, any changes will be visible on either train objects, or animated objects containing functions within the world.
One new command has also been introduced for .b3d and .csv objects as part of this change:
Cheers
First, a picture from 1.5.0.9:
Second, a picture from today's daily build:
You can hopefully see that in prior builds, there's a visible seam between the different textures on this loco front. (SteveGR's Class 47s)
From my digging, this behaviour appears to have appeared in Michelle's v1.4.0.5, where non-static objects seem to have been changed to force RepeatRepeat as the texture repeat mode, which would appear to me to be a bug.
Testing, I can't see any downsides to the change I've made, but could really do with someone else looking to see if they can see any oddities.
I'd also like someone else to confirm using Steve's 47s (Or anything else that shows this!) that this has vanished for everyone
Specifically, any changes will be visible on either train objects, or animated objects containing functions within the world.
One new command has also been introduced for .b3d and .csv objects as part of this change:
CSV:
SetWrapMode
B3D:
WrapMode
This may be set to RepeatRepeat ClampRepeat RepeatClamp or ClampClamp and controls the OpenGL wrap mode used for that texture/ face.
(It's very hard to explain simply what this does, but if you want to change it from the default, you should know how it works)
Due to the differences between the main program and the viewers, this is only supported in the main program.
Cheers
Re: Textures: Altering of the default load behaviour (Test please!)
It looks fine now, Chris.
I've looked at several train externals, and there is no sign of any thin black lines now.
Tony
I've looked at several train externals, and there is no sign of any thin black lines now.
Tony
call2- Posts : 53
Join date : 2011-08-31
Re: Textures: Altering of the default load behaviour (Test please!)
Thanks for this small tweak, it was very annoying in some case.
I wonder if there would be any side effects if this was applied to static objects too, because I have noticed it in static parts in a train I am developing. You can get the train here if you need it: http://bvebarcelona.tk/en/downloads/trains/3000-series/
In the screenshot attached to this message you will see what I mean. The transparency setting in OpenBVE is set to "Smooth".
Thank you!
I wonder if there would be any side effects if this was applied to static objects too, because I have noticed it in static parts in a train I am developing. You can get the train here if you need it: http://bvebarcelona.tk/en/downloads/trains/3000-series/
In the screenshot attached to this message you will see what I mean. The transparency setting in OpenBVE is set to "Smooth".
Thank you!
- Attachments
Marc Riera- Posts : 28
Join date : 2015-12-21
Location : Barcelona, Spain
Re: Textures: Altering of the default load behaviour (Test please!)
Hmm....
The short answer is that I'm not sure that implementing a generic fix for this won't break something else, or at least make some stuff look worse
Michelle's code is essentially determining the wrap mode based upon the entire model, rather than for each texture in turn, which would probably be the 'conventional' way of doing things.
The fix described in the first post just rolls back the behaviour to that prior to 1.4.0.5 , which introduced a (probable) bug whereby dynamic and static objects were treated differently.
To fix these seams with the current build:
Add the following code to the end of the texture declaration of any face exhibiting the issue (ParetCab.png, plus the handrail textures I can see)
The short answer is that I'm not sure that implementing a generic fix for this won't break something else, or at least make some stuff look worse
Michelle's code is essentially determining the wrap mode based upon the entire model, rather than for each texture in turn, which would probably be the 'conventional' way of doing things.
The fix described in the first post just rolls back the behaviour to that prior to 1.4.0.5 , which introduced a (probable) bug whereby dynamic and static objects were treated differently.
To fix these seams with the current build:
Add the following code to the end of the texture declaration of any face exhibiting the issue (ParetCab.png, plus the handrail textures I can see)
- Code:
SetWrapMode,Clamp,Clamp
Re: Textures: Altering of the default load behaviour (Test please!)
Thank you, the new command is very useful and I will use it from now on. As you said, it is better to stick to the command rather than breaking compatibility while trying to fix the issue from the program itself.
Marc Riera- Posts : 28
Join date : 2015-12-21
Location : Barcelona, Spain
Similar topics
» Wireframe behaviour
» Abnormal ColorAll behaviour
» AI train - wrong behaviour
» Sound.cfg ATS section configuration for default sounds
» Overlay Textures
» Abnormal ColorAll behaviour
» AI train - wrong behaviour
» Sound.cfg ATS section configuration for default sounds
» Overlay Textures
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum