Giter Club home page Giter Club logo

qrcoder's Introduction

QRCoder

Build Code coverage Build status NuGet Package
Latest / Stable codecov Build, test, pack, push (Release) NuGet Badge
CI / Last commit codecov Build, test, pack, push (CI) Github packages

Info

QRCoder is a simple library, written in C#.NET, which enables you to create QR codes. It hasn't any dependencies to external libraries1, is available as package on NuGet and supports .NET Framework, .NET Core, .NET Standard and .NET. A full list of supported target frameworks can be found here.

Feel free to grab-up/fork the project and make it better!

For more information see: QRCode Wiki | Creator's blog (english) | Creator's blog (german)

Release Notes

The release notes for the current and all past releases can be read here: 📄 Release Notes

Legal information and credits

QRCoder is a project by Raffael Herrmann and was first released in 10/2013. It's licensed under the MIT license.


Installation

Either checkout this Github repository or install QRCoder via NuGet Package Manager. If you want to use NuGet just search for "QRCoder" or run the following command in the NuGet Package Manager console:

PM> Install-Package QRCoder

CI builds

The NuGet feed contains only major/stable releases. If you want the latest functions and features, you can use the CI builds via Github packages. (More information on how to use Github Packages in Nuget Package Manager can be found here.)

Usage

You only need a couple lines of code, to generate your first QR code.

QRCodeGenerator qrGenerator = new QRCodeGenerator();
QRCodeData qrCodeData = qrGenerator.CreateQrCode("The text which should be encoded.", QRCodeGenerator.ECCLevel.Q);
QRCode qrCode = new PngByteQRCode(qrCodeData);
byte[] qrCodeImage = qrCode.GetGraphic(20);

There are a plenty of other options. So feel free to read more on that in our wiki: Wiki: How to use QRCoder

Special rendering types

Besides the normal PngByteQRCode-class (which is shown in the example above) for creating QR codes in Bitmap format, there are some more QR code rendering classes, each for another special purpose.

Note: Please be aware that not all renderers are available on all target frameworks. Please check the compatibility table in our wiki, to see if a specific renderer is available on your favourite target framework.

For more information about the different rendering types click on one of the types in the list above or have a look at: Wiki: Advanced usage - QR-Code renderers

PayloadGenerator.cs - Generate QR code payloads

Technically QR code is just a visual representation of a text/string. Nevertheless most QR code readers can read "special" QR codes which trigger different actions.

For example: WiFi-QRcodes which, when scanned by smartphone, let the smartphone join an access point automatically.

This "special" QR codes are generated by using special structured payload string, when generating the QR code. The PayloadGenerator.cs class helps you to generate this payload strings. To generate a WiFi payload for example, you need just this one line of code:

PayloadGenerator.WiFi wifiPayload = new PayloadGenerator.WiFi("MyWiFi-SSID", "MyWiFi-Pass", PayloadGenerator.WiFi.Authentication.WPA);

To generate a QR code from this payload, just call the "ToString()"-method and pass it to the QRCoder.

//[...]
QRCodeData qrCodeData = qrGenerator.CreateQrCode(wifiPayload.ToString(), QRCodeGenerator.ECCLevel.Q);
//[...]

You can also use overloaded method that accepts Payload as parameter. Payload generator can have QR Code Version set (default is auto set), ECC Level (default is M) and ECI mode (default is automatic detection).

//[...]
QRCodeData qrCodeData = qrGenerator.CreateQrCode(wifiPayload);
//[...]

Or if you want to override ECC Level set by Payload generator, you can use overloaded method, that allows setting ECC Level.

//[...]
QRCodeData qrCodeData = qrGenerator.CreateQrCode(wifiPayload, QRCodeGenerator.ECCLevel.Q);
//[...]

You can learn more about the payload generator in our Wiki.

The PayloadGenerator supports the following types of payloads:


(1) Depending on the targeted framework the .NET libraries System.Drawing.Common and System.Text.Encoding.CodePages will used as package dependencies.

qrcoder's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qrcoder's Issues

CreateAntilogTable generates an exception

Hello,

I compiled master source code and tried to generate a bitmap; the method CreateAntilogTable systematically generates an overflow exception whenever variable i is greater than 30.
My workaround is the following:

