pseudorandom21 166 Practically a Posting Shark

I haven't really done this myself but my hypothesis is you should be able to store the directory hierarchy information in your application, and use it to make new folders and then place the actual data files in them.

Oh I see in your sig you're using Code::Blocks, I don't know how to add resources to the project using that compiler/IDE. Hopefully you can find that yourself.

pseudorandom21 166 Practically a Posting Shark

Well if you're completely new to C++ I strongly suggest reading up on the "ifstream" class.

http://cplusplus.com/reference/iostream/ifstream/

Then you can easily do something like:

#include <iostream>
#include <string>
#include <fstream>
using namespace std;

int main()
{
   const char *fileName = "C:/myFile.txt";
   ifstream inFile(fileName);//Automatically opens the file.
   string inputLine;
   while( getline(inFile,inputLine) ){
      cout << inputLine << endl;
   }
   inFile.close();
}

This example doesn't include error checking.

pseudorandom21 166 Practically a Posting Shark

For projects on my own time, it is either the payoff or the awesomeness of the idea.

pseudorandom21 166 Practically a Posting Shark

Ok heres what I want to do: I want to put a file in a console application (during compileation\codeing not running) and when it runs it saves the file in the same place it was run from. Like moving a movie as an exe to hide it while it is in

Add the file to the project as a resource. Of course, if you don't have a legitimate reason to do so, then by all means don't for the good of everyone.

pseudorandom21 166 Practically a Posting Shark

In most cases, it's illegal. Torrents are for file sharing (usually illegal music/movies/pirated software) like Napster used to be.

I live in a rural area and the only "high-speed" internet service available is uber-slow and it simply isn't even possible to download large files in the normal manner (the download will fail and waste hours of my time, trust me). Thus I turn to torrents of legitimate downloads that are quite large and torrents work quite well. There is nothing inherently illegal about torrents, and I feel the system has very legitimate uses as well as "illegal."

The prime benefit is that torrents allow for reliably pausing, resuming, and bandwidth limiting of downloads as well as decentralization.

But on the other hand most of the time people that illegally file share *may* simply feel Hollywood doesn't need their money so that they can buy another solid gold dog (and dog house). In which case it's entirely OK.

But keep in mind at the maximum I am able to download files at 70 kilobytes per second (down speed) with an upload rate of 15.
I think it's fairly safe to say those who take their massive bandwidth for granted are often likely to improperly label torrents as "illegal" while those with a legitimate use for it are left trying to ride the wave of ignorance that surely ensues and destroys the entire system.

pseudorandom21 166 Practically a Posting Shark

Don't use "void main()" bub.
http://users.aber.ac.uk/auj/voidmain.shtml

pseudorandom21 166 Practically a Posting Shark

"std" is a namespace and it is short for "standard".

If you don't include "using namespace std;" then you have to do this:

#include <iostream>
int main(){
std::cout << "Notice the namespace followed by the scope resolution operator?" << std::endl;
}
pseudorandom21 166 Practically a Posting Shark

Anyone play Counter Strike: Source Beta ? PM me and I can add you on steam.

pseudorandom21 166 Practically a Posting Shark

Likely on your system there is also a Windows Media Player class.

pseudorandom21 166 Practically a Posting Shark

http://en.wikipedia.org/wiki/Quadtree

Well my first question is:
It says Q-trees "decompose space into adaptable cells", how are the cells "adaptable" what does it mean by that?

It seems that structure's usage in "Image representation" (based on the example) is to recursively classify rectangular regions of the image based on a color (grey for mixed, black for solid black, etc.), which is simple for the example because it is black and white. I suppose one could apply a "weight" to that consisting of a floating point or integral value.

Originally I did intend my training data to be greyscale (what luck!) so the rectangular region's average value from the color white could be used as it's "weight"?

Now with this simple neural network that we're building here (gotta love Daniweb) could we could average the values of many sets of input data to produce median values with which to use in recognition?

I think this could be used to solve my problem excellently, specifically when the section of image to be matched varies in size.

But then once we have these images decomposed and represented internally by the computer, how do we do proper matching? I mean is it going to work properly if I make a match between Depth 5 of my training input image with depth 1005 of my test image? Obviously this won't work properly when it comes down to a group of 4 pixels versus a rather large section …

pseudorandom21 166 Practically a Posting Shark

Hello all, I'm a Jr. in college and I haven't studied machine learning yet to any extent. I would like to at least know how to specify this project I have in mind though.

