colorvalue in progressive mesh sample
Hi, new to DirectX in C#, not in C++.
In the August 2005 DirectX sdk update, there is a sample in C# called "Progressive Mesh". When I compile this sample, I get 36 errors, all of which are type or namespace missing errors. Here's an example. 'ColorValue', which is supposed to be of the
Microsoft.DirectX.Direct3D namespace simple does not appear to be there. MSDN says it's part of the namespace, auto-complete does not. What is going on? I know this is probably a newb question, but hey, I'm a newb :)
[541 byte] By [
kshawol] at [2008-3-3]
Have you added the right DLL files to the project? Right click references in the Solution explorer and add the DLLs that contains the namespaces. Directx.DLL and so on. Can't remember the names by heart and I am in Linux right now, sorry..
- ?? -
Assembly Microsoft.DirectX.Direct3D
C:\WINDOWS\assembly\GAC\Microsoft.DirectX.Direct3D\1.0.900.0__31bf3856ad364e35\Microsoft.DirectX.Direct3D.dll
It's there already.
These are all the references.
Microsoft.DirectX
Microsoft.DirectX.Direct3D
Microsoft.DirectX.Direct3DX
mscorelib
System
System.Drawing
System.Windows.Forms
The file is dxmutgui.cs
Here are the namespace uses.
using
System; using
System.Collections; using
Microsoft.DirectX; using
Microsoft.DirectX.Direct3D; It declares a namespace:
namespace
Microsoft.Samples.DirectX.UtilityToolkit this is the structure where I get my first error.
public struct BlendColor {
public ColorValue[] States; // Modulate colors for all possible control states
It can't find ColorValue.
All the errors occur within dxmutgui.cs or dxmutmisc.cs.
ColorValue also does not appear in the object browser.
Delete the DirectX references, then add them back in ensuring you get the latest version number for all of them.
There is something screwy in the solution files or in the way VS2005 opens them.
That did it, it compiles and runs, thankyou.
Still getting warnings..
Warning 1 The file 'Common\AssemblyInfo.cs' could not be added to the project. Cannot add a link to the file C:\Documents and Settings\Chameleon\My Documents\Visual Studio 2005\Projects\Progressive Mesh\Common\AssemblyInfo.cs. This file is within the project directory tree.
Any idea how to fix this?
Yes, this appears to be a problem with updating Visual Studio 2005 References in general. Anytime I update a Class Library and copy it to another project, I have to delete its Reference in the new Project and then re-add it, or it acts like I'm still using the old one somehow... even though it no longer exists. I wonder where it even gets the old code from.