コード例 #1
0
 public static List <Rect> GetList(ref List <Rect> rList, long L, int nIndex)
 {
     try
     {
         long VM = FCLibHelper.fc_get_vm_ptr(L);
         if (rList == null)
         {
             rList = new List <Rect>();
         }
         else
         {
             rList.Clear();
         }
         long   ptr        = FCLibHelper.fc_get_param_ptr(L, nIndex);
         int    nArraySize = FCLibHelper.fc_get_array_size(ptr);
         Rect[] buffer     = new Rect[nArraySize];
         FCLibHelper.fc_get_array_rect(ptr, buffer, 0, nArraySize);
         rList.AddRange(buffer);
     }
     catch (Exception e)
     {
         Debug.LogException(e);
     }
     return(rList);
 }
コード例 #2
0
    public static Rect[] GetArray(ref Rect[] rList, long L, int nIndex)
    {
        long ptr        = FCLibHelper.fc_get_param_ptr(L, nIndex);
        int  nArraySize = FCLibHelper.fc_get_array_size(ptr);

        rList = new Rect[nArraySize];
        FCLibHelper.fc_get_array_rect(ptr, rList, 0, nArraySize);
        return(rList);
    }
コード例 #3
0
    public static List <Rect> GetList(ref List <Rect> rList, long L, int nIndex)
    {
        if (rList == null)
        {
            rList = new List <Rect>();
        }
        else
        {
            rList.Clear();
        }
        long ptr        = FCLibHelper.fc_get_param_ptr(L, nIndex);
        int  nArraySize = FCLibHelper.fc_get_array_size(ptr);

        Rect[] buffer = new Rect[nArraySize];
        FCLibHelper.fc_get_array_rect(ptr, buffer, 0, nArraySize);
        rList.AddRange(buffer);
        return(rList);
    }