Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
3e477651
Commit
3e477651
authored
Mar 18, 2009
by
charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
finishing work on hpgl plotting functions
parent
f9642fd4
Changes
3
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
299 additions
and
358 deletions
+299
-358
pcbplot.h
pcbnew/pcbplot.h
+86
-78
plot_rtn.cpp
pcbnew/plot_rtn.cpp
+136
-95
plothpgl.cpp
pcbnew/plothpgl.cpp
+77
-185
No files found.
pcbnew/pcbplot.h
View file @
3e477651
/************/
/* pcbplot.h*/
/************/
/************/
/* pcbplot.h*/
/************/
#ifndef PCBPLOT_H
#define PCBPLOT_H
...
...
@@ -36,7 +36,7 @@ eda_global int g_Plot_Mode // = FILAIRE, FILL or SKETCH
=
FILLED
#endif
;
eda_global
bool
Plot_Set_MIROIR
;
eda_global
bool
Plot_Set_MIROIR
;
eda_global
bool
Sel_Rotate_Window
;
eda_global
bool
HPGL_Org_Centre
;
// TRUE si en HPGL, l'origine le centre de la feuille
eda_global
int
g_PlotPSColorOpt
;
// True for color Postscript output
...
...
@@ -66,11 +66,11 @@ eda_global bool PlotPadsOnSilkLayer /* Plot pads sur couche serigraphie */
#endif
;
eda_global
bool
Plot_Pads_All_Layers
;
/* Plot pads meme n'appartenant pas a la
couche ( utile pour serigraphie) */
*
couche ( utile pour serigraphie) */
/* Variables utiles */
/* Variables utiles */
eda_global
FILE
*
dest
;
eda_global
FILE
*
dest
;
/* Gestion des plumes en plot format HPGL */
eda_global
int
g_HPGL_Pen_Num
/* num de plume a charger */
...
...
@@ -87,11 +87,11 @@ eda_global int g_HPGL_Pen_Diam; /* diametre en mils */
eda_global
int
g_HPGL_Pen_Recouvrement
;
/* recouvrement en mils ( pour remplissages */
/* Gestion des cadrages et echelles de trace */
eda_global
float
Scale_X
,
Scale_Y
;
/* coeff d'agrandissement en X et Y demandes */
eda_global
float
Scale_X
,
Scale_Y
;
/* coeff d'agrandissement en X et Y demandes */
eda_global
wxPoint
g_PlotOffset
;
/* Offset de trace modifies par l'echelle */
eda_global
int
g_PlotLine_Width
;
/* Largeur du trait en mode filaire (utilise en serigraphie,
pour traces en mode sketch et filaire) */
*
pour traces en mode sketch et filaire) */
eda_global
int
g_PlotFormat
/* id for plot format (see enum PlotFormat in plot_common.h) */
#ifdef MAIN
...
...
@@ -99,9 +99,9 @@ eda_global int g_PlotFormat /* id for plot format (see enum PlotFormat in plot_
#endif
;
eda_global
int
g_PlotOrient
;
/* numero de code de l'orientation du trace ( voir
defines precedents):
0 = normal
PLOT_MIROIR = MIROIR
*
defines precedents):
*
0 = normal
*
PLOT_MIROIR = MIROIR
*/
eda_global
int
g_PlotScaleOpt
// 0 = automatique, >=1 echelle specifiee
#ifdef MAIN
...
...
@@ -111,14 +111,14 @@ eda_global int g_PlotScaleOpt // 0 = automatique, >=1 echelle specifiee
eda_global
int
g_DrillShapeOpt
#ifdef MAIN
=
1
// 0 = no drill mark, 1 = small mark, 2 = real drill
=
1
// 0 = no drill mark, 1 = small mark, 2 = real drill
#endif
;
/*************************************/
/* Constantes utiles en trace GERBER */
/*************************************/
/*************************************/
/* Constantes utiles en trace GERBER */
/*************************************/
/* codes de type de forme d'outils */
#define GERB_CIRCLE 1
...
...
@@ -128,56 +128,64 @@ eda_global int g_DrillShapeOpt
#define GERB_DONUT 5
/* PLOT_RTN.CC */
void
PlotTextePcb
(
TEXTE_PCB
*
pt_texte
,
int
format_plot
,
int
masque_layer
);
/* Trace 1 Texte type PCB , c.a.d autre que les textes sur modules,
prepare les parametres de trace de texte */
void
PlotArc
(
int
format_plot
,
wxPoint
centre
,
int
start_angle
,
int
end_angle
,
int
rayon
,
int
width
);
void
PlotCircle
(
int
format_plot
,
int
width
,
wxPoint
centre
,
int
rayon
);
void
PlotFilledPolygon
(
int
format_plot
,
int
nbpoints
,
int
*
coord
);
void
PlotPolygon
(
int
format_plot
,
int
nbpoints
,
int
*
coord
,
int
width
);
void
PlotTextePcb
(
TEXTE_PCB
*
pt_texte
,
int
format_plot
,
int
masque_layer
);
void
PlotDrawSegment
(
DRAWSEGMENT
*
PtSegm
,
int
format_plot
,
int
masque_layer
);
/* Trace 1 Texte type PCB , c.a.d autre que les textes sur modules,
* prepare les parametres de trace de texte */
void
PlotArc
(
int
format_plot
,
wxPoint
centre
,
int
start_angle
,
int
end_angle
,
int
rayon
,
int
width
);
void
PlotCircle
(
int
format_plot
,
int
width
,
wxPoint
centre
,
int
rayon
);
void
PlotFilledPolygon
(
int
format_plot
,
int
nbpoints
,
int
*
coord
);
void
PlotPolygon
(
int
format_plot
,
int
nbpoints
,
int
*
coord
,
int
width
);
void
PlotCotation
(
COTATION
*
Cotation
,
int
format_plot
,
int
masque_layer
);
void
PlotDrawSegment
(
DRAWSEGMENT
*
PtSegm
,
int
format_plot
,
int
masque_layer
);
void
PlotMirePcb
(
MIREPCB
*
PtMire
,
int
format_plot
,
int
masque_layer
);
void
PlotCotation
(
COTATION
*
Cotation
,
int
format_plot
,
int
masque_layer
);
void
Plot_1_EdgeModule
(
int
format_plot
,
EDGE_MODULE
*
PtEdge
);
void
PlotMirePcb
(
MIREPCB
*
PtMire
,
int
format_plot
,
int
masque_layer
);
void
PlotFilledAreas
(
ZONE_CONTAINER
*
aZone
,
int
aFormat
);
void
Plot_1_EdgeModule
(
int
format_plot
,
EDGE_MODULE
*
PtEdge
);
void
PlotFilledAreas
(
ZONE_CONTAINER
*
aZone
,
int
aFormat
);
/* PLOTGERB.CPP */
void
SelectD_CODE_For_LineDraw
(
int
aSize
);
void
trace_1_contour_GERBER
(
wxPoint
pos
,
wxSize
size
,
wxSize
delta
,
int
penwidth
,
int
orient
);
/* Trace 1 contour rectangulaire ou trapezoidal d'orientation quelconque
donne par son centre, ses dimensions,
ses variations, l'epaisseur du trait et son orientation orient */
void
trace_1_contour_GERBER
(
wxPoint
pos
,
wxSize
size
,
wxSize
delta
,
int
penwidth
,
int
orient
);
/* Trace 1 contour rectangulaire ou trapezoidal d'orientation quelconque
* donne par son centre, ses dimensions,
* ses variations, l'epaisseur du trait et son orientation orient */
/* PLOTHPGL.CC */
void
trace_1_segment_HPGL
(
int
pos_X0
,
int
pos_Y0
,
int
pos_X1
,
int
pos_Y1
,
int
hauteur
);
/* PLOTHPGL.CPP */
void
trace_1_pad_TRAPEZE_HPGL
(
wxPoint
padpos
,
wxSize
size
,
wxSize
delta
,
int
orient
,
int
modetrace
);
/** Function Plot a filled segment (track)
* @param aStart = starting point
* @param aEnd = ending point
* @param aWidth = segment width (thickness)
* @param aPlotMode = FILLED, SKETCH ..
* @return true if Ok, false if aWidth > pen size (the segment is always plotted)
*/
bool
Plot_Filled_Segment_HPGL
(
wxPoint
aStart
,
wxPoint
aEnd
,
int
aWidth
,
GRFillMode
aPlotMode
);
void
trace_1_pastille_RONDE_HPGL
(
wxPoint
padpos
,
int
diametre
,
int
modetrace
)
;
void
trace_1_pastille_OVALE_HPGL
(
wxPoint
padpos
,
wxSize
size
,
int
orient
,
int
modetrace
);
void
PlotRectangularPad_HPGL
(
wxPoint
padpos
,
wxSize
padsize
,
int
orient
,
int
modetrace
);
void
trace_1_pad_TRAPEZE_HPGL
(
wxPoint
padpos
,
wxSize
size
,
wxSize
delta
,
int
orient
,
int
modetrace
);
void
trace_1_pastille_RONDE_HPGL
(
wxPoint
padpos
,
int
diametre
,
int
modetrace
);
void
trace_1_pastille_OVALE_HPGL
(
wxPoint
padpos
,
wxSize
size
,
int
orient
,
int
modetrace
);
void
PlotRectangularPad_HPGL
(
wxPoint
padpos
,
wxSize
padsize
,
int
orient
,
int
modetrace
);
/**************/
/* PLOTPS.CPP */
/**************/
void
trace_1_pastille_OVALE_POST
(
wxPoint
centre
,
wxSize
size
,
int
orient
,
int
modetrace
);
void
trace_1_pastille_RONDE_POST
(
wxPoint
centre
,
int
diametre
,
int
modetrace
);
void
trace_1_pad_rectangulaire_POST
(
wxPoint
centre
,
wxSize
size
,
int
orient
,
int
modetrace
);
void
trace_1_contour_POST
(
wxPoint
centre
,
wxSize
size
,
wxSize
delta
,
int
dim_trait
,
int
orient
);
void
trace_1_pad_TRAPEZE_POST
(
wxPoint
centre
,
wxSize
size
,
wxSize
delta
,
int
orient
,
int
modetrace
);
void
trace_1_pastille_OVALE_POST
(
wxPoint
centre
,
wxSize
size
,
int
orient
,
int
modetrace
);
void
trace_1_pastille_RONDE_POST
(
wxPoint
centre
,
int
diametre
,
int
modetrace
);
void
trace_1_pad_rectangulaire_POST
(
wxPoint
centre
,
wxSize
size
,
int
orient
,
int
modetrace
);
void
trace_1_contour_POST
(
wxPoint
centre
,
wxSize
size
,
wxSize
delta
,
int
dim_trait
,
int
orient
);
void
trace_1_pad_TRAPEZE_POST
(
wxPoint
centre
,
wxSize
size
,
wxSize
delta
,
int
orient
,
int
modetrace
);
#endif
/* #define PCBPLOT_H */
pcbnew/plot_rtn.cpp
View file @
3e477651
This diff is collapsed.
Click to expand it.
pcbnew/plothpgl.cpp
View file @
3e477651
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment