Skip to content

A Reconstruct Series made of Simple Shapes suitable for Development and Testing

Notifications You must be signed in to change notification settings

SynapseWeb/Simple-Shapes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 

Repository files navigation

Simple-Shapes

A Reconstruct Series made of Simple Shapes suitable for Development and Testing

This series is designed for rapid testing of code. The shapes are intentionally simple to allow quick tracing and relatively easy examination and interpretation of the XML.

Animation showing slices inside the original objects:

SlicingAnimation

Usage Examples

Understanding Closed Point-by-Point Drawing Mode (Reconstruct.exe)

The following two images show the points created with the "Closed Point-by-Point Drawing" tool in Reconstruct.exe version 1.1.0.0.

This first image shows the points that result from drawing the polygons with "simplify" ("Automatically simplify new closed traces after drawing") turned off. The numbers show the order and locations of the individual mouse clicks to create the trace. There is exactly one point per mouse click (although the ordering of the points seems to be reversed from the clicks).

SimplifyOff

This second image shows the points that result from the same process with "simplify" turned on (the default setting). Note the additional points that Reconstruct has inserted between the actual mouse clicks.

SimplifyOn

This image shows some close up views of the newly inserted points. The points with white circles were the locations of the actual mouse clicks. The other points were generated by Reconstruct.exe.

SimplifyOnDetail

Understanding point ordering (Reconstruct.exe)

The Reconstruct manual is very clear about defining positive area (clockwise) traces and negative area (counterclockwise) traces. In the second paragraph of Chapter 8 (Traces), the manual states:

"Point order is clockwise for traces with positive orientation. Clockwise traces have positive area and enclose the interior of the object. Counterclockwise traces have negative area and enclose holes."

However, it appears that Reconstruct.exe stores points in the XML in reverse ordering from this convention. The following diagram is taken from the "simple_Shapes_1" image (in this repository). It shows the coordinates of the triangle from that image:

TrianglePoints

This triangle was traced with the original Reconstruct.exe (1.1.0.0) using the "Closed Point-by-Point Drawing" tool described on page 72 of the manual with "Automatically simplify" turned off. The points were traced in clockwise order starting with the "Top" point, followed by the "Lower Right" (LR) point, and concluded with the "Lower Left" (LL) point. However, the points list in the XML file are listed in reverse order. Here's the XML file:

<?xml version="1.0"?>
<!DOCTYPE Section SYSTEM "section.dtd">

<Section index="1" thickness="0.05" alignLocked="false">
<Transform dim="0"
 xcoef=" 0 1 0 0 0 0"
 ycoef=" 0 0 1 0 0 0">
<Image mag="0.00254" contrast="1" brightness="0" red="true" green="true" blue="true"
 src="simple_shapes_1.jpg" />
<Contour name="domain1" hidden="false" closed="true" simplified="false" border="1 0 1" fill="1 0 1" mode="11"
 points="0 0,
	591 0,
	591 479,
	0 479,
	"/>
</Transform>

<Transform dim="0"
 xcoef=" 0 1 0 0 0 0"
 ycoef=" 0 0 1 0 0 0">
<Contour name="domain1" hidden="false" closed="true" simplified="false" border="1 0 1" fill="1 0 1" mode="9"
 points="0.569187 0.876916,
	0.914512 0.874591,
	0.738943 1.16992,
	"/>
</Transform>

</Section>

Notice the "points" list in the last transform:

 points="0.569187 0.876916,
	 0.914512 0.874591,
	 0.738943 1.16992,
	 "

The first point (0.569187 0.876916) is the Lower Left (LL) point. The second point (0.914512 0.874591) is the Lower Right (LR) point. The final point (0.738943 1.16992) is the Top point. This is actually a counterclockwise direction. So the ordering of the points as traced (Top, LR, LL) was changed when stored in the XML file to be (LL, LR, Top).

The following image shows the use of Reconstruct.java to examine the direction of traces in a section. The points and arrows are shown or hidden through the "Extras / Line" menu in Reconxtruct.java.

ReconstructPointOrdering

These points are drawn as listed in the XML file (counterclockwise) ... even through they were originally drawn in the clockwise direction. The square shows the first point of the trace in the file.

About

A Reconstruct Series made of Simple Shapes suitable for Development and Testing

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages