Thanks for all the input!
I'm sure that noone expects otherwise
- tho I'd love to see it running under wine.
I'll look into that, because it would be crazy
. But much later.
well, this is a bit of a "problem". from my point of view, it depends on how well it maps. one of the reasons that we chose the naming and static convention that we did for lwjgl, was that using import static would make a lot of the code "just" work from C/C++. By changing the names one has to refactor some code to make it work. Typically, however, this isn't a really big issue.
Users would still have to refactor their C/C++ D3D code any way since there are multiple ways to program. You can use
(all three mean the same thing).
Then call methods via the C++ way
or the C way
IDirect3DDevice9_BeginScene( dev );
OpenGL is a C API anyway, so it's all functional programming, which Java can do. Also, all the method names start with lowercase 'gl'. You guys had it easy
Another thing is that if there is an 'I' in front of a class, it denotes an interface, even in C++. Keeping it IDirect3DDevice9 in Java may confuse some newcomers. But, after typing this and remembering that D3D is an interface for the graphics card, it makes sense to keep the 'I', kinda.
fair enough. The dx api, is really a bit ugly IMO.
I too would keep the mapping as close to 1:1 as possible. This makes a transition easier and if people want Java style identifiers they can always just write their own wrappers on top of your work.
I'm pretty sure people wont get confused if their method names were lowercased.
I guess the best way to do it would be to have as little refactoring as possible. But, refactoring will have to take place no matter what.
I'm really torn between keeping it 1:1 or making it more Java friendly. There are positives and negatives to both. I'm leaning more to make it Java friendly. I think users of D3D would appreciate it.
A solution I came up with was to provide both capitalized and lowercase method names and both 'create' method types, returning an HRESULT or an object. Hell, why not include the C wrapper as well
. I'm only kidding... unless it's a good idea.