Пример #1
0
        public void Init(HashTableSettings settings, ICommonDeviceInterface cdi)
        {
            this.settings = settings;
            settings["Molecule.Shading.Material.Type"] = "BySerie";

            // load settings
            BackColor = (Color)settings["View3D.BgClr"];

            // load local modules
            foreach (ISettingsModule module in modules)
            {
                module.LoadModuleSettings(settings);
            }

            renderContext           = new ChemRenderingContext3DDX9(settings, this, (CommonDeviceInterface)cdi);
            renderContext.BackColor = BackColor;

            // load default output settings
            CompleteOutputDescription desc = CompleteOutputDescription.LoadDescription(Assembly.GetExecutingAssembly().GetManifestResourceStream("NuGenSVisualLib.defaultOutput.xml"));

            desc.SchemeSettings         = new BallAndStickSchemeSettings();
            desc.SchemeSettings.AtomLOD = 2;
            ApplySettings(desc);
        }
Пример #2
0
        public void Init(HashTableSettings settings, ICommonDeviceInterface cdi)
        {
            this.settings = settings;
            settings["Molecule.Shading.Material.Type"] = "BySerie";

            // load settings
            BackColor = (Color)settings["View3D.BgClr"];

            // load local modules
            foreach (ISettingsModule module in modules)
            {
                module.LoadModuleSettings(settings);
            }

            renderContext = new ChemRenderingContext3DDX9(settings, this, (CommonDeviceInterface)cdi);
            renderContext.BackColor = BackColor;

            // load default output settings
            CompleteOutputDescription desc = CompleteOutputDescription.LoadDescription(Assembly.GetExecutingAssembly().GetManifestResourceStream("NuGenSVisualLib.defaultOutput.xml"));
            desc.SchemeSettings = new BallAndStickSchemeSettings();
            desc.SchemeSettings.AtomLOD = 2;
            ApplySettings(desc);
        }