Posts

Showing posts from June, 2013

Skype doesn't start

On Ubuntu 13.04 my Skype refused to start. Maybe something went wrong while trying to install driver for ATI Radeon 7730m graphics card. So the first thing to do to troubleshoot is to try, to run Skype from terminal. Open terminal and type skype and press enter. If you get the following error: skype: error while loading shared libraries: libGL.so.1: cannot open shared object file: No such file or directory Then run the following command in terminal again and this should fix Skype not starting problem. sudo apt-get install --reinstall libgl1-mesa-glx:i386

Slice Bitmap Image In Android

With this simple function you can slice one bitmap image and return array with the sliced images. Just pass in the bitmap you want to slice and number of rows and columns you want it sliced into. public static ArrayList GetSplittedBitmap(Bitmap picture, int numRow, int numColumn){ ArrayList imgs = new ArrayList (); int pieceHeight = picture.getHeight()/numRow; int pieceWidth = picture.getWidth()/numColumn; for(int i=0; i for(int j=0; j imgs.add(Bitmap.createBitmap(picture,j*pieceWidth,i*pieceHeight,pieceWidth,pieceHeight)); } } return imgs; }