How to change the bitmap image in blackberry
Hello
1. work on the version of BB storm (9500/9530 Simulator) is v4.7.0.75
2 opportunity BB JDE 4.7
3. the request is:
I display a bitmap image by using the drawBitmap method. now I want to select a portion of the bitmap, and then I need to cut & paste the part somewhere in the screen (MSPaint we have option 'Select').
is there any method that will make the similar operation (or) any idea to accomplish this in blackberry.
Thank you
Sendhil Kumar V
Take a look at this thread and refers to the J2ME code:
http://supportforums.BlackBerry.com/Rim/Board/message?board.ID=java_dev&message.ID=24929
The 'trick' is getARGB() and setARGB(). As long as you check out relevant Bitmap Moose ARGB values, you should be able to create a new Bitmap. That said, I never did. Let us know how you go.
Tags: BlackBerry Developers
Similar Questions
-
How to convert the Bitmap Image in BlackBerry
Hello
In my application, I get the picture from the server. Now, I want to convert this Bitmap Image to display on the screen. For this I use below codes. But it doesn't give me the same image does not mean with the clarity and the exact size. He's smaller than the picture.
I used the codes below:
private Bitmap getBitmapFromImg(Image img) { Bitmap bmp = null; try { Logger.out(TAG, "It is inside the the image conversion " +img); Image image = Image.createImage(img); byte[] data = BMPGenerator.encodeBMP(image); Logger.out(TAG, "It is inside the the image conversion---333333333"+data); bmp = Bitmap.createBitmapFromBytes(data, 0, data.length, 1); } catch (Exception e) { // TODO Auto-generated catch block e.printStackTrace(); } return bmp; // TODO Auto-generated method stub }
Here is the BMPGenerator class:
public final class BMPGenerator { /** * @param image * @return * @throws IOException * @see {@link #encodeBMP(int[], int, int)} */ public static byte[] encodeBMP(Image image) throws IOException { int width = image.getWidth(); int height = image.getHeight(); int[] rgb = new int[height * width]; image.getRGB(rgb, 0, width, 0, 0, width, height); return encodeBMP(rgb, width, height); } /** * A self-contained BMP generator, which takes a byte array (without any unusual * offsets) extracted from an {@link Image}. The target platform is J2ME. You may * wish to use the convenience method {@link #encodeBMP(Image)} instead of this. *
* A BMP file consists of 4 parts:- *
-
*
- header *
- information header *
- optional palette *
- image data *
Where an error in my code? Is there another way to do the same thing?
Why you want to use a bmp image?
You can just use png, jpg or whatever of the original image is.
If there is a situation where you need the bitmap image call http://www.blackberry.com/developers/docs/7.1.0api/net/rim/device/api/system/EncodedImage.html#getBi... -
Change the bitmap image, remove background in Flash CS4?
HI people, I tried to slide in Photoshop, a layer with a transparent background, and image but it becomes white in Flash, so I imported the psd image. However, the black background interfere with the placement of the image. In OLD flash, there was formerly a magic wand and the ability to select areas of the bitmap and delete, but it seems that the feature is now missing or hidden in the new flash. I transformed the image bitmap and I don't want to follow, because it's a picture. So, without tracking, how you change the image as I am doing?
Thank you
Jeff
The magic wand is in the same place in CS4 (select Lasso, and then it is in the area of the toolbar options).
-
BlackBerry smartphone how to change the email account on blackberry 8900
Hi all
I installed my yahoo e-mail address on my BB 8900, some days before, I changed the password of my yahoo email address of the PC, now I can not receive or send e-mails form BB, I tried to update the new password in the BB, but I have no idea on how to change the e-mail account on BB 8900 , I will be very appreciated if it someone help me solve my problems.
Concerning
alobaydee
Connect to your BIS account:
Here, find and edit your yahoo account. Either change the password, or simply delete the account and re - add new.
Go to the Personal Email Set Up icon and sign.
Your desktop PC: http://www.blackberry.com/btsc/KB02830
North American carriers - scroll down to select your carrier
Carriers worldwide - find your operator from the list -
How to change the background image of a newtab
Hello
I'm looking for a simple addon that will allow me to change the background image for my new tab page. I still want the empty bar url and the new tab to say "new tab". Just the simple ability to change the background image without changing anything else.
Thanks in advance
NielsHere's an add-on which may help! https://addons.Mozilla.org/en-us/Firefox/addon/customize-aboutnewtab/
-
How to change the background image of the "submit" button
Hi all
I want to change the appearance of a submit button: instead of show a button with text 'Add', I want the button submit to be like an icon 'more'
I tried to change the background image of the button submit like that, but it doesn't work. What is the ownership change?
CSSStyle customCss = new CSSStyle(); customCss.setProperty("background-image", "url('/OA_MEDIA/plus.png')"); OASubmitButtonBean addSubmitButton = (OASubmitButtonBean)webBean.findIndexedChildRecursive("addSubmitButton"); addSubmitButton.setInlineStyle(customCss);
Thank you
Kind regards
Afaf
Why not try with just an Image and fireAction on it?
-
How to change the logo image in the Message Inbox
Hello! I am a beginner to the BlackBerry java development and I want to change the image of the logo from the Message to the list, so if anyone has an idea please tell me what this means...
OK, thank you nice to be with you Simon.
-
How to change the background image of display themes?
original title: photos of desktop theme
How can I change the desktop themes backgroung image? When I try the method of customization and select a new theme, it is just something that already existed. The done button does not appear at the bottom of the themes page. Using Windows Home Premium 64-bit edition.
Jim t8817 of Hello and welcome in the Microsoft community
There are two ways to change the theams and aperences of your computer
I usually use the registry, but it's a quick way to make a paper weight
hear is a way via the command prompt
This is the safest way recommended to do it without the control panel
http://www.ehow.com/how_6930915_do-Windows-theme-command-line_.html
I also sugest you read the following tutorial
http://windows7themes.NET/cant-change-Windows-7-theme.html witch allows a large number of customization options
also focus on fixing your aero it will improve your customization options
http://support.Microsoft.com/mats/aero_effects_not_working/en-us?WA=wsignin1.0
-
How to change the background image in a model.
I have Startboot Business Casual open in DW. It has a brick background. I want to replace it with a few trees and clouds. I did a picture of decent size and I've replaced the image, bg.jpg in files, but nothing has changed. Do I have to change the code? And if so, how? Or should I remove the background image for each page and then replace it with the new image?
Did you do a refresh of the page? You are testing in a real browser?
Nancy O.
-
Problem by changing the Bitmap Image
Hello
I'm creating an application.
I have a login screen, the details and the NewScreen.NewScreen contains three options, named A, B, and C.
When I click on any of the option and the user is not connected so I first go to the login screen and after successful connection, I go to the screen details and when I press the back button I go back to NewScreen.
Now what I want to when I press the back button and come to the NewScreen then image option B Gets the change. And the new image must be in the details page.
So, I have to save the persistent memory image?
The problem is solved...
-
How to use the Gif image in Blackberry android runtime
Hello
I deploy an android app in blackberry 10. All that it works well in blackberry 10 except gif image. In app android gif image is displayed using the AnimationDrawable from the link
http://developer.Android.com/reference/Android/graphics/drawable/AnimationDrawable.html
So how to use blackberry 10.
Is it possible to use GIFs in blackberry 10.
Please suggest.
Thanks in advance.
Hello
I found the solution.
He needs of the gifDecoder and gifDecoderView classes and following code extract
Mode, mode = inflate.inflate (R.layout.layout_gspot, null);
GIF GifDecoderView = view.findViewById (R.id.gifView) (GifDecoderView);
gif.setGifImageFromAssets ("abc.gif");and following the layout code
<>
Android:ID="@+id/gifView".
Android: layout_width = "120dp."
Android: layout_height = "120dp."
Android:layout_alignLeft="@+id/textView1".
Android: layout_centerVertical = "true".
Android:background="@Android:color/transparent" / > -
How to change the background image list?
Hi forum, I am using bbUI.js & css (v0.9.5), can I change bb-type_donnees = "item" title background?
found...
listItem.setAttribute ("style", "font-size: 32px;") make-weight: bold; background-color: #000 ');
-
How can I change the background image of an album?
I'm trying to figure out how to change the background image of the album. I'm not trying to change the picture of the official album, but the background image for the album. Is there a way I can change it?
Your screenshot is the section of the iTunes store. None of the graphics or text on the iTunes Store are under your control. You cannot change them.
-
How to change the phone number of Simulator
Hi Experts,
Please help me on how to change the phone number of blackberry Simulator.
Thanking you in advance,
In JDE:
Edit-> preferences-> Simulator-> network-> phone number
-
Change the background image on the login page (smarthphone theme)
Hello
I would like to know how to change the background image on my login page.
Version of the apex is 4.2.4.
The theme is jQuery Mobile Smartphone (topic 50).Pls remind me if I missed some important information.
I have a model of customised area on this page. My user name text fields and password + "CONNECT" button is placed in this area.
I also have an inline css that centers in my area. My dimensions of the region are also placed here.
Not available to access the application today so bad im trying to provide the look of it with a drawing.
Also I noticed that my experience has some white color.
Ty for any information that you provide.
Hi Para,
Try the style of your page like
But if trying to define for your application color gradients extract ThemeRoller to http://jquerymobile.com/themeroller
to set the themes of all colors and gradients you want without doing custom overrides CSS jQM Apex definitions.
Everything you have requested can be configured via the ThemeRoller.
Also found what may be useful if you are going to customize your login
Kind regards
Benjamin.
Maybe you are looking for
-
Possible Fake Firefox update reviews?
I recently received a notice that I have to put my browser. However when I go to help on Firefox in my menu. The pop up says I have the latest version of Firefox. I was wondering if it might be a virus, or a scam, someone tried to shoot. The URL for
-
Smart playlists: condition album randomly?
Hello! Since the update to Itunes 12.4.0.119, I have a problem with my smart playlist: I use a list of smart playlist to fill my ipod with random albums with a maximum of MB. But since I've updated, it added songs and albums together in the playlist.
-
I can't find the touchpad Control Panel
I can't find the touchpad Control Panel.
-
Numeric values on tank of money
Hello I would use an indicator of tank silver palette with a scale up to 10'000 [l] I can put a size of 10,000, but the value is greater than the indicator of tank area. My solution is to use the notation IF (10 k), but the customer wants to see 10,0
-
After you install an update from the CPU to 100% usage
I installed an important update for Win 7, it was for forefront security. After the installation was successful, I saw that my CPU usage went to 100% and the memory above 70 %s. In the Task Manager, I saw around 50-100 process rundll32, and also a lo