Thank you! Your feedback has been delivered
Thank you! Your feedback has been sent

Generate a C++ DLL to create a QR Code

I need a C++ DLL created that will have a single method that takes a string and returns a QR Code that contains the String.

The method needs to take a string and the size of the code in Pixels.

As an example I would call the Method with "Hello World", 5 and a code would be generated that looks as follows:

Qr Code

Note the Z in the middle of the code. That needs to be on every code generated by the dll and must resize with the code generated.

User Gravatar

markhewson

Posted Jun 19 2014 3:49 UTC

$100


  • Assigned To Deleted User
  • Solved
  • c++
    qrcode
    imaging
  • 4476 Views

5 Replies


Hi Mark,

Could you please elaborate on the following questions?

  1. Do you need the actual source code or just the DLL?
  2. How would you like the code to be outputted? In what format?
  3. Would you like this exact "Z" logo, as shown in the picture to be rendered on top of the code? If so can you please add a link to its file?
  4. On what operating system would the code run?
  5. Are external libraries allowed? For example this one - http://fukuchi.org/works/qrencode/

Thank you!

CodersClan Team.

User Gravatar

CodersClan

Posted Jun 19 2014 11:56 UTC

1) Do you need the actual source code or just the DLL? The actual code and a compiled DLL 2) How would you like the code to be outputted? In what format? .PNG format please 3) Would you like this exact "Z" logo, as shown in the picture to be rendered on top of the code? If so can you please add a link to its file? Yes please enter image description here 4) On what operating system would the code run? Windows 7 and 8 5) Are external libraries allowed? For example this one - http://fukuchi.org/works/qrencode/ Yes, no problem.

Thanks,

Mark

User Gravatar

markhewson

Posted Jun 20 2014 6:34 UTC

I have it done and working here: http://haikarainen.1.ai/strtoqr.zip

Proof that it's working: http://haikarainen.1.ai/generatedqrcode.png

The above image was generated with a simple line of code:

StrToQr("This is now encoded", 64);

The method is defined as follows:

std::string DLL_EXPORT StrToQr(const std::string &toEncode, unsigned int square_size);

Where toEncode is the string to encode, square_size is the width (and height) of the final image, and it returns the filename of the image (which is currently hardcoded to generatedqrcode.png)

logo.png needs to be accessible from the linking application at runtime.

User Gravatar

Deleted User

Posted Jun 23 2014 17:46 UTC

Solution

This didn't solve your task? Get your own custom solution.

Forgot to mention it depends on http://fukuchi.org/works/qrencode/ and SFML, the DLL is compiled with mingw32-gcc 4.8.1 but it should compile fine under visual studio as well.

User Gravatar

Deleted User

Posted Jun 23 2014 17:49 UTC

Sorry for the delay. I've been away.

This is perfect thanks so much

User Gravatar

markhewson

Posted Jul 6 2014 4:58 UTC

Add a reply

By posting a reply on CodersClan you agree to our Terms & Conditions