The ports are still work in progress, there are still major features missing (like render to texture/shadow support in d3d11) so please don't report bugs.

I'm trying to change as less as possible on the API and pipeline. Documentation of the changes is in https://github.com/attilaz/horde3d-x/wiki/GLES2-and-D3D11-port.I made some breaking changes so any comment/criticism is appreciated. I'm open for any suggestions to make it better and suitable for the whole community.

Attachments:

File comment: Here is a screenshot of the knight sample on d3d11knight_d3d11.jpg [ 74.04 KiB | Viewed 18138 times ]

First of all, congratulations to the first working D3D rendering backend for Horde3D.

Regarding your changes I totally aggree that dynamic texture compression is something that should be probably avoided anyway and may be done in a preprocessing step or moved to a separate utility library that creates compressed textures on the fly and pass those to horde (e.g. when using a custom h3dutLoadResourcesFromDisk version or something like that).

I also agree that it's proably better to switch to RGBA8888 that is available on all platforms instead of using BGRA. I never noticed any measurable difference in speed and for texture streaming maybe PBOs would make a bigger difference, but are currently not used by Horde3D.As a lot of the ES2.0 devices do not support BGRA, I think switching to RGBA by default would make a lot of sense.

I never did any shader programming on D3D, so regarding your shader definition changes I'm probably not the right person for giving advises. But maybe we should use the D3D names in lowercase by default. So in OpenGL vertPos becomes position0, normal => normal0, etc.

First of all, congratulations to the first working D3D rendering backend for Horde3D.

Thanks and thanks for the feedback.

Volker wrote:

Regarding your changes I totally aggree that dynamic texture compression is something that should be probably avoided anyway and may be done in a preprocessing step or moved to a separate utility library that creates compressed textures on the fly and pass those to horde (e.g. when using a custom h3dutLoadResourcesFromDisk version or something like that).

Moving compression to h3dutLoadResourcesFromDisk is a clever idea. With some compression method this could be usable (eg. realtime dxt compression). Our pvrtc and etc compression method on best quality takes minutes for 1024x1024 textures so obviously we convert it in preprocessing. I will remove "compression on upload" related flags from h3d and update the docs on github.

Volker wrote:

I also agree that it's proably better to switch to RGBA8888 that is available on all platforms instead of using BGRA. I never noticed any measurable difference in speed and for texture streaming maybe PBOs would make a bigger difference, but are currently not used by Horde3D.As a lot of the ES2.0 devices do not support BGRA, I think switching to RGBA by default would make a lot of sense.

Thanks for the info about your experience about bgra/rgba upload. Then I think it is better to switch rgba8888 on all backend.

Volker wrote:

I never did any shader programming on D3D, so regarding your shader definition changes I'm probably not the right person for giving advises. But maybe we should use the D3D names in lowercase by default. So in OpenGL vertPos becomes position0, normal => normal0, etc.That would make mapping a bit more easier I guess.

To be honest this is my first d3d11 project (I used d3d9 only). As renaming attributes in opengl backends is a quite large change I postpone this till the backends are mature enough and there is no better solution.

Here is a new screenshot of the current status of d3d11 renderer on github.

Attachment:

knight_d3d11_v2.jpg [ 91.64 KiB | Viewed 17964 times ]

Shadowing and 'render to target'/posteffect are working now.

Documentation is updated on github's wiki.

Future work:GLES2 shadowing support is still not working, and I would like to support rt rendering without depth texture support for hardwares like tegra3.After that I will work on a test framework as the features (especially the d3d11 renderer and ktx format support) are hardly tested.

I would like to focus on windows version now. Using native GL,D3D11. For GLES2 using emulation with ANGLE.Any help is appreciated with porting to other platforms (iOS, android, ...).

On win32 the examples(es2, d3d11) work on my machine, but on iOS and android they are still not working perfectly. Probably the shaders needs some fixing, and they are still trying to load dds/dxtc textures instead of pvr/etc.

For platform support I chose to use a slightly modified cocos2d-x/platform framework. maybe this is not the best solution.Other alternative could be using SDL(SFML?) but this is a large dependency and I am not sure if they supports every platform that cocos2d-x/platform supports.Or implement our own platform framework which is much more work, and as I don't have access to every platform can't do it alone. I am open for suggestions.

Need some help with fastmath and gles2_d3d11? I can test these patches for you on Windows 7 (VS2012/VS2013) and Mac OS X (Clang 3.2) and create a pull request (in your name using your gmail address, as its your work). Any objections?

Need some help with fastmath and gles2_d3d11? I can test these patches for you on Windows 7 (VS2012/VS2013) and Mac OS X (Clang 3.2) and create a pull request (in your name using your gmail address, as its your work). Any objections?

Any help is appreciated in testing/bug fixing. Feel free to use it/create a patch. Currently I'm busy with finishing our next game, after that I will probably have some time finishing the es2 port. I am not planning to do further work on the d3d11 port in the near future. Instead I will focus on #ifdef-able shader/fx, it is more important for us, I could halve our shader count, as we are using different shaders for opaque/alphatest(tiled renderers needs this optimization)/alphablend materials.

In my former job I compiled it using the NDK, but there are currently no out-of-the-box makefiles available for Android. It shouldn't be to difficult to create one based on the examples shipped with the NDK. But you also have to add JNI bindings in case you don't develope a NativeActivity

I am doing my Android NDK (NativeActivity) development with on Windows 8 with Visual Studio 2010 Pro and the great NVIDIA Tegra Android Development Pack.It comes bundles with everything and on installer downloads and installs it all.

I am very much interested in any progress with Direct3D 11 (because of Windows Phone and OpenGL ES for Android and iOS.Is it still being worked on?

Since I am going to take on a new game project, and my own framework does not provide any 3D support, I am looking around for 3D rendering engines to use. I could not find many engines with OpenGL ES and DirectX support, and some force you to use their own framework (game engines) which won't work with my multiplatform framework.

Of course, I am happy to help with the development of Horde if I am going to use it.

Who is online

Users browsing this forum: No registered users and 2 guests

You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forumYou cannot post attachments in this forum