예제 #1
0
        public bool Reset(AgCrdnAxesPluginResultReset Result)
        {
            string objPath = "[" + Result.ObjectPath + "]";

            Debug.WriteLine(m_DisplayName + ".Reset()", "Entered:");

            m_CalcToolProvider   = Result.CalcToolProvider;
            m_VectorToolProvider = Result.VectorToolProvider;

            m_ICRFAxes = m_VectorToolProvider.ConfigureAxes("ICRF", "<MyObject>", "ICRF", "<MyObject>");

            Debug.WriteLine(m_DisplayName + ".Reset()", "Exited:");

            return(true);
        }
예제 #2
0
        public bool PreCompute(AgAccessConstraintPluginResultPreCompute Result)
        {
            // Get the topocentric Axes from the Vector Tool,
            // for the Facility/Target, to be used in the computation later

            AgAccessConstraintPluginObjectDescriptor baseDesc = Result.Base;
            string basePath = baseDesc.ObjectPath;

            if (basePath != "")
            {
                if (!m_AxesHash.ContainsKey(basePath))
                {
                    AgCrdnPluginProvider vgtProvider = baseDesc.VectorToolProvider;

                    if (vgtProvider != null)
                    {
                        string cbName = "Earth";                        //
                        cbName = baseDesc.CentralBodyName;
                        cbName = "CentralBody/" + cbName;

                        AgCrdnConfiguredAxes topoAxes = vgtProvider.ConfigureAxes(
                            "Fixed", cbName, "TopoCentric", "");

                        if (topoAxes != null && topoAxes.IsConfigured)
                        {
                            m_AxesHash.Add(basePath, topoAxes);
                        }
                    }
                }
            }

            if (m_Site != null && m_DebugMode)
            {
                Message(AgEUtLogMsgType.eUtLogMsgInfo, m_DisplayName + ": PreCompute()");
            }

            return(true);
        }