terrain only engine

Started by
17 comments, last by 3dmodelerguy 20 years, 1 month ago
why do some people always seem to want to "convert" other people to C++, or to C?

he wants a C terrain engine. fine... his original question hasn't been answered yet, but we've had a start of a discussion about C vs C++.. great :|

sirSolarius>
quote:It will take you exactly 0 minutes and 0 seconds, since c++ is backwards compatible with c.


that doesn't take into account the portability wrburns tlked about, does it?

also, why do you people care witch language he uses? do you feel the urge to enlighten him with your ideas? :/


3smodelerguy> a terrain engine is pretty vague.. what do you want your final terrain to be like? does it have to be rather huge? (like 50 Km), or can it be smaller? (1-2 Km)?

I don't know anything about pre-made terrain engines, but I _think_ openscenegraph has an implementation of thatcher ulritch's chunked lod.. perhaps you could have a look at that for a start?
(edit: sorry, just realized it's C++... anyway, using the chunker lod's paper, or even roam/roam2 (also, what is your target hardware?), you should be able to come up with a C implementation...)

[edited by - sBibi on March 19, 2004 5:19:23 PM]

[edited by - sBibi on March 19, 2004 5:20:13 PM]
Advertisement
C++ is not 100% compatible with C.

For example, in "C," a common variable name is "new". Try stuffing that in your C++ pipe and compile it ;-)
enum Bool { True, False, FileNotFound };
And there are also one or two new keywords added to C last revision. I beleive one is something like ''restrict'' though I have not followed what has happened with C.
quote:Original post by Drath
And there are also one or two new keywords added to C last revision. I beleive one is something like ''restrict'' though I have not followed what has happened with C.


AFAIK, it''s also not necessary to declare your functions in C, whereas they must always be declared in C++. That can cause problems as well.

Besides that, C++ is notorious for compiling on some compilers, but not on others. That can lead to serious problems if he is planning on targetting VC++, GCC, Borland, ICC, etc.
Something you can do in c, but not in c++:

void *ptr1;
long *ptr2 = ptr1;

My Site
with good reason as well, its called ''type''
just coz you can do something dont make it good

As for C++ compiler issues, stick to the standard and get a new compiler (VC7.1 for example) and you''ll have little to no problems (templates seem to be the only sticky and then its generaly obscure stuff).

and the last 5 posts (inc this one) havent helpped the OP at all or even been worth while, well done
Why do I even brother to ask any question on this forum, I ask for a c based engine (I dont care, as long as it can display some, even small, terrain). Now it has turned into a c vs C++ thread.
because it seems some people are too wrapped up in pushing their own prefered language or way of doing things onto others and commenting on what one thing can do which the other cant

www.vterrain.org might have something which will help you on it
Closed. If you want to ask the question again, 3dmodelerguy, go ahead.

Richard "Superpig" Fine - saving pigs from untimely fates - Microsoft DirectX MVP 2006/2007/2008/2009
"Shaders are not meant to do everything. Of course you can try to use it for everything, but it's like playing football using cabbage." - MickeyMouse

This topic is closed to new replies.

Advertisement