@@ -29,11 +29,31 @@ namespace SubjectNerd.PsdImporter.Reconstructor
2929{
3030 public struct ReconstructData
3131 {
32+ /// <summary>
33+ /// Sprite that corresponds to the layer indexId
34+ /// </summary>
3235 public Dictionary < int [ ] , Sprite > spriteIndex ;
33- public Dictionary < int [ ] , Vector2 > spriteAnchors ;
36+ /// <summary>
37+ /// Anchor information that corresponds to the layer indexId.
38+ /// Ratio of the Sprite size
39+ /// </summary>
40+ public Dictionary < int [ ] , Vector2 > spriteAnchors ;
41+ /// <summary>
42+ /// Size and position data of PSD layer, corresponds to the layer indexId.
43+ /// Data in document pixel space
44+ /// </summary>
3445 public Dictionary < int [ ] , Rect > layerBoundsIndex ;
46+ /// <summary>
47+ /// Size of the PSD, in pixels
48+ /// </summary>
3549 public Vector2 documentSize ;
50+ /// <summary>
51+ /// Pivot position for the PSD document, in ratio of size
52+ /// </summary>
3653 public Vector2 documentPivot ;
54+ /// <summary>
55+ /// Unity pixels per unit value of the PSD document
56+ /// </summary>
3757 public float documentPPU ;
3858
3959 public ReconstructData ( Vector2 docSize , Vector2 docPivot , float PPU )
@@ -67,6 +87,13 @@ public interface IReconstructor
6787 /// <returns></returns>
6888 bool CanReconstruct ( GameObject selection ) ;
6989
90+ /// <summary>
91+ /// Function that rebuilds the PSD structure
92+ /// </summary>
93+ /// <param name="root">The root of the PSD to reconstruct</param>
94+ /// <param name="data">Data gathered by the importer for rebuilding the layers with</param>
95+ /// <param name="selection">Object user has selected</param>
96+ /// <returns></returns>
7097 GameObject Reconstruct ( ImportLayerData root , ReconstructData data , GameObject selection ) ;
7198
7299 /// <summary>
0 commit comments