Basically I'd like to have a number of input images to "train" the software with, and then use the software to recognize new images that contain a rectangular region similar to the inputs. I've heard a little about this type of thing involving artificial neural networks, but I would like to know what this type of task is called and if there is a suitable C++ library that may help with it's development.

A quick google search returned these results:
http://sourceforge.net/projects/annie/
http://sourceforge.net/projects/nnetlib/files/
http://knnl.sourceforge.net/

Any information you may have would be helpful, I find this to be a very interesting problem to solve and I just wish I knew more about it.

pseudorandom21 166 Practically a Posting Shark

Whats this like online in comparison to how BF looks ? is it fast paced, amount of people playing and what match making is like ?

I'm investing in Gears3 when it comes out and cant wait for BF3, thats me becoming a recluse for the winter, the better half will NOT be happy.

http://www.youtube.com/watch?v=b6h7Ley8CwE
It's the same as the first Crysis was, the video/pix don't do it justice.

pseudorandom21 166 Practically a Posting Shark

Actually there's a button at the bottom so that you yourself can mark it as solved.

pseudorandom21 166 Practically a Posting Shark

So, who plays Crysis2 multiplayer?

Me! Man that game is beautiful, I bet BF3 will only be slightly prettier. Come to think of it I need some more RAM too.

Other than that I have a small selection of Steam games, and I mainly play Counter-Strike: Source Beta. I would play Americas Army 3 more often but the game is just so terrible it barely runs on my system.

pseudorandom21 166 Practically a Posting Shark

of course it does!

Create a new project, expand the options until you find C#, select a Windows Forms Application and get to it.

pseudorandom21 166 Practically a Posting Shark

If you post in the C++ forum I'll help you, as will others.

pseudorandom21 166 Practically a Posting Shark

Wait what?

Did I just hear the double quote is the escape sequence for quote?

Whatever happened to:
" \" "
and
" \' "
??

pseudorandom21 166 Practically a Posting Shark
pseudorandom21 166 Practically a Posting Shark

Will it run on VMware?

pseudorandom21 166 Practically a Posting Shark

Hey guys what's the easiest way to find the Nth occurrence of a character in a string? I'm hoping there is a standard library function with a name like "NthOf" or something.

Thx.

pseudorandom21 166 Practically a Posting Shark

C++/CLI is great too and I wish more people used it.

pseudorandom21 166 Practically a Posting Shark

Yeah you should post in the C# forum because C++/CLI uses .NET
People like "Moschops" don't even know what C++/CLI is.

pseudorandom21 166 Practically a Posting Shark

Ehh I haven't examined your design in detail but as long as you avoid a circular dependency it should work.

http://en.wikipedia.org/wiki/Circular_dependency

pseudorandom21 166 Practically a Posting Shark

I think this is called a "circular dependency" where one class requires another which in turn requires the other class and doesn't compile.

To see what I mean, try removing "GCF"'s dependency on "Calclist" and then try building.

Unfortunately the remedy is to remove the circular dependency...

pseudorandom21 166 Practically a Posting Shark

INB4
vote for Ron Paul

pseudorandom21 166 Practically a Posting Shark

Hmm..
How about.. "Vampire Hunter D" it's alright for a cartoon.
Or maybe...
"Scarface" wait...
"District 9" ? It's good, trust meh.

There's also another one about a guy who hires some woman to help him find parts for his sex robot in a futuristic wasteland.
I forgot the name though :(

This movie "Brazil" is pretty strange, was entertaining one night when I couldn't sleep though.

Yeah I missed the "Informative" part entirely.
trololololo

pseudorandom21 166 Practically a Posting Shark

By "basic design" do you mean you have studied enough about the HTTP protocol to actually implement creating a basic web browser?

My suggestion to you is to attempt to create a text-only web browser first, but I don't expect you'll ever complete your task. Instead I think, it will be superseded by an attempt to use the QT library's webkit to accomplish your task, or even another programming language like C# (which has a built-in drag and drop "web browser" control).

All in all I think you should rethink your solution to the problem, is having an anonymous web browser the best way to solve the problem?

It's probably leaps and bounds easier to use C# to do this, and then you don't have to deploy with all those QT DLLs that you may or may not know how to use yet.

Not to say it wouldn't be a lot of fun to use C++ though ;)

pseudorandom21 166 Practically a Posting Shark

void main()

Change "void main" to int main() .

Also, writing the program so that there is less coding would be beneficial, what happens when you try to run that thing?

pseudorandom21 166 Practically a Posting Shark

Actually I have a more practical idea for the perfect computer desk, I just need to build it lol.

If I build it, they will buy it...

pseudorandom21 166 Practically a Posting Shark

Yes, I completely agree now. You are not worth my time. You do not listen to what other people say, and when someone does not agree with you, you try to desperately defend your own opinion by insulting others.

That is a lie, my interest in this thread just dropped to about zero when I noticed the flock of naysayers were about to drag this thread on for.foorking.ever.

pseudorandom21 166 Practically a Posting Shark

Maybe it's throwing an exception you didn't catch?

pseudorandom21 166 Practically a Posting Shark

Are you done insulting other people without an apparent reason? If you are, then I may discuss with you this subject further. If you do not have anything intelligent to say, then I am done here.

It's just that the flock of naysayers aren't worth the time.

pseudorandom21 166 Practically a Posting Shark

Well, I personally use Linux :)
The link you posted does not account the servers Linux, TVs, new refrigerators, PS3s, Microprocessors, cars and planes, super computers, Phones, and Tablet PCs. No-one misinterprets you, but we are just telling you there is things other then Windows.

