예제 #1
0
        public XbimGeometryEngine()
        {
            // Warn if runtime for Engine is not present
            XbimPrerequisitesValidator.Validate();

            var    conventions  = new XbimArchitectureConventions(); // understands the process we run under
            string assemblyName = "Xbim.Geometry.Engine" + conventions.Suffix;

            ObjectHandle oh = Activator.CreateInstance(assemblyName, "Xbim.Geometry.XbimGeometryCreator");

            _engine = oh.Unwrap() as IXbimGeometryCreator;
        }
예제 #2
0
        public XbimGeometryEngine()
        {
            // Warn if runtime for Engine is not present
            XbimPrerequisitesValidator.Validate();

            var    conventions  = new XbimArchitectureConventions(); // understands the process we run under
            string assemblyName = conventions.ModuleName + conventions.Suffix;

            try
            {
                var ass = Assembly.Load(assemblyName);
                var oh  = Activator.CreateInstance(ass.FullName, "Xbim.Geometry.XbimGeometryCreator");
                _engine = oh.Unwrap() as IXbimGeometryEngine;
            }
            catch (Exception e)
            {
                throw e;
            }
        }