Re: Dynamic QR image

2014-02-12 Thread deliadavis...@hotmail.com
Apply an image barcode creating tool to  create 2d qr code
http://www.rasteredge.com/how-to/vb-net-imaging/barcode-generating-qrcode/  
as well as  generate pdf 417
http://www.rasteredge.com/how-to/vb-net-imaging/barcode-generating-pdf417/  
on image or document page. The supportable image file can be jpeg, bmp, gif,
png and the compatible document files are printable pdf, fax-exclusive tiff,
Microsoft word, excel and powerpoint.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Dynamic-QR-image-tp4659029p4664383.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Dynamic QR image

2013-05-26 Thread Delange
Hi,
I'm trying to create a dynamic QR image on the screen. 


Html


Wicket
form.add(new Image(image5, getImage5Resource()));
public ResourceReference getImage5Resource() {
return new ResourceReference(CompanyPanel.class, image5)
{
@Override
public IResource getResource()
{
final BufferedDynamicImageResource resource = new
BufferedDynamicImageResource();
final BufferedImage image = new BufferedImage(300, 300,
BufferedImage.TYPE_INT_RGB);
String text = ;

String t=\n;
text = 
+BEGIN:VCARD+t
+VERSION:2.1+t
+NOTE:This works!+t
+CATEGORIES:BUSINESS,WORK+t
+END:VCARD;


drawQR( (Graphics2D)image.getGraphics() , text );
resource.setImage(image);
return resource;
}
};
}
void drawQR(Graphics2D graphics,String text)
{
 
try {
BitMatrix byteMatrix = new QRCodeWriter().encode(text,
BarcodeFormat.QR_CODE, 300, 300);
int matrixWidth = byteMatrix.getWidth();

//MatrixToImageWriter.writeToStream(byteMatrix, png, new
FileOutputStream(new File(qrcode_test.png +))); 
BufferedImage image = new BufferedImage(matrixWidth , 
matrixWidth,
BufferedImage.TYPE_INT_RGB);

 

graphics = image.createGraphics();
graphics.drawImage(image, 0, 0, 300, 300, null);
 
 
System.out.println(text);

} catch (WriterException e) {
  
e.printStackTrace();
} catch (Exception e) {
 
e.printStackTrace();

}
}



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Dynamic-QR-image-tp4659029.html
Sent from the Users forum mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Dynamic QR image

2013-05-26 Thread Ernesto Reinaldo Barreiro
See dynamicimage.


On Mon, May 27, 2013 at 12:12 AM, Delange delan...@telfort.nl wrote:

 Hi,
 I'm trying to create a dynamic QR image on the screen.


 Html


 Wicket
 form.add(new Image(image5, getImage5Resource()));
 public ResourceReference getImage5Resource() {
 return new ResourceReference(CompanyPanel.class, image5)
 {
 @Override
 public IResource getResource()
 {
 final BufferedDynamicImageResource resource = new
 BufferedDynamicImageResource();
 final BufferedImage image = new BufferedImage(300, 300,
 BufferedImage.TYPE_INT_RGB);
 String text = ;

 String t=\n;
 text = 
 +BEGIN:VCARD+t
 +VERSION:2.1+t
 +NOTE:This works!+t
 +CATEGORIES:BUSINESS,WORK+t
 +END:VCARD;


 drawQR( (Graphics2D)image.getGraphics() , text );
 resource.setImage(image);
 return resource;
 }
 };
 }
 void drawQR(Graphics2D graphics,String text)
 {

 try {
 BitMatrix byteMatrix = new QRCodeWriter().encode(text,
 BarcodeFormat.QR_CODE, 300, 300);
 int matrixWidth = byteMatrix.getWidth();

 //MatrixToImageWriter.writeToStream(byteMatrix, png, new
 FileOutputStream(new File(qrcode_test.png +)));
 BufferedImage image = new BufferedImage(matrixWidth ,
 matrixWidth,
 BufferedImage.TYPE_INT_RGB);



 graphics = image.createGraphics();
 graphics.drawImage(image, 0, 0, 300, 300, null);


 System.out.println(text);

 } catch (WriterException e) {

 e.printStackTrace();
 } catch (Exception e) {

 e.printStackTrace();

 }
 }



 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/Dynamic-QR-image-tp4659029.html
 Sent from the Users forum mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




-- 
Regards - Ernesto Reinaldo Barreiro