Skip to content

UnityEngine Surface

TL;DR: CVR ships ~288 generated per-type binders covering a deliberately scoped slice of Unity: core engine objects (Transform, GameObject, Rigidbody, Colliders, Renderer, Material, Texture, etc.), animation, audio mixers, full NavMesh, rendering command buffers, SceneManagement, core UI graphics, and TMPro. This page lists what’s covered by namespace, with links back to the on-disk files.

  1. Look in CVR-GameFiles/WasmBinder.Links.{Namespace}/{TypeName}Link.cs.
  2. Look in CVR-GameFiles/WasmBinder.LinksManual.UnityEngine/ for any overrides (Debug, GameObject, GraphicsBuffer, Object).
  3. If neither exists, the type is not bound. The guest-side shim from CCKWasmModule will typically refuse to compile against it.

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine/.

Coverage grouped by top-level concern:

  • Transform, RectTransform
  • GameObject (manual overrides in LinksManual.UnityEngine/GameObjectLinksManual.cs)
  • Object (manual, covers base class identity)
  • Component
  • Renderer, MeshRenderer, SkinnedMeshRenderer
  • Material, MaterialPropertyBlock, MaterialGlobalIlluminationFlags
  • Mesh, MeshFilter, MeshTopology, MeshCollider
  • Texture, Texture2D, Texture3D, Texture2DArray, TextureFormat, TextureWrapMode, FilterMode, RenderTexture, RenderBuffer, CustomRenderTexture, CustomRenderTextureInitializationSource, CustomRenderTextureUpdateMode, CustomRenderTextureUpdateZoneSpace
  • Shader, Hash128
  • Light, LightBakingOutput, LightProbeProxyVolume, LightProbes, LightmapSettings, LightmapData, LightShadowResolution, LightShadows, LightShape, LightType, LightRenderMode
  • ReflectionProbe
  • Camera, CameraType, CameraClearFlags, CameraEvent (in Rendering)
  • FlareLayer, Flare
  • StereoscopicEye, StereoTargetEyeMask, SinglePassStereoMode (in Rendering)
  • Animator, AnimatorClipInfo, AnimatorControllerParameter, AnimatorCullingMode, AnimatorRecorderMode, AnimatorUpdateMode
  • AnimationClip, AnimationCurve, AnimationEvent
  • Motion, MotionVectorGenerationMode
  • Avatar, AvatarIKGoal, AvatarIKHint, AvatarTarget
  • Rigidbody, RigidbodyConstraints, RigidbodyInterpolation, RigidbodyType2D
  • Collider, BoxCollider, SphereCollider, CapsuleCollider, MeshCollider, WheelCollider, CharacterController
  • ArticulationBody, ArticulationDofLock, ArticulationDrive, ArticulationDriveType, ArticulationJointType, ArticulationReducedSpace
  • Physics, PhysicsScene, PhysicMaterial, PhysicMaterialCombine
  • RaycastHit, RaycastHit2D, QueryTriggerInteraction
  • ForceMode, CollisionDetectionMode, CollisionFlags
  • Joint variants (character, fixed, hinge, spring, …)
  • Bounds, BoundingBoxMode
  • AudioSource, AudioListener, AudioClip, AudioBehaviour
  • AudioRolloffMode, AudioVelocityUpdateMode
  • See also UnityEngine.Audio below.
  • Time (read-only)
  • KeyCode, LayerMask, Space
  • PrimitiveType, HideFlags
  • Coroutine
  • WaitForSeconds, WaitForEndOfFrame, WaitForFixedUpdate, WaitUntil, WaitWhile (check per-type)
  • Quaternion, Vector2, Vector3, Vector4, Color, Color32, Matrix4x4 (value types surfaced by value)
  • ParticleSystem and related enums
  • Debug (manual)
  • GraphicsBuffer (manual)
  • Random
  • GeometryUtility, PlayerLoopSystem, PlayerLoop

Exact list: ls "CVR-GameFiles/WasmBinder.Links.UnityEngine/".

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.AI/. Full NavMesh surface:

NavMeshAgent, NavMeshObstacle, NavMesh, NavMeshData, NavMeshDataInstance, NavMeshLink, NavMeshLinkData, NavMeshLinkInstance, NavMeshHit, NavMeshPath, NavMeshPathStatus, NavMeshQueryFilter, NavMeshTriangulation, NavMeshBuildDebugFlags, NavMeshBuildDebugSettings, NavMeshBuilder, NavMeshBuildMarkup, NavMeshBuildSource, NavMeshBuildSourceShape, NavMeshCollectGeometry, NavMeshObstacleShape, ObstacleAvoidanceType, OffMeshLink, OffMeshLinkData, OffMeshLinkType.

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.Audio/.

