OpenCores
URL https://opencores.org/ocsvn/mb-jpeg/mb-jpeg/trunk

Subversion Repositories mb-jpeg

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /
    from Rev 18 to Rev 19
    Reverse comparison

Rev 18 → Rev 19

/trunk/encoder/main.c
11,7 → 11,9
 
#include <stdio.h>
#include <stdlib.h>
#ifndef __MICROBLAZE
#include <windows.h>
#endif
#include "zzq.h"
#include "io.h"
#include "huffman.h"
18,6 → 20,7
#include "dct.h"
#pragma hdrstop
 
 
//---------------------------------------------------------------------------
 
INFOHEADER _bmpheader;
42,7 → 45,9
FILE *infile, *outfile;
INFOHEADER *bmpheader;
JPEGHEADER *jpegheader;
#ifndef __MICROBLAZE
LARGE_INTEGER st, en;
#endif
unsigned int col, cols, row, rows, remaining,component;
unsigned char amount_remaining, Ydcvalue, Cbdcvalue, Crdcvalue ;
 
82,7 → 87,9
}
else { //start codec
outfile = fopen(argv[2],"wb");
#ifndef __MICROBLAZE
QueryPerformanceCounter(&st);
#endif
if(encode) { //encode infile to JPEG
if (getbmpheader(infile,bmpheader)) { //File is a valid BMP
printf("\nImage width: %d pixels", bmpheader->width);
150,8 → 157,10
fprintf(outfile,"0x%x, ",header[i]);
fclose(outfile);
fclose(infile); */
#ifndef __MICROBLAZE
QueryPerformanceCounter(&en);
printf("\nExecution time: %f seconds",(double)(en.QuadPart-st.QuadPart)/1000000);
#endif
// free(bmpheader);
}
printf("\n\nHit ENTER to close this window.");

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.