TrDiff

The intricacies, or simplicities of 3D modelling are worth understanding. Alongside other forums like Building Rolling Stock, Scenic Item Creation and the other tool specific forums here's another place to ask questions that just don't quite fit the other forums.

Moderator: Moderators

User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

TrDiff

Post by RiscaStation »

Hi all,

I have spent this morning trying to get RailWorks to accept the "TrDiff" shader on a simple box but it wont.
I have checked my entries to ensure they are all correctly typed and still cant get the shader into the game.
I have no problems using "TexDiff" on the same simple box.

Kind regards
Mike
User avatar
malkymackay
Very Active Forum Member
Posts: 2194
Joined: Mon Jan 18, 2010 8:01 pm
Location: Kilsyth, Scotland

Re: TrDiff

Post by malkymackay »

Have you got the Modfile text in the folder of your cube, so that BigEx knows to translate it to the full shader name? TexDiff will work as it doesn't need translating.
Expanding the TS wagon fleet.
User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

Re: TrDiff

Post by RiscaStation »

Hi,

I followed "Andis" Box tutorial and the shader is not being accepted.

Kind regards
Mike
User avatar
malkymackay
Very Active Forum Member
Posts: 2194
Joined: Mon Jan 18, 2010 8:01 pm
Location: Kilsyth, Scotland

Re: TrDiff

Post by malkymackay »

Hmm, that's a bit strange. I managed to export a WIP wagon today, using TrDiff, without any issues.
Expanding the TS wagon fleet.
User avatar
gavo01
Well Established Forum Member
Posts: 824
Joined: Thu Jun 25, 2009 9:55 pm

Re: TrDiff

Post by gavo01 »

RiscaStation wrote: I followed "Andis" Box tutorial and the shader is not being accepted.
Mike, I assume that the problem occurs in the blueprint editor?

If so, would you mind showing us a screenshot of the error message that you're getting.
User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

Re: TrDiff

Post by RiscaStation »

Hi Gav,

I would like to but I don't have a premium account.
Still on the subject of Boxes, I have tried "Zug Guy" tutorial "Through a glass, not so darkly" but I am unable to Export because Bigex does not have the ability to handle Alpha channels without adding extra lines of text.
Zug Guy has said in his tutorial that lines of extra text need to be added to enable "Trans" to be recognised.
I dont have any programing experience so I have no idea how to go about it.
If some one would be kind enough to explain how to go about it I would be very grateful.

Kind regards
Mike
User avatar
gavo01
Well Established Forum Member
Posts: 824
Joined: Thu Jun 25, 2009 9:55 pm

Re: TrDiff

Post by gavo01 »

RiscaStation wrote:I would like to but I don't have a premium account.
You dont need one to post pictures. Just take a screenshot, resize to anything up to 800x600, but no bigger, then upload it using the Upload Attachment option which is situated just underneath the save/preview/submit buttons on the reply page.
attachment.jpg
RiscaStation wrote:Extra text need to be added to enable "Trans" to be recognised. If some one would be kind enough to explain how to go about it I would be very grateful.
The lines I think that ZugGuy talks about are these Mike.

[Materials:ZBufferMode]
[glass.*ZTO.*]=3
[Materials:AlphaTestMode]
[glass.*TRA.*]=1
User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

Re: TrDiff

Post by RiscaStation »

Hi Gav,

Thank you for picture information I thought I had to have an account.
TrDiff.jpg
TrDiff.jpg (11.66 KiB) Viewed 6997 times
I replaced "TrDiff" with "TexDiff" and re-exported with no problem getting my box into RailWorks.

Any idea how I get the 2 "Zug" lines into Blender please?

Kind regards
Mike
User avatar
gavo01
Well Established Forum Member
Posts: 824
Joined: Thu Jun 25, 2009 9:55 pm

Re: TrDiff

Post by gavo01 »

RiscaStation wrote:Any idea how I get the 2 "Zug" lines into Blender please?
Mike, those two lines just need to be copy+pasted into your IGS_ExpModFile.

The TrDiff error message has me stumped. I take it this line, TrDiff=TrainBasicObjectDiffuse.fx is in your IGS_ExpModFile?
User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

Re: TrDiff

Post by RiscaStation »

Hi Gav,


I only have 2 files showing when I select Export and they are;--

RailSim ( .ia )
RailSim ( .igs )

Where will I find "IGS_ExpModFile" please?

I have been reading the Manual on Bigex and have noticed a screen capture showing a file in the scripts named;--

RailSim ( igs ) export preparation..

and I cant find anything in the Manual to explain what it is about, its another file I dont have.


I am grateful to you for your assistance.
Kind regards
Mike
User avatar
malkymackay
Very Active Forum Member
Posts: 2194
Joined: Mon Jan 18, 2010 8:01 pm
Location: Kilsyth, Scotland

Re: TrDiff

Post by malkymackay »

Page 10 of the Bigex Manual tells you where you will find the IGS_ExpModFile text. It holds the information used to overcome the name length limitation of Blender, with regards to some of the longer shader names used in Railworks. TrDiff is just the shorthand version of TrainBasicObjectDiffuse.fx

You should only need to concern yourself with RailSim ( .ia ) & RailSim ( .igs ) as the export options. I suspect anything else in any screenshots in the manual would be to do with Henning's work in creating Bigex
Expanding the TS wagon fleet.
User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

Re: TrDiff

