예제 #1
0
/*
 * Class:     org_upp_AndroidMath_Vector
 * Method:    getSize
 * Signature: ()I
 */
JNIEXPORT jint JNICALL Java_org_upp_AndroidMath_Vector_getSize
  (JNIEnv *env, jobject obj)
{
	Vector* vec = mm.Get(env, obj);
	
	return vec->GetSize();
}
예제 #2
0
/*
 * Class:     org_upp_AndroidMath_Vector
 * Method:    get
 * Signature: (I)F
 */
JNIEXPORT jfloat JNICALL Java_org_upp_AndroidMath_Vector_get
  (JNIEnv *env, jobject obj, jint id)
{
	Vector* vec = mm.Get(env, obj);
	
	return vec->Get(id);
}
예제 #3
0
/*
 * Class:     org_upp_AndroidMath_Vector
 * Method:    toStirng
 * Signature: ()Ljava/lang/String;
 */
JNIEXPORT jstring JNICALL Java_org_upp_AndroidMath_Vector_toString
  (JNIEnv *env, jobject obj)
{
	Vector* vec = mm.Get(env, obj);
	
	return env->NewStringUTF((vec->ToString()).c_str());
}
예제 #4
0
/*
 * Class:     org_upp_AndroidMath_Vector
 * Method:    multipleByScalar
 * Signature: (F)V
 */
JNIEXPORT void JNICALL Java_org_upp_AndroidMath_Vector_multipleByScalar
  (JNIEnv *env, jobject obj, jfloat scalar)
{
	Vector* vec = mm.Get(env, obj);
	vec->MultipleByScalar(scalar);
}
예제 #5
0
/*
 * Class:     org_upp_AndroidMath_Vector
 * Method:    set
 * Signature: (IF)V
 */
JNIEXPORT void JNICALL Java_org_upp_AndroidMath_Vector_set
  (JNIEnv *env, jobject obj, jint id, jfloat value)
{
	Vector* vec = mm.Get(env, obj);
	vec->Set(id, value);
}