Problems can happen when converting an LDD file: Use the menu entry File | Import… | Import Model…,.From the file browser, select a file to import.From the Welcome screen, click Import (C),.To import an LDD file as a submodel in the current model: Browse and select a file on your computer.From the Welcome screen, click Open (B),.To open an LDD file in a new project, click on File | Open, use the keyboard shortcut Ctrl O or: Opening a file will make it a new project. Importing a file will add it as a submodel in the current project. Daniela Rodríguez Careri on FMOD 2.Studio can read and write LEGO Digital Designer (LDD) files.lxf or.Photometric Lighting – What is it and why do we need it?.
Since it would be “one queue, one call” there’d be no races – you’d queue as many times as you need. A more useful API would be “queue callback on main thread once”, callable from a thread, so that worker threads can queue _something_ in plugin land on demand. Given the above data race you describe, I think such an API (wake up the worker from a thread) would be pretty useless in a lot of situations due to “lost wake-ups” – there might be work-arounds but they’d be messy to do.
We never shipped that code – we realized after the fact that a bunch of internals of the SDK weren’t ready, so we backed away from it – you might find spurious older docs claiming thread safety to be available for a small number of calls. We aren’t going to call your callback that often – register a single one for the entire callback and you’re good to go.Ī follow-up: we did at one point intend to make already-created flight-loop scheduling asynchronous, specifically to allow worker threads to ‘wake up’ something inside the sim, and you are correct that there’d be a data race between the thread putting itself to sleep and async code waking it back up again. make sure that your check-and-dequeue is fast when the FIFO is empty. The way to solve this is to always run your flight loop callback and ensure that the under-run case is as cheap as possible, e.g. If you are trying to build a message queue to move work from a worker thread to the sim, you aren’t allowed to schedule the flight loop callback from the worker thread at all! And since you are ONLY allowed to schedule/deschedule the flight loop CB from a single thread, there cannot be race conditions because there can’t be concurrent operation. With that in mind, I think your example from the org post is moot. I am aware of some plugins openly violating this, and in the future we may intentionally kill the app immediately when this happens, rather than have plugins introduce race conditions and re-entrancy that show up as really really mysterious crashes later that we can’t understand.
Re: threading: the plugin SDK is absolutely not thread safe and it is illegal to call any XPLM routine from a thread OTHER than the thread we called you from, full stop. Please file bug reports for the above 3 VR bugs. This leads to strange errors when trying to draw in VR windows.Ĥ) Non-VR, please see here in the second post: ///index.php?/forums/topic/145871-question-about-thread-safety-of-xplmscheduleflightloop/ However, if you ask for the window’s geometry, it will report the restricted coordinates as if it were never resized by the user.
The further away from the center, the bigger the error.ģ) If you set a resize policy on a VR window, it has no visual effect: The user can resize the window. Also, this leads to an invalid affine transformation when trying to convert mouse coordinates from boxels to pixels.
This doesn’t happen for non-VR windows with decoration. This is due to the border decoration being subtracted from the geometry. The other messages get correct coordinates.Ģ) If you create a new window using the new API in VR, the actual window size as reported by GetGeometry is smaller than what you requested. Three are related to VR, the other is not:ġ) If you create a window using the new API, the mouse handler will get passed the coordinates of the real mouse instead of the VR pointer in the DRAG message. During my development of a VR plugin, I believe to have found four bugs in the API.