private static List<Antilog> galoisField = new List<Antilog>() { 
            new Antilog (0, 1),
            new Antilog (1, 2),
            new Antilog (2, 4),
            new Antilog (3, 8),
            new Antilog (4, 16),
            new Antilog (5, 32),
            new Antilog (6, 64),
            new Antilog (7, 128),
            new Antilog (8, 29),
            new Antilog (9, 58),
            new Antilog (10, 116),
            new Antilog (11, 232),
            new Antilog (12, 205),
            new Antilog (13, 135),
            new Antilog (14, 19),
            new Antilog (15, 38),
            new Antilog (16, 76),
            new Antilog (17, 152),
            new Antilog (18, 45),
            new Antilog (19, 90),
            new Antilog (20, 180),
            new Antilog (21, 117),
            new Antilog (22, 234),
            new Antilog (23, 201),
            new Antilog (24, 143),
            new Antilog (25, 3),
            new Antilog (26, 6),
            new Antilog (27, 12),
            new Antilog (28, 24),
            new Antilog (29, 48),
            new Antilog (30, 96),
            new Antilog (31, 192),
            new Antilog (32, 157),
            new Antilog (33, 39),
            new Antilog (34, 78),
            new Antilog (35, 156),
            new Antilog (36, 37),
            new Antilog (37, 74),
            new Antilog (38, 148),
            new Antilog (39, 53),
            new Antilog (40, 106),
            new Antilog (41, 212),
            new Antilog (42, 181),
            new Antilog (43, 119),
            new Antilog (44, 238),
            new Antilog (45, 193),
            new Antilog (46, 159),
            new Antilog (47, 35),
            new Antilog (48, 70),
            new Antilog (49, 140),
            new Antilog (50, 5),
            new Antilog (51, 10),
            new Antilog (52, 20),
            new Antilog (53, 40),
            new Antilog (54, 80),
            new Antilog (55, 160),
            new Antilog (56, 93),
            new Antilog (57, 186),
            new Antilog (58, 105),
            new Antilog (59, 210),
            new Antilog (60, 185),
            new Antilog (61, 111),
            new Antilog (62, 222),
            new Antilog (63, 161),
            new Antilog (64, 95),
            new Antilog (65, 190),
            new Antilog (66, 97),
            new Antilog (67, 194),
            new Antilog (68, 153),
            new Antilog (69, 47),
            new Antilog (70, 94),
            new Antilog (71, 188),
            new Antilog (72, 101),
            new Antilog (73, 202),
            new Antilog (74, 137),
            new Antilog (75, 15),
            new Antilog (76, 30),
            new Antilog (77, 60),
            new Antilog (78, 120),
            new Antilog (79, 240),
            new Antilog (80, 253),
            new Antilog (81, 231),
            new Antilog (82, 211),
            new Antilog (83, 187),
            new Antilog (84, 107),
            new Antilog (85, 214),
            new Antilog (86, 177),
            new Antilog (87, 127),
            new Antilog (88, 254),
            new Antilog (89, 225),
            new Antilog (90, 223),
            new Antilog (91, 163),
            new Antilog (92, 91),
            new Antilog (93, 182),
            new Antilog (94, 113),
            new Antilog (95, 226),
            new Antilog (96, 217),
            new Antilog (97, 175),
            new Antilog (98, 67),
            new Antilog (99, 134),
            new Antilog (100, 17),
            new Antilog (101, 34),
            new Antilog (102, 68),
            new Antilog (103, 136),
            new Antilog (104, 13),
            new Antilog (105, 26),
            new Antilog (106, 52),
            new Antilog (107, 104),
            new Antilog (108, 208),
            new Antilog (109, 189),
            new Antilog (110, 103),
            new Antilog (111, 206),
            new Antilog (112, 129),
            new Antilog (113, 31),
            new Antilog (114, 62),
            new Antilog (115, 124),
            new Antilog (116, 248),
            new Antilog (117, 237),
            new Antilog (118, 199),
            new Antilog (119, 147),
            new Antilog (120, 59),
            new Antilog (121, 118),
            new Antilog (122, 236),
            new Antilog (123, 197),
            new Antilog (124, 151),
            new Antilog (125, 51),
            new Antilog (126, 102),
            new Antilog (127, 204),
            new Antilog (128, 133),
            new Antilog (129, 23),
            new Antilog (130, 46),
            new Antilog (131, 92),
            new Antilog (132, 184),
            new Antilog (133, 109),
            new Antilog (134, 218),
            new Antilog (135, 169),
            new Antilog (136, 79),
            new Antilog (137, 158),
            new Antilog (138, 33),
            new Antilog (139, 66),
            new Antilog (140, 132),
            new Antilog (141, 21),
            new Antilog (142, 42),
            new Antilog (143, 84),
            new Antilog (144, 168),
            new Antilog (145, 77),
            new Antilog (146, 154),
            new Antilog (147, 41),
            new Antilog (148, 82),
            new Antilog (149, 164),
            new Antilog (150, 85),
            new Antilog (151, 170),
            new Antilog (152, 73),
            new Antilog (153, 146),
            new Antilog (154, 57),
            new Antilog (155, 114),
            new Antilog (156, 228),
            new Antilog (157, 213),
            new Antilog (158, 183),
            new Antilog (159, 115),
            new Antilog (160, 230),
            new Antilog (161, 209),
            new Antilog (162, 191),
            new Antilog (163, 99),
            new Antilog (164, 198),
            new Antilog (165, 145),
            new Antilog (166, 63),
            new Antilog (167, 126),
            new Antilog (168, 252),
            new Antilog (169, 229),
            new Antilog (170, 215),
            new Antilog (171, 179),
            new Antilog (172, 123),
            new Antilog (173, 246),
            new Antilog (174, 241),
            new Antilog (175, 255),
            new Antilog (176, 227),
            new Antilog (177, 219),
            new Antilog (178, 171),
            new Antilog (179, 75),
            new Antilog (180, 150),
            new Antilog (181, 49),
            new Antilog (182, 98),
            new Antilog (183, 196),
            new Antilog (184, 149),
            new Antilog (185, 55),
            new Antilog (186, 110),
            new Antilog (187, 220),
            new Antilog (188, 165),
            new Antilog (189, 87),
            new Antilog (190, 174),
            new Antilog (191, 65),
            new Antilog (192, 130),
            new Antilog (193, 25),
            new Antilog (194, 50),
            new Antilog (195, 100),
            new Antilog (196, 200),
            new Antilog (197, 141),
            new Antilog (198, 7),
            new Antilog (199, 14),
            new Antilog (200, 28),
            new Antilog (201, 56),
            new Antilog (202, 112),
            new Antilog (203, 224),
            new Antilog (204, 221),
            new Antilog (205, 167),
            new Antilog (206, 83),
            new Antilog (207, 166),
            new Antilog (208, 81),
            new Antilog (209, 162),
            new Antilog (210, 89),
            new Antilog (211, 178),
            new Antilog (212, 121),
            new Antilog (213, 242),
            new Antilog (214, 249),
            new Antilog (215, 239),
            new Antilog (216, 195),
            new Antilog (217, 155),
            new Antilog (218, 43),
            new Antilog (219, 86),
            new Antilog (220, 172),
            new Antilog (221, 69),
            new Antilog (222, 138),
            new Antilog (223, 9),
            new Antilog (224, 18),
            new Antilog (225, 36),
            new Antilog (226, 72),
            new Antilog (227, 144),
            new Antilog (228, 61),
            new Antilog (229, 122),
            new Antilog (230, 244),
            new Antilog (231, 245),
            new Antilog (232, 247),
            new Antilog (233, 243),
            new Antilog (234, 251),
            new Antilog (235, 235),
            new Antilog (236, 203),
            new Antilog (237, 139),
            new Antilog (238, 11),
            new Antilog (239, 22),
            new Antilog (240, 44),
            new Antilog (241, 88),
            new Antilog (242, 176),
            new Antilog (243, 125),
            new Antilog (244, 250),
            new Antilog (245, 233),
            new Antilog (246, 207),
            new Antilog (247, 131),
            new Antilog (248, 27),
            new Antilog (249, 54),
            new Antilog (250, 108),
            new Antilog (251, 216),
            new Antilog (252, 173),
            new Antilog (253, 71),
            new Antilog (254, 142),
            new Antilog (255, 1),
        };
  • Change Antilog struct definition to:
        private struct Antilog
        {
            public readonly int ExponentAlpha;
            public readonly int IntegerValue;

            public Antilog(int e, int v)
            {
                ExponentAlpha = e;
                IntegerValue = v;
            }
        }
  • Ditch CreateAntilogTable method

