August 17th, 2003, 10:28 PM
read from file and generate to graph
i'd like to ask, is there anyway to treat a file as a database where we read particular data from the file and generate them on the graph using C language?
If yes, can Microsoft Visual C++ do it?
can MS-DOS run the reading file and the generation of the graphs?
DO I need to use C++ together with C or
C is enough?
August 18th, 2003, 04:09 AM
C can achieve _EVERYTHING_ C++ can.
It is not a matter of which compiler or library you link with (win32 api, vc++ compiler etc). All that you are doing is parsing/processing data, then outputting a binary file with all the required properties of the image format youwish to save it as (windows bitmap for example, has a bitmap header, bitmap information header, possible pallete, bitmap data).
You could use an external library with image rendering routines, you can find these on google. The hardest part, if you are going to use someone elses image library, is processing the data properly (and securely).
I don't think this is something you should bother trying to write yet, get to grips with basic file handling, pointers, structures etc.
August 18th, 2003, 06:42 AM
erm...okay...yeah...i want to know the concepts first..
Let's start with pointers...
i read about stacks....and queues..
for stacks, it is LIFO and queues is FIFO...
but, I cannot get the idea where to apply these kind of things..
why we need to insert in the middle? why do we need to insert at the end?
Erm....in Microsoft, something like undo and redo...this is Stacks..am i correct?
then, for printing...it is queues right? cause when we print a lot of stuff, they will print the first one we want to print.
Then, what is insertion in the middle about?
August 18th, 2003, 07:15 AM
Insertion in the middle allows doubly linked lists to be in-order, potentially speeding up searches (especially if the list pointer is central).
Wwhen I said pointers I didn't mean using pointers to implement data structures, I meant to modify & parse file data once it's in memory.
August 20th, 2003, 01:51 AM
if i want to display a simple graph (something line line graph) in MS-DOS....
do I need to calculate the x,y axis?
can I use dimensional array?
if yes, how's the concept using dimensional array?