diff --git a/YUVviewer.pro b/YUVviewer.pro index 2d675b6..500010f 100644 --- a/YUVviewer.pro +++ b/YUVviewer.pro @@ -28,17 +28,20 @@ CONFIG += c++11 SOURCES += \ src/YUVviewer.cpp \ src/ImgViewer.cpp \ + src/ImgExport.cpp \ src/YUVdecoder.cpp \ src/configFile.cpp HEADERS += \ src/YUVviewer.h \ src/ImgViewer.h \ + src/ImgExport.h \ src/YUVdecoder.h \ src/configFile.h FORMS += \ src/UI_YUVviewer.ui \ + src/UI_ImgExport.ui \ src/UI_ImgViewer.ui RESOURCES += \ diff --git a/src/ImgExport.cpp b/src/ImgExport.cpp new file mode 100644 index 0000000..1805745 --- /dev/null +++ b/src/ImgExport.cpp @@ -0,0 +1,325 @@ +#include +#include + +#include "ImgExport.h" +#include "ImgViewer.h" + +#include "ui_UI_ImgExport.h" + +ImgExport::ImgExport(QWidget *parent) : + QDialog(parent), + ui(new Ui::ImgExportWindow) +{ + ui->setupUi(this); + + QObject::connect(ui->buttonBox, SIGNAL(accepted()), this, SLOT(buttonBoxAccepted())); + QObject::connect(ui->buttonBox, SIGNAL(rejected()), this, SLOT(buttonBoxRejected())); +} + +ImgExport::~ImgExport() +{ + delete ui; +} + +void ImgExport::showEvent(QShowEvent* event) { + //"png" + ui->f0RadioButton->setChecked(true); + QDialog::showEvent(event); +} + +void ImgExport::buttonBoxAccepted(void) +{ + ImgViewer *iw = static_cast(this->parent()); + int list_index = iw->img_list.indexOf(iw->currentImg_RGB_list); + QList img_RGB_list = iw->img_list[list_index]; + int img_index = img_RGB_list.indexOf(iw->currentImg); + QString name = iw->lastPath + "/" + iw->filelist[list_index].replace(".yuv","-").replace(".data","-").replace(".raw","-") + QString::number(img_index); + + if(ui->f0RadioButton->isChecked()) { + //"png"; + export_png(iw->currentImg,name); + } else if(ui->f1RadioButton->isChecked()) { + //"YV12"; + } else if(ui->f2RadioButton->isChecked()) { + //"YU12/I420"; + } else if(ui->f3RadioButton->isChecked()) { + //"NV21"; + } else if(ui->f4RadioButton->isChecked()) { + //"NV12"; + } else if(ui->f5RadioButton->isChecked()) { + //"YUY2/YUYV"; + } else if(ui->f6RadioButton->isChecked()) { + //"YVYU"; + } else if(ui->f7RadioButton->isChecked()) { + //"UYVY"; + } else if(ui->f8RadioButton->isChecked()) { + //"4:4:4"; + } else if(ui->f9RadioButton->isChecked()) { + //"RGB565_L"; + } else if(ui->f10RadioButton->isChecked()) { + //"RGB565_B"; + } else if(ui->f11RadioButton->isChecked()) { + //"BGR565_L"; + } else if(ui->f12RadioButton->isChecked()) { + //"BGR565_B"; + } else if(ui->f13RadioButton->isChecked()) { + //"RGB888"; + } else if(ui->f14RadioButton->isChecked()) { + //"BayerBG"; + export_bayer(iw->currentImg,"BGGR",8,name); + } else if(ui->f15RadioButton->isChecked()) { + //"BayerGB"; + export_bayer(iw->currentImg,"GBRG",8,name); + } else if(ui->f16RadioButton->isChecked()) { + //"BayerRG"; + export_bayer(iw->currentImg,"RGGB",8,name); + } else if(ui->f17RadioButton->isChecked()) { + //"BayerGR"; + export_bayer(iw->currentImg,"GRBG",8,name); + } else if(ui->f18RadioButton->isChecked()) { + //"BayerBG_RAW10"; + export_bayer(iw->currentImg,"BGGR",10,name); + } else if(ui->f19RadioButton->isChecked()) { + //"BayerGB_RAW10"; + export_bayer(iw->currentImg,"GBRG",10,name); + } else if(ui->f20RadioButton->isChecked()) { + //"BayerRG_RAW10"; + export_bayer(iw->currentImg,"RGGB",10,name); + } else if(ui->f21RadioButton->isChecked()) { + //"BayerGR_RAW10"; + export_bayer(iw->currentImg,"GRBG",10,name); + } else if(ui->f22RadioButton->isChecked()) { + //"BayerBG_RAW12"; + export_bayer(iw->currentImg,"BGGR",12,name); + } else if(ui->f23RadioButton->isChecked()) { + //"BayerGB_RAW12"; + export_bayer(iw->currentImg,"GBRG",12,name); + } else if(ui->f24RadioButton->isChecked()) { + //"BayerRG_RAW12"; + export_bayer(iw->currentImg,"RGGB",12,name); + } else if(ui->f25RadioButton->isChecked()) { + //"BayerGR_RAW12"; + export_bayer(iw->currentImg,"GRBG",12,name); + } else if(ui->f26RadioButton->isChecked()) { + //"BayerBG_RAW16"; + export_bayer(iw->currentImg,"BGGR",16,name); + } else if(ui->f27RadioButton->isChecked()) { + //"BayerGB_RAW16"; + export_bayer(iw->currentImg,"GBRG",16,name); + } else if(ui->f28RadioButton->isChecked()) { + //"BayerRG_RAW16"; + export_bayer(iw->currentImg,"RGGB",16,name); + } else if(ui->f29RadioButton->isChecked()) { + //"BayerGR_RAW16"; + export_bayer(iw->currentImg,"GRBG",16,name); + } + + + emit this->accepted(); +} + +void ImgExport::buttonBoxRejected(void) +{ + emit this->rejected(); +} + +void ImgExport::export_png(QImage *Img, const QString &name) +{ + QString savefile_name = QFileDialog::getSaveFileName(this, "保存文件", name + ".png", "Image files(*.png)"); + if(savefile_name != nullptr) { + Img->save(savefile_name); + } +} + +void ImgExport::export_bayer(QImage *Img, const QString &sequence,int bit, const QString &name) +{ + QMessageBox::warning(this, "Warning", + "导出此格式将通过模拟抽样的方式,图像信息将会出现损失!", + QMessageBox::StandardButtons(QMessageBox::Ok)); + QString savefile_name = QFileDialog::getSaveFileName(this, "保存文件", name + "-bayer" + sequence + QString::number(bit) +".raw", "RAW files(*.raw)"); + if(savefile_name != nullptr) { + QFile save(savefile_name); + if (save.open(QIODevice::WriteOnly)) { + for(int j = 0;j < Img->height();j++) { + if(j%2 == 0) { + for(int i = 0;i < Img->width();i+=4) { + QRgb p0 = Img->pixel(i,j); + QRgb p1 = Img->pixel(i+1,j); + QRgb p2 = Img->pixel(i+2,j); + QRgb p3 = Img->pixel(i+3,j); + + unsigned char B0 = qBlue(p0); + unsigned char G0 = qGreen(p0); + unsigned char R0 = qRed(p0); + unsigned char B1 = qBlue(p1); + unsigned char G1 = qGreen(p1); + unsigned char R1 = qRed(p1); + unsigned char B2 = qBlue(p2); + unsigned char G2 = qGreen(p2); + unsigned char R2 = qRed(p2); + unsigned char B3 = qBlue(p3); + unsigned char G3 = qGreen(p3); + unsigned char R3 = qRed(p3); + + unsigned char P0 = 0; + unsigned char P1 = 0; + unsigned char P2 = 0; + unsigned char P3 = 0; + if(sequence == "BGGR") { + P0 = B0; + P1 = G1; + P2 = B2; + P3 = G3; + } else if(sequence == "RGGB"){ + P0 = R0; + P1 = G1; + P2 = R2; + P3 = G3; + } else if(sequence == "GBRG"){ + P0 = G0; + P1 = B1; + P2 = G2; + P3 = B3; + } else if(sequence == "GRBG"){ + P0 = G0; + P1 = R1; + P2 = G2; + P3 = R3; + } + + if(bit == 8) { + save.write((const char *)&P0,1); + save.write((const char *)&P1,1); + save.write((const char *)&P2,1); + save.write((const char *)&P3,1); + } else if(bit == 10) { + unsigned short P0_10 = P0*4; + unsigned short P1_10 = P1*4; + unsigned short P2_10 = P2*4; + unsigned short P3_10 = P3*4; + unsigned char piexl[5] = { + (unsigned char)(P0_10>>2), + (unsigned char)(P1_10>>2), + (unsigned char)(P2_10>>2), + (unsigned char)(P3_10>>2), + (unsigned char)(((P3_10&0x03)<<6)|((P2_10&0x03)<<4)|((P1_10&0x03)<<2)|(P0_10&0x03)) }; + save.write((const char *)piexl,5); + } else if(bit == 12) { + unsigned short P0_12 = P0*16; + unsigned short P1_12 = P1*16; + unsigned short P2_12 = P2*16; + unsigned short P3_12 = P3*16; + unsigned char piexl[6] = { + (unsigned char)(P0_12>>4), + (unsigned char)(P1_12>>4), + (unsigned char)(((P1_12&0x0f)<<4)|(P0_12&0x0f)), + (unsigned char)(P2_12>>4), + (unsigned char)(P3_12>>4), + (unsigned char)(((P3_12&0x0f)<<4)|(P2_12&0x0f)) + }; + save.write((const char *)piexl,6); + } else if(bit == 16) { + unsigned short P0_16 = P0*256; + unsigned short P1_16 = P1*256; + unsigned short P2_16 = P2*256; + unsigned short P3_16 = P3*256; + save.write((const char *)&P0_16,2); + save.write((const char *)&P1_16,2); + save.write((const char *)&P2_16,2); + save.write((const char *)&P3_16,2); + } + } + } else { + for(int i = 0;i < Img->width();i+=4) { + QRgb p0 = Img->pixel(i,j); + QRgb p1 = Img->pixel(i+1,j); + QRgb p2 = Img->pixel(i+2,j); + QRgb p3 = Img->pixel(i+3,j); + + unsigned char B0 = qBlue(p0); + unsigned char G0 = qGreen(p0); + unsigned char R0 = qRed(p0); + unsigned char B1 = qBlue(p1); + unsigned char G1 = qGreen(p1); + unsigned char R1 = qRed(p1); + unsigned char B2 = qBlue(p2); + unsigned char G2 = qGreen(p2); + unsigned char R2 = qRed(p2); + unsigned char B3 = qBlue(p3); + unsigned char G3 = qGreen(p3); + unsigned char R3 = qRed(p3); + + unsigned char P0 = 0; + unsigned char P1 = 0; + unsigned char P2 = 0; + unsigned char P3 = 0; + if(sequence == "BGGR") { + P0 = G0; + P1 = R1; + P2 = G2; + P3 = R3; + } else if(sequence == "RGGB"){ + P0 = G0; + P1 = B1; + P2 = G2; + P3 = B3; + } else if(sequence == "GBRG"){ + P0 = R0; + P1 = G1; + P2 = R2; + P3 = G3; + } else if(sequence == "GRBG"){ + P0 = B0; + P1 = G1; + P2 = B2; + P3 = G3; + } + + if(bit == 8) { + save.write((const char *)&P0,1); + save.write((const char *)&P1,1); + save.write((const char *)&P2,1); + save.write((const char *)&P3,1); + } else if(bit == 10) { + unsigned short P0_10 = P0*4; + unsigned short P1_10 = P1*4; + unsigned short P2_10 = P2*4; + unsigned short P3_10 = P3*4; + unsigned char piexl[5] = { + (unsigned char)(P0_10>>2), + (unsigned char)(P1_10>>2), + (unsigned char)(P2_10>>2), + (unsigned char)(P3_10>>2), + (unsigned char)(((P3_10&0x03)<<6)|((P2_10&0x03)<<4)|((P1_10&0x03)<<2)|(P0_10&0x03)) }; + save.write((const char *)piexl,5); + } else if(bit == 12) { + unsigned short P0_12 = P0*16; + unsigned short P1_12 = P1*16; + unsigned short P2_12 = P2*16; + unsigned short P3_12 = P3*16; + unsigned char piexl[6] = { + (unsigned char)(P0_12>>4), + (unsigned char)(P1_12>>4), + (unsigned char)(((P1_12&0x0f)<<4)|(P0_12&0x0f)), + (unsigned char)(P2_12>>4), + (unsigned char)(P3_12>>4), + (unsigned char)(((P3_12&0x0f)<<4)|(P2_12&0x0f)) + }; + save.write((const char *)piexl,6); + } else if(bit == 16) { + unsigned short P0_16 = P0*256; + unsigned short P1_16 = P1*256; + unsigned short P2_16 = P2*256; + unsigned short P3_16 = P3*256; + save.write((const char *)&P0_16,2); + save.write((const char *)&P1_16,2); + save.write((const char *)&P2_16,2); + save.write((const char *)&P3_16,2); + } + } + } + } + save.close(); + } + } +} diff --git a/src/ImgExport.h b/src/ImgExport.h new file mode 100644 index 0000000..32b460c --- /dev/null +++ b/src/ImgExport.h @@ -0,0 +1,31 @@ +#ifndef BOOTSELECTBOX_H +#define BOOTSELECTBOX_H + +#include + +namespace Ui { +class ImgExportWindow; +} + +class ImgExport : public QDialog +{ + Q_OBJECT + +public: + explicit ImgExport(QWidget *parent = nullptr); + ~ImgExport(); + void export_png(QImage *Img, const QString &name); + void export_bayer(QImage *Img, const QString &sequence,int bit, const QString &fileName); + +protected: + void showEvent(QShowEvent* event) override; + +private slots: + void buttonBoxAccepted(void); + void buttonBoxRejected(void); + +private: + Ui::ImgExportWindow *ui; +}; + +#endif // BOOTSELECTBOX_H diff --git a/src/ImgViewer.cpp b/src/ImgViewer.cpp index 4e5fad8..e5a1c68 100644 --- a/src/ImgViewer.cpp +++ b/src/ImgViewer.cpp @@ -66,6 +66,7 @@ ImgViewer::ImgViewer(QWidget *parent,QWidget *parentWindow) : ui->setupUi(this); qRegisterMetaType>("QList"); this->parentWindow = parentWindow; + imgExportWindow = new ImgExport(this); setWindowTitle("loading file, please wait ...."); ui->left_PushButton->setFlat(true); ui->right_PushButton->setFlat(true); @@ -75,6 +76,7 @@ ImgViewer::ImgViewer(QWidget *parent,QWidget *parentWindow) : } ImgViewer::~ImgViewer() { + delete imgExportWindow; delete ui; } @@ -254,13 +256,7 @@ void ImgViewer::mouseReleaseEvent(QMouseEvent *event) { void ImgViewer::mouseDoubleClickEvent(QMouseEvent *event) { if (!this->img_list.empty()) { if( event->button() == Qt::LeftButton) { - int list_index = this->img_list.indexOf(this->currentImg_RGB_list); - QList img_RGB_list = this->img_list[list_index]; - int img_index = img_RGB_list.indexOf(this->currentImg); - QString savefile_name = QFileDialog::getSaveFileName(this, "保存文件", this->filelist[list_index].replace(".yuv","-") + QString::number(img_index) + ".png", "Image files(*.png)"); - if(savefile_name != nullptr) { - this->currentImg->save(savefile_name); - } + imgExportWindow->show(); } else if(event->button() == Qt::RightButton) { this->flipRGB = this->flipRGB ? false : true; this->point = QPoint(0, 0); diff --git a/src/ImgViewer.h b/src/ImgViewer.h index 04cff4c..c9237d3 100644 --- a/src/ImgViewer.h +++ b/src/ImgViewer.h @@ -17,6 +17,7 @@ #include #include #include +#include "ImgExport.h" #include "YUVdecoder.h" namespace Ui { @@ -60,6 +61,12 @@ class ImgViewer : public QWidget { bool setFileList(QStringList filelist,QString YUVFormat, int W, int H, int startframe, int totalframe); bool setFileList_multithreading(QStringList filenamelist, QString YUVFormat, int W, int H, int startframe, int totalframe); + QImage *currentImg; + QList> img_list; + QStringList filelist; + QList currentImg_RGB_list; + QString lastPath; + private slots: void reciveimgdata(QList img_RGB_list, QString filename); void previousImg(); @@ -78,17 +85,16 @@ private slots: private: void draw_img(QPainter *painter); Ui::ImgViewerWindow *ui; + ImgExport *imgExportWindow; QWidget *parentWindow; bool left_click; - QList> img_list; - QStringList filelist; + QList decode_thread; QList decode_thread_finsh; - QList currentImg_RGB_list; - QImage *currentImg; + QImage scaled_img; QPoint point; QPoint startPos; diff --git a/src/UI_ImgExport.ui b/src/UI_ImgExport.ui new file mode 100644 index 0000000..c0a0e6d --- /dev/null +++ b/src/UI_ImgExport.ui @@ -0,0 +1,383 @@ + + + ImgExportWindow + + + + 0 + 0 + 507 + 538 + + + + Format + + + + + + File Format + + + + + + + + png + + + + + + + false + + + YV12 + + + + + + + false + + + YU12/I420 + + + + + + + false + + + NV21 + + + + + + + false + + + NV12 + + + + + + + false + + + YUY2/YUYV + + + + + + + false + + + YVYU + + + + + + + false + + + UYVY + + + + + + + false + + + 4:4:4 + + + + + + + false + + + RGB565_L + + + + + + + + + + + false + + + RGB565_B + + + + + + + false + + + BGR565_L + + + + + + + false + + + BGR565_B + + + + + + + false + + + RGB888 + + + + + + + true + + + BayerBG + + + + + + + true + + + BayerGB + + + + + + + true + + + BayerRG + + + + + + + true + + + BayerGR + + + + + + + true + + + BayerBG_RAW10 + + + + + + + true + + + BayerGB_RAW10 + + + + + + + + + + + true + + + BayerRG_RAW10 + + + + + + + true + + + BayerGR_RAW10 + + + + + + + BayerBG_RAW12 + + + + + + + BayerGB_RAW12 + + + + + + + BayerRG_RAW12 + + + + + + + BayerGR_RAW12 + + + + + + + true + + + BayerBG_RAW16 + + + + + + + true + + + BayerGB_RAW16 + + + + + + + true + + + BayerRG_RAW16 + + + + + + + true + + + BayerGR_RAW16 + + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + Qt::Horizontal + + + QDialogButtonBox::Cancel|QDialogButtonBox::Ok + + + + + + + + + buttonBox + accepted() + ImgExportWindow + accept() + + + 248 + 254 + + + 157 + 274 + + + + + buttonBox + rejected() + ImgExportWindow + reject() + + + 316 + 260 + + + 286 + 274 + + + + + diff --git a/src/YUVdecoder.cpp b/src/YUVdecoder.cpp index eb50ff9..40b6948 100644 --- a/src/YUVdecoder.cpp +++ b/src/YUVdecoder.cpp @@ -357,59 +357,62 @@ QList ImageDecoder::bayer(const QString &yuvfilename,int W, int H, int file.open(QFile::ReadOnly); file.seek(startframe*W*H); QDataStream out(&file); - char *temp = nullptr; + uint8_t *temp = nullptr; switch (bit) { case 8: + temp = new uint8_t[W*H]; break; case 10: - temp = new char[W*H*5/4]; + temp = new uint8_t[W*H*5/4]; break; case 12: - temp = new char[W*H*3/2]; + temp = new uint8_t[W*H*3/2]; break; case 16: - temp = new char[W*H*2]; - break; - default: + temp = new uint8_t[W*H*2]; break; } while((!out.atEnd()) && (totalframe != 0)) { cv::Mat *rgbImg = new cv::Mat; - yuvImg.create(H, W, CV_8UC1); + yuvImg.create(H, W, CV_8U); + uint8_t * dest = (uint8_t *)yuvImg.data; switch (bit) { case 8: { - out.readRawData((char *)yuvImg.data,W*H); + out.readRawData((char *)temp,W*H); + for(int i=0;i>2)&0x3))/4); - yuvImg.data[j+2] = (uint8_t)(((piex[2]<<2) | ((piex[4]>>2)&0x3))/4); - yuvImg.data[j+3] = (uint8_t)(((piex[3]<<2) | ((piex[4]>>2)&0x3))/4); + dest[j+0] = (uint8_t)(((piex[0]<<2) | ((piex[4]>>0)&0x3))/4); + dest[j+1] = (uint8_t)(((piex[1]<<2) | ((piex[4]>>2)&0x3))/4); + dest[j+2] = (uint8_t)(((piex[2]<<2) | ((piex[4]>>4)&0x3))/4); + dest[j+3] = (uint8_t)(((piex[3]<<2) | ((piex[4]>>6)&0x3))/4); j+=4; } break; } case 12: { - out.readRawData(temp,W*H*3/2); + out.readRawData((char *)temp,W*H*3/2); for(int i=0,j=0;i>4)&0xf))/16); + dest[j+0] = (uint8_t)(((piex[0]<<4) | ((piex[2]>>0)&0xf))/16); + dest[j+1] = (uint8_t)(((piex[1]<<4) | ((piex[2]>>4)&0xf))/16); j+=2; } break; } case 16: { - out.readRawData(temp,W*H*2); + out.readRawData((char *)temp,W*H*2); for(int i=0,j=0;i ImageDecoder::bayer(const QString &yuvfilename,int W, int H, int rgbImglist.insert(rgbImglist.constEnd(), rgbImg); } - switch (bit) { - case 8: - break; - case 10: - case 12: - case 16: - delete[] temp; - break; - default: - break; - } - + delete[] temp; file.close(); return rgbImglist; diff --git a/src/YUVviewer.cpp b/src/YUVviewer.cpp index f8a3e9b..899e2b6 100644 --- a/src/YUVviewer.cpp +++ b/src/YUVviewer.cpp @@ -522,7 +522,7 @@ bool YUVviewer::updateConfig(void) { } } -bool YUVviewer::imgView(QStringList openfile_list) { +bool YUVviewer::imgView(QStringList openfile_list, const QString &folderpath) { if (openfile_list.empty()) { return false; } @@ -531,6 +531,7 @@ bool YUVviewer::imgView(QStringList openfile_list) { imgViewer = nullptr; } imgViewer = new ImgViewer(nullptr,this); + imgViewer->lastPath = folderpath; int startFrame = ui->startFrame_LineEdit->text().toInt(); int endFrame = ui->endFrame_LineEdit->text().toInt(); int frameSize_Width = ui->frameSize_Width_LineEdit->text().toInt(); @@ -586,7 +587,7 @@ void YUVviewer::openFile() { if(openfile_list.size() != 0) { QFileInfo file(openfile_list[0]); YUVviewerConfigFile->config_dict.lastPath = file.absolutePath(); - imgView(openfile_list); + imgView(openfile_list,file.absolutePath()); } } } @@ -609,7 +610,7 @@ void YUVviewer::openFolder() { openfile_list.append(QDir::toNativeSeparators(openfolder_name + '/' +file_name)); } if(openfile_list.size() != 0) { - imgView(openfile_list); + imgView(openfile_list,openfolder_name); } } } diff --git a/src/YUVviewer.h b/src/YUVviewer.h index 40a77ad..4f85719 100644 --- a/src/YUVviewer.h +++ b/src/YUVviewer.h @@ -54,7 +54,7 @@ private slots: void updateUiSvg(QList color_list); void showParaErrMessageBox(void); bool updateConfig(void); - bool imgView(QStringList openfile_list); + bool imgView(QStringList openfile_list, const QString &folderpath); Ui::YUVviewer *ui; ConfigFile *YUVviewerConfigFile; ImgViewer *imgViewer; diff --git a/test/640x480_BayerBG10.data b/test/640x480_BayerBG10.data new file mode 100644 index 0000000..a5b6265 Binary files /dev/null and b/test/640x480_BayerBG10.data differ diff --git a/test/640x480_BayerBGRAW12.data b/test/640x480_BayerBG12.data similarity index 100% rename from test/640x480_BayerBGRAW12.data rename to test/640x480_BayerBG12.data diff --git a/test/640x480_BayerBG16.data b/test/640x480_BayerBG16.data new file mode 100644 index 0000000..c2d7954 Binary files /dev/null and b/test/640x480_BayerBG16.data differ diff --git a/test/640x480_BayerGB10.data b/test/640x480_BayerGB10.data new file mode 100644 index 0000000..e3d44f8 Binary files /dev/null and b/test/640x480_BayerGB10.data differ diff --git a/test/640x480_BayerGBRAW12.data b/test/640x480_BayerGB12.data similarity index 100% rename from test/640x480_BayerGBRAW12.data rename to test/640x480_BayerGB12.data diff --git a/test/640x480_BayerGB16.data b/test/640x480_BayerGB16.data new file mode 100644 index 0000000..98d3861 Binary files /dev/null and b/test/640x480_BayerGB16.data differ diff --git a/test/640x480_BayerGR10.data b/test/640x480_BayerGR10.data new file mode 100644 index 0000000..db074d0 Binary files /dev/null and b/test/640x480_BayerGR10.data differ diff --git a/test/640x480_BayerGRRAW12.data b/test/640x480_BayerGR12.data similarity index 100% rename from test/640x480_BayerGRRAW12.data rename to test/640x480_BayerGR12.data diff --git a/test/640x480_BayerGR16.data b/test/640x480_BayerGR16.data new file mode 100644 index 0000000..195e468 Binary files /dev/null and b/test/640x480_BayerGR16.data differ diff --git a/test/640x480_BayerRG10.data b/test/640x480_BayerRG10.data new file mode 100644 index 0000000..2db695e Binary files /dev/null and b/test/640x480_BayerRG10.data differ diff --git a/test/640x480_BayerRGRAW12.data b/test/640x480_BayerRG12.data similarity index 100% rename from test/640x480_BayerRGRAW12.data rename to test/640x480_BayerRG12.data diff --git a/test/640x480_BayerRG16.data b/test/640x480_BayerRG16.data new file mode 100644 index 0000000..09df274 Binary files /dev/null and b/test/640x480_BayerRG16.data differ