Page 12 of 13

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Sun Aug 26, 2012 10:29 am
by PhilipLB
Nice one. :)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Sun Aug 26, 2012 11:00 am
by MirceaKitsune
sleo wrote:not rendered, real photography, for motivation :)
jMrd0zTVuZI.jpg
If you posted that picture a few years ago, that wouldn't have been necessary to mention. With some of today's awesome graphics, it made sense :P

Graphics like in that image should be possible at good FPS. For those rocks / dirt, parallax mapping should be used. For the grass and flowers, lots of automated model scattering (with rendering the same model in batches, which should be a ton faster as an OGRE demo shows).

Anyway, last time I tried this I remember it was either discontinued or just wouldn't compile for me. I'm currently taking a look at polyvox and seeing if I can compile their demo with OGRE (I heard that's how it should work). Since I'm a C++ noob however, it might take a bit.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Sun Aug 26, 2012 10:21 pm
by PhilipLB
GSoC, but not project end! Release and more stabilizing.
  • Created another fork of Ogre and added this project manually to the 1.9 branch there. Development happens from now on here as I need a clean branch for my thesis without commits from other persons. Will be merged every few commits to the main repo.
  • Some more optimizations of the loading time by about 25%.
  • Merged the code into the main repository!
  • Fixed accidently slipped in Windows line endings.
  • Added a small helptext to the terrain sample of how to move arround.
  • Fixed the triplanar texturing shader of the RTSS.
  • The CSG sample now uses the RTSS triplanar texturing and has a nicer thumbnail.
Image

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Aug 27, 2012 8:32 am
by TheSHEEEP
If you release the thesis, once it is done, I guess someone might take the time to translate it.

I mean... we do have some German team members ;)

Of course, I've never translated such a thing, and my mathematical understanding might not suffice to actually get what's going on, but it should be possible to translate it still. At least in a good enough quality for everyone to understand.
And we should really only translate it if there is a huge enough desire to have it in English and if you say that it would be very helpful in understanding your code :)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Aug 27, 2012 11:02 pm
by Mind Calamity
+1 For an english version. Just to add to that desire thing. ;)

If someone doesn't translate it, I'll let Google Translate do it's thing and butcher every word in there. :)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Aug 27, 2012 11:34 pm
by PhilipLB
I think I could just put my thesis then in a bitbucket repository, when everything is done == thesis defense done and my prof actually agreed to CC-SA (I don't see problems here).
Bitbucket is a nice option as I write in LaTeX anyway.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Fri Aug 31, 2012 10:10 am
by PhilipLB
So, we reached August 31th. :)
Between the 26th and today, only some refactoring happened to the codebase and I submitted the version of August 20th to Google. For now, I'm mainly writing on my thesis. How will this project proceed? There are several areas which I'd like to develop, in my current priority:

Documentation
Currently, there's hardly any documentation beside the two samples. I see the documentation in two areas: Usage and theory. The usage-part will get some wiki-articles in the next days. The theoretical part is all about how everything works. This is partly covered by my thesis I'm writing. I like the idea here of putting the LaTeX files on Bitbucket after I defended it. :) But this will take some time. The deadline for the written part is the 6th of Novembre, the defense is... at some point afterwards, maybe a few days, maybe a few weeks... I also aim to write a paper or two about this and present it on conferences. But no concrete plans about this. :)

More sources and procedural generation
I'd love to have a noise source. :)

Editing capabilities
The only serious way to create the 3D textures needed for the terrain I'm aware of, is Acropora [0]. But this program is not free (and also my trial expired :(). Please tell me, if you know something here, a free editor would be the best. :) So an editor would be awesome. For this, a few parts are still missing: Some intersection with rays. For editing, intersection with the actual volume should be good which doesn't sound that hard. Also a way of updating the volume data during runtime is needed ("add sphere here coming from a brush"). And the third thing is the update of the chunks. A chunk needs some milliseconds (like... 15-25ms on my dualcore?) to be created, might be practicable or not, has to be tried.

Paging
For real large worlds, paging is a must. The paged data could be the dualgrid and not the actual meshes of the chunks. Also the volume source needs to be paged maybe, as it's not reasonable to hold a giant memory block of the texture data in memory. With procedural sources, this would work, as they naturally require not a lot of memory. Must be further investigated.

So there are plans for the future to keep this project alive and busy. :) The wiki page also contains a random collection of ideas in no particular order.

[0] http://www.voxelogic.com/index.php?opti ... &Itemid=21

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Fri Aug 31, 2012 10:22 am
by Zonder
If you created the editing functions for the terrain it could be integrated with some of the scene editors for ogre.

I am sure the Ogitor team are interested (I am sure jacmoe mentioned something already in this thread)

Also nauk mentioned in his editors thread he's interested in it http://ogre3d.org/forums/viewtopic.php?f=11&t=42507

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Fri Aug 31, 2012 11:36 am
by Alexiss
I would also be very interested in implementing voxel editing in IWE (http://www.ogre3d.org/forums/viewtopic.php?f=11&t=67673).
I already had a working implementation to some degree using Polyvox.

Although development is currently halted, I plan on resuming work in the upcoming months.

Anyway, I take this opportunity to congrulate you for the great work you've done here.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Fri Aug 31, 2012 12:45 pm
by spacegaier
Yes, we - the Ogitor team - are always interested in any additions and help we can get!

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Fri Aug 31, 2012 2:30 pm
by duststorm
Having a proper editor for this terrain is a really big step to getting it used in actual projects.
I'm all for an Ogitor plugin! :)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Sep 03, 2012 4:30 pm
by PhilipLB
I think, I'll still just use this thread for updates?
I post here, whenever I add something, until 1.9 is released, instead of weekly updates. :)
  • Added support for material definition in volume terrain config files.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Sep 03, 2012 8:36 pm
