:)
Ok, it now works to some extend. See the EDIT from post #1
I can compile the whole thing, but can you help with the second code-snippet? Is this intended to be compiled along with the 6 files above, or replace one of them (it is basically a Graph implemented as adjacency list)
I would just like to run these examples myself, but it won't work :/
User Profile
Collapse
-
GRAPH.h from "Algorithms in C"
Hey, I recently bought "Algorithms in C" by Robert Sedgewick
In his programms (Part 5) he refers to "graph.h"
On the website, I found an ftp Server with those files on it:
ftp://ftp.cs.princeton.edu/pub/cs226/map/c/
Now, I downloaded graph.h, graph.c, point.h, point.c, pqindex.h, pqindex.c from there.
I opened these in Dev-C++, and tried to compile "graph.c"... -
Thanks
Ok, will do, thanks. I found some .c file while googling, but wasn't sure what to make of it. Obviously, it wasn't what I needed. The -bmp should be quite simple, as I only need two colors, and no greytones :) So filesize should be small (but it isn't really an issue, there will never be more than one output file :)
This can be closed/archived/whatever now.Leave a comment:
-
I thought there might be a header file I am unaware of, or some pre-written .c file including what I need. Anyways, it seems there isn't...
This correctly opens "output.bmp " in binary mode?...Code:FILE* output = fopen("output.bmp", "wb");Leave a comment:
-
:)
Thanks for that. I then take it there is no easier way to do this?Leave a comment:
-
How to Turn Array of integers into image file
For a project (homework), I need to manipulate an Array of integers (2D) so that only certain positions take the value 1, and all others take the value 0.
The Array is 800x600 in size, but may vary depending on the instance.
This works fine, the problem lies in the output:
To make output more readable (800x600 Array, dumped into a text file, is annoying to check for errors), I would like to turn this into an...
No activity results to display
Show More
Leave a comment: