microsoft / microsoft/win32metadata
Missing legacy Direct3D APIs
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 1.5k
- Forks
- 149
- Avg merge
- 5d 16h
- Merged PRs (30d)
- 4
Description
While currently the legacy DirectDraw interfaces (`IDirectDraw` etc) are listed.
There is a whole bunch of related legacy Direct3D interfaces (`IDirect3D` etc) that are missing. The are created by calling `QueryInterface` on the DirectDraw interface.
I had a dig around with the code search and the included Windows SDK files that are parsed do include the missing definitions in the header file `d3d.h` (which is a different file to the newer Direct3D 9 - 12 versions). This is a companion to `ddraw.h` which is already being scanned. The header is https://github.com/microsoft/win32metadata/blob/main/generation/WinSDK/RecompiledIdlHeaders/um/d3d.h
I tried to figure out how bits of this project work, and I believe the missing `d3d.h` file needs to be added to https://github.com/microsoft/win32metadata/blob/main/generation/WinSDK/Partitions/DirectDraw/main.cpp
There is a question about which partition these files belong in. They can't be used without first creating a DirectDraw interface so it might make sense to include them there.
There is already https://github.com/microsoft/win32metadata/tree/main/generation/WinSDK/Partitions/Direct3D but that is used for `d3dcommon.h` which is used with Direct3D version 9 and newer. So I don't think is good choice as then applications only targeting recent versions will get all the legacy stuff included.
Another option might be to create a "Direct3DLegacy" partition. But it can't be used on its own without the DirectDraw partition.
I can make a PR if I can figure out how this project builds/tests changes.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with generation/WinSDK/Partitions/DirectDraw/main.cpp and compare how ddraw.h is scanned with the definitions in generation/WinSDK/RecompiledIdlHeaders/um/d3d.h. Review the existing generation/WinSDK/Partitions/Direct3D partition to understand its scope, then determine the appropriate partition for the legacy interfaces. Done means the legacy Direct3D APIs are generated without pulling them into the newer Direct3D partition, with the relevant build or tests passing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100