I was inspired by @STREGAsGate's interest in building a game on Windows with DirectX and Swift. DirectX is a large framework and provides multiple sub-frameworks including Direct 3D and Direct 2D for accelerated graphics as well as things such as Direct Input and Direct Audio for audio and input handling.
In order to demonstrate that using this functionality is both possible and how far Swift on Windows has actually come, I decided to write one of the time honoured traditional demos for 3D graphics with Swift (and HLSL) to show how to use Direct 3D on Windows with Swift - an orthographic projection of a cube.
Note that this proof of concept implementation does not always follow best practices (e.g. does not use v-sync) but it does show the viability of implementing 3D graphics on Windows with Swift. The code patterns are not entirely idiomatic Swift, but would be very familiar to someone who is experienced with DirectX.
Hmm, I would then guess that there could be a mismatch between the SDK version in use and where the module map is currently present. This can happen if you have more than one SDK installed or if you have a mismatch between the UCRT and WinSDK. Perhaps a recent update to Visual Studio put things out of sync?
Yes, the implementation of the demo leaves much to be desired. I tried to call that out in the README, but if its not clear, please send a PR. I think that there could be value in providing a better implementation to make it easier for people to get started with DirectX, but that was beyond the scope of that particular attempt - but I definitely see the value in a separate attempt to provide something which can serve as a starting point for others.
I think this example is fantastic as is. It just needs some adjusting specifically when someone wants to use a VM for development as the VM and host become unresponsive, however on a native machine it runs great. I've already used this example to help me make a basic window, which was really difficult for me to understand. As a mac/Linux programmer the way windows does it's references and com is a challenge for me and this example really helped me begin to grasp that stuff.
I'm still working on my Direct3D12 abstraction layer but because of SR-8671 I need to reevaluate how I'm doing that before I can continue. I think I'll follow your lead and make a more swifty version of this demo for it when it's usable.
The directx_Jun2010_redist worked for getting it going.
Still has a fault that if you tab off the game it closes but I have been able to play otherwise. Perhaps a solution overall is closely related to this.
If none of the mentioned workarounds work for you there are basically two options, you can either run the game via DevilutionX or add a DirectDraw wrapper dll to the game folder that redirects the DirectDraw calls to a more modern graphics API.
Uninstalling Alienware Control Center Suite resolved my crashes. Disabling it in the 'Startup' column in Task Manager didn't stop it from launching on startup and it would restart even after using 'End Task' in Task Manager, so I uninstalled it.
I can confirm the streaming and screen recording app, 'OBS' also includes the .dll, 'graphics-hook64.dll,' but I've not had any issues with Vectorworks 2022 SP0 while this app is running and recording.
Is there an update to this with any other known apps or DLLs that cause 2022 crashes? I found one of them in the OBS Studio (uninstalled) as well as in EGVA Precision X1 (also uninstalled). I have searched my entire system for all of the listed DLLs again, finding none now, but it is as crashing. Any update would be greatly appreciated.
I'm encountering the same thing. I found PXSHW10_x64.dll in EVGA PrecisionX 16 and uninstalled it. I ran another search for all the .dll files on the list and couldn't find any. Unfortunately, it did not stop the crashes. Switching between two documents more than once will cause a crash 100% of the time.
Given the severity of your symptoms I'm not surprised you say that! Conversely, the fact that they are unique and severe suggests they will be caused by conditions specific to your computer. Conditions which can be usually be improved.
Because you haven't included any information about your operating system, hardware or circumstances the following is based on a few assumptions, so they may not apply to your situation. Please add your current hardware, operating system and pertinent software to your profile signature or include it in your comments and posts.
Not having issues with other software or prior versions of Vectorworks does not preclude the possible causes I mentioned above. My Windows laptop had no issue with Vectorworks 2021 + Interiorcad, but suffered the issues in this thread with Vectorworks 2022 (without Interiorcad installed). So I suggest you start with (in order of least-imposition to most:
@Daniel M71 Have Vectorworks Tech Support been able to help you resolve this issue? Do make sure you get the driver directly from NVIDIA, in the past we have seen problems with vender versions of graphic drivers like Microsoft, Dell, PNY, etc. it's better to get them straight from the manufacturer if possible.
-us
My biggest issue was Graphics card driver update and settings and an apparently corrupted file. I'm not sure we solved the actual problem but it was with a site model and once it was recreated from site date and new site modifiers were applied it worked fine. But second thanks Jeremy....and too many others to list.
Getting a DirectX 11 crash a lot with 2022 and it tells me the suspect DLL is related to NahimicOSD (which is on the bad list, but when I search for my start up apps - there is nothing like this on the list, so where to find this and clear it out?
Well this is just ridiculous. No previous version of Vectorworks has had an issue with Dell and Alienware support services, and frankly I am not going to uninstall core features of a laptop I've purchased to be able to run a piece of software that should operate perfectly fine alongside them.
has so far worked for me on an alienware M15 R5 Ryzen edition. I can now change workspaces and resize my windows and I am not getting the DLL crash. Remains to be seen if I run in to issues elsewhere, but so far so good.
Thank you for that valuable insight @Anthony Neary. A modified version of the instructions you have linked to worked for me. I've been able to reinstall Alienware Command Center and Vectorworks 2022 now allows me to adjust docked palettes without crashing or the applicable warning coming up (added in Service Pack 3).
In Summary: Add 'vectorworks2022.exe' to one or more 'exception list' files titled, 'BlackApps.dat.' This will prevent NahimicOSD or similar apps from being used with Vectorworks. This solution works only because the makers of the conflicting software included this 'exception list' facility in their software.
Important Advice: Other programs that use these or other DLLs will not be helped by this process. In such cases uninstalling those programs may be the only solution for now, but it is possible they have their own, different way to add programs like Vectorworks to an 'exception list.' Search the software name and the terms, 'exception list,' 'whitelist,' etc to look into this.
Other makes or models may have other software installed that includes the NahimicOSD frameworks which apparently relate to audio processing on certain computers. Knowing this may help you identify pertinent folders to look inside.
Users that have this software installed no longer have to uninstall it to stop it interfering with Vectorworks. See my more recent comment (immediately above your comment) which instructs how to add Vectorworks to an 'exception list' so the software concerned stops trying to 'help' Vectorworks graphics or audio processing.
If you still want to uninstall Alienware Command Center, this is achieved the same way you uninstall any other program on Windows. Search for then select 'Add or Remove Programs,' click on the software concerned and click, 'Uninstall.' (Just so you know, Vectorworks has its own dedicated 'Uninstall' app inside the Vectorworks program folder). Removing Alienware Command Center will only affect performance if you already use it to adjust the performance of your programs (typically games). If you don't use it for this purpose performance will not be affected but you may loose control of 'Alienware' style features like the keyboard lights etc. I prefer to keep this software intact.
Hello, my VW also keeps closing after just opening it. Sometimes it helps to restart the laptop and I also have most of the apps startups deactivated. But most often this little window pops up that sends me to this website to resolve the crashing. From the above comments I also checked whether I have the Alienware Control Suite which I do not have installed. My laptop is a dell inspiron 7506.
Vectorworks should be up to date and for the graphics cards I tried everything. I tried assigning one card to VW then the other and also letting windows choose but that does not seem to work. I updated the latest intel drivers for the graphics cards but I think that only made my laptop crash. So I reset that update again. A few days ago I even rebooted windows because it got to a point where I could not open VW for even a few minutes. The rebooting helped but now it seems to be acting up again.