Version: 
  • C# API

    Show / Hide Table of Contents
    • PiXYZ
      • CoreLoadingException
      • NoValidLicenseException
      • OutOfTermsException
      • PiXYZDefinesManager
      • PiXYZException
    • PiXYZ.Config
      • Compatibility
      • Configuration
      • LicenseServer
      • Token
      • WebLicense
    • PiXYZ.Editor
      • AboutWindow
      • ColoredTheme
      • ColorType
      • DispatcherEditor
      • EditorExtensions
      • EditorGUIExtensions
      • IProgressBar
      • LicensingWindow
      • NonPersistentSerializer
      • PrefabDependenciesDestination
      • Preferences
      • ProgressBar
      • ScriptedImporterBehaviour
      • SingletonEditorWindow
      • StaticStyles
      • TextureCache
      • UpdateWindow
    • PiXYZ.Import
      • ExceptionHandler
      • Formats
      • Importer
      • ImportSettings
      • ImportSettingsTemplate
      • ImportStamp
      • LodGenerationSettings
      • LodGroupPlacement
      • LodQuality
      • LodsGenerationSettings
      • Metadata
      • Parameter<T>
      • ParameterAvailability
      • SubProcess
      • TransformVariant
      • VariantSets
      • VariantSets.MaterialSet
      • VariantSets.Set
      • VariantSets.Set<T, U>
      • VariantSets.TransformSet
      • VariantSets.VariantGroup
      • VariantSets.VariantSet
      • VariantSets.VariantStructure
      • VariantsManager
      • VariantsManager.MaterialSwitch
      • VariantsManager.Switch
      • VariantsManager.Switch<T>
      • VariantsManager.TransformSwitch
    • PiXYZ.Import.Editor
      • DropInSceneImporter
      • ImportSettingsEditor
      • ImportStampEditor
      • ImportWindow
      • LODsSettingsDrawer
      • MetadataEditor
      • PostProcessor
      • PostprocessVRED
      • PreprocessVRED
      • ScriptedImporter
      • ScriptedImporterAttribute
      • ScriptedImporterEditor
    • PiXYZ.Tools
      • ActionBase
      • ActionIn<Input>
      • ActionInOut<Input, Output>
      • ActionOut<Output>
      • FieldInstance
      • FieldInstanceSerializer
      • FilterParameter
      • FreePassAction
      • HelperMethod
      • IRenamable
      • PrefabModificationException
      • Rule
      • RuleBlock
      • RuleSet
      • ToolboxMenuItems
      • ToolsBase
      • UserParameter
    • PiXYZ.Tools.Builtin
      • AddChild
      • AddChild.Placement
      • AddCollider
      • AddCollider.ColliderType
      • AddLight
      • AddRigidbody
      • CreateLightmapUVs
      • CreateNormals
      • CreateUVs
      • Decimate
      • Decimate.DecimationCriterion
      • Decimate.DecimationQuality
      • Delete
      • ExplodeSubmeshes
      • FilterOnLayer
      • FilterOnMaterial
      • FilterOnMaterial.StringConstrain
      • FilterOnMetadata
      • FilterOnMetadata.PropName
      • FilterOnMetadata.PropName.PropertyNameConstrain
      • FilterOnMetadata.PropValue
      • FilterOnMetadata.PropValue.PropertyValueConstrain
      • FilterOnName
      • FilterOnName.StringConstrain
      • FilterOnPosition
      • FilterOnPosition.BoundsCondition
      • FilterOnTag
      • FlipNormals
      • GetAllGameObjects
      • GetChildAt
      • GetChildren
      • GetGameObject
      • GetImportedModel
      • GetLatestImportedModel
      • GetSelectedGameObjects
      • Merge
      • MoveOrigin
      • MoveOrigin.MovePivotOption
      • PrintGameObjectsInfo
      • PrintMaterialsInfo
      • PrintMeshesInfo
      • RandomizeTransform
      • RemoveHidden
      • RemoveHidden.SelectionLevelUnity
      • RepairMesh
      • ReplaceBy
      • ReplaceBy.ReplaceByMode
      • Retopologize
      • Retopologize.MeshReconstructionQuality
      • Retopologize.RetopologyMode
      • SetAsStatic
      • SetEnabled
      • SetLayer
      • SetMaterial
      • SetMesh
      • SetMetadata
      • SetName
      • SetPosition
      • SetPosition.Referential
      • SetTag
      • SwitchMaterials
      • SwitchMaterials.CopyReplace
      • SwitchMaterials.MaterialRemplacement
      • TextureQuality
    • PiXYZ.Tools.Editor
      • CoreContext
      • FieldInstanceDrawer
      • RenamePopup
      • RuleEngineMenu
      • RuleSetEditor
      • RuleSetWindow
      • Toolbox
      • ToolboxWindow
      • ToolsEditor
    • PiXYZ.Utils
      • BaseExtensions
      • CollectionExtensions
      • Dispatcher
      • Dispatcher.DelayedAction
      • Dispatcher.DelayFramesDispatch
      • Dispatcher.GoMainThreadDispatch
      • Dispatcher.GoThreadPoolDispatch
      • Dispatcher.SleepForSecondsDispatch
      • Dispatcher.WaitForSecondsDispatch
      • Dispatcher.YieldInstruction
      • DynamicEnum
      • FilePath
      • FloatingMesh
      • GameObjectToVoidHandler
      • GenericRenderer
      • LookupTable<K, V>
      • MergingContainer
      • MeshExtensions
      • Profiler
      • Profiling
      • ProgressHandler
      • Range
      • ReflectionExtensions
      • SceneExtensions
      • StringToStringHandler
      • TextureScaler
      • ThreadQueue
      • TypePathToUnityObject
      • UnityObjectToStringHandler
      • UnityObjectToUnityObjectHandler
      • VerticesData
      • VoidHandler

    Class Importer

    Single-use class for importing 3D data to Unity.
    This class can be used in the editor as well as in runtime, if the license requirements are met.

    Inheritance
    System.Object
    Importer
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: PiXYZ.Import
    Assembly: cs.temp.dll.dll
    Syntax
    public sealed class Importer

    Constructors

    Importer(String, ImportSettings)

    Declaration
    public Importer(string file, ImportSettings importSettings)
    Parameters
    Type Name Description
    System.String file
    ImportSettings importSettings

    Properties

    elaspedTicks

    Elasped ticks since the begining of the import.

    Declaration
    public long elaspedTicks { get; }
    Property Value
    Type Description
    System.Int64

    filePath

    The file to import

    Declaration
    public string filePath { get; set; }
    Property Value
    Type Description
    System.String

    gameObjectCount

    Declaration
    public int gameObjectCount { get; }
    Property Value
    Type Description
    System.Int32

    importedModel

    Declaration
    public ImportStamp importedModel { get; }
    Property Value
    Type Description
    ImportStamp

    importSettings

    Returns the ImportSettings reference

    Declaration
    public ImportSettings importSettings { get; set; }
    Property Value
    Type Description
    ImportSettings

    isAsynchronous

    [Default is True] If set to true, the import process will run as much as it can on different threads than the main one, so that it won't freeze the Editor/Application and performances are kept to the maximum. In Asynchronous mode, it is recommended to use callback methods to get information on the import status.

    Declaration
    public bool isAsynchronous { get; set; }
    Property Value
    Type Description
    System.Boolean

    isStopped

    Declaration
    public bool isStopped { get; }
    Property Value
    Type Description
    System.Boolean

    LatestModelImportedObject

    The GameObject reference to the latest imported model. Returns null if no model was imported during this session.

    Declaration
    public static ImportStamp LatestModelImportedObject { get; }
    Property Value
    Type Description
    ImportStamp

    LatestModelImportedPath

    The file path to the latest imported model. Returns null if no model was imported during this session.

    Declaration
    public static string LatestModelImportedPath { get; }
    Property Value
    Type Description
    System.String

    polycount

    Declaration
    public int polycount { get; }
    Property Value
    Type Description
    System.Int32

    postprocess

    Declaration
    public SubProcess postprocess { get; }
    Property Value
    Type Description
    SubProcess

    preprocess

    Declaration
    public SubProcess preprocess { get; }
    Property Value
    Type Description
    SubProcess

    printMessageOnCompletion

    [Default is True] If set to true, the importer will print a message in the console on import completion.

    Declaration
    public bool printMessageOnCompletion { get; set; }
    Property Value
    Type Description
    System.Boolean

    Methods

    AddOrSetPostprocess(String, SubProcess)

    Add a post-process action to run for a specific file format.

    Declaration
    public static void AddOrSetPostprocess(string format, SubProcess postprocessingAction)
    Parameters
    Type Name Description
    System.String format
    SubProcess postprocessingAction

    AddOrSetPreprocess(String, SubProcess)

    Add a pre-process action to run for a specific file format.

    Declaration
    public static void AddOrSetPreprocess(string format, SubProcess preprocessingAction)
    Parameters
    Type Name Description
    System.String format
    SubProcess preprocessingAction

    AddOrSetTemplate(String, ImportSettingsTemplate)

    Add a pre-process action to run for a specific file format.

    Declaration
    public static void AddOrSetTemplate(string format, ImportSettingsTemplate template)
    Parameters
    Type Name Description
    System.String format
    ImportSettingsTemplate template

    GetPostprocess(String)

    Declaration
    public static SubProcess GetPostprocess(string filePath)
    Parameters
    Type Name Description
    System.String filePath
    Returns
    Type Description
    SubProcess

    GetPreprocess(String)

    Declaration
    public static SubProcess GetPreprocess(string filePath)
    Parameters
    Type Name Description
    System.String filePath
    Returns
    Type Description
    SubProcess

    GetSettingsTemplate(String)

    Declaration
    public static ImportSettingsTemplate GetSettingsTemplate(string filePath)
    Parameters
    Type Name Description
    System.String filePath
    Returns
    Type Description
    ImportSettingsTemplate

    run()

    Starts importing the file. Can be executed only once per Importer instance.

    Declaration
    public void run()

    stop()

    Declaration
    public void stop()

    Events

    completed

    Callback function triggered when the importer has finished importing. In Async mode, this callback is triggered only when everything is finished. Always occurs in the main thread.

    Declaration
    public event GameObjectToVoidHandler completed
    Event Type
    Type Description
    GameObjectToVoidHandler

    failed

    Callback function trigerred when the import failed

    Declaration
    public event ExceptionHandler failed
    Event Type
    Type Description
    ExceptionHandler

    progressed

    Callback function triggered everytime the importer has progressed. Always occurs in the main thread.

    Declaration
    public event ProgressHandler progressed
    Event Type
    Type Description
    ProgressHandler
    Back to top PiXYZ Plugin for Unity 2019.1