fprintf worked! =D
program is officially done and fully functional!! /victorydance
thanks, fellow programmers, i couldnt have done with without you!!!! <3 <3 <3 <3 <3
Type: Posts; User: TheReceptionist
fprintf worked! =D
program is officially done and fully functional!! /victorydance
thanks, fellow programmers, i couldnt have done with without you!!!! <3 <3 <3 <3 <3
one last question (FTW)
im having trouble with fwrite. im sure everything else works coz i printf-ed it every time, but i dont know why its not working. i know fwrite returns the number of...
ok, NEVERMIND. i fixed it. someone else told me about passing ints to int *s; all you need is to add a &infront of the int being passed to an int*
ohhh... ok, i see what your saying about 1 fread for all of it. tweaked that part already and checked that the right information was being copied, etc. thanks!!
still having issues with returning...
thanks, KCfromNC. i figured that out at 4am when i got tired of not knowing the pixel values. i opened adobe and literally looked what the first/last few pixels RGB values were and realized it was...
ohhhh, i see what youre talking about! this is where we have to use the pointer as an array (dynamically allocated storage for arrays)?
that was the problem ~_~ THANK YOU!! deadlines creeping up and thats when mistakes tend to happen ^^;
getting a segmentation fault error that i havent been able to fix in 7 hours. ive looked stuff up and all it says is that it has to do with a reference to a memory location that it cant find/is...
thanks, anduril. that seems to have fixed it (for the moment atleast lol) =D
i had it down in my notes that int=1 byte and char=4.
**EDIT
thanks also, quzah! that was def my problem
not sure, actually. im assuming its an int, part of the binary file info and that its one byte (instructions say each value is a byte)
new issue: reading information from the binary file.
this is the part of my code that reads the values from the file and its output. i know the dimension values are correct, not sure about pixel...
thanks for the clarification, quzah! ^_^
evergrove{83}> gcc -o jpeg_main jpeg_main.c jpeg64.o -ljpeg
evergrove{84}> ./jpeg_main
262146
this works perfectly! thanks!
what does md5sum do? i read up a little on it and it seems its...
Thanks for all the info! Ubuntu it is! =D
Thanks, tabstop and KCfromNC. My ubuntu crapped out yesterday so I'm going to reinstall and try to work through that.
Were being told to compile using
gcc histogram.c jpeg64.o -ljpeg...
im getting the following error
$ gcc jpeg64.o histogram3.o
jpeg64.o: In function `loadJPG':
jpeg.c:(.text+0xa7): undefined reference to `jpeg_std_error'
jpeg.c:(.text+0xc7): undefined...
yup. i have all those files. to compile in windows tho, i need to use
%gcc -ljpeg etc etc but i dont have the -ljpeg extension to compile it
tried renaming to .txt and renaming after copying: no dice.
i tried looking for the class directory in winscp to see if i can get it from the server: no dice either
i guess im kinda stuck until...
yup. def opens in pic viewer.
im connected through putty and use winscp to transfer files over to a dedicated directory on the server. when i try to open the lenna.jpg copy thats copied onto the...
this is what i have so far:
#include <stdio.h>
#include <stdlib.h>
#include "jpeg.h"
int loadJPG(const char* input_file_name, const char* output_file_name);
int main()
if only! class is basically him reading from PPT lectures from the publisher of the book, so it would be great if someone who actually wanted to help us comprehend/understand programming would take...
thanks, quzah. that takes care of that. so what about the .o file?
i follow what the book says (C a modern approach, king, 2ed) and type
gcc -o load histogram.c jpeg32.o Lenna.jpg.
it gives an error
Lenna.jpg: file not recognized: File format not...
the histogram part weve done twice before.
first time, it simply counted how many of each number (from 0-19) appeared in a list. the max number of entries was specified by the user.
second...