示例#1
0
 public SGIO(SGIO orig) : this(modshogunPINVOKE.new_SGIO__SWIG_1(SGIO.getCPtr(orig)), true)
 {
     if (modshogunPINVOKE.SWIGPendingException.Pending)
     {
         throw modshogunPINVOKE.SWIGPendingException.Retrieve();
     }
 }
示例#2
0
 public void set_global_io(SGIO io)
 {
     modshogunPINVOKE.SGObject_set_global_io(swigCPtr, SGIO.getCPtr(io));
     if (modshogunPINVOKE.SWIGPendingException.Pending)
     {
         throw modshogunPINVOKE.SWIGPendingException.Retrieve();
     }
 }
示例#3
0
        public void printStructure()
        {
            //display debug texts
            Grammar g   = SceneManager.SelectedGrammar;
            string  txt = "";

            txt += "Grammar.currentStep=" + g.currentStep.ToString();
            for (int i = 0; i < g.stagedOutputs.Count; i++)
            {
                if (i < g.subNodes.Count)
                {
                    txt += "\nRule #" + i.ToString() + g.subNodes[i].description;
                }
                else
                {
                    txt += "\nRule #" + i.ToString() + ">=" + g.subNodes.Count;
                }
                txt += "\n   Input: ";
                foreach (ShapeObject o in g.subNodes[i].inputs.shapes)
                {
                    if (o != null)
                    {
                        txt += o.Format() + ",";
                    }
                    else
                    {
                        txt += "null,";
                    }
                }
                txt += "\n   Output: ";
                foreach (ShapeObject o in g.subNodes[i].outputs.shapes)
                {
                    if (o != null)
                    {
                        txt += o.Format() + ",";
                    }
                    else
                    {
                        txt += "null,";
                    }
                }


                txt += "\n   Staged output: ";
                SGIO io = g.stagedOutputs[i];
                foreach (ShapeObject o in io.shapes)
                {
                    if (o != null)
                    {
                        txt += o.Format() + ",";
                    }
                }
                txt += "\n";
            }
            stageIOText.text = txt;
        }
示例#4
0
    public SGIO get_global_io()
    {
        IntPtr cPtr = modshogunPINVOKE.SGObject_get_global_io(swigCPtr);
        SGIO   ret  = (cPtr == IntPtr.Zero) ? null : new SGIO(cPtr, false);

        if (modshogunPINVOKE.SWIGPendingException.Pending)
        {
            throw modshogunPINVOKE.SWIGPendingException.Retrieve();
        }
        return(ret);
    }
示例#5
0
 internal static HandleRef getCPtr(SGIO obj)
 {
     return((obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr);
 }
示例#6
0
 public static void set_global_io(SGIO io) {
   modshogunPINVOKE.set_global_io(SGIO.getCPtr(io));
   if (modshogunPINVOKE.SWIGPendingException.Pending) throw modshogunPINVOKE.SWIGPendingException.Retrieve();
 }
示例#7
0
 public SGIO(SGIO orig) : this(modshogunPINVOKE.new_SGIO__SWIG_1(SGIO.getCPtr(orig)), true) {
   if (modshogunPINVOKE.SWIGPendingException.Pending) throw modshogunPINVOKE.SWIGPendingException.Retrieve();
 }
示例#8
0
 internal static HandleRef getCPtr(SGIO obj) {
   return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
 }