I compiled again and it works. Benefits are:

  • faster execution (values are not calculated any more)
  • static list (kept in memory until application is discarded)

I hope it is useful ...

not decode?

This component is pretty good.
But there is a lack of important functions (not decoded)

Can not install

Install-Package : The current environment doesn't have a solution open.
At line:1 char:1

  • Install-Package QRCoder
  •   + CategoryInfo          : InvalidOperation: (:) [Install-Package], InvalidOperationException
      + FullyQualifiedErrorId : NuGetNoActiveSolution,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    

question: automatic char at the end

Hi all,
thank for this fantastic library, it is very simple to use.
The only problem that I found is that at the end of the string is added, by default, a /n that it is uncomfortable in some application. (you can see it for example if you try to create an empty QRcode). It is possible to remove it? Thanks you so much

Missing QRCoder.dll ?

Hello, I came across this repo and would like to use it, but I cannot seem to find the QRCoder.dll you mention in the readme file.
Am I completely blind, or am I doing something wrong? (Either is very possible)

Thanks :)

NuGet support

Is it possible to put QRCoder on NuGet for ease of use/deployment?

Install error QRcode 1.2.3

After installing: PM> Install-Package QRCoder
Error:
Install-Package : Could not install package 'QRCoder 1.2.3'. You are trying to install this package into a project that targets 'MDD,Version=v8.1', but the package does not contain any assembly references or cont
ent files that are compatible with that framework. For more information, contact the package author.