AudioMixer, AudioMixerGroup, AudioMixerSnapshot, AudioMixerUpdateMode.

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.EventSystems/.

UIBehaviour. Most UI event interfaces (IPointerClickHandler, etc.) are not bound — use persistent UnityEvents via the inspector (see Unity Events Rewiring).

UnityEngine.Experimental.Rendering (7 types)

Section titled “UnityEngine.Experimental.Rendering (7 types)”

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.Experimental.Rendering/.

DefaultFormat, GraphicsFormat, RayTracingAccelerationStructure, RayTracingMode, RayTracingShader, RayTracingSubMeshFlags, TextureCreationFlags.

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.Rendering/. Full CommandBuffer + scriptable rendering pipeline surface. Highlights:

  • CommandBuffer, CommandBufferExecutionFlags
  • AsyncGPUReadbackRequest
  • BuiltinRenderTextureType, CameraEvent, CameraProperties
  • ComputeQueueType, GraphicsFence, GraphicsFenceType, GraphicsTier
  • IndexFormat, MeshUpdateFlags, SubMeshDescriptor, VertexAttribute*
  • LocalKeyword, GlobalKeyword, LocalKeywordSpace, ShaderKeywordType, ShaderPropertyFlags, ShaderPropertyType, ShaderTagId
  • RenderTargetBinding, RenderTargetFlags, RenderTargetIdentifier
  • ReflectionProbe* variants
  • ShadowCastingMode, ShadowSamplingMode
  • SphericalHarmonicsL2
  • ScriptableCullingParameters, LODParameters, RendererList
  • SynchronisationStage*

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.SceneManagement/.

Scene struct. Scene loading APIs (SceneManager.LoadScene, etc.) are not bound — CVR manages world scene loading itself.

Path: CVR-GameFiles/WasmBinder.Links.UnityEngine.UI/.

Graphic, MaskableGraphic, CanvasUpdate.

Most UI widgets (Button, Slider, Toggle, Image, Text, Dropdown, InputField, ScrollRect) are available via the CCKWasmModule shim without direct binder links — scripts interact with them via their persistent UnityEvents and by reading serialized state on the wrapped component. If you need runtime mutation of UI state you go through Transform, GameObject, or MaskableGraphic.

Path: CVR-GameFiles/WasmBinder.Links.TMPro/.

  • TextMeshProUGUI (the UI variant used in CVR worlds)
  • TMP_Text, TMP_Style
  • Alignment/style/color enums: HorizontalAlignmentOptions, VerticalAlignmentOptions, TextAlignmentOptions, FontStyles, FontWeight, ColorMode, TextOverflowModes, TextRenderFlags, TextureMappingOptions, TMP_VertexDataUpdateFlags, VertexGradient, VertexSortingOrder

Path: CVR-GameFiles/WasmBinder.Links.CVR/.

CVRCamera, CVRCameraRenderingMode, CVRPlayerCamera, CVRPortableCamera.

These augment the CVR host bindings with typed access to CVR’s camera components. Plus the CCK component set — documented separately in the CCK section of this book.

CVR-GameFiles/WasmBinder.Links.UnityEngine/TransformLink.cs:

linker.DefineFunction("UnityEngine", "UnityEngineTransform__get__position",
(CallerAction<long, int>)delegate(Caller callerParam, long selfObjectId, int positionPointer)
{
StoreData data = WasmBindingUtils.GetData(callerParam);
CVRScriptScopeContext scope = CVRScriptScopeContext.Any;
try {
Transform transform = WasmBindingUtils.IdToClass<Transform>(data, selfObjectId, ref scope);
data.AccessManager.CheckAccess("UnityEngineTransform__get__position",
CVRScriptObjectContext.Any, CVRScriptOwnerContext.Any,
CVRScriptScopeContext.Any, scope);
data.Memory.Write(positionPointer, transform.position);
} catch (Exception ex) {
WasmBindingUtils.RaiseException(data, ex);
}
});

Every generated getter follows this skeleton. Setters swap Memory.Write for Memory.Read and narrow the scope mask to Self.