zoukankan      html  css  js  c++  java
  • Plugins in Unity

    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

  • 相关阅读:
    react-echarts之折线图的显示
    Log4j2
    测试驱动开发Junit4
    JavaWeb基础: Cookie
    JavaWeb前端:Bootstrap基础
    JavaWeb前端:CSS
    JavaWeb前端:JQuery
    Android基础:Activity
    JavaWeb前端: JavaScript 简介
    JavaWeb前端:HTML5 简介
  • 原文地址:https://www.cnblogs.com/tekkaman/p/3973475.html
Copyright © 2011-2022 走看看