Post by RiscaStation »

Hi,

In the subfolder "Bigex_ExampleObjects" there are 4 files according to the Bigex manual and yet there are only 2 that I can find namely "IG_ExpModFile.txt" and "IA_ExpModFile.txt".
The 2 files I cant find are "IG_specific_IGExpModFile.txt" and "IA_specific_IAExpModFile.txt".
I have opened the file IG_ExpModFile.txt and it displays in notepad form, just one block of text, what should I do with this file or where should I put it?

I only wanted to be able to complete the Tutorial "Through a glass, not so darkly" by Zug Guy but this is proving to be very difficult indeed to achieve in Blender.
Lost as to what to do now.

Kind regards
Mike
User avatar
gavo01
Well Established Forum Member
Posts: 824
Joined: Thu Jun 25, 2009 9:55 pm

Re: TrDiff

Post by gavo01 »

Mike, the IGSModFile should be copied and pasted into the same folder as your. Blend files.

Then just copy+paste those two lines I put in a previous reply and that is all there is to it for zugguys tutorial to work. :)

Feel free to return with any other problems. We're here to help. :D
User avatar
RiscaStation
Very Active Forum Member
Posts: 1466
Joined: Fri Feb 24, 2006 7:52 pm
Location: Newport, South wales

Re: TrDiff

Post by RiscaStation »

Hi Gav,

This is the only IGS_ExpModFile I have;--

# File: IGS_Export_ModFile.txt
# Default Export Data Modification (EDM) file for Blender IA/IGS exporter Bigex
#
# This default modify file is a good place to specify all global / general replacement instructions.
# This may be Shader names, Texture file specs, etc
# For the replacement expressions regarding a specific 3D model / igs file, you should use the
# modify file: "<Your_igs_export_file_name>_ModFile.txt"
#
# All replacement instructions found in both files will be applied on the export data which will
# be written into the igs/is file.
#
# Search ranges:
# Search ranges are specified in square brackets. The opening bracket must be the first charachter
# at the beginning of a new line.
# e.g. [ObjectList:EntryName]
# where ObjectList is the list which EntryName entries are searched through.
# All replacement instructions after this replacement specifier until end of file or until the
# next replacement specifier, are related to the object list and entry specified.
#
# Replacement instructions:
# - the whole string from beginn of a line until the = will be used as search string
# - the whole string from = until end of a line = will be used as replacement string
# Only exceptions are:
# - string with length of 0 (zero) will match everything. So be carefull.
# - numbers or ranges in square brackets e.g. [99], [10-19], [n], [n-m] will be applied only
# on the n-th, resp. n-th to m-th entry in the specified object list. (see examples below)
#
# Comments:
# Each line staring with a # contains comments and will be ignored at execution time.
#
# Examples:
#
# Example 1:
# ...
# [Materials:ShaderName]
# SName1=SName2
# ...
# replaces the shader name for all materials with the current shader name 'SName1' to 'SName2'
#
# Example 2:
# ...
# [Materials:ShaderName]
# [99]SName1=SName2
# ...
# sets the shader name of material number 99 to 'SName2' if the shader name is 'SName1'
#
# Example 3:
# ...
# [Materials:ShaderName]
# [99]=SName2
# ...
# sets the shader name of material number 99 to 'SName2' regardless what it is currently.
#
# Section header for shader name name replacement
# [Materials:ShaderName]
# Shader Names (non-fx shader)
# Note: Replacemet not activated ( commented out with #) due to Blender can hold the full name
#
# Tex=Tex
# TexDiff=TexDiff
# BlendATexDiff=BlendATexDiff
# AddTex=AddTex
# AddATex=AddATex

# N O T E : The following expressions are activated (not commented out with #)!
#
# Section header for shader name name replacement
[Materials:ShaderName]
# Shader Names (fx shader)
#
Shadow=StencilShadow.fx
TrDiff=TrainBasicObjectDiffuse.fx
TrGlass=TrainGlass.fx
TrSpec=TrainBasicObjectSpecular.fx
TrSpecEM=TrainSpecEnvMask.fx
TrBumpSpec=TrainBumpSpec.fx
TrBumpSpecEM=TrainBumpSpecEnvMask.fx
TrLightMap=TrainLightMapWithDiffuse.fx
TrEnv=TrainEnv.fx
TrFlora=TrainFlora.fx
TrVFaceFlora=TrainViewFacingFlora.fx
TrUpVFaceFlora=TrainUprightViewFacingFlora.fx
LoftTexDiff=LoftTexDiff.fx
LoftTexDiffTr=LoftTexDiffTrans.fx
Skin=SkinDiffuse.fx
Water=WaterCubeMap.fx
WaterScenery=WaterScenery.fx
Sky=TrainSkyDome.fx

What do I do now please?
Kind regards
Mike
User avatar
gavo01
Well Established Forum Member
Posts: 824
Joined: Thu Jun 25, 2009 9:55 pm

Re: TrDiff

Post by gavo01 »

RiscaStation wrote:What do I do now please?
Just copy+paste the lines below into your IGS_ExpModFile. :)
[Materials:ZBufferMode]
[glass.*ZTO.*]=3
[Materials:AlphaTestMode]
[glass.*TRA.*]=1
I also have this line in there too.

[Materials:AlphaTestMode]
[glow]=1

Not sure whats its function is but its there anyway.
Locked

Return to “[RW] 3D Modelling”