Questions tagged [cimg]

The CImg Library is a small, open source, C++ toolkit for image processing.

The CImg Library is a small, open source, C++ toolkit for image processing.

CImg stands for Cool Image: It is easy to use, efficient and is intended to be a very pleasant toolbox to design image processing algorithms in C++. Due to its generic conception, it can cover a wide range of image processing applications.

297 questions
1
vote
1 answer

Does anyone know if I can draw on the image window using CImg and C++?

I'm trying to get user input from the image window using the CImg library and C++. I want the user to draw a shape on the displayed window so I can save and use their data later, but I haven't found anything that resembles what I am trying to do.…
quela
  • 81
  • 7
1
vote
0 answers

How to fix "undefined reference SetDIBitsToDevice", even already linked library "gdi32.lib"?

This is my first time learning about Cimg. I'm trying the code from the Cimg tutorial. I get an error message, "undefined reference to SetDIBitsToDevice@48". I am using CodeBlocks 17.12. I already linked to gdi32.lib from the Windows kit. I used…
henry huang
  • 154
  • 1
  • 6
1
vote
0 answers

how I could encode fast video rgb planar format?

I compile a command and use this command for encode and then speed up the video g++ -Wall -o main lena2.cpp -lpng -lz -lX11 -lpthread -fopenmp -std=c++11 ;./main | ffmpeg -y -f rawvideo -pixel_format gbrp -video_size 1024x768 -i - -c:v h264…
speedy
  • 27
  • 6
1
vote
1 answer

add background image to this code instead black?

I see this code and need add a image of background like this enter image description here how I could do this add a background instead black background please help me I get this code from another question but I dont know how change the…
speedy
  • 27
  • 6
1
vote
1 answer

How can I create a bunch of images overlaying two images quickly?

I'm trying with ImageMagick GraphicsMagick and CImg but it takes 10 minutes to complete 10,000 images. I need to do this in 3 minutes. How I could do this task faster? This is my code: #define cimg_use_png #define cimg_display 0 #include…
newquest
  • 13
  • 6
1
vote
1 answer

Cimg throwing CImgIOException at random

I have some code that runs a bunch of threads in parallel. Each thread execute a function in order to copy a "watermark" over an image loaded from a directory, and save the modified image in another directory, specified by the user. In order to…
g_rmz
  • 721
  • 2
  • 8
  • 20
1
vote
1 answer

The correct way to implement an animation loop in CImg

I am trying to use CImg to visualize my program. I don't want to use OpenGL because I am trying to write a small rendering engine(Just for my own interest, not an assignment!!!). I want to create an animation loop in CImg. This is my loop. while…
1
vote
0 answers

Use CImg.h to write a simple interface

#include "stdafx.h" #include "CImg.h" #include #include "windows.h" #include using namespace cimg_library; using std::cin; using std::cout; int main(){ CImg window(600, 500, 1, 3, 1); //定义一个 长600px…
1
vote
1 answer

CImg.h can't run in Xcode environment

*****Code***** #include "CImg.h" #include using namespace cimg_library; int main() { CImg image("lena.png"); image.display(); return 0; } *****ERROR***** Build successful but stuck…
郭昆鹏
  • 11
  • 3
1
vote
1 answer

How to find a specific shape in a png file in C++?

I'm using CImg and Imagemagick and what I'm trying to do is to write a code in which the program gets the image, searches for particular shapes in it (rectangles or triangles for example), then crops each shape and finally saves them as some other…
mitrafrz
  • 51
  • 6
1
vote
1 answer

Using CImg to draw triangle and fill in color using interpolation

I have to use CImg construct a image and draw a triangle using mid-point algorithm and then color the edges using linear interpolation. I have a hard time understanding the syntax of CImg Library. All I have right now is the black blank…
William
  • 53
  • 10
1
vote
1 answer

X11 Problems when using CImg header in XCode on Mac OSX 10.11.6

I added X11 to my header search paths, library search paths, and I linked the binary to the X11 library in the build settings and build phases in XCode however I am still getting the errors shown in the picture below. I am 99.999% Sure the problem…
1
vote
0 answers

CImg with Eclipse linking error (C++)

I'm trying to run a simple program that uses CImg with Eclipse: #include #include #include "CImg.h" using namespace cimg_library; int main() { // read a jpg image CImg imgin("frog.jpg"); CImg
leqo
  • 356
  • 4
  • 15
1
vote
1 answer

CImg - how to convert interleaved raw data?

I just started using CImg libraries and I would like to test it with raw data, but I am experiencing big problems to figure out why I cannot obtain correct results. My RGB24 raw file format is RGB interleaved (RGBRGBRGB ...) while CImg stores data…
user8688547
1
vote
1 answer

How to compute SVD using Cimg (or maybe openCV or eigen library)?

May anyone give me a quick guide on how to use Cimg to compute SVD for a 3-dimension array? I just want to get the decomposition of the array in order to compress it small for speeding up further process. What value should I input at where, and how…
jihchuan
  • 307
  • 1
  • 5
  • 14