我开发了一个应用程序,其中显示了一个立方体OpenGL ES,当用户触摸屏幕并滑动它时,立方体从一个位置转换到另一个位置(某种平移实现) - 用glTranslatef()
我已经习惯 MotionEvent.ACTION_MOVE了这种滑动动作.现在我的问题是我希望使用多点触控实现这一点,因此用户必须使用至少两个手指进行此翻译.
已经尝试使用GestureDetector.SimpleOnGestureListener&ScaleGestureDetector但仍不清楚.
任何人都可以帮我看这个.提前致谢 !!
我需要监控Windows服务(如CPU负载,内存使用等),所以我安装了Nagios监控工具.安装完成,还安装了'check_nt'插件.到目前为止没有错误,但是在使用代理NSClient ++执行脚本时"主机拒绝连接"错误仍然存在.
./check_nt -H 10.112.32.78 -p 1248 -v MEMUSE -w 80 -c 90
Connection refused by host
./check_nt -H 10.112.32.78 -p 1248 -v MEMUSE -w 80 -c 90
Socket timeout after 10 seconds
Run Code Online (Sandbox Code Playgroud)
我已经证实nagios工作正常,如下.
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Nagios Core 3.4.1
Copyright (c) 2009-2011 Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 05-11-2012
License: GPL
Website: http://www.nagios.org
Reading configuration data...
Read main config file okay...
Processing object config file '/usr/local/nagios/etc/objects/commands.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/contacts.cfg'... …Run Code Online (Sandbox Code Playgroud) 尝试通过NDK平台在android中执行基于C ++的程序时,编译出现错误,发现未找到'gl.h'和'glext.h'头文件,因为我在C ++代码中都包含了这两个文件。M使用android-ndk-r8并使用Cygwin进行编译。
here s my code:
**ANDROID.MK**
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := NDK1
FILE_LIST := $(wildcard $(LOCAL_PATH)/*.cpp)
LOCAL_SRC_FILES := $(FILE_LIST:$(LOCAL_PATH)/%=%)
include $(BUILD_SHARED_LIBRARY)
---
**APPLICATION.MK**
APP_STL := stlport_static
APP_ABI := armeabi armeabi-v7a
APP_PLATFORM := android-3
---
**Viewer.cpp**
#include <iostream>
#import "OpenGLES/ES2/gl.h"
#import "OpenGLES/ES2/glext.h"
//#import <GLKit/GLKEffects.h>
#import <GLKit/GLKMath.h>
#include "Viewer.h"
void Viewer::render() {
glClearColor(0.65f, 0.65f, 0.65f, 1.0f);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glBindVertexArrayOES( _vertexArray[0]);
// Render the object with GLKit
glDrawArrays(GL_TRIANGLES, 0, 36);
/////////
glBindVertexArrayOES(_vertexArray[1]);
// Render the object with …Run Code Online (Sandbox Code Playgroud)