Windows (as OS) and .NET are written in C++ and C, this functions you used are written in C++ lower-level API and just called from C#. So nothing can be made without C++. Some of the devices that use C and C++ don't even have screens, so how would the implement the screen-shots? You should care for all the programmers, not only about yourself, and this is what Dennis Ritchie and Bjarn Stroustrup did!

Sounds like more butthurt babbling because you don't want to hear that .NET is better for business.

GrimJack commented: Why must you stoop to name-calling, a little defensive? +0
jwenting commented: ad-hominem attacks instead of arguments... +0
pseudorandom21 166 Practically a Posting Shark

You're confusing the core language (C++) with a specific implementation of that language on a specific operating system (Visual C++).

Yep, Windows for the business world.

As it stands I've made my point quite well, even if you should decide to misinterpret it.
http://lh6.ggpht.com/-IoO3eeZZi9E/TkRaZ1oWk3I/AAAAAAAAAAA/O92T5p8mKY8/s1600/OS%2BMarket%2BShare%2BCP%2B2011-03%2B530%2B2011-04-01.jpg

pseudorandom21 166 Practically a Posting Shark

What I want to do is have a predefined battle function, I can code the function, all I need to know how to do is have the function sitting there, so when I call it, all it takes is one or two variables to set up and go. So every time I don't have to input damage calculators, defense algorithms etc.
Help would be greatly appreciated, thanks.

Wut?
I don't think we have enough information to help you to a great extent, but you may look into passing by value and passing reference, as well as passing arrays and pointers.

pseudorandom21 166 Practically a Posting Shark

Since c++ is not a Microsoft product why would you expect the language to contain those things? C++ was not even invented by Microsoft. If you want all that support for Microsoft Office then use a different language which is designed for that purpose.

Expect? What are you daft? No, but they are useful features and their omission may potentially be leading to a decline in the use of C++, particularly (as stated previously) at least partially due in part to the features meeting the business needs of today.

Would you consider it a benefit for a useful feature to be included in the language's standard "library" ?

pseudorandom21 166 Practically a Posting Shark

Don't use "void main()" either.
Use instead, "int main()"

pseudorandom21 166 Practically a Posting Shark

Well since I got in a little late I'll spare no other's ego any expense.

C++ still has the same drawbacks it's always had since I've been programming, and it's very nature implies that it doesn't have a built-in Microsoft Word file format interpreter that gets updated every time M$ releases a new version, it doesn't have a built-in IE based Web Browser for browser automation tasks, and it doesn't have a built-in Microsoft copyright logo creator.

C++ is great because it's flexible, but RAD tools seem to be the way of business needs these days. If you knew C++ and C# and had to, say.. Capture a portion of the screen and compress it as a jpeg and reduce the quality to 50% to reduce the file size (for scraping needs or something), which language would you rather use?

If the built-in .NET framework classes/methods didn't do what you wanted, then and only then would you most likely be using C++ as long as performance isn't a concern.

Speaking from a noob's standpoint, knowing very very little about screen capture and absolutely nothing about jpeg compression I must say C# is the correct language to use.

//GetScreen.cs
using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using System.Drawing.Imaging;
using System.Windows.Forms;
using System.IO;

namespace ScreenCapture
{
    
    public class GetScreen
    {
        private Graphics gfx;
        private Bitmap bmp;
        private Point zero;
        private Size resolution;
        private Size imgSz;

