CSE598/494 System-Level Hardware-Software Codesign: Difference between revisions
From esoterum.org
Jump to navigationJump to search
No edit summary |
No edit summary |
||
| Line 2: | Line 2: | ||
*Gregory K. Wallace, [http://white.stanford.edu/~brian/psy221/reader/Wallace.JPEG.pdf "The JPEG Still Picture Compression Standard"], IEEE Transactions on Consumer Electronics, 1991 | *Gregory K. Wallace, [http://white.stanford.edu/~brian/psy221/reader/Wallace.JPEG.pdf "The JPEG Still Picture Compression Standard"], IEEE Transactions on Consumer Electronics, 1991 | ||
*[http://library.lib.asu.edu/search/X?SEARCH=The+Data+Compression+Book ''The Data Compression Book'' at ASU Library] | *[http://library.lib.asu.edu/search/X?SEARCH=The+Data+Compression+Book ''The Data Compression Book'' at ASU Library] | ||
== Project 2 == | |||
*[http://www.thescripts.com/forum/thread753816.html Can this be used to replace file pointers?] | |||
Here is an example of using `fmemopen' to create a stream for | |||
reading from a string: | |||
<code> | |||
#include <stdio.h> | |||
static char buffer[] = "foobar"; | |||
int | |||
main (void) | |||
{ | |||
int ch; | |||
FILE *stream; | |||
stream = fmemopen (buffer, strlen (buffer), "r"); | |||
while ((ch = fgetc (stream)) != EOF) | |||
printf ("Got %c\n", ch); | |||
fclose (stream); | |||
return 0; | |||
} | |||
</code> | |||
This program produces the following output: | |||
Got f | |||
Got o | |||
Got o | |||
Got b | |||
Got a | |||
Got r | |||
Revision as of 23:58, 12 February 2008
JPEG
- Gregory K. Wallace, "The JPEG Still Picture Compression Standard", IEEE Transactions on Consumer Electronics, 1991
- The Data Compression Book at ASU Library
Project 2
Here is an example of using `fmemopen' to create a stream for
reading from a string:
#include <stdio.h>
static char buffer[] = "foobar";
int
main (void)
{
int ch;
FILE *stream;
stream = fmemopen (buffer, strlen (buffer), "r");
while ((ch = fgetc (stream)) != EOF)
printf ("Got %c\n", ch);
fclose (stream);
return 0;
}
This program produces the following output:
Got f
Got o
Got o
Got b
Got a
Got r