Posts by lenidcamper

    Is anyone using network position events in the latest release (production or beta. I have tried both)?

    Last year I wrote an app that captured position events and wrote them out to a KML file for display in Google Earth. It was working back in June.

    When I try the same app now with the latest release it detects no events.

    The Wireshark Network Analyzer detects no activity on port 49002

    I am using the the same config (I think :/) in main.mcf that I used last year







    Local network is 192.168.0.XXX



    sorry I did not scroll down in the include.

    Based on the log, the string compare (without leading zero) should have exported 2 different models.

    But it is actually exporting <[string8][geometry][..\objects\Piers\Pier_Wood_1_6\pier_wood_1_6]> ???

    I don't see where that could possibly come from based on the included config.

    "1_6" does not appear anywhere in the config!!!

    As I mentioned in the postscript to a previous post, the expression engine did not internally resolve data types of

    variables and all variables defaulted to string. So it was doing a string compare for all numeric variables in expressions.

    I am testing a fix that loads int or float variables as required.

    In the pier example what is the expression in the model map?

    Hi Thomas

    A number of issues here

    At first I thought

    "Of course, you are not using the operator alias #GE# for >="

    The expression engine provides the alias/escape strings for operators to avoid special characters in XML. However >= will actually evaluate correctly.

    "<=" will give a syntax error. for consistency it is probably better to always use the alias strings

    The (...) construct is intended to define precedence in the expression. The ($pier:width) defeats my variable preload algorithm.

    I am parsing the expression into tokens on spaces to pick out variable names to preload before tag data is loaded. This avoids a "variable not defined" exception from the expression engine and allows the sparse tag negation functionality added in 0.7.1

    Use $pier:width #GE# '10' or ($pier:width #GE# '10')

    That lead me to the core problem. It appears there is a bug in the XSharper engine with comparison of left justified numeric values.

    ($height #LE# '90') will evaluate true for height tag value '100'


    ($height #LE# ' 90') will evaluate to false

    I need to look under the hood of the XSharper engine to see if there is any way to fix this or find a workaround.



    what tag data are you comparing?

    zero padding will work.

    '090' will evaluate correctly compared with '100'

    where '90' will not.

    If you have added these tags using leading zero pad


    turns out XSharper variables were defaulting to string type.

    need to detect tag datatype and force a cast to int or float as the variable is set.

    I have a request for parking density:


    I have looked at the parking density issue. Adding a computed parameter is possible but is a can of worms I would rather not open right now.

    Particularly since there is a work around for this issue.

    All it requires is separate configurations for the few (3? 5??) different parking densities.

    Each configuration would have a selectionCondition expression with the appropriate parking_density value and randomInteger upperLimit.

    Using sharedModelMaps there will only be a dozen lines for each configuration.

    If there is a scenario that cannot be solved without numeric tag operations I can look at the issue again.


    could it already work?

    There is currently no way to specify arithmetic operations on tags. The XSharper expression engine has that capability. I only exposed what was needed for boolean selection expressions.

    I need to think about a generic way to expose this.

    Under Windows \ or / might both work

    I had not placed any attention towards platform independence. I can update examples and documentation to forward slash and lower case.

    It is possible with the current release of ObectGen to place a building object at the "midpoint" of a building footprint.

    As with the scenProc FLENGTH the wayLength derived tag could be used to distinguish residential vs commercial.

    The random tag could be used to mix model types.

    Currently the objects would have random orientation.

    It is difficult to derive a meaningful orientation for an arbitrary polygon. If the way has 5 nodes it is a square or rectangle and an axis of orientation could be derived. But few houses are simple rectangles (particularly in NA housing developments).

    Uploaded version v0.7 of ObjectGen

    The main feature is XREF library support.

    There are some schema changes to support this.

    There is a standalone xmlConvert utility to migrate locally modified configuration files to the current schema.

    See the readme and User Guide

    I have seen examples of TSC files with enumerated [elements] and with [0]

    I assumed the scenery loader needs to merge [element] entries from multiple TSC files into an internal list anyway so enumeration does not seem

    to be particularly relevant. Since it works without enumeration I did not bother to add it.

    As for the [autoheight_override] I am unclear on the interpretation. I forget where I copied the original snippet for the template but it did have [-1]

    Models I have placed at zero elevation in Sketchup seem to render at grade level with it set to [-1] (or [10] ) so I left it at [-1]

    For an object model with larger area, if there is a slight slope in the elevation data one edge may be floating or depressed.

    I had to extend the pylon piers well below grade to avoid floating pylon legs on steeper grades

    If [autoheight_override] is set to [0] only XREF objects will render (no user defined objects).

    As with the element index the autoheight_override did not seem broken so I did not fix it.

    Changing the default values is easy if there is a "correct" answer.

    Adding an optional model configuration element is more work so I would need to see good justification for the change.

    The models I have converted worked fine with a zero elevation in Sketchup and autoheight_override of -1


    can you introduce an empty parking lot factor?

    You don't need dummy map entries.

    If you set the default model name to empty string and set the upperLimit on the random tag to be appropriately larger than the number of (real) entries in the model map, when there is no match in the model map the empty default model is exported.

    In v0.7 the [tmsimulator_scenery_object][element] will no longer be exported if the model name is blank (to avoid the "..\..\..\..\objects\.tmb' not found"messages in the TM.log)

    I had assumed that the default model was fail safe and would always exist , but that is no longer the case.

    Maybe when Jeff is farther along with vehicle animation

    the preview of Aerofly Life is very interesting.

    It may make ObjectGen traffic redundant.
    No indication yet of how the traffic is defined or how easy that will be for large areas.

    The same issues of multiple lanes and intersections need to be addressed.

    any creative solution for the car traffic at intersections?

    Variable density at intersections is pretty far down the list.

    There are more significant issues to deal with for crossing ways.

    Even in the motorway scenario there is the problem that there is no easy way to detect that the crossing way is actually an overpass (flyover) and no vehicles should be placed at the crossover unless it is a rail underpass then it is ok. A crossing line algorithm would be pretty slow for a node set in the thousands.

    At street intersections there is the problem of 2 lanes becoming 4 lanes without any change in the OSM way.

    Or a 4 way stop intersection with multiple turning lanes tagged (and drawn) as a roundabout.

    That is on top of the general way misalignment to highway center line issue.

    There are limits to the realism of vehicle cultivation without extreme efforts on the processing side and a lot of tweaking of the OSM data

    no one is always parking strictly to the front line

    The spacing can be randomized slightly.

    The offset could be a min max. Even for highway traffic the vehicles don't always stay centered in the lanes.

    Then of course we need a orientationMode of Random to give a mix of nose-in / node-out.

    Although in NA 95% of people park nose-in unless they can pull through.

    Or convert from orientationMode enum to orientationSense value

    100 => 100% Forward

    50 => 50/50 mix

    0 => 0% Forward ( ie 100% Reverse)