Plugins in Unity

  In Unity, you normally use scripts to create functionality but you can also include code created outside Unity in the form of aPlugin. There are two kinds of plugins you can use in Unity: Managed plugins and Native plugins.

  Managed plugins is accessible to the standard .NET tools that Unity uses to compile scripts.

  Native plugins are not accessible to Unity’s tools in the way that managed libraries are.

  Unity has extensive support for Plugins, which are libraries of native code written in C, C++, Objective-C, etc. Plugins allow your game code (written in Javascript, C# or Boo) to call functions from these libraries. This feature allows Unity to integrate with middleware libraries or existing C/C++ game code.

  Note: For security reasons, plugins are not usable with webplayers.

  In order to use a plugin you need to do two things:

  • Write functions in a C-based language and compile them into a library.
  • Create a C# script which calls functions in the library.

  The plugin should provide a simple C interface which the C# script then exposes to other user scripts. It is also possible for Unity to call functions exported by the plugin when certain low-level rendering events happen (for example, when a graphics device is created).

参考:http://docs.unity3d.com/Manual/Plugins.html

Plugins in Unity的更多相关文章

  1. Gvr SDK for Unity 分析(二)

    前言 关于google vr sdk的具体使用,传送门 Gvr SDK for Unity 分析(一) Google Daydream平台已经整合进Google VR SDK 本文环境:Unity5. ...

  2. 怎么给Unity写一个原生的插件

    本文章由cartzhang编写,转载请注明出处. 所有权利保留. 文章链接:http://blog.csdn.net/cartzhang/article/details/50266889 作者:car ...

  3. linux mint & ubuntu 安装QQ国际版

    ubuntu安装QQ相对简单 下载qq国际版deb文件,直接安装即可. 下载地址: http://pan.baidu.com/s/1hqmYzlU 下面就重点说一下linux mint 安装qq. 1 ...

  4. Unity 特殊文件夹 Assets Resources StreamingAssets Editor Plugins......

    AssetsAssets文件夹是unity项目中放置游戏资源的主文件夹. 该文件夹中的内容将直接反应在编辑器的Project视口中.许多系统API基于该文件夹路径. ResourcesUnity允许你 ...

  5. Unity 使用Plugins接入安卓SDK 基础篇

    一.须知 本帖适合对安卓一点基础都没有,有一定Unity基础.刚刚接完一个某文档很简单的渠道SDk,也当是自己总结一下. 二.Unity中的目录创建与理解. Plugins:插件目录,该目录再编译项目 ...

  6. Unity Plugins的使用方法

    一.为插件设置平台的方法 unity5之前,是通过把插件搞到对应目录进行区分平台的(比如在build target是ios平台时只把IOS目录的插件build进去),unity5之后提供了设置平台/c ...

  7. Unity插件之Unity调用C#编译的DLL

    Unity插件分为两种:托管插件(Managed Plugins)和本地插件(Native Plugins).本文先来说说Unity中的托管插件,本地插件的文章留到下一篇文章再说. 有时候我们会有这样 ...

  8. Unity中脚本的执行顺序总结(@WhiteTaken)

    (Editor)以上是Unity官方文档中的截图,脚本在被挂载到物体上,会启用Editor的方法Reset. (Initialization)当执行脚本开始,初始化的过程中,依次执行的是Awake-& ...

  9. Unity 最佳实践

    转帖:http://www.glenstevens.ca/unity3d-best-practices/ 另外可以参考:http://devmag.org.za/2012/07/12/50-tips- ...

随机推荐

  1. python mysql基本操作

    1.创建数据库.表添加数据. # -*- coding: utf-8 -*- import MySQLdb.cursors conn =MySQLdb.connect(',charset = 'utf ...

  2. HttpMessageConvert

    1. 我们先来看看框架会自动注册哪些httpmessageconvert? 在哪个地方开始注册的? 在对mvc:annotation-driven解析的AnnotationDrivenBeanDefi ...

  3. js各种效果

    1.JavaScript 仿LightBox内容显示效果 2.固定高度的div,竖直方向出现滚动条,水平方向固定 http://www.jb51.net/css/109928.html <!do ...

  4. 容灾管理中的RTO与RPO的关系

    在灾难恢复方面,目前业界公认有三个目标值得努力.一是恢复时间,企业能忍受多长时间没有 IT,处于停业状态:二是网络多长时间能够恢复:三是业务层面的恢复.整个恢复过程中,最关键的衡量指标有两个:一个是 ...

  5. Java 设计模式之抽象工厂模式(三)

    原文地址:Java 设计模式之抽象工厂模式(三) 博客地址:http://www.extlight.com 一.前言 上篇文章 <Java 设计模式之工厂模式(二)>,介绍了简单工厂模式和 ...

  6. 打包python文件,让文件程序化

    通过对源文件打包,Python程序可以在没有安装 Python的环境中运行,也可以作为一个独立文件方便传递和管理. 现在网上主流的打包方式有两种py2exe或者pyinstaller两款多平台的Pyt ...

  7. erlang入门之编译和运行

    测试erlang脚本如下 -module(empty). -author("mmc"). %% API -export([test/1,test/0]). test()-> ...

  8. idea之jrebel热部署使用教程

    JRebel是一个J2EE热部署的工具.使用它可以减少浪费8-18%的开发时间在项目的构建和部署上.虽然Java也提供了HotSpot的JVM,但是如果你修改的类中有方法名称变动的话,HotSpot就 ...

  9. Tomcat原理的一点看法

    版权声明:本文为博主原创文章,未经博主允许不得转载. 首先,运行tomcat之前,先写一个html页面, 再写一个serlvet程序 配置文件如下: 那么程序是怎样运行的呢? 浏览器发起请求到 --& ...

  10. MySQL查询优化器工作原理解析

    手册上查询优化器概述 查询优化器的任务是发现执行SQL查询的最佳方案.大多数查询优化器,包括MySQL的查询优化器,总或多或少地在所有可能的查询评估方案中搜索最佳方案.对于联接查询,MySQL优化器所 ...