Originally posted by Galo
It seems like people who are into C++ don’t like C# cause it is captured in a framework called dot net and people think you can only make webapplications with it and portable applications, or am i wrong.
C# as part of the M$ .NET developments relies upon the CLR and the .NET class libs, yes. Then again, C# as part of relies upon an open-source flavor of a CLR and similar class libs and can’t really be attributed to M$ even though they have set the pace while offering C# and the CLR as an open standard.
well give me a awnser to this then.
If i was a young developer, just starting out, shoud i pick C++ or C# to learn graphic programming ?
And please look @ the future, is C# gonna be a replacement for C++ ?
You didn’t specify how far into the future to speculate. Depending on the length of the time answer to the question will differ. In the next few years it is unlikely that C# will replace C++ as THE dominant language yet will gain a very strong position in application development (especially Windows based development seeing as how the future of the OS is tied in with the .NET class libs and the CLR). In a longer distant future (let’s round it at 5 to 10 years) it is without question that managed code will be more prevalent than unmanaged code but the language used to write managed code will become less relevant (managed C++, managed C#, etc.). As complexity of software design and demand on effort increases the importance of managed code will increase at an equal rate.
If you are looking specifically at graphics related development then it depends largely on the kind of development. Complex realtime state-of-the-art games will always rely on pushing the most out of the system and will not adopt managed code for most of their work. Games that are not considered graphically at the top of what’s possible will adopt managed code earlier and quicker because they can afford to sacrifice a few percent of performance in order to have a cleaner and more maintainable project. If you’re doing in-house tools then the choice between the two languages will depend largely on whether something is a one-shot application that will not be under any expansion or maintenance track or whether it’s part of a growing and consistent toolbox and how much time and effort can be saved vs. the small sacrifice in performance. A mix of managed and unmanaged code already is taking shape as the basis of in-house developments and I suspect that will continue to grow. It also depends on whether software is aimed at a commercial market and requires a higher level of maintainability and as such managed code will be considered more interesting for companies that aim at volume markets. And of course there’s the platform issue that should be taken into account seeing as how Windows will remain an early bird when it comes to managed code while the others will continue to trail behind it for the forseeable future.
What I predict is that managed and unmanaged code will blend together as part of smaller and larger projects whereby performance optimized portions will remain done in C++ while additional portions will be done in managed code where possible. The current paradigm shift isn’t too different from the one that took place going from assembly to C++. While optimized portions were still written in ASM the remainder was done with C++.
My advice would be to learn C++ and keep your eyes on C#. The step from unmanaged code and C++ to managed code and C# (or managed C++ for that matter) is an easier one to make if you have gained sufficient C++ experience. The catch here is that C# is probably easier to learn than C++ because as a language C# is cleaner, younger, and carries a lot less of the confusing baggage that C++ has built up for itself over the many years. I haven’t encountered anyone yet who’s gone from C# to C++ but it seems that going that route will be more confusing since the first thing you’d run into are all those particularities regarding C++.
Do they both have directX and OGL ?
Both are provided through libraries, regardless of platform and tend to be language agnostic since you can use the libs through many other languages. C# and managed DirectX support looks very interesting, yet is a Windows-only stronghold. OGL and C# is a bit of a achilles heel since the support is lacking and various open-source developments are in an early stage and offer only sufficient wrappers around the original libraries.
Are they Both OOP ?
Yes, though many will argue that C++ has the worst OOP concept. I consider OOP/OOD to be part of the design while the language offers a degree of support for it. A language that is said to offer OOP can still easily be construed to create a complete sequential mess that decends into chaos. No amount of OOP/OOD support from a language will help you there. The OO model provided by C# is definitely cleaner and easier to handle and maintain but in the end it’s the design of the code that defines how much the OO model assists (or frustrates) the developer.
Do they support pointers both ?
Yes. Though pointers in C# are rarely used and would require the use of unsafe code blocks. There’s nothing to stop you from using them in C# but the longevity of pointers seems to be heading for a slow death in the realm of managed code.
Are you just as free (as an programmer) in C# then in C++ ?
Define freedom. 
Depends… you’re free in C++ to create a mess while C# will provide you a battle if you really want to create a mess. I guess in that sense C++ offers more freedom. However, that’s at the syntax level that defines the language. When it comes to actual development activities, getting into subclassing, inheritance, polymorphism, events, delegates, exceptions, etc. it looks like C# offers more freedom to implement the design without putting too many boundaries on how you wish to get the job done.
I mean isn’t c++ the base language of all computers, how can C# replace that, was C# written in C++ cause C# was not there yet so it has to be…
Over at M$ they have managed to write the C# compiler in C#. Always a good test for a language and its compiler seeing as how quite a few C++ compilers were written in C++. C++ isn’t a ‘base’ language per-se seeing as how C++ kicked ASM off its throne many years ago and is now starting to be kicked around itself a bit. The nice thing with compilers and languages is that you can, in practice, build a compiler for a language in that very same language. C++ has gained the status as the standard for most development, that’s all. And standards undergo a paradigm shift every number of years in relation to the shifts computer technology itself makes. C# is aiming (and starting to) replace C++ in the areas where the most benefits can be gained from it (areas where complexity and maintainability under budget constraints are the predominant factors that influence the development efforts). But it’ll be another 5-10 years before managed code will be the new standard for application development. And even then there’ll still be folks doing parts in C++ when needed just like there were folks still using ASM a few years ago where it mattered to their performance requirements.
And i read that C# is much less complicated and th code seems to be verry clean.
I would agree on that. The code is cleaner due to the cleaner syntax, therefor easier to read and thus offers more effective maintenance. It’s still possible to write C# code that appears manually obfuscated but it takes more effort to do that while C++ offers many more ways to design something unreadable. It depends a lot on the programmer and the design, though.