示例#1
0
            public InterpretationFromImage(Bitmap image)
            {
                Dictionary <String, Object> attrs = new Dictionary <String, Object>();

                attrs.Add("is_migrating", "true");
                interpretation = Tree.FromPixels(image, attrs);
            }
示例#2
0
        private static void Interpret(string appname, string filename)
        {
            try{
                Bitmap bitmap = Bitmap.FromFile(filename);
                Tree   start  = Tree.FromPixels(bitmap, new Dictionary <string, object>());



                //List<LayerWrapper> layers = LayerChain.LoadChain("prefab", @"../../../layers");
                //AnnotationUpdateUtility.UpdateInvalidatedLayers(layers);


                //Tree output = LayerChain.InterpretChain(layers, start);


                ////Print the output
                //string json = Tree.ToJson(output);
                //Console.WriteLine(json);

                //foreach(LayerWrapper l in layers)
                //    l.Layer.Close();
            }catch (Exception e) {
                FailedToLoad(filename, e);
            }
        }