Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Poll

After experimenting with the options, how is 40d13? Problems only count if the defaults don't work.

Faster than 40d, no problems
- 42 (26.1%)
Faster than 40d, problems
- 72 (44.7%)
No slower than 40d, no problems
- 14 (8.7%)
No slower than 40d, problems
- 16 (9.9%)
Slower than 40d, no problems
- 2 (1.2%)
Slower than 40d, problems
- 3 (1.9%)
Doesn't work (please explain)
- 12 (7.5%)

Total Members Voted: 160


Pages: 1 ... 122 123 [124] 125 126 ... 147

Author Topic: FotF: Help test the output code for the next version of DF (40d13)  (Read 373189 times)

Baughn

  • Noble Phantasm
  • The Haruhiist
  • Hiss
    • View Profile

To zoom users in general:

The middle mouse button does not reset zoom anymore, instead it switches zooming modes. You press f12 to reset it.

I'll get a proper guid up in the first post soon.
Logged
C++ makes baby Cthulhu weep. Why settle for the lesser horror?

Baughn

  • Noble Phantasm
  • The Haruhiist
  • Hiss
    • View Profile

..geez, what happened to the window dialog box? It's all box-y. ;_;
Logged
C++ makes baby Cthulhu weep. Why settle for the lesser horror?

Baboonanza

  • Bay Watcher
    • View Profile

I'm not commenting on the OpenGL aspects, but the new map output function.

The effort is very nice, but the format leaves something to be desired. As far as I can tell it outputs a very large text file over 6 meg in size (for one layer? and that's on a very small map). The file consists of:
Code: [Select]
Tile: Air
Material: White sand
Info: inside, dark, above ground
---
Tile: Air
Material: Red sand
Info: inside, dark, above ground
---
Tile: Air
Material: White sand
Info: inside, dark, above ground
---
Tile: Air
Material: White sand
Info: inside, dark, above ground
---
Tile: Air
Material: White sand
Info: inside, dark, above ground
---
Tile: Air
Material: Pelagic clay
Info: inside, dark, above ground
---
Tile: Air
Material: White sand
Info: inside, dark, above ground
---
Tile: Air
Material: White sand
Info: inside, dark, above ground
Which is impractical for the purposes of parsing into another representation. It would take a long, long time to load this map given all the string lookup and various other processing required.

What is needed is a binary form that contains tile information in a similar format to DFs internal structures. For each tile something like:
[tile_type_enum][material_type][material_index][water_level/type][other_flags]

The external application can then reference the RAWs to find the names/colors of materials.
« Last Edit: July 06, 2009, 09:16:11 am by Baboonanza »
Logged

Baughn

  • Noble Phantasm
  • The Haruhiist
  • Hiss
    • View Profile

Better yet, a format that starts off by describing how the binary should be interpreted, then goes off in binary. So you don't need the raws.

I'd disagree that this version is too slow, though. Yes, 6MB is too much, but a reasonably efficient program could still parse it in quite a lot less than a second. Just don't use python.

Here, I'll show you: *writes a parser. Check back later.*
Logged
C++ makes baby Cthulhu weep. Why settle for the lesser horror?

ilsadir

  • Bay Watcher
    • View Profile

I exported a map into the raw text files, and I agree it isn't parser-friendly.

How do you determine the x-y dimensions of the map?  The files output something like fortressname-blah-blah-N-M-level, but N and M don't appear to be the correct numbers (i.e. I exported from a 6x4 map, so the numbers shouldn't be 274x48 like they are).
Logged

Rose

  • Bay Watcher
  • Resident Elf
    • View Profile

why not something standard like CSV or XML?

those are standardised and there's alredy parsers for them a plenty
Logged

virus_found

  • Bay Watcher
    • View Profile

Still won't compile from 96726cf4ce0fcd
Logged

Baughn

  • Noble Phantasm
  • The Haruhiist
  • Hiss
    • View Profile

It should've. Never mind..

At this point, just use the latest version; it works now.
Logged
C++ makes baby Cthulhu weep. Why settle for the lesser horror?

Baboonanza

  • Bay Watcher
    • View Profile

