[DotNet-OSGeo] RE: 3D display

Harold Dunsford hadunsford at gmail.com
Tue May 31 12:23:27 EDT 2011


I created a DirectX 3D viewer in the past for small grids and vectors in the
past.  The ability to turn a small grid into a 3D terrain map using DirectX
is fairly straight forward.  However, the real element that is necessary is
a library module that can start with a massive terrain grid in a standard
GIS format, process it into perhaps a custom format that works more like a
Mipmap and then have an open source library that works with that format in
order to generate the necessary DirectX models on the fly as you zoom
around, but does it without huge delays.  We all know how google earth
feels, but a lot of very smart developers had to work quite some time in
order to coordinate that sort of ability.  Everyone points out that gaming
engines can do spectacular things with 3D vertices.  When you "walk around"
in a 3D world, some of them can even load the necessary elements as you go,
and accomplish changes without noticeable loading screens.  However, what
they don't typically do is zoom way out and zoom back in the way we are used
to doing in GIS.  When they do support something like that, the 3D part is
very low definition, almost flat, and most of what you are seeing is image
mipmapping, which allows for rapid scaling.

I think one thing that is important to remember is that while everyone knows
that the gaming industry uses techniques in order to create extremely
effective 3D displays, they usually work on engines that are designed for
very specialized applications.  The difference between a tiny crude 3D grid
being displayed on the screen and a navigable 3D world is proprietary,
secret or just so specialized for a particular type of gaming that it
usually isn't helpful for GIS.  Further, the people with the training and
skill to work with those tools demand a notable salary compared to your
standard graduate student.

If truly effective open source GIS specialized 3D engines were available,
they would obviously be in high demand and used by a lot of people.  But you
almost have to have an entertainment business model in mind to cost-justify
the expense building it.  You might almost have to imagine a game that works
a lot like GIS, so that you could finance the framework development by
selling the resulting game that depends on the open source framework :P.

Ted




On Tue, May 31, 2011 at 8:42 AM, Michael P. Gerlek <mpg at flaxen.com> wrote:

