- Upvotes Received
- 0
- Posts with Upvotes
- 0
- Upvoting Members
- 0
- Downvotes Received
- 3
- Posts with Downvotes
- 3
- Downvoting Members
- 2
10 Posted Topics
Hi, i would like to calculate the execution time of my program. is there any function available to enable it?? | |
hi, i have to rotate an image. the image is stored in an image[rows][cols] array.. i am trying to rotate it using trignometric functions. i am not sure what happens when i rotate the image, does the address of the pixel vary or the value of the pixel vary. and … | |
Re: for starters u can get the image (100x100 pixels) in this way.. then alter the value of each pixel to change the image.. #include <stdio.h> #include <stdlib.h> #include <math.h> #include <conio.h> void main( ) { FILE *fp; unsigned char i[100][100; int m,n; clrscr(); if((fp = fopen("lenna.dat","r+")) == 0) { printf("Just … | |
Hi, i am trying to implement gabor filter for image enhancement. if someone has any code snippet or pseudocode or any idea of implementing it in C, please help me out with it. thanks. | |
hi, i have to do image read and write in Turbo C. i am very new to C. so please help me out as to how to do these operations and provide some sample code if you have any.. i have a vague idea that it can be read as … | |
Re: u can use this code; [code]#include<stdio.h> int main(void) { FILE *fp; unsigned char image[256][256]; int r,c; if((fp = fopen("f16.dat","r+")) == NULL) { printf("Unable to open the specified file.\n"); getch(); exit(1); } else { for(r=0;r<256;r++) { for(c=0;c<256;c++) { image[r][c]=(unsigned char) fgetc (fp); } } fclose(fp); } getch(); return(0); }[/code] you can … | |
Re: one easy way to do it is, declare image and header array; [code] unsigned char Header[0x435],image[256][256]; [/code] and to read image; [code] fread(Header,1,0x435,fp); // copy image header to Header array fseek(fp,0x436,SEEK_SET); // Move file pointer to start of image data fread(image,1,256*256,fp); // read image data and copy to ImageIn1[][] array … | |
Hi, i am using pow command quite frequently in my codes, and i have a feeling that i may be using it incorrectly. foe ex: [CODE]pow(image[x][y],2);[/CODE] image[x][y] is unsigned char and 2 is numeric, so is the arguments ok. [CODE]std_dev=pow(((ur_mean/(R*C))-(im_mean*im_mean)),.5);[/CODE] this a bit complicated, will it work this way? is … | |
hi, in turbo C the maximum array size i am able to specify is array[250][250].. what should i do to enlarge this size to say..array[512][512].. i dont know a thing about memory allocation, so please help me out/.. :-| | |
hi, i am writing an image into an array. well i want to know the difference of having this command 'fprintf(fp1,"\n");' in the following code.. fp1=fopen("f16.raw","w"); for(m=0;m<100;m++) { for(n=0;n<100;n++) { fprintf(fp1,"%c",i[m][n]); } fprintf(fp1,"\n"); :?: } fclose(fp1); how does the statement change the process :?: |