Well, I've changed my mind somewhat after writing a quick parser. It doesn't include anything that I can't already access directly in DF memory, but this is definitely an improvement over having to find offsets for every version.

Building, items and creature information is included. Multi-tile buildings have an entry for each tile, with a coordinate. As stated above, I can't work out the map dimensions but the last number in the filename is the z-layer I presume.

Output from my parser:
Spoiler (click to show/hide)
Spoiler (click to show/hide)
1.6 seconds makes it slower than reading the data from memory (including buildings/correct stone types) by a factor of 2-5. I would expect the files to get much, much larger for a normal fortress. The test map I ran it against had little in the way of buildings and items. If you've got 10000 stone lying about this is going to be sloooow.

Exporting from DF is really quite slow too, and it needs to be possible to export the whole map in one go, preferably to a directory containing the layers as different files.

A a binary would relieve the speed issues, personally I think it's too slow at the moment.

Edit: The 'Red sandDeer' in the output above is a bug in the DF output code as it's present in the original file. The last output string was 'red sand', so there probably some accidental concatenation going on.
« Last Edit: July 06, 2009, 11:06:08 am by Baboonanza »
Logged

Mephansteras

  • Bay Watcher
  • Forger of Civilizations
    • View Profile

I had voted as 'Doesn't work', but that turned out to just  be a problem with my interface file. So it works, and I'll give you a better review once I've had a chance to play with it a bit.
Logged
Civilization Forge Mod v2.80: Adding in new races, equipment, animals, plants, metals, etc. Now with Alchemy and Libraries! Variety to spice up DF! (For DF 0.34.10)
Come play Mafia with us!
"Let us maintain our chill composure." - Toady One

Baughn

  • Noble Phantasm
  • The Haruhiist
  • Hiss
    • View Profile

Well, I had fun writing a map-dump compressor - code at http://hpaste.org/fastcgi/hpaste.fcgi/view?id=6583#a6583, or in the DF/libgraphics git repository.

It parses the entire file in three seconds on my system. Not great, but good enough for unoptimized, high-level code. The file it spits out is a tenth of the size for a simple map, but would probably get bigger rather fast - its only semblance of compression is that it uses 1, 2 or 4 bytes per tile element based on how many different elements there are.

And basically because I could, I made it multithreaded. One thread per file, but you can pass it as many files as you like.
Logged
C++ makes baby Cthulhu weep. Why settle for the lesser horror?

Mephansteras

  • Bay Watcher
  • Forger of Civilizations
    • View Profile

How would I get this thing to actually get me a full-screen view on my laptop? I can only get about half the screen to actually be used, and it's way to small for my tastes.
Logged
Civilization Forge Mod v2.80: Adding in new races, equipment, animals, plants, metals, etc. Now with Alchemy and Libraries! Variety to spice up DF! (For DF 0.34.10)
Come play Mafia with us!
"Let us maintain our chill composure." - Toady One

drawf_irons

  • Bay Watcher
    • View Profile

A bizarre bug: In adventure mode, I am completely unable to visit map tiles using > on 40d13. A quick check using identical saves on 40d11 or 40d reveals no such problem.
Logged

Eidalac

  • Bay Watcher
  • Ecchi Inside
    • View Profile
    • Facebook

Loads a hair faster than d11, and seems to run just a -bit- faster, but that's with 150 dorfs and 200+ animals, rivers, moats, lava ect.  FPS reads the same as in d11 (16ish in my worst areas), but it _feels_ smoother.

We'll see what it can do when I get my mist generator online. :)

Now I have to get my mouse working so I can play with the zoom-y-ness.

No real time to test anything, but I did also notice the text in some of the sub menus (designations, building, ect) is... not right, as in AbuDhabi's screen shot.


Man, you guys make me sad I don't have time to do any coding these days. :(

Keep up the good work all.
Logged
is he okay?
In the traditional sense of the word?  No, he's been dissolved in magma.

Corona688

  • Bay Watcher
    • View Profile

What do translucent tilesets in a one-tile-per-square system actually do?  Or is that supposed to mean graphic sets?
Logged
You never know when you might need a berserk dwarf to set loose somewhere.
Pages: 1 ... 122 123 [124] 125 126 ... 147