while trying to overlay an image in blackberry i am getting this error
Image outerFrame = Image.createImage("/outerFrame.png");
Image innerFrame = Image.createImage("/开发者_JAVA技巧innerFrame.png");
OverlayControl overlay = myMediaProcessor.getControl ("javax.microedition.media.control.imageeffect.OverlayControl");
overlay.insertImage(innerFrame, 0,0,1); // order = 1
overlay.insertImage(outerFrame, 0,0,0); // order = 0
I can’t get to create “myMediaProcessor”.
You do not show a lot of context, so it's hard to understand what you're actually asking for.
myMediaProcessor
should be an object of a class that implements the
javax.microedition.media.Controllable
interface. See the Controllabale javadoc for a list of classes that implement it.
Alternatively, look at the javadoc for the MediaProcessor interface, and the GlobalManager docs. These have the information you seem to be looking for.
精彩评论