ChrisMacPherson
Programmer
Hello all,
I am having trouble creating an array of Point(s). At one time I even got an error stating something like "Internal Compiler Error" !! Which shocked me a little. I dont have that code to hand anymore but need to get this working.
It's hard to find anything on the net due to the word point being used with reference to pointers, so please dont think I'm being lazy and havent looked.
I need to have a file which contains a line of integers seperated by spaces which are read in by my function and inserted in to an array of type Point.
Therefore the 1st integer would be pointArray[0].x and the 2nd pointArray[0].y
Then the 3rd integer would be pointArray[1].x and the 4th pointArray[1].y etc. etc.
I know how to open and read the file and loop to the end of the file, so really it is just how to initialise the point array.
This seems to me like it should be really simple, I cant think why I'm having such difficulty.
Thanks for any help...
Chris MacPherson
I am having trouble creating an array of Point(s). At one time I even got an error stating something like "Internal Compiler Error" !! Which shocked me a little. I dont have that code to hand anymore but need to get this working.
It's hard to find anything on the net due to the word point being used with reference to pointers, so please dont think I'm being lazy and havent looked.
I need to have a file which contains a line of integers seperated by spaces which are read in by my function and inserted in to an array of type Point.
Therefore the 1st integer would be pointArray[0].x and the 2nd pointArray[0].y
Then the 3rd integer would be pointArray[1].x and the 4th pointArray[1].y etc. etc.
I know how to open and read the file and loop to the end of the file, so really it is just how to initialise the point array.
This seems to me like it should be really simple, I cant think why I'm having such difficulty.
Thanks for any help...
Chris MacPherson