Do you have a new version with this version?

some generated QRCode cannot be scanner read

data:0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

ECClevel: M

and almost 25% can not be scanner read

Removing the border

Hey there!

First of all, thanks for all your hard work, it's a really nice library. 👍

I was wondering how I'd go about removing the white border? I'll make sure to add some white-space around it in my CSS, it's pretty difficult to place and scale responsively with the border, so I'd rather just do it without.

You can consider this a feature request also! :-)

Problem German Umlaute

Problem with
123456789äüß will return
123456789???
But
Ä123456789äüß returns
Right

Please correct

Naming consideration (capitalization)

I've integrated QRCoder into our project and in a few minutes I was up and running with QR codes. You've done a great job, thank you!

I felt immediately at home: I was expecting the two-letter QR acronym to stay as a two-letter upper case name in the source code, as recommended by the Framework Design Guidelines summarized here.

There are, however, a few small glitches where the naming is not OK:

var generator = new QRCoder.QRCodeGenerator ();
var data = generator.CreateQrCode (value, QRCoder.QRCodeGenerator.ECCLevel.Q);
var code = new QRCoder.QRCode (data);
var bitmap = code.GetGraphic (8);
  • CreateQrCode() should be CreateQRCode() for consistency's sake.
  • ECCLevel uses the three letter acronym ECC which should therefore be written as EccLevel.

There may be other such glitches in the code base, I did not check.

What do you think? Would it be OK for you to introduce breaking changes to make the library
even easier to consume, by removing these small surprises?

NuGet package does not support UAP

I tried to install the NuGet package in my UAP app but I get the following errors form the packagaing manager console:

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0.
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0.
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0 (win10-arm).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0 (win10-arm).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0 (win10-arm-aot).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0 (win10-arm-aot).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0 (win10-x64).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0 (win10-x64).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0 (win10-x64-aot).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0 (win10-x64-aot).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0 (win10-x86).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0 (win10-x86).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : QRCoder 1.1.9 is not compatible with UAP,Version=v10.0 (win10-x86-aot).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Install-Package : Some packages are not compatible with UAP,Version=v10.0 (win10-x86-aot).
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

