Bonjour,

Je cherche à afficher un qrCode à travers un Bitmap.
Pour l'instant, je me retrouve avec aucune image affichée.
Alors que normalement, celle-ci devrait être blanche.
J'ai testé l'affichage avec une autre fonction ou cette fois-ci,
je télécharge une image via une url et je l'affiche et la cela se passe bien.

Avez-vous une idée ou j'ai commis une erreur ds mon code ?

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
 
	Bitmap bitmap = Bitmap.createBitmap(width, height,Bitmap.Config.ARGB_8888);
 
 
    	//create buffered image to draw to
 
    	//iterate through the matrix and draw the pixels to the image
    	for (int y = 0; y < height; y++) { 
    	 for (int x = 0; x < width; x++) { 
    	  boolean grayValue = matrix.get(x,y); 
 
    	  System.out.println(grayValue);
 
    	  bitmap.setPixel(x, y, 0xFFFFFF);
    	 }
    	}
 
    	image.setImageBitmap(bitmap);