37 #include <Base/Image/Image.hh>
38 #include <Base/Image/ImageIO.hh>
39 #include <Base/ImageUtils/ImageDraw.hh>
40 #include <Base/Image/ColourRGB.hh>
47 int main(
int argc,
char** argv ){
50 if (argc>=2)
if (strcmp(argv[1],
"-darttest")==0) {
52 std::cout<<
"started dart test: "<<argv[0]<<std::endl;
57 string filename( BIAS_TESTS_DATA
"r4.jpg" );
58 if (!darttest && (argc>1)) filename=argv[1];
61 cout<<
"error loading image "<<filename<<endl;
64 cout<<
"loaded image "<<filename<<
" with dim: "<<img.
GetWidth()<<
"x"<<img.
GetHeight()<<endl;
102 CV_FONT_HERSHEY_SIMPLEX, 1.5, 1.5, 0, 2, CV_AA);
104 CV_FONT_HERSHEY_PLAIN, 0.8, 1.2, 0, 1, CV_AA);
110 string outFn(
"out_ExampleIplImageDraw.jpg");
114 if (result==0) cout<<
"wrote "<<outFn<<endl;
123 <<
"<DartMeasurementFile name=\"outputImage1\" type=\"image/jpeg\">"<<outFn<<
"</DartMeasurementFile>"
unsigned int GetWidth() const
unsigned int GetHeight() const
static int Save(const std::string &filename, const ImageBase &img, const enum TFileFormat FileFormat=FF_auto, const bool sync=BIAS_DEFAULT_SYNC, const int c_jpeg_quality=BIAS_DEFAULT_IMAGE_QUALITY, const bool forceNewID=BIAS_DEFAULT_FORCENEWID, const bool &writeMetaData=true)
Export image as file using extrnal libs.
static int Load(const std::string &FileName, ImageBase &img)
first tries a call to Read MIP image and if that fails, tries to Import Image with all other availabl...
drawing simple entities into the image like rectangles or lines As all functions are static they have...