using CImg in cpp - c++

i'm trying to open image file for an university project using the CImg library.
when trying to load a png file, i get a message that the format file is not supported.
after some reading, i tried to install ImageMagick++ and add it as a dependency to my Visual Studio project following this post: http://www.imagemagick.org/discourse-server/viewtopic.php?t=30295
but it still doesn't work.
how do i add magick++ to my project? (even without the CImg library) is fine.

Related

Including TensorFlow into JUCE project

I am trying to include the TensorFlow C Library in my JUCE project. Until now, with no luck.
When following the TensorFlow guide on how to install the library for C I get lost after the extraction part (developing with Windows). I Add the files inside the include folder to my project using the Projucer. The library with the dll and lib file is added as well. When running Visual Studio, however, there are some includes not inside the provided include folder. My guess is, that I need to link the included library with the full TensorFlow blackened.
Did anyone manage to include TensorFlow inside a JUCE project?
Tutorials I've looked at already:
https://www.tensorflow.org/install/lang_c
https://forum.juce.com/t/has-anyone-managed-to-integrate-tensorflow-api-in-a-juce-project/28019
How to use the tensorflow 2.0 C API?

Linking libjpeg to an xCode project for iOS dev

Good evening,
I have been working on a C++ project from someone of my University which I had to improve for my Bachelor thesis. It basically uses the library libjpeg to do some computation resulting in a steganographic process in order to embed a message into a given image.
Now that the C++ code works smoothly, I'd like to create a little iOS app allowing the user to encrypt whatever message he'd like into an image of his choice. So I created an xCode project following this procedure: using c++ in an iOS app
I also found the following file: libjpeg for iOS which allowed me to compile libjpeg for iOS. Since I'm not so sure how to use the framework freshly created and couldn't find anything sufficiently convincing on the internet, I put all the files (.c and .h) of the libjpeg library into my "include" folder where I have my own .hpp.
xCode only throws me the following error:
xCode error
From what I could gather on several posts, I have to modify the build options of my xCode project to link manually the library, so I tried the following:
Other linking flags
Library search path
This wasn't enough to do the trick and I'm still struggling with the same error xCode throws at me. Any help would be very appreciated on how to proceed!
Thanks a lot,
Theo.
Do not add the .c files to your project, add the libjpeg.a file produced by your build to your project. Add the .h files as you are already doing, or edit the project settings to include their containing folder in the search path.
HTH

FlyCapture2.h: No such file or directory

I am trying to read images from a ptgrey camera on Ubuntu with OpenCV. I have installed the SDK and the SDK samples work.
I am unable to run the samples from ptgrey regarding the image conversion. I have the cpp files but I get the above error when I run the make file.
What should I add to my CMakeLists.txt to detect the FlyCapture2.h file?

ImageMagick ++ Read Error ErrorMissingDelegate

I have downloaded and installed ImageMagick++ from http://www.imagemagick.org/Magick++/.
I am using Windows7 32 bit and Visual Studio 2008. I want to use the ImageMagick in an existing project. I made the required/suggested changes to my project properties like adding dependencies etc. I added three libraries in the additional dependencies (CORE_RL_Magick++_.lib,CORE_RL_MagickCore_.lib and CORE_RL_MagickWand_.lib
I added
<Magick++.h> header file and
using namespace Magick
Then
Magick:: Image image (No error)
image.read("5.png") throws an error "ErrorMissingDelegate at memorry location ....".
I tried other image formats also, but same error.
Please help.

Should I install jpeg library when I use Generic Image Library in BOOST

I have a question related to Generic Image Library in BOOST. At the beginning of using the library, I try to read a jpeg image using the following codes:
rgb8_image_t img;
jpeg_read_image("test.jpg",img);
However, when I compile the codes, I have the following error:
error C1083: Cannot open include file: 'jpeglib.h': No such file or directory
I find the jpeglib.h is not a file inside the library, and therefore I think it is mandatory to install the jpeg library when using this library. However, when very little information about it can be found in the Internet. I am now using the library with VC10 in the windows environment, and should I compile the JPEG library before using the Generic Image Library? Furthermore, should I compile the JPEG library statically or dynamically? Where should I put the library inside the Generic Image Library?
I think that your answer can be found here.
It looks like you don't need to compile libjpeg before boost, but you do need to have it available when building code that uses the jpeg I/O functions.
I ran into the same problem. boost GIL is closely tied to a separate, external library from www.ijg.org (seems like mostly Germans). For Microsoft platforms,
I found there is no installer - you have to compile the source code. And worse
for me, there are some Visual Studio configuration files, but not for v. 8.
So I made my own solution/project from scratch. Don't be alarmed, it's not
so bad. It readily compiles. Briefly, here's how:
[1] download the source code zip file jpegsr9b.zip, from www.ijg.org.
[2] make a simple console-based Visual Studio project ("jconfig") somewhere in the directory where you unpacked the source tree. Add just 1 source code file: ckconfig.c. Compile and run the program. It will make a header file, jconfig.h. Copy or move this file into the main source code directory - there is only 1 directory containing source code in this package.
[3] make another Visual Studio project that will create the library for the JPG package. Configure the project to make a library (I assume you know how), and include the JPG package source code directory in the "Additional Include Directories" configuration parameter.
[4] Include all the source code files (they are all .c files), except the following: rdjpgcom.c, wrjpgcom.c, and jpegtran.c. These files are standalone programs (each with main() -obviously you don't want them in a library).
[5] exclude 2 of the following files (ie, include only 1 of these files): jmemname.c, jmemnobs.c, or jmemansi.c. They contain a different implementations of a "memory manager". I used jmemnobs.c, as the comments indicated it was the simplest implementation, and I just wanted the code to work and was in a hurry. So, in other words, if you did step [4] and included all .c files, now take out 2 of the 3 files listed from your main project file.
[6] build the library. It is completely standalone, so all the files should compile fine.