by duststorm
PhilipLB wrote:I think, I'll still just use this thread for updates?
Or you could create a fancy new thread in the Showcase forum, with nice images and demonstration movie, to attract more attention.
Make that your official thread.
A lot of people don't come in this forum.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Sep 03, 2012 8:47 pm
by PhilipLB
That's true, I'll think, I'll do this with a nice "what's done" and "future"-descriptions.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Tue Sep 04, 2012 9:18 am
by Zonder
PhilipLB wrote:That's true, I'll think, I'll do this with a nice "what's done" and "future"-descriptions.
Yeah that's definitely a good idea.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Wed Sep 19, 2012 10:27 pm
by PhilipLB
Just wanted to send a ping that everything is still alive with this project. :) What keeps me busy currently is the written part of the thesis and every now and then a small fix or optimization. The promised documentation will come for sure and of course the further development.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Wed Sep 19, 2012 10:42 pm
by jacmoe
If you need any help - with docs and stuff (not the thesis, obviously! :P ) - just shout. ;)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Thu Sep 20, 2012 10:43 am
by robert_sasu
Can you look a little bit into your sample in the sample browser, the volume terrain sample, and try it running on DirectX 11 Render System ? It gives me a crash at OgreVolumeTexture.cpp line 85. I do not know if wether this is the Render Systems error or not. I need a little bit help to resolve all the bugs in the DirectX 11 Render System. (if you have time)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Thu Sep 20, 2012 4:35 pm
by PhilipLB
I don't have a DirectX capable GPU. :(

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Thu Sep 20, 2012 4:51 pm
by robert_sasu
No problem. Then I will debug it, when I will have a little more time :)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Oct 08, 2012 9:30 pm
by DragonM
The triplanarReference implementation fails substantially. From the samplebrowser Ogre Log:

Code: Select all

15:18:16: Parsing script triplanarReference.program
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called fogParams does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(7): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightDiffuse1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(22): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightDiffuse2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(23): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpecular1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(25): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpecular2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(26): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightAttenuation0 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(27): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightAttenuation1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(28): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightAttenuation2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(29): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpotlight1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(31): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpotlight2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(32): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called spotlightDir1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(34): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called spotlightDir2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(35): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightPosition1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(37): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightPosition2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(38): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called fogColour does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(40): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called fogParams does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(60): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightDiffuse1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(75): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightDiffuse2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(76): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpecular1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(78): setting of constant failed
15:18:16: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpecular2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:16: Compiler error: invalid parameters in triplanarReference.program(79): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightAttenuation0 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(80): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightAttenuation1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(81): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightAttenuation2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(82): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpotlight1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(84): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightSpotlight2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(85): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called spotlightDir1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(87): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called spotlightDir2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(88): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightPosition1 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(90): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called lightPosition2 does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(91): setting of constant failed
15:18:17: OGRE EXCEPTION(2:InvalidParametersException): Parameter called fogColour does not exist.  in GpuProgramParameters::_findNamedConstantDefinition at ..\..\ogre\OgreMain\src\OgreGpuProgramParams.cpp (line 1453)
15:18:17: Compiler error: invalid parameters in triplanarReference.program(93): setting of constant failed
This happens under either OpenGL or D3D9.

The results look somewhat ok under ambient light, but many of the expected effects are missing and if a surface using the triplanar material receives a shadow, it goes to dead black. No visible texture.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Oct 08, 2012 9:44 pm
by PhilipLB
It's ok, that setting those constants fails as most of them aren't in the compiled shader because of some #ifdefs. There is no uniform var for light 1 and 2 if only light 0 is active. I'm not aware of a workaround beside delivering multiple programs or commenting out the not used. I think, I'll do the later with comments like "If you use fog, uncomment the following vars" etc..

The shader itself shouldn't fail though. Could you post a screenshot?

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Oct 08, 2012 9:57 pm
by bstone
Are there any messages related to compiling the related cg program? That looks like the vertex/fragment program failed to compile and hence it doesn't consume any of those parameters.

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Mon Oct 08, 2012 10:32 pm
by PhilipLB
I just merged a new version to the 1.9 branch where the not used parameters are commented out in the program file. The exceptions are gone now for me. If you still see any exceptions in the triplanarReference.program, then we got a trace why it fails for you. :)

Re: [GSoC 2012] Volume Rendering with LOD aimed at terrain

Posted: Tue Oct 09, 2012 12:03 am
by DragonM
Using the new version, I get no parse errors in the log and these are my results:

Daylight. You can see in the distance the contrast where Ogre stops rendering shadows. (The trees cast shadows.)
Screenshot_10082012_175337827.jpg
Daylight with tree shadows
Screenshot_10082012_175337827.jpg (119.83 KiB) Viewed 7725 times
Evening, where the sun is at a low enough angle that only the trunk shadows are reaching the ground.
Screenshot_10082012_175422473.jpg
Evening with three shadows
Screenshot_10082012_175422473.jpg (145.09 KiB) Viewed 7725 times
And night, after the sun (the sole light source besides ambient light) has set.
Screenshot_10082012_175439691.jpg
Night with nothing casting shadows.
Screenshot_10082012_175439691.jpg (129.71 KiB) Viewed 7725 times
I'm probably just doing it wrong, since I'm not a shader guy. Possibly I should switch to using the RTSS version?

I should specify: shadow technique is SHADOWTYPE_TEXTURE_MODULATIVE.