Hello,
I've a little problem with a code routine here.
I'm opening a file using std::ifstream::open, with standard opening attributes std::ios::in
now I read the complete file with std::ifstream::read( ... )
and put the content into a char buffer:
std::ifstream _fileInputStream;
_fileInputStream.open( "File.txt", std::ios::in );
char buffer[ 500 ];
_fileInputStream.read( buffer, sizeof( buffer ) );
with that the buffer is full with the data from the file.
But now:
The data structure looks like this:
X-Coords Y-Coords
23 112
25 134
34 188
.
.
.
And I have to move the int values into a
struct d_Struct
{
int x, y;
}
But how can I cut the char string buffer into its x and y parts ??
Thanks for all help,
ciao,
lex