Aller au contenu
View in the app

A better way to browse. Learn more.

Forum de Frandroid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

rotation image (bitmap et matrix)

Featured Replies

Posté(e)

Bonjour tout le monde.

J'ai besoin de faire une rotation sur mon Bitmap. J'ai donc écrit une petite méthode :

private Bitmap rotation(Bitmap bitmapOrg, int angle, int x, int y){
int width = bitmapOrg.getWidth();
int height = bitmapOrg.getHeight();
Matrix matrix = new Matrix();
matrix.postRotate(angle,x,y);
return Bitmap.createBitmap(bitmapOrg, 0, 0,width, height, matrix, true);
}

La rotation se fait bien mais le point pivot n'est pas au centre de l'image.

J'ai bien essayé de changer le point pivot mais il n'y a pas de différence.

Le point pivot n'est même pas dans un angle.

Edit : Il n'y a pas de décalage pour les angles : 90, 180, 270.

Est ce que vous avez déjà eu ce problème ?

Merci.

Modifié par jfs77

Posté(e)
  • Auteur

A noter que le problème existe sur mon émulateur en résolution WVGA800 et Android 2.2 ou mon Galaxy S

Mais je n'ai pas le problème sur un émulateur en résolution HVGA et Android 1.6...

Archivé

Ce sujet est désormais archivé et ne peut plus recevoir de nouvelles réponses.

Account

Navigation

Rechercher

Rechercher

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.