Hi.
I am trying to create a C program that will take a binary file containing over 7000000 different values and store them so that i can process the data. I already have a Matlab program that does this but my aim is to convert this to C to improve the speed of the data processing.
so far I have this that I got from looking on websites etc.
Code:
#include <conio.h>
#include <iostream>
using namespace std;
int main(int argc, char *argv[])
{
FILE *f;
unsigned char buffer[463488];
int n;
f = fopen("C:\\Dev-Cpp\\Project1\\test.fti", "rb");
if (f)
{
n = fread(buffer, 463488, 1, f);
}
else
{
// error opening file
}
getch();
return EXIT_SUCCESS;
}
I am only a beginner programmer so please excuse my limited knowledge but I want to learn.