plowFindWidth() pass by-pointer const TileTypeBitMask* instead of by-value
sizeof(TileTypeBitMask) == 32
This commit is contained in:
parent
bc5a4a0fb1
commit
2ff6d6113d
|
|
@ -1762,7 +1762,7 @@ retry:
|
||||||
{
|
{
|
||||||
*prReal = *prMin;
|
*prReal = *prMin;
|
||||||
prReal->pr_next = prReal + 1;
|
prReal->pr_next = prReal + 1;
|
||||||
dist = plowFindWidth(edge, prMin->pr_oktypes, bbox, &maxBox);
|
dist = plowFindWidth(edge, &prMin->pr_oktypes, bbox, &maxBox);
|
||||||
|
|
||||||
/* Conservative test of whether we need to yank more */
|
/* Conservative test of whether we need to yank more */
|
||||||
if (plowYankMore(&maxBox, 1, 1))
|
if (plowYankMore(&maxBox, 1, 1))
|
||||||
|
|
|
||||||
|
|
@ -273,7 +273,7 @@ PlowTest(w, cmd)
|
||||||
editArea.r_ybot, editArea.r_ytop);
|
editArea.r_ybot, editArea.r_ytop);
|
||||||
saveDef = plowYankDef;
|
saveDef = plowYankDef;
|
||||||
plowYankDef = def;
|
plowYankDef = def;
|
||||||
(void) plowFindWidth(&edge, okTypes, &def->cd_bbox, &editArea);
|
(void) plowFindWidth(&edge, &okTypes, &def->cd_bbox, &editArea);
|
||||||
plowYankDef = saveDef;
|
plowYankDef = saveDef;
|
||||||
GeoTransRect(&EditToRootTransform, &editArea, &rootBox);
|
GeoTransRect(&EditToRootTransform, &editArea, &rootBox);
|
||||||
ToolMoveBox(TOOL_BL, &rootBox.r_ll, FALSE, rootBoxDef);
|
ToolMoveBox(TOOL_BL, &rootBox.r_ll, FALSE, rootBoxDef);
|
||||||
|
|
|
||||||
|
|
@ -62,13 +62,12 @@ int plowWidthNumChoices = 0;
|
||||||
*/
|
*/
|
||||||
|
|
||||||
int
|
int
|
||||||
plowFindWidth(edge, types, bbox, prect)
|
plowFindWidth(
|
||||||
Edge *edge; /* Edge along the LHS of this material */
|
Edge *edge, /* Edge along the LHS of this material */
|
||||||
TileTypeBitMask types; /* Types whose width is being computed. Note
|
const TileTypeBitMask *typesp,/* Types whose width is being computed.
|
||||||
* that this set is passed by value.
|
|
||||||
*/
|
*/
|
||||||
Rect *bbox; /* Bounding box of the cell */
|
Rect *bbox, /* Bounding box of the cell */
|
||||||
Rect *prect; /* (Debugging only): if this is non-NULL,
|
Rect *prect) /* (Debugging only): if this is non-NULL,
|
||||||
* the rectangle it points to is filled
|
* the rectangle it points to is filled
|
||||||
* in with the rectangle found by this
|
* in with the rectangle found by this
|
||||||
* algorithm to be the largest containing
|
* algorithm to be the largest containing
|
||||||
|
|
@ -76,6 +75,7 @@ plowFindWidth(edge, types, bbox, prect)
|
||||||
* set 'types'.
|
* set 'types'.
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
|
TileTypeBitMask types = *typesp; /* TTMaskCopy(&types, typesp); */
|
||||||
Plane *plane = plowYankDef->cd_planes[edge->e_pNum];
|
Plane *plane = plowYankDef->cd_planes[edge->e_pNum];
|
||||||
TileTypeBitMask ctypes;
|
TileTypeBitMask ctypes;
|
||||||
struct wclip wc;
|
struct wclip wc;
|
||||||
|
|
|
||||||
|
|
@ -257,7 +257,7 @@ extern int plowApplySearchRules();
|
||||||
extern int plowAtomize();
|
extern int plowAtomize();
|
||||||
extern void plowCleanupJogs();
|
extern void plowCleanupJogs();
|
||||||
extern void plowDebugEdge();
|
extern void plowDebugEdge();
|
||||||
extern int plowFindWidth();
|
extern int plowFindWidth(Edge *edge, const TileTypeBitMask *typesp, Rect *bbox, Rect *prect);
|
||||||
extern int plowFindWidthBack();
|
extern int plowFindWidthBack();
|
||||||
extern int plowGenRandom();
|
extern int plowGenRandom();
|
||||||
extern void plowQueueDone();
|
extern void plowQueueDone();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue