Page 4 of 11
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Thu Jun 21, 2012 12:10 pm
by duststorm
jacmoe wrote:You can 'forget' those files, and add them to an .hgignore file and commit/push again.
It's no problem.
Mercurial is very forgiving.

Really? you mean that hg will purge any existence of them from its history?
That's a very handy feature!

Thanks, I didn't know that.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Thu Jun 21, 2012 12:29 pm
by spacegaier
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Thu Jun 21, 2012 12:59 pm
by duststorm
How about amend? Can it change the history?
Hmm, I guess this contains the best answer:
http://hgbook.red-bean.com/read/finding ... :aaaiiieee
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Thu Jun 21, 2012 1:10 pm
by jacmoe
History is sacred in Mercurial.
To remove an already added and committed file, you need to 'forget' it, add it to .hgignore and commit/push.
It doesn't remove it from history, but it removes it from the repository, which is what you want.
BUT, if you are the only one working on the repository, and you have the mq extension (IIRC), you can strip the changesets.
And permanently erase a string of changesets from history.
That does only work if the changesets you want to kill is the last ones.
Not recommended, unless the repo is completely f****d up.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Thu Jun 21, 2012 10:30 pm
by robert_sasu
I have removed the Dependencies folder from my repo and added to hgignore to not make further errors. I am working on the tessellation feature created functions as:
_setTessellationMode(const String &tMode);
_setReductionMode(const String &rMode);
_setuQuadTessFactors(unsigned int qLeft, unsigned int qRight, unsigned int qTop, unsigned int qBottom);
_setTessFactor(); _setScale();
For setting the general tessellation variables.
In the init function I initialize all variables to a common value. Then have different methods for calculating(setting) Hull and Domain shaders for Triangles and Quads separately. Finally methods for patternTessellation for triangles and quads.
Tomorrow I will continue this work and I will also work with testing after I got the modules from cherlix.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Fri Jun 22, 2012 8:40 pm
by robert_sasu
Today I have been working with the implementation of the domain and hull shaders to the current version of DirectX 11 Render System. I have almost finished the work, will push my code when I finish the implementation. I have also continued to work with the pattern tessellation, which is on the final stages.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Fri Jun 22, 2012 9:29 pm
by Assaf Raman
Can you draw up a quick summary class diagram of the classes you created\modified?
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Fri Jun 22, 2012 9:36 pm
by robert_sasu
OgreMain/include/OgreGpuProgram.h
OgreMain/include/OgrePass.h
OgreMain/include/OgreRenderSystem.h
OgreMain/include/OgreRenderSystemCapabilities.h
OgreMain/include/OgreScriptCompiler.h
OgreMain/include/OgreScriptTranslator.h
OgreMain/src/OgreGpuProgram.cpp
OgreMain/src/OgrePass.cpp
OgreMain/src/OgreRenderSystem.cpp
OgreMain/src/OgreScriptCompiler.cpp
OgreMain/src/OgreScriptTranslator.cpp
RenderSystems/Direct3D11/include/OgreD3D11GpuProgram.h
RenderSystems/Direct3D11/include/OgreD3D11HLSLProgram.h
RenderSystems/Direct3D11/include/OgreD3D11RenderSystem.h
RenderSystems/Direct3D11/src/OgreD3D11GpuProgram.cpp
RenderSystems/Direct3D11/src/OgreD3D11GpuProgramManager.cpp
RenderSystems/Direct3D11/src/OgreD3D11HLSLProgram.cpp
RenderSystems/Direct3D11/src/OgreD3D11RenderSystem.cpp
These are the classes I have modified for this support. I will add more details about this part of the work after I push my code (tomorrow).
I have also created OgreD3D11Tessellation.h and OgreD3D11Tessellation.cpp which will contain the methods I described I want to make for tessellation. First of all a general pattern tessellation, after that I will continue with implementing PN-Patches, Detailed tessellation with brezier displacement and surface tessellation. These methods will use all the implemented functions/methods I created so far (Domain, Hull and Compute shaders).
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Sat Jun 23, 2012 8:43 am
by robert_sasu
I ave pushed my code to the repo, later today I will come with more changes. I created GPU programs for the 3 shaders (Compute, Domain and Hull) and implemented all the necessary functions for these. I have also added support for geometryshader, as it was missing in at some point in the D3D11 Render System.
I have added 2 files from Sample of DirectX11 Tessellation Tutorial -
www.xtunt.com, for tessellation samples.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Sat Jun 23, 2012 9:22 am
by duststorm
You're really making good progress. I must say I'm really amazed at the quality of this year's GSoC projects, some amazing work is being done.
Keep it up, you're doing some really valuable work here!
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Sat Jun 23, 2012 11:14 am
by robert_sasu
I have completed the support for hull, domain, compute and geometry shaders. If I missed out something please tell me