Paketwiederherstellungsfehler für "TempCheckPiUI".
Install-Package : Fehler bei der Paketwiederherstellung. Es wird ein Rollback der Paketänderungen für "TempCheckPiUI" ausgeführt.
In Zeile:1 Zeichen:1

  • Install-Package QRCoder
  • - CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
    - FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    
    

I could try to insert the code directly in my project but I would prefer to have the official package.

not working on ASP.NET Core

hi, is it possible, that this libraray isn't working on ASP.NET Core applications?
I have installed it via NuGet and there are missing some classes.
Ican create the qrCodeData, but there is no class to work with it (Base64QRCode etc)

Extending Payload

Hello, great lib BTW!

Can you share how to extend the Payload to implement a custom Payload action. For e.g. send to printer or send to image.

thanks

Bug with number 2132

I generate a qr code from number 2132.
But when I use another qr readers, they read 2122.

Memory managment

I'm using QRCoder in an application and i must generate code for ticket (the number is very important and bigger) and i get an exception of out of memory and i guest the problem is in qrcode generation, now i need to implement IDisposable interface.
i'd need to know if i'm in good way to fix it and if my troublshoot is right ?

ASP MVC

Hello, how can I set the sizing and mime type for ASP MVC to ensure it gets through IIS

Add PngByteQRCode type

As discussed in this issue #73 let's add PngByteQRCode as QRCode type for systems which doesn't support System.Drawing.

Plans to support QRCode renderer on .NET Standard 2.1?

Dear QRCoder team,

First of all, great work on QRCoder!

I'm choosing a QR Code library for a .NET Core 2.0 project and QRCoder is looking very promising. I'm well aware of the difficulties to work with graphics on .NET Standard 1.x and even 2.0 because of the missing classes on the System.Drawing namespace, so I totally get that only the BitmapByteQRCode renderer is available for .NET Standard.

Microsoft has promised to fill that gap for .NET Standard 2.1, to be released by the end of this year. I would like to know if you have plans to extend the support for the advanced renderers, more specifically the QRCode renderer, once .NET Standard 2.1 is out.

Thanks!

Bugs while creating QRCode

Hi Raffael
I use your library for printing QRCode on documents. Some of the codes are generated incorrectly. I give a few examples, and the parameters and values ​​with which they were noticed.
Encoded string: PA 9486/AMG/2014
ECC Level: M
Decoded as: PA 94870AMG/2014

Encoded string: PA 9490/AMG/2014
ECC Level: M
Decoded as: PA 949CFAMG/2014

Encoded string: PA 9491/AMG/2014
ECC Level: M
Decoded as: PA 949DFAMG/2014

Does not run on netstandard / core on Ubuntu

System.Drawing.KnownColors and other exceptions are thrown when running on Ubuntu using basic qr generation.

public static Bitmap WriteQRImage(string data, int ppm = 20) { using (var qrGenerator = new QRCodeGenerator()) { using (var qrCodeData = qrGenerator.CreateQrCode(data, QRCodeGenerator.ECCLevel.Q)) { using (var qrCode = new QRCode(qrCodeData)) return qrCode.GetGraphic(ppm); } } }

Doesn't work with .Net 3.5 which is the highest version supported by Unity 4.3

Hello!

I am making a project in Unity 4.3 where I need to create a QR code on the screen for the phones to connect to. And I'm having issues including this in Unity as Unity can only support dlls of .Net versions upto 3.5 and this plugin uses .Net 4.0

Is there a possible quick fix for that?
I don't have any experience with .Net and C# outside of Unity so I don't know how this can be done, but this library seems really cool and I will definitely use it if this problem can be solved!

Thanks for your time.

Wireless SSID and Password Generation

Thanks for the great library, is there a way this could be used to generate Wireless Password QRCodes? I know you can pipe this through

WIFI:S:<SSID>;T:<WPA|WEP|>;P:<password>;;

and it seems to work.

Merge HOTP and TOTP algorithms into this library?

Would be a neat addition. I have made several.

For people using TOTP in C#, it would go a lot more smoothly than importing yet another library. It is small and simple and I could do it.

Thoughts?

"ER225410741DB-0" qrcode is wrong

I generate a batch of qrcode image and decode by zxing, but some qrcode cannot be decoded such as the string "ER225410741DB-0" which encoded in version 2 and "H" ECCLevel.

Please support drawQuietZones=false on BitmapByteQRCode

Dear QRCoder team,

Is there any impediment for supporting the drawQuietZones = false option on BitmapByteQRCode? If not, would you please be so kind as to consider adding it?

Thank you very much!

PS: I know that option is available on the QRCode renderer, but I'm on .NET Core

QR Code complexity

Hello,

After updating from 1.2.0.0 to 1.2.1.0 the complexity of the QR codes generated is increased.

1.2.0.0:
1 2 0 0 test

1.2.1.0:
1 2 1 0 test

Is there a way we can force the QR code to be less complex in the new version? We need to print the QR codes on small labels and we always try to use the less complex QR code. Now we cannot update unfortunately to the newest version of your great library.

Regards,

Frank

Errornous QR-Codes when using special amount of chars in input

Hallo,

ich glaube, das ich einen Bug gefunden habe. Ich versuche einen QR-Code für folgenden Text zu generieren:

[#P-BOF#]
XX
XXX
XXXXXXXXX
Test-Text
XXXXXXXXXXXXX
$XX=255.255.0.0
$XX=10.10.0.254
$XX=
$XX1=16
$XX2=16
$XX3=16
$XX4=16
$YY1=ON
$YY2=OFF
$YY3=ON
$YY4=OFF
$ZZ1=16
$ZZ2=16
$ZZ3=16
$ZZ4=16
$AA1=B
$AA2=B
$AA3=B
$AA4=B
$VID1=1
$VID2=1
$VID3=1
$VID4=1
$VID5=1
[#EOF#]

Generiert habe ich den QR-Code mit folgendem Code:

Encoding iso = Encoding.GetEncoding("ISO-8859-1");
Encoding utf8 = Encoding.UTF8;

QRCodeGenerator qrGenerator = new QRCodeGenerator();
QRCodeData qrCodeData = qrGenerator.CreateQrCode(iso.GetString(utf8.GetBytes(Text)), QRCodeGenerator.ECCLevel.L);
QRCode qrCode = new QRCode(qrCodeData);
Bitmap qrCodeImage = qrCode.GetGraphic(5);

Der so erzeugte QR-Code kann nicht gelesen werden (Versuch mit mehreren Apps und Betriebssystemen (IOS, Androdi). Wenn ich nur einen Buchstaben hinzufüge, oder entferne z.B. von meinem Test-Text, funktioniert der Barcode wieder sofort.

Ändere ich im Code den "PixelPerModule"-Wert von 5 auf z.B: 6 , bleibt der Fehler,
Ändere ich das ECCLevel von "L" auf "M" funktioniert der QR-Code auch, nur genau bei meinen Einstellungen tritt der Fehler auf.

Hoffe der Bug kann auch bei dir reproduziert werden.

special characters encoding

I've got a problem while trying to encode special characters.
When using characters like č, š, etc, qr code is generated but can not be decoded. Otherwise it works great.
Is there any way to set encoding to UTF-8?

QRCoder on Unity generate code but phone app QRreader not read information

Hi,

I'm using your code on a Unity Standalone aplicación. I can generate the QR code and assing to a texture, but my pone App QRReader not read any information. I want to generate a QR of a url.

my code is

public void QR2() { QRCodeGenerator qrGenerator = new QRCodeGenerator(); PayloadGenerator.Url urlPayload = new PayloadGenerator.Url("http://www.google.es"); QRCodeData qrCodeData = qrGenerator.CreateQrCode(urlPayload.ToString(), QRCodeGenerator.ECCLevel.Q); UnityQRCode qrCode = new UnityQRCode(qrCodeData); Texture2D qrCodeImage = qrCode.GetGraphic(50); GetComponent<Renderer> ().material.mainTexture = qrCodeImage; }
what i'm doing worng?
Thanks you

Generate Base64 encoded QRCode image string

Hey, codebude,

Thanks for this amazing library.

I'm building a website and needed to generate QRCode for Urls dynamically, and then show them in the webpage. Since there is a way to render Base64 encoded image string in the browser like this:

<img src="data:image/jpg;base64,......" />

it'll be much better that QRCoder could directly output the encoded string rather than having users transforming its output Bitmap image to the Base64 string.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.