> For a year now, I have had a dream of making a really slick DirectX-based
> 3D viewing engine for geo applications.  The work I’ve done in the past, and
> the work you’re doing now, is all stuff that the DirectX “experts” have done
> a million times and we are just reinventing their wheel.  Since I do mostly
> lidar these days, I’d love to make a solid, canonical open source library
> for 3D, but I’ve just not had the time/funding for it yet…
>
>
>
> -mpg
>
>
>
>
>
>
>
> *From:* dotnet-bounces at lists.osgeo.org [mailto:
> dotnet-bounces at lists.osgeo.org] *On Behalf Of *Carsten Troelsgaard
> *Sent:* Monday, May 30, 2011 1:45 PM
> *To:* dotnet at lists.osgeo.org
> *Subject:* [DotNet-OSGeo] RE: 3D display
>
>
>
>
> Hi Michael
> Thanks for the informative response.
>
> > 3D, but it really depends on what you need to do. Simple
> rendering/viewing?
>
> Yes, I think that it comes down to this. Making a crude topography appear
> on the screen is a good start for getting to work on a lot of topics that
> relates to the topography. I admit that I'm hooked on delicious appearances,
> But .. as for transferring data through the net, vectors as in a topologic
> grid, passes a lot of info pr bit compared to bitmap image data. The
> abillity to interact with it as a viewer (flyby and such) makes the
> perception of the topological data unsurpasable by other media.
> As a geologist of education, I have a watchfull eye on the posibillities of
> displaying subsurface geology, but I would probably run short of proper data
> to use. (If I should get involved in bitmap-texturing it would be in the
> context of conveying subsurface geological visual presentations - but it has
> a low priority for now)
>
> > Custom display controls? Integration with other geo tools and libraries?
> >
> > You have a few options for doing your own 3D display on Windows, and
> again
> > it depends on what your needs are:
> >
> > * DirectX / D3D
> >
> > - DirectX/D3D is great, but is doesn’t have .NET bindings, so you have
> > to code the engine in C++ and use interop from C#
>
> I use the Visual Studio Express. It has a C++ IDE. Yes .. I would still
> miss DirectX3D in that editor. I think that I tried to do an integration of
> this editor with something referred to as the "Windows SDK". .. it usually
> leads to a plain new reinstall of the Express tools .. The MSDN library on
> the Windows SDK has all the stuff about DirectX3D that I spent a little year
> of learning and would like to stick to becourse of that. Leaving the
> net-framework may mean that I'll have to learn how to deploy ... so far I've
> made small tools that produces one single .exe that simply works when copied
> from the pile of files that the Express IDE produces.
>
> > - SlimDX is a really nice open source C# API that sits on top of the
> > DirectX C++ API, so using SlimDX you can skip the interop and code
> directly
> > in C#
>
> Either way I do it, I'll have to come to terms with the fact, that I won't
> get anywhere without dependancies .. being it directX3D, Xna or OpenGL.
>
> > - if you want to use WPF with DirectX underneath, you can use SlimDX as
> > well, although it takes some work to get the D3DImage class to behave (my
> > own SlimDXControl package is one solution for this problem)
> >
> > * WPF or Silverlight
> >
> > - this would be very appealing, but you can't represent points directly,
> > only polygons, so if you want to do raw point clouds this isn't an
> option;
> > also, if you're trying to do tens of thousands of vertices, it will start
> to
> > slow down
> >
> > - the latest release of Silverlight has started to add 3D primitives, but
> > again you can't do points and you often can't scale into thousands of
> > objects
> >
> > * XNA
> >
> > - I know the least about this option; XNA is really designed as a game
> > API, and my quick look a couple years ago made me stay away because I
> didn't
> > have either the raw power of using DirectX directly or the flexibility of
> > actual UI framework like WPF/Silverlight
> >
> > * OpenGL
> >
> > - powerful and low-level, like DirectX, but also lacking a native C# API
> >
> > - there are some C# bindings libraries out there, but I've no experience
> > with them
> >
> >
> > So, it comes down to these questions:
> >
> > - do you want to program in C++, C#, or a mix?
>
> I have an idea that I can make a 'lean an mean' C++ form as a basis,
> but I'm not done on pondering about the slow-down. I can display 700*700
> vertices with an annoying slow performance; and 800*800 will not be
> accepted. I think that I use the 'fixed pipeline' as I cannot make the code
> for multiple vertex-lists work. The vertices are turned into triangles ..
> that would be 100.000 triangles .. far less than I anticipated though it's
> plenty enough to have a decent look. There are different approaches to deal
> with these issues.
>
> http://cid-382e99b169b58267.photos.live.com/self.aspx/Billeder/ng%5E_2.jpg
>
> I'm getting the hang of C#. There's no intelli-sense so I have all the
> reason I need to be slow. The coding that lies behind the image above uses
> the parts of DirectX3D that I know .. most of the Xna stuff is one big
> haystack that hangs together, so it's been difficult to sort the subset out,
> but it's been much like making a form in C# with a different sort of code in
> the Paint-event (it IS a C# form).
>
> > - do you want a low-level library which supports points like
> > DirectX/OpenGL, or do you want a higher level polygonal framowork like
> WPF?
> > - do you want to jus trun on a Windows desktop, or do you want to be able
> > to port your engine to Windows Phone, Linux, etc?
>
> There won't be any WPF and I prefer a proper screen for display, so desktop
> it is. I had some issues with Silverlight, so it's out too.
>
> Michael, I don't hope that I have abused your attention.
>
> Carsten
>
> _______________________________________________
> DotNet mailing list
> DotNet at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/dotnet
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/dotnet/attachments/20110531/18011d1d/attachment-0001.html


More information about the DotNet mailing list