.
Here are the options for rendering:
We have more shader models (hull, domain, compute, vertex, pixel, geometry).
These are the possibilities of rendering:
1. vertex, fragment(pixel)
2. vertex, geometry, fragment(pixel)
3. vertex, hull, domain, fragment(pixel)
4. vertex, hull, domain, geometry, fragment (pixel)
5. compute
General set-up's to decide which shaders will we use:
1. if we are using compute shaders, other types of shaders are impossible to be bound
2. Tesselation is enabled when hull and domain shaders are bound
3. Stream output is enabled when vertex and geometry shaders are bound, and there is no fragment(pixel) shader bounded
4. DrawAuto is enabled when VertexData::vertexCount == -1
5. Otherwise, vertex-fragment(pixel) and vertex-geometry-fragment(pixel) behavior remained the same
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Sun Jun 24, 2012 10:43 am
by Xavyiy
As @duststorm pointed out, you're doing an amazing work. Can't wait to see it in action!
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Mon Jun 25, 2012 8:56 pm
by robert_sasu
I have cleaned up a little bit my code and corrected the errors. Also added a sample for tessellation which uses the hlsl file added on Saturday. cherlix finished his work on testing the first tasks we were working on, I will upload the results later today.
I have also added the newly created class OgreD3D11Tessellation for DirectX 11 Render System. I want the user to be able to run a defined tessellation with calling on method, so to simplify the usage. It is not complete and it is just for the pattern tessellation, but will continue to do the more complex algorithm for tessellation, as I described it a week ago. I would need some suggestion on this part, as I can't really decide how would this be the best

. I am having problems just on setting and creating the shaders: whether to oblige the user to set every single shader, or just create them there and asking for the object which he wants to tessellate. Another question would be (in the second case) should I compile the shader from the file or from the memory (which would be passed as a parameter (a path + filename or a pointer to the memory).
If you have any other suggestions, please tell me

.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Tue Jun 26, 2012 6:07 am
by Assaf Raman
Use our stream - not a file name.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Mon Jul 02, 2012 2:00 pm
by robert_sasu
I have completed the pattern tessellation, and continued to work with PN patches algorithm. I have also improved capabilities check for D3D10, D3D10.1 and D3D11 drivers. I have also continued to work with cherlix on the test modules.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Mon Jul 02, 2012 2:17 pm
by Assaf Raman
Great.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Mon Jul 02, 2012 2:59 pm
by robert_sasu
Today I will continue to work and upload the code again, around midnight time with some more changes

.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Mon Jul 02, 2012 3:20 pm
by Brocan
A few screenshots?

Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Mon Jul 02, 2012 9:04 pm
by robert_sasu
I have talked with cherlix, we need to rewrite the shaders on our test modules. He will do it on the next 3 days. In this time I will continue to work on tessellation support. After cherlix will finish his code, I will prepare the showcase of the work which has been done so far. I will try to update some screenshots tomorrow, but the a showcase for a complex test will be done in the week-end.
In the next week I will also make some samples for PNPatches and detailed tessellation with Brezier displacement.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Wed Jul 04, 2012 4:39 pm
by robert_sasu
Yesterday I have found some bugs, I resolved it and everything was working fine. Today I was making some adjustments to the tessellation sample file (just that). SampleBrowser was working until a point when I changed on what video-card to run (from Intel HD4000 to GeForce GT640M, each compatible with DX11). After that I can not run SampleBrowser I get 2 errors. Even if I changed it back it doesn't work. I reinstalled everything still the same. I have also installed to another folder, neither that resolved my problem. It seems that Ogre doesn't recognize my videocards.
Can somebody help me on this ?
For Intel HD4000:
For GT 640M:

Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Wed Jul 04, 2012 4:45 pm
by Wolfmanfx
I think under the user folder appdata roaming or something like that the samplebrowser saves a cfg file which containse the last selected rendersystem and video mode.
So after switching the device the video mode is not avaiable on one of the cards so it crashes - to resolve this error locate the cfg file and delete it and everything should work.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Wed Jul 04, 2012 4:48 pm
by Assaf Raman
Yes.
If deleting the cfg file doesn't help - post the full call stack.
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Wed Jul 04, 2012 5:28 pm
by Mind Calamity
I just checked it and it's in "%HOMEPATH%\My Documents\Ogre" and there should be a directory named by the codename of the OGRE version you're using (for me it's Byatis).
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Sun Jul 08, 2012 10:55 am
by Assaf Raman
Can you summaries what have been done so far in the project - and was is still left to do as we continue?
Re: [GSoC 2012] Complete the DirectX 11 render system
Posted: Sun Jul 08, 2012 8:42 pm
by robert_sasu
Yesterday I have been to a wedding till 6 am today, so I couldn't work on Saturday and Sunday, but I consider I am ahead of my proposed work.
Till now this tasks are mainly done nr. : 1, 2, 3, 3.1, 3.2, 3.3, 8, 9, 10.
1. Test and merge the DX11 enhancement patch
2. Test and merge the DX11 Unicode build and alpha-blending support
3. Planning the tessellation support, adding support for Shader Models 5.0
3.1 Tessellation Pattern Viewer
3.2 PN-1 Triangles algorithm
3.3 Detailed tessellation, Brezies with displacement
8. Test and merge the DX11MRT Support patch
9. Test and merge the DX11Separate Scene Blending & operations patch
10. Test and merge the DX11 comparison filtering implementation patch
The screenshots will come soon, I just have to do some debug to obtain the proper result.
In the next phase, after I will finish debugging and showing all the results, there are 2 major and 1 minor tasks to be done for the second part of GSoC:
1. Testing multi-window support
2. Multi-device support (copying from Directx9RS and making adjustments)
3. RT shader system support for shader model 4/5 with dynamic linking
Cherlix started to work on rewriting the shaders in the RT shader system to Shader Model 5.0.