修改了
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,4 +1,4 @@
|
||||
#version 450
|
||||
#version 450
|
||||
|
||||
layout (binding = 1) uniform sampler2D samplerColor;
|
||||
layout (binding = 2) uniform sampler2D samplerColor_ex;
|
||||
@@ -18,21 +18,14 @@ void main()
|
||||
|
||||
vec4 textureColor = color;
|
||||
|
||||
//if (textureColor.a < 0.1)
|
||||
//{
|
||||
//textureColor = vec4(0.2, 0.2, 0.2, 0.5);
|
||||
// discard;
|
||||
//}
|
||||
|
||||
// ¼ÆËãÓë (0,0,1) µÄµã³Ë
|
||||
// 计算与 (0,0,1) 的点乘
|
||||
float ndot = dot(N, vec3(0.0, 0.0, -1.0));
|
||||
|
||||
// ±£Ö¤½á¹û >= 0
|
||||
// 保证结果 >= 0
|
||||
ndot = max(ndot, 0.0);
|
||||
|
||||
vec4 blendedColor = mix(color_ex, color, ndot);
|
||||
|
||||
outFragColor = blendedColor;
|
||||
|
||||
// outFragColor = vec4(1, 0, 0, 1);
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
@@ -85,23 +85,8 @@ void processWithVulkan(uint8_t* data, int width, int height, int format,
|
||||
TextureLoadProcessWithVulkan(data, width, height, rowStride, dataSize);
|
||||
}
|
||||
|
||||
extern "C"
|
||||
JNIEXPORT void JNICALL
|
||||
Java_com_hmwl_face_FaceActivity_processImageNative(JNIEnv *env, jobject thiz, jobject buffer,
|
||||
jint width, jint height, jint format,
|
||||
jint row_stride, jint pixel_stride,
|
||||
jint rotation) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
extern "C"
|
||||
JNIEXPORT void JNICALL
|
||||
Java_com_hmwl_face_FaceActivity_passDataToNative(JNIEnv *env, jobject thiz, jobject buffer,
|
||||
jint point_count, jint width, jint height) {
|
||||
|
||||
}
|
||||
extern "C"
|
||||
JNIEXPORT void JNICALL
|
||||
Java_com_hmwl_face_1sdk_FaceActivity_processImageNative(JNIEnv *env, jobject thiz, jobject buffer,
|
||||
|
||||
Reference in New Issue
Block a user