QSwingImageBridge Class Reference

QSwingImage Bridge. More...

#include <QSwingImageBridge.h>

List of all members.

Static Public Member Functions

static jlong createImage (JNIEnv *env)
 Creates new image.
static jlong createImage (JNIEnv *env, jobject obj, jbyteArray imageData, jint lenght)
 Creates new image.
static jobject createScaled (JNIEnv *env, jlong imagePointer, jint width, jint height, jint hints, jstring format)
 Creates new image.
static void initialize (JNIEnv *env, jclass cls)
 Initializes QSwingImageBridge class.
static jobject newInstance (const QPixmap &pixmap, jstring format)
 Creates QSwing image from specified QPixmap.
static QPixmap * createDisabledPixmap (QPixmap *pm)
 Creates new disabled Pixmap from the specified Pixmap.
static bool loadImage (JNIEnv *env, jbyteArray imageData, jint length, QPixmap *pixmap)
 Loads image.


Detailed Description

QSwingImage Bridge.

Author:
Slobodan Vrkacevic (slobodan.vrkacevic@gmail.com)
Version:
0.2.0

Member Function Documentation

jlong QSwingImageBridge::createImage ( JNIEnv *  env  )  [static]

Creates new image.

Parameters:
env the JNIEnv pointer
Returns:
image pointer

jlong QSwingImageBridge::createImage ( JNIEnv *  env,
jobject  obj,
jbyteArray  imageData,
jint  lenght 
) [static]

Creates new image.

Parameters:
env the JNIEnv pointer
obj the QSwing image object
imageData the image data
lenght the lenght of the image data
Returns:
image pointer

jobject QSwingImageBridge::createScaled ( JNIEnv *  env,
jlong  imagePointer,
jint  width,
jint  height,
jint  hints,
jstring  format 
) [static]

Creates new image.

Parameters:
env the JNIEnv pointer
imagePointer the pointer of the original image
width the new image width
height the new image height
hints the transformation hints
format the format
Returns:
pointer of the scaled image

void QSwingImageBridge::initialize ( JNIEnv *  env,
jclass  cls 
) [static]

Initializes QSwingImageBridge class.

Parameters:
env the JNIEnv pointer
cls the QSwingGraphics class

jobject QSwingImageBridge::newInstance ( const QPixmap &  pixmap,
jstring  format 
) [static]

Creates QSwing image from specified QPixmap.

Parameters:
pixmap the pixmap
format the image format
Returns:
QSwing image

QPixmap * QSwingImageBridge::createDisabledPixmap ( QPixmap *  pm  )  [static]

Creates new disabled Pixmap from the specified Pixmap.

Parameters:
pm the QPixmap
Returns:
new disabled QPixmap

bool QSwingImageBridge::loadImage ( JNIEnv *  env,
jbyteArray  imageData,
jint  length,
QPixmap *  pixmap 
) [static]

Loads image.

Parameters:
env the JNIEnv pointer
imageData the image data
length the image data length
pixmap the pixmap
Returns:
true if succeed


Copyright © 2007 ETF and contributors. All Rights Reserved.