TIFFs files for CFS3 landclasses
Page 1 of 3 123 LastLast
Results 1 to 25 of 56

Thread: TIFFs files for CFS3 landclasses

  1. #1

    Icon9 TIFFs files for CFS3 landclasses

    Hello all!
    I´m trying to generate a cfs3 landclass file using Martin´s (mwgfx.co.uk) cfs3 scenery tutorial.
    I´m using a Photosho cs6 to generate de 32bit Tiff file, but during the TIFF2LCF conversion, i received this message (attached).
    The Tiff file generated was checked if containing only the colours defined on c2v.txt...

    Please help...
    Attached Thumbnails Attached Thumbnails tiff2lcf _error.JPG  

  2. #2
    Firstly, somebody is working on landclasses? Hooray! This is something I've wanted to try for a long time, but the tool won't work at all for me. I can try to look over things when I get home from work and see if I can see what the issue might be. What are your plans for working on the landclasses?

  3. #3

    Icon27 Main Objective on Landclasses

    Dear gecko,

    After studied CFS3 terrain SDK a lot, some questions fired in my mind:
    - Why CFS3 sdk terrain tools are more complex than CFS2 and the results are so bad?
    - The terrain resolution can be improved if you have a good shoreline generated with the same terrain resolution. Landclasses tools can supports higher resolutions (Strider 90m and 32m per pixel)?
    - For my landclasses studies, i need to generate a test tiff file with lower parameters: Lower TIFF 32bits image size (1000x1000), higher stride (1024), same landclasses.xml used on cfs3 original... WHY I CANNOT GENERATED the LCF file???? What´s wrong???

    Well, I believe that the landclass system is the saint graal of cfs3 detailed scenery. Of course, if I get hability to work with landclasses tools, I´ll write a detailed lanclass tutorial for all SOH team .

    Best Regards,
    (Sorry my bad English)

  4. #4
    Bob would be the best person to ask but he has retired from cfs3 design . Maybe you could a send private message ? his username is rbp71854 .
    If you don't have any luck , I can try to email him for you.

    He does seem to pop in here from time to time

  5. #5
    In the meantime, check the options in Photoshop for saving in TIFF. You may have one or more options set by default which the TIFF2LCF tool can't handle: there are a few:–





    These are not the recommended options shown, it's just an illustration of how many options there are!
    Tom
    __________________________________________________ ___________________________________________
    Wisdom is the principal thing; therefore get wisdom: and with all thy getting get understanding. Proverbs 4:7



  6. #6
    re-member,remem-ma-member popsaka's Avatar
    Join Date
    Dec 2006
    Location
    downtown L.A.,Ca., usa,'ey?
    Age
    74
    Posts
    1,345

    Icon5

    Will these explorations also address land altitude???

  7. #7

    Photoshop version issue for TIFFs

    Dear all, Thanks a lot by your support...

    Hairyspin, whats is your photoshop version?

    My CS6 Do not have RLE compression option for TIFF export, only ZIP. Maybe its a big issue (image attached)

    But, if RLE compression is needed for layers compression, It means that each landclass color must be in a separeted layer?

    Popsaka,
    About the terrain mesh, It is possible to use SRTM3 files ~ 90m per pixel. CFS3 uses SRTM30 ~ 1024m per pixel.
    But SRTM3 files with original cfs3 shorelines causes many spikes at shorelines regions. A new shoreline must be generated with the same SRTM3 resolution. I find a way to make this. But I´m not tested yet. I Need the landclass LCF first...

    sdsbolt,
    Thanks by the info about rbp71854. If I do not get success until friday, i´ll try to contact him.
    Attached Thumbnails Attached Thumbnails Photoshop_CS6_TIFF_Options.JPG  

  8. #8
    Hmm. I'd save in IBM PC byte order for starters, uncompressed and flattened to a single layer. I'm not at my own PC this week so can't check exact details and I use Photoshop CS4 anyway, but don't think CS6 can be much different for TIFF saves.
    Tom
    __________________________________________________ ___________________________________________
    Wisdom is the principal thing; therefore get wisdom: and with all thy getting get understanding. Proverbs 4:7



  9. #9

    Tiff configurations already confirmed for LCF tool

    Dear all,
    An image attached shows a photoshop export configurations that TIFF2LCF tool loads with a pixel type error. The options in red, only one of them, will generate a Tiff file rejected by the TIFF2LCF tool.

    The CFS3 sdk was made on 2003 year. The Photoshop version on 2003 was CS2. The first version with 32 bits mode capacity. Tiff 32bits Files generated by CS2 are every flattened (no multilayers). Then, like hairyspin said:uncompressed and flattened to a single layer.

    More info for Tiff generation...

    One more: I think that a TIFF 32bit RGB file generated until now doesn´t work because the file need an ALPHA CHANNEL. But i need to learn to work with alpha channel in Photoshop, and save the file in a RGBA format (maybe its a 4 samples per pixel requested by an error message).

    Best Regards.
    Attached Thumbnails Attached Thumbnails Tiff Export.JPG  

  10. #10
    I think you need to enable alpha in TIFFs via the Photoshop preferences first, but I can't check myself yet...
    Tom
    __________________________________________________ ___________________________________________
    Wisdom is the principal thing; therefore get wisdom: and with all thy getting get understanding. Proverbs 4:7



  11. #11
    SOH-CM-2020
    Join Date
    Jun 2005
    Location
    Aotearoa, New Zealand
    Age
    63
    Posts
    2,896

    Martin Wright's Commentary on making landclass files

    I've just dug up some extracts from a document I found on Martin Wright's website. I hope this stuff helps.....

    MartinW on CFS3 Terrain SDK

    CFS3 Terrain SDK
    We are currently slowly working through the public beta of the CFS3 Terrain sdk. My plan is to collect together bits and pieces as we work through it slowly. Hopefully the end result will be new Theatres available for CFS3.
    Where there are links below to view text of image files you can either left-click to view them in your browser or right-click and select "Save Target as.." to download them to your computer
    Step 1 - Creating Mesh files
    Step 2 - Creating the Landclass file
    Step 3 - Putting the bare theatre into CFS3

    Now, skipping through to his Step 2......

    Second step.......Creating Landclass
    Landclass (LCF) files are required for theatres to tell CFS3 what type of terrain texture to use at a particular location.
    There are 15 landclass types defined in CFS3. You can add your own or create a whole new set for your theatre but as each landclass type requires a full set of multiple seasonal mosaics it would be easiest to stick with the default ones for the moment. If you want to mainly use the default landclasses but add an additional one or two then you should make a copy of Landclasses.xml (found in terrdata.zip in the Terrains folder) rename it to something else and then open and edit it to add additional landclasses using free numbers.
    Landclass numbers found in the default landclasses.xml file
    1 Ice/snow
    6 Grass
    8 Crop and Town
    10 Grass, Crop and Scrub
    15 Crops
    17 Marsh
    24 Forest
    25 Forest and Fields
    26 Coniferous Forest
    27 Mixed Forest
    31 Large City
    34 Medium City
    47 Small City
    51 Dry wooded scrub
    56 Rock

    Landclass files are created using the TIFF2LCF tool. The Tiff image used is an image of the theatre with each pixel representing a certain area and the colour of that pixel is used to define the landclass to use at that location in the Theatre.
    In order to be able to translate a colour to a specific landclass value the tool requires a translation table. This takes the form of a text file where each line contains 4 numbers seperated by commas. The first number is the landclass value. The other 3 are the RGB values that make up the colour.
    You can make up your own translation file or you can use the one I have created for my own use. My file is c2v.txt .Using my selection of landclass colours and applying them to the default theatre landclass file we see :-

    [sorry you can't see - my document does not have the image]

    I feel that these colours give a fairly good representation. You can of course use any colours you like.
    In order to create an LCF file for your theatre you will need to create an image of your theatre similar to the map section above and colour in the various parts with the landclasses you wish to appear there.
    There is a technical problem as TIFF2LCF is very fussy about the type of Tiff file you use. It must be a 32 bit Tiff containing ONLY the colours you have defined in your translation file. A further complication is that the only paint program I have found that will create Tiff images that work with this tool is PhotoShop. Tiff files created by PaintShopPro are rejected by the tool. There may be other paint programs that can create the correct sort of Tiff but the only one I can definitely confirm is PhotoShop.
    TIFF2LCF parameters in order
    InTIFF The Tiff image file to use. Must be 32 bit
    Color2Vulcan The text file containing the translation table linking specific RGB values to a landclass number. See c2v.txt
    TheatreDim The width of the theatre in metres
    Stride The width in metres of each single landclass tile. SDK says this must be a power of 2.
    LandclassesXML The name (without path) of the XML file to be used at runtime to find the details of each landclass type. Unless you are going to create your own just use Landclasses.xml
    OutLCF The name of the LCF file to create.

    eg - TIFF2LCF "myterrain.tif" "c2v.txt" 786650 1024 Landclasses.xml "myterrain.lcf"
    This will create the Landclass file MyTerrain.lcf from the supplied parameters.
    Note that the TheatreDim divided by the Stride must exactly equal the width of your Tiff image! You may have to resize your tiff after doing the relevant calculations.
    TIFF2LCF will stop with an error if it calculates that the Tiff image size is not correct for the TheatreDim and Stride settings. It will also stop with an error if it finds a colour in the image that doesn`t appear in your translation table.

    Anyway Odin_br I am very excited that someone is looking at this stuff. I've also got a lot of guides on terrain creation which I've nver had time to digest properly - but happy to share if you PM me.

  12. #12
    SOH-CM-2020
    Join Date
    Jun 2005
    Location
    Aotearoa, New Zealand
    Age
    63
    Posts
    2,896
    Ooops my bad, I should have read your first post!!

  13. #13
    re-member,remem-ma-member popsaka's Avatar
    Join Date
    Dec 2006
    Location
    downtown L.A.,Ca., usa,'ey?
    Age
    74
    Posts
    1,345
    This stuff is brain drain to the limit... I dunno why I can't wrap my head around it
    I'm beside meself with awe and respect
    Cripes Martin must've put a lot of time a'thunkin'...
    ...and the possibilities are really wonderful! Imagine flying low through Northern Italy's
    mountains and gulleys with nothing to JAR you out of your immersion!

  14. #14

    Icon28 We are real close...

    Dear all,

    Thanks a lot by your efforts...
    I believe that Hairyspin will bring good news next week...

    Also, more News:
    I´ve received a Martin Wright's contact. He only remember that TIFFs must be a RGBA (with alpha channel). And, recommended to contact MAW team for infos.

    (Sorry my bad english)
    Best Regards!

  15. #15

    Adding an Alpha channel in Photoshop

    Really easy this, here we go!






    The new channel will be an alpha channel by default, all the other channels will be immediately hidden:–





    (if you click on the visibility box for RGB, the others will all be shown)






    The bitmap is now ready to save as a TIFF, but remember to include the Alpha channel with it:–







    We've already covered the other options.
    Tom
    __________________________________________________ ___________________________________________
    Wisdom is the principal thing; therefore get wisdom: and with all thy getting get understanding. Proverbs 4:7



  16. #16
    You don't see the finished image in Photoshop as it will be seen by other programs.

    Here I've put a diagonal graduated monochrome band in the alpha channel and with all channels visible the reddish band is all you see to indicate anything unusual:–







    However view the saved TIFF in Windows Photo Viewer and you get this:–






    That's how we do transparency and degrees of it in texture files for conversion to .DDS (DXT3)
    Tom
    __________________________________________________ ___________________________________________
    Wisdom is the principal thing; therefore get wisdom: and with all thy getting get understanding. Proverbs 4:7



  17. #17
    SOH-CM-2020
    Join Date
    Jun 2005
    Location
    Aotearoa, New Zealand
    Age
    63
    Posts
    2,896
    Yahoo this looks really good, thanks, Hairyspin! I really hope this stuff can be recorded permanently, as valuable terrain building info from the Pacific theatres might not be around any more....(which would be a crying shame but I cannot criticise people who have burnt themselves out to provide us with a new sandbox to play in......)


  18. #18
    re-member,remem-ma-member popsaka's Avatar
    Join Date
    Dec 2006
    Location
    downtown L.A.,Ca., usa,'ey?
    Age
    74
    Posts
    1,345
    That was really cool...

  19. #19

    Not yet...

    Dear all,

    I get no conversion with TIFF 32bits RGBA (With alpha channel). Please, can anyone contact RS or MAW developers to check what are the tiffs requirements to TIFF2LCF tool?

    Also, I attached my stydies files: A 1000x1000 8bit RGBA file (8bits for small file size) with all landclass colors described by Martin´s c2v.txt.
    You must to convert to 32bit mode in PHOTOSHOP before saving - Menu Image - Mode 16bits/channel
    again- Menu Image - Mode 32bits/channel
    save with alpha channel enable.
    A c2v.txt
    A text file with TIFF2LCF command to you to copy and paste on command line window (Comando_LC.txt).
    All those files must be in a dir with SDK tools and required DLLs.
    Please, try to convert. If you get a sucess, please post ASAP!!
    Best regards!
    Attached Files Attached Files

  20. #20
    Are the dimensions of your tiff file correct for the theater size?

  21. #21

    About the TiFF file.

    Dear Gecko,

    I´m using this file for study only. I want to generate a LCF file before the true TIFF file for my theatre.
    The main reason for this small 1000 x 1000 file is for the TIFF2LCF tool can manage it easily. I want to find if this tool have a limit. For example: This tool can convert a 1GB of a TIFF file (For a GIANT theater)?

    But no success until now.. I'm afraid that this knowledge has been forgotten and lost...
    I´m still trying.

    Maybe It´s a resolution issue (I`m using 72 pixels/inch).

    Best Regards.

  22. #22
    SOH-CM-2024 Pat Pattle's Avatar
    Join Date
    Jun 2005
    Location
    Newton Abbot, Devon. Dear old Blighty
    Age
    60
    Posts
    2,904
    Blog Entries
    1
    Very interesting thread Odin, I really hope you can get this cracked.

    I have nothing technical to add, the guys that had this knowledge have either sadly passed away or moved on from the hobby.

    There was one chap called Rob (Biff) whom I'm assuming is no longer around but left a blog, might be some useful tit bits:

    http://scene-explore.blogspot.co.uk/

    Good luck!
    CFS3 Battle of Britain Website: https://cfs3bob.wixsite.com/cfs3-bob
    CFS3 ACC Member & ETO Expansion Group

  23. #23
    Well I emailed a link to this page to Bob from RS. Not sure if it's current email address though.

  24. #24
    isnt there a need to keep the common game engine texture resolution rule, which in this case would be 1024x1024 image?

  25. #25

    Icon22 Success!!!!!!!!!

    Dear all

    SUCCESSFUL CONVERSION!!!!!!!
    The TIFF status for LCF conversion revealed!!


    I´m so Happy!!!
    I´m was following a totally wrong path. Now I discovered the PANDORA BOX of new CFS3 theatre!!!!

    TUTORIAL IS COMING!!!!!

    BEST REGARDS

Members who have read this thread: 8

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •