There are plenty of scripts out there that can generate a black and white QR code.
I have a script on my website that will generate the QR code.
However, I wanted a script that allows the user to modify the black and white QR code and customize it to a more colorful QR code.
Are there open source scripts that will allow the user to customize their QR code with color?
So that they can select
QR color
Background color
Use color gradient
Gradient style: Radial
2nd QR color for gradient
Rounded Corners
Upload logo
These sites do not offer their scripts for open source
http://www.qrhacker.com/
http://uqr.me/2012/06/qr-code-beautifier/
There is a round-about way to do colour gradients - I had a need recently to do this and it took some figuring out because, as you observed, those that can are closed source and the open source alternatives don't do it.
Generate the gradient as an image. Someone wrote a helpful PHP class to generate the image for you in a variety of directions and styles - one of which is radial (well, ellipse anyway).
Use a library like endroid's qr-code library.
Reload the QR code in GD and set the QR code colour as transparent.
Overlay the QR code onto your gradient image.
Related
I had got a requirement to create a QR code with a logo at the center, so first I thought it may require some different library.
For experiment, I just put a logo using Illustrator at the center on the provided QR code and the scanner was able to read it. I used black and white both bg below logo, still it was reading correctly.
So my question is: if I put a logo within the center of any QR code, will it work fine or should I use a library for this matter?
All QR codes with an image or logo in the center take advantage of the fact that the QR code contains redundant information so it can still be decoded despite poor image quality or poor printing. This is part of the error correction.
The QR code standard does not have any explicit facility for making room in the center for an image.
Thus, your approach is perfectly fine. Any other QR code library would do the same: generate the QR code and then add an image in the center.
To ensure that the QR code can still be successfully scanned, it is advisable to use the higher error correction levels if possible (level Q or H instead of M or L).
Yes is is safe to put a logo on any QR code at center. QR Codes only use the 'outsite dots' to process the information.
If you want you can create a QR Code with a logo online, there are a bunch of websites that let you do that quite easly. For example:
qrty let you create a qr code and put your logo inside it!
I am using aplypy to create an RGB image of the Eagle nebula from three FITS files, representing the red, green and blue components of the image. The FITS files are available here, 673nm being the red, 656nm the green and 502nm the blue.
import aplpy
aplpy.make_rgb_cube(['673nmos.fits','656nmos.fits','502nmos.fits'], 'nmod_cube.fits')
aplpy.make_rgb_image('nmod_cube.fits','nmod.png')
f = aplpy.FITSFigure('../data/nmod_cube_2d.fits')
f.show_rgb('../data/output/nmod.png')
The image should look something like this, but comes out looking like the image below. The blue component is clearly misaligned with the red and green.
make_rgb_cube is supposed to realign the three images in to the same projection based on the WCS information in each FITS header, according to the docs, but it doesn't seem to be working in this case.
Do I need to employ a star matching library to get the alignment accuracy?
There is an error in the WCS coordinates in the header of the Blue FITS file. I have contacted spacetelescope.org to alert them.
Another example from the site, of M17, is created correctly using the aplpy script shown in the question. Blinking through each filter using DS9, as suggested in the comments, confirms the correct alignment.
Use the STScI software TweakReg to align the images and get a good alignment before combining. More information and worked examples can be found on the DrizzlePac website.
TweakReg:
Combining images using astrodrizzle requires that the WCS information in the headers of each input image align to within sub-pixel accuracy. The tweakreg task allows the user to align sets of images to each other and/or to and external astrometric reference frame or image.
It is optimized for use with HST instruments, but can be adapted for other observatories/instruments.
I'm looking to see if this is possible and if so how to do it. I want the user to upload an image with a white background. The image can be anything from a pair of shoes to a hat. The website will then automatically turn that white background transparent then store it. What I want to know is there a way using HTML Canvas/CSS to transform that white background to 100% transparency?
You can have a look at this answer, which explains nicely how to change colors in an image using javascript : How to change color of an image using jquery
However, you should do this using server side code, and be aware that results may vary, as just removing a color will not look nice on the edges of your object.
Overview
I'm looking for advice / solutions on standardizing color profiles on comps so colors of HTML/CSS gradients/blends match effects achieved in a comp. I often get PSDs using the sRGB color profile so when I color pick something to recreate a gradient / icon / or background the HEX color and resulting CSS/HTML gradient does not match the original sRGB gradient provided in the comp. Typically I just discard the embedded color profile for a Monitor RGB color profile that better matches PSD colors to end result CSS colors. Here's an example showing differences between color profiles.
Details
So here's the predicament: A designer wants to standardize PSDs to use an embedded sRGB color profile because exported images (JPEG / PNG) retain that sRGB color profile to display correctly when loaded in a browser. So photos / textures / things that I can't recreate in CSS will export as JPEG/PNG with the better sRGB profile (which is an understandable request).
As a front-end developer I often recreate elements displayed in a comp using CSS and HTML (no images) and this requires me to match HEX colors properly between what's in the PSD and what's rendered on the website. So, I would prefer to standardize with a Monitor RGB color profile so that everyone uses something closer to what's actually rendered in the browser.
Just curious how everyone else approaches this problem? There's often cases where I use a mixture of CSS and PNGs to achieve an effect (especially effects that need to change dynamically (size/hue/shading...) so exporting an image with sRGB and overlaying it with CSS gradients / shadows ends up being a mixture of sRGB / Monitor RBG and hence subtly different from the comp.
Answer Format
Hopefully I've properly asked this question - suitable answers would just give a perspective on how you deal with the problem - OR (better) if theres an SCSS sRGB() function or some other algorithm to convert an RGB / HEX color to sRGB then I will throw it into a SASS mixin.
Here's how we ensure color consistency in Photoshop: correct color-picking and consistency in saved-for-web images.
Setting Up Photoshop Color Space
The first thing we all have to do is to ensure we are working under the correct color profiles. To do this follow these steps:
Go to Edit > Color Settings or Shift + Command + K or Shift + Control + K in windows.
From the Settings drop down select North America Web/Internet
Commit your changes by hitting OK.
Go to View > Proof Setup and select Internet Standard RGB (sRGB)
Hit Command + Y or Control + Y in windows to enable Proof Colors, alternatively you can just go to View > Proof Colors
Exporting (Save for Web)
When exporting via Save for Web ensure that Convert to sRGB is checked.
You are done, you should now enjoy color accuracy across all of your files and in HTML and images will be ensured to display consistently across devices and browsers.
I have been looking for a good server side graphing / charting library that has a lot of design options. Most seem to be very difficult to customize the specific way we are looking to.
I don't mind if it is python, php, java, etc... I just need it to generate server side and output an image to be embedded on a pdf.
Specifically I need the following.
Gradients in bars fill color
Ability to have rounded edges on bars of chart
From a design perspective those are the important ones that I can not find in a specific library.
Ended up using MatPlotLib and used the example below. Essentially you can use an image and set the repeating area of the image. Instead of the gift boxes, I used a rounded corners horizontal gradient image.
http://matplotlib.sourceforge.net/examples/pylab_examples/demo_ribbon_box.html