1

I am learning OpenGL/C++ by following a tutorial series on in2gpu. I set up my Project just like the autor did. It is an Empty Visual C++ Project. Inside the project I linked glew and freeglut, the according files are inside a Dependencies folder which I copied into the project folder. Everything works like a charm so far, I can build and run.

Now I tried to add the solution to a TFS-collection on my Visual Studio Team Services account. Here I encounter two problems.

  1. While the autor of the tutorial adds folders inside his Visual Studio Solution I have only the option to add filters. enter image description here

This seems to break my project structure. After I check in the solution and inspect it in Source Control Explorer on my TFS it does not have it's folder structure anymore. All header and cpp files are placed inside the solution without any folders or filters. This of course makes it impossible to get a working latest version of the project. I have to restructure the entire project every time I get the latest version in order to solve compile errors. How can I get it to work?

  1. The second problem I have is more of a general question about versioning of this kind of projects. Like I mentioned before I have several dependencies which are referenced via Linker settings.

Glut dependencies Glew dependencies

They are not included into the solution though. It is just a folder inside the project folder. Therefore they are not included into the Solution in the TFS, but the Linker settings seem to be saved. Would it be possible to include these dependencies into the version control too?

1 Answer 1

2

Visual Studio solutions work differently for C++ (compared to C# or VB). With C++ project you do not get "hand held" with your folder layout in the project mirroring that on disk. Instead, with C++ you can put your files anywhere you like, and organise them as you like using filters. eg you can have many folders on disk with lots of C++ or resource files in them, but see them in your project as a single filter of all these files. Alternatively you can have your open GL code and application code in the same folder on disk, but view them in different filters in the project.

To fix your problem, put your files in folders right from the start.Then organise them into the filters you want. Do not think a project filter in VS is the same as a folder on disk.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.