Question: I want use many bitmap for my game canvas.

I can't `Recycle` bitmaps, because I have to use bitmaps for the whole section.

Do mention some guidelines to optimize the code to handle many bitmap also faster performance for my canvas based Game Application.

Currently i am using the following code to get bitmap from drawable resource,

```
    BitmapFactory.Options bfOptions=new BitmapFactory.Options();
    bfOptions.inSampleSize = 1;
    bfOptions.inDither=false;                     //Disable Dithering mode
    bfOptions.inPurgeable=true;                   //Tell to gc that whether it needs free memory, the Bitmap can be cleared
    bfOptions.inInputShareable=true;              //Which kind of reference will be used to recover the Bitmap data after being clear, when it will be used in the future
    bfOptions.inTempStorage=new byte[16 * 1024]; 

    myBitMap=BitmapFactory.decodeResource(getResources(),ID, bfOptions);

```

I am currently following this [code](http://obviam.net/index.php/sprite-animation-with-android/) for drawing in canvas.

the images are in sprite so while trying to load many sprite its giving problem.

In this code link **MainGamePanel.java** is what i am doing exactly . for bitmap decoding i use the above method.

Answer: 
Select the appropriate elements, then select the parent `tr`s and finally remove them: <http://jsfiddle.net/pimvdb/RYrA4/3/>.

```
$('#delete').click(function(){
    $(":checkbox[name='yes[]']:not(:checked)") // select non-checked checkboxes
        .parent()  // <td>s (parents of checkboxes)
        .parent()  // <tr>s (parents of <td>s)
        .remove(); // remove <tr>s
})

```
jQuery's [closest](http://api.jquery.com/closest/) method finds the nearest tag defined by the selector starting at the current element and progressing up the tree:

```
$('#delete').click(function(){
    $("input:checkbox[name='yes[]']:not(:checked)").closest('tr').remove();
})

```