mirror of
https://github.com/lucaspalomodevelop/meshlab.git
synced 2026-03-20 03:16:10 +00:00
Added the Pen Radius Slider
This commit is contained in:
parent
7bae6905b5
commit
dcccc26d20
@ -275,9 +275,6 @@ void EditSegment::StartEdit(QAction * mode, MeshModel & m, GLArea * parent) {
|
||||
parent->setCursor(QCursor(
|
||||
QPixmap(":/images/editsegment_cursor.png", "PNG"), 1, 1));
|
||||
|
||||
/*if (!meshCut)
|
||||
meshCut = new MeshCutting<CMeshO>(&m.cm);*/
|
||||
|
||||
if (!glarea_map.contains(parent)) {
|
||||
glarea_map.insert(parent, new MeshCutting<CMeshO>(&m.cm));
|
||||
}
|
||||
@ -307,7 +304,7 @@ void EditSegment::StartEdit(QAction * mode, MeshModel & m, GLArea * parent) {
|
||||
SLOT(ColorizeMeanSlot()));
|
||||
QObject::connect(meshCutDialog, SIGNAL(normalWeightSignal(int)),this, SLOT(changeNormalWeight(int)));
|
||||
QObject::connect(meshCutDialog, SIGNAL(curvatureWeightSignal(int)),this, SLOT(changeCurvatureWeight(int)));
|
||||
|
||||
QObject::connect(meshCutDialog, SIGNAL(penRadiusSignal(int)),this, SLOT(changePenRadius(int)));
|
||||
}
|
||||
meshcut_dock->setVisible(true);
|
||||
meshcut_dock->layout()->update();
|
||||
@ -533,6 +530,10 @@ void EditSegment::changeNormalWeight(int value) {
|
||||
normalWeight = value;
|
||||
}
|
||||
|
||||
void EditSegment::changePenRadius(int value) {
|
||||
pen.radius = value;
|
||||
}
|
||||
|
||||
void EditSegment::ColorizeGaussianSlot() {
|
||||
if (meshCut) {
|
||||
meshCut->ColorizeCurvature(true);
|
||||
|
||||
@ -20,8 +20,6 @@
|
||||
|
||||
struct Penn {
|
||||
float radius;
|
||||
int paintutensil;
|
||||
int painttype;
|
||||
bool backface;
|
||||
bool invisible;
|
||||
};
|
||||
@ -91,6 +89,7 @@ public slots:
|
||||
void doRefineSlot(bool);
|
||||
void changeNormalWeight(int);
|
||||
void changeCurvatureWeight(int);
|
||||
void changePenRadius(int);
|
||||
|
||||
void ColorizeGaussianSlot();
|
||||
void ColorizeMeanSlot();
|
||||
|
||||
@ -38,6 +38,9 @@ void MeshCutDialog::on_curvatureWeightSlider_valueChanged() {
|
||||
emit curvatureWeightSignal(ui.curvatureWeightSlider->value());
|
||||
}
|
||||
|
||||
void MeshCutDialog::on_penRadiusSlider_valueChanged() {
|
||||
emit penRadiusSignal(ui.penRadiusSlider->value());
|
||||
}
|
||||
|
||||
//debug function
|
||||
void MeshCutDialog::on_gaussianButton_clicked() {
|
||||
|
||||
@ -34,12 +34,16 @@ private:
|
||||
void on_normalWeightSlider_valueChanged();
|
||||
void on_curvatureWeightSlider_valueChanged();
|
||||
|
||||
void on_penRadiusSlider_valueChanged();
|
||||
|
||||
signals:
|
||||
void meshCutSignal();
|
||||
void selectForegroundSignal(bool);
|
||||
void doRefineSignal(bool);
|
||||
void normalWeightSignal(int);
|
||||
void curvatureWeightSignal(int);
|
||||
|
||||
void penRadiusSignal(int);
|
||||
|
||||
void colorizeGaussianSignal();
|
||||
void colorizeMeanSignal();
|
||||
|
||||
@ -31,8 +31,8 @@
|
||||
<widget class="QWidget" name="layoutWidget" >
|
||||
<property name="geometry" >
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>14</y>
|
||||
<x>12</x>
|
||||
<y>16</y>
|
||||
<width>116</width>
|
||||
<height>153</height>
|
||||
</rect>
|
||||
@ -74,14 +74,14 @@
|
||||
<item>
|
||||
<layout class="QVBoxLayout" >
|
||||
<item>
|
||||
<widget class="QLabel" name="pennLabel" >
|
||||
<widget class="QLabel" name="penLabel" >
|
||||
<property name="text" >
|
||||
<string>Penn Radius</string>
|
||||
<string>Pen Radius</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSlider" name="pennSlider" >
|
||||
<widget class="QSlider" name="penRadiusSlider" >
|
||||
<property name="maximum" >
|
||||
<number>10</number>
|
||||
</property>
|
||||
@ -125,10 +125,10 @@
|
||||
<widget class="QWidget" name="layoutWidget" >
|
||||
<property name="geometry" >
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>12</y>
|
||||
<x>1</x>
|
||||
<y>13</y>
|
||||
<width>132</width>
|
||||
<height>226</height>
|
||||
<height>224</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" >
|
||||
@ -211,64 +211,60 @@
|
||||
<item>
|
||||
<layout class="QVBoxLayout" >
|
||||
<item>
|
||||
<layout class="QVBoxLayout" >
|
||||
<item>
|
||||
<widget class="QLabel" name="label" >
|
||||
<property name="text" >
|
||||
<string>Normal Weight</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSlider" name="normalWeightSlider" >
|
||||
<property name="maximum" >
|
||||
<number>10</number>
|
||||
</property>
|
||||
<property name="pageStep" >
|
||||
<number>2</number>
|
||||
</property>
|
||||
<property name="value" >
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="tickInterval" >
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<widget class="QLabel" name="label" >
|
||||
<property name="text" >
|
||||
<string>Normal Weight</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" >
|
||||
<item>
|
||||
<widget class="QLabel" name="label_2" >
|
||||
<property name="text" >
|
||||
<string>Curvature Weight</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSlider" name="curvatureWeightSlider" >
|
||||
<property name="maximum" >
|
||||
<number>10</number>
|
||||
</property>
|
||||
<property name="pageStep" >
|
||||
<number>2</number>
|
||||
</property>
|
||||
<property name="value" >
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="tickInterval" >
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<widget class="QSlider" name="normalWeightSlider" >
|
||||
<property name="maximum" >
|
||||
<number>10</number>
|
||||
</property>
|
||||
<property name="pageStep" >
|
||||
<number>2</number>
|
||||
</property>
|
||||
<property name="value" >
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="tickInterval" >
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" >
|
||||
<item>
|
||||
<widget class="QLabel" name="label_2" >
|
||||
<property name="text" >
|
||||
<string>Curvature Weight</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSlider" name="curvatureWeightSlider" >
|
||||
<property name="maximum" >
|
||||
<number>10</number>
|
||||
</property>
|
||||
<property name="pageStep" >
|
||||
<number>2</number>
|
||||
</property>
|
||||
<property name="value" >
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="tickInterval" >
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user