Vuforia SDK分析

Vuforia SDK分析VuforiaArchi 高通组件 camera nbsp nbsp nbsp 单实例 在需要摄像头的时候会返回唯一的摄像头实例 ImageConvert nbsp nbsp nbsp 单实例 像素级的图像转换器 在相机的 OpenGLESrend 格式和 tracking 的格式之间转换 Tracker nbsp nbsp nbsp 单实例 用一种可自定义变更的算法跟踪在摄像

Vuforia Architecture(高通组件)

camera

    单实例,在需要摄像头的时候会返回唯一的摄像头实例。

Image Converter

    单实例,像素级的图像转换器。在相机的 OpenGL ES rendering 格式和 tracking 的格式之间转换。

Tracker

Video Background Renderer

Application Code

    3个关键动作:

    1. 查询 state object 的最新状态, 并且标记或更新这些 state 的状态。

    2. 为新加入的数据更新程序逻辑。

    3. 把图形叠加并且显示到屏幕。

Target Resources

    目标资源创建于在线的 Target Management System  。下载的数据中包含 XML 配置文件,让开发者能配置一个跟踪特点,在二进制文件中还包含一个跟踪目标数据。

Trackables (可被追踪的目标)

参数:
  • Trackable type

                 Enum that defines the type of the trackable:

  •            UNKNOWN_TYPE – A trackable of unknown type.
  •           IMAGE_TARGET – A trackable of ImageTarget type.
  •           MULTI_TARGET – A trackable of MultiTarget type.
  •           MARKER – A trackable of Marker type.
  • Trackable name / identifier
                   A string that uniquely identifies the trackable within the database of targets.

                   Max string length: 25 characters
                   Character set: a-z, A-Z, 0-9,[ – _ .]
  • Trackable status
                   Each trackable has a status information associated with it in the State object, which is updated as each camera frame is processed. The status is    characterized by an enum:
  •                     UNKNOWN – The state of the trackable is unknown. This is usually returned before tracker initialization.
  •                    UNDEFINED – The state of the trackable is not defined.
  •                    NOT_FOUND – The trackable was not found, E.x. The referenced trackable is not part of the database.
  •                    DETECTED – The trackable was detected in this frame.
  •                   TRACKED – The trackable was tracked in this frame.
  • Trackable pose
                     Current valid pose of a 
DETECTEDor
TRACKED trackable is returned as a 3×4 matrix in row-major order. The Vuforia SDK provides simple tool functions to convert the Vuforia pose matrix into a GL model-view matrix, and to project 3D points from the 3D scene to the device screen.


坐标系统:

    高通SKD使用右手坐标系,坐标系如下图:

Vuforia SDK分析

x:右为正方向

y:正上方为正方向

z:远离图像的方向为正方向

Relevant API’s

           QCAR::Trackable::

           TYPE getType ()
           bool isOfType (TYPE type)
           STATUS getStatus ()
           int getId ()
           char* getName ()
           Matrix34F& getPose ()
           TYPE { UNKNOWN_TYPE, IMAGE_TARGET, MULTI_TARGET, MARKER }
           STATUS { UNKNOWN, UNDEFINED, NOT_FOUND, DETECTED, TRACKED }






           QCAR::State::

           Frame getFrame ()
           int getNumTrackables ()
           Trackable* getTrackable (int idx)
           int getNumActiveTrackables ()
           Trackable* getActiveTrackable (int idx)



Inherited Classes
  • Image Targets
  • Multi Targets
  • Frame Markers


Image Targets

定义:  

    目标是提前在 Target Management System 中输入的 JPG 或者 PNG 图形 (只有 RGB 或者 灰度图像是被支持的)。把这些数据保存在数据库并在运行的时候提取。

     高通SDK允许同时有多个图像目标,同时允许5个目标在摄像头范围内(性能随CPU和GPU限制)。高通SDK同时可以允许50个图像目标在资源数据库中。在运行的时候允许交换数据集,这使得应用程序可以容纳更多的目标。

其他详细说明:https://ar.qualcomm.at/qdevnet/developer_guide Image Targets 章节

Multi Targets

定义:

    多目标数据集的一部分。注意,数据集可以被加载,激活,残疾,卸在运行时。详细信息请参见图像目标的DevGuide节。

其他详细说明:https://ar.qualcomm.at/qdevnet/developer_guide Multi Targets 章节


Frame Markers

定义:

    除了基于特征检测和跟踪,Vuforia SDK可以跟踪一个特殊类型的基准标记称为“框架标记”。独特的id的一个框架标记是编码到一个二进制模式沿着边境的标记图像。一个框架标记允许任何图像被放置在标记边界。他们是更可取的,因为他们看起来更自然比其它更传统的基准的标记。这个Vuforia SDK要求框架和二进制模式是完全可见的相机形象识别。

    不像图像目标,框架生成的标记并不是在线目标管理系统。所有512架标记作为存档分布在资产\文件夹的Vuforia SDK安装。扩展他们适当的可打印的大小、使用规模经营的“没有过滤”或“最近邻”选项在任何图像编辑器(如Adobe Photoshop)。

其他详细说明:https://ar.qualcomm.at/qdevnet/developer_guide  Frame Markers 章节

Virtual Buttons

定义:

其他详细说明:https://ar.qualcomm.at/qdevnet/developer_guide  Virtual Buttons 章节









版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/228234.html原文链接:https://javaforall.net

(0)
上一篇 2026年3月16日 下午7:30
下一篇 2026年3月16日 下午7:30


相关推荐

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号