        public GetScreen()
        {
            zero = new Point(0, 0);
            resolution = new Size(Screen.PrimaryScreen.Bounds.Width, …
pseudorandom21 166 Practically a Posting Shark

There are certainly some jobs in the CS department that don't involve programming.

You know what they say, those who can't do, teach.

pseudorandom21 166 Practically a Posting Shark

Hello there, I'm not too entirely familiar with the operation of scheduled tasks within Windows XP and I'm tasked with finding an operable solution.

Firstly, a couple things come to mind:

1. Start the process with windows using a low priority and sleep until it is time to function. This idea is definitely not an elegant solution.

2. Use the Windows XP Task Scheduler to schedule a task for the right time(s) that use my tool by passing command-line arguments. I would like a way to add the task to the schedule via C# but haven't found it yet.
http://support.microsoft.com/kb/308569

Secondly, I would like to ask about other potential solutions and just a spare opinion on which one you would choose.

Regards,
pseudorandom21

pseudorandom21 166 Practically a Posting Shark

It's all in the for-loop.

pseudorandom21 166 Practically a Posting Shark

You didn't explain what you're supposed to do to get the output.

pseudorandom21 166 Practically a Posting Shark

as far as I know you can't name a variable starting with a number.

try clearing the error bits before opening a new file with a previous fstream.

i.e.,

//...
file01.close();
file01.clear();
file01.open("...");
//...
pseudorandom21 166 Practically a Posting Shark

Is there a built-in way to convert a string to an operator like + or - ?
I get the feeling support for it isn't there but it's worth a try...

pseudorandom21 166 Practically a Posting Shark

don't use "01" and "02" as variable names.

Your IDE may have a handy find & replace feature to let you quickly change it too,
try hitting Ctrl + F.

pseudorandom21 166 Practically a Posting Shark

Very interesting, I wish I had one to play with so I could pass judgement on it too.

pseudorandom21 166 Practically a Posting Shark

Do I Need to know assembly?

pseudorandom21 166 Practically a Posting Shark

While I am of course concerned with people ripping off the product and I appreciate the suggestions on piracy protection, I'm more concerned with:

1) finding testers that are relevant.
2) protecting myself if my application crashes and the tester insists that damage was caused by my application.
3) getting usable feedback from the testers in a easy and effective way.

I know that people will try to rip things off, it's the name of the game these days. The internet is chock full of pirated software, and no matter how big or small your company is or how popular or unpopular your software is, people will steal it. There's really nothing I can do about that. As soon as I come up with a way to protect my application from it, someone will break it. It's an endless cycle. Even Bill Gates, when asked what he thought about all the people pirating Windows, he said "well at least they are stealing my software and not someone elses!"

I'm not sure I agree that software piracy protection is futile, if that's what you mean.
I honestly believe that I can prevent every jackhole in the entire world from cracking my software and putting it on bit-torrent.

Maybe I should go into that field of work, lol.

As far as useful testers go, you can always hire some freelancers to give their opinion but I'm sure that is an expensive route and you are far better …

pseudorandom21 166 Practically a Posting Shark

Basically I'm wondering what a sensible approach to learning Windows driver development would be.

I have a logitech mouse that logitech decided to drop support for Vista/W7 on, and I'd like to write a driver for it but if that isn't possible it's fine and I would work with some other device.

Where to begin?

pseudorandom21 166 Practically a Posting Shark

The project I have been working on and seeking advice on from this forum for over a year is approaching it's final steps. All that really remains is arranging the controls on the forms into a layout that is both functional and "pretty" (and getting a nice bottle of champagne of course).

Once that step is done I'll need to test my application, preferably with those who know a little about the goals of it and can provide constructive feedback.

My question is 3 fold:

1) How can I find such beta testers? (preferably for free)
2) Before providing copies of the solution to the testers, are there any suggestions on how to protect all of my hard work besides obfuscating the code, which only protects me from hackers/programmers (and even then only marginally).
3) What kind of protections should I have in place to prevent the concept and goals of my solution from falling into the hands of my future competitors? And what, if any, liability for data loss, hardware failure etc...would not be covered with a standard EULA that the testers would agree to?

I know #3 is kind of a legal question and trust me I plan on consulting with counsel first, but would prefer to get some feedback from those who might know before spending $250/hr for someone to stare at me and say "ummm...I can turn my computer on and off? I can show you if you want?"

Well this might be too …