From: <de...@us...> - 2008-09-21 23:14:59
|
Revision: 3966 http://fudaa.svn.sourceforge.net/fudaa/?rev=3966&view=rev Author: deniger Date: 2008-09-21 23:14:52 +0000 (Sun, 21 Sep 2008) Log Message: ----------- Modified Paths: -------------- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/courbe/FudaaCourbeTime.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/report/FudaaReportAnimationAdapter.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dGraphesResultatsEditor.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileCourbeTime.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileFlowrateFille.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/TrLauncherDefault.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/common/Tr3DCalque.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoLayer.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoModel.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheLayer.java branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheModel.java branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/tr/Test3D.java Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/courbe/FudaaCourbeTime.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/courbe/FudaaCourbeTime.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/courbe/FudaaCourbeTime.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -28,9 +28,9 @@ final ListSelectionModel selection_; - final ListModel timeModel_; + final FudaaCourbeTimeListModel timeModel_; - public FudaaCourbeTime(EGGroup _m, EGModel _model, ListModel _timeModel) { + public FudaaCourbeTime(EGGroup _m, EGModel _model, FudaaCourbeTimeListModel _timeModel) { super(_m, _model); timeModel_ = _timeModel; selection_ = new DefaultListSelectionModel(); @@ -43,6 +43,10 @@ return selection_.getMaxSelectionIndex(); } + public double getTimeStepValueSec(int _idx) { + return timeModel_.getTimeInSec(_idx); + } + public ListModel getTimeListModel() { return timeModel_; } @@ -55,6 +59,10 @@ return (String) timeModel_.getElementAt(_idx); } + // public double getTimeStepValueSec(int _idx) { + // return timeModel_.; + // } + public void setTimeStep(int _idx) { selection_.setSelectionInterval(_idx, _idx); Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/report/FudaaReportAnimationAdapter.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/report/FudaaReportAnimationAdapter.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/commun/report/FudaaReportAnimationAdapter.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -54,6 +54,11 @@ return first == null ? CtuluLibString.ZERO : first.getTimeStep(_idx); } + public double getTimeStepValueSec(int _idx) { + EbliAnimationSourceInterface first = getFirstAnim(); + return first == null ? 0 : first.getTimeStepValueSec(_idx); + } + public String getTitle() { return controller_.owner_.getTitle(); } Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dGraphesResultatsEditor.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dGraphesResultatsEditor.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dGraphesResultatsEditor.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -663,7 +663,13 @@ public String getTimeStep(int _idx) { return editeur_.getListePasTpsSection().getModel().getElementAt(_idx).toString(); } + + + public double getTimeStepValueSec(int _idx) { + //TODO a ameliorer + return Double.valueOf(getTimeStep(_idx)); + } /** * @param _idx l'indice a afficher */ Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileCourbeTime.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileCourbeTime.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileCourbeTime.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -19,6 +19,7 @@ import org.fudaa.ctulu.CtuluVariable; import org.fudaa.ebli.animation.EbliAnimationAdapterInterface; import org.fudaa.ebli.controle.BSelecteurListTimeTarget; +import org.fudaa.fudaa.commun.courbe.FudaaCourbeTimeListModel; import com.memoire.bu.BuResource; @@ -31,9 +32,10 @@ final ListSelectionModel selection_ = new DefaultListSelectionModel(); - ListModel time_; + FudaaCourbeTimeListModel time_; - public MvProfileCourbeTime(final MvProfileCourbeGroup _m, final MVProfileCourbeModel _model, final ListModel _time) { + public MvProfileCourbeTime(final MvProfileCourbeGroup _m, final MVProfileCourbeModel _model, + final FudaaCourbeTimeListModel _time) { super(_m, _model); time_ = _time; time_.addListDataListener(this); @@ -42,16 +44,13 @@ selection_.addListSelectionListener(this); } - public MvProfileCourbe duplicate() { + public MvProfileCourbe duplicate() { final MvProfileCourbeTime res = new MvProfileCourbeTime((MvProfileCourbeGroup) getParent(), getM().duplicate(), time_); res.setAspectContour(getAspectContour()); res.getM().setTitle(getTitle() + CtuluLibString.ESPACE + BuResource.BU.getString("Copie")); return res; } - - - public void contentsChanged(final ListDataEvent _e) { updateTitle(); @@ -65,6 +64,10 @@ return time_.getElementAt(_idx).toString(); } + public double getTimeStepValueSec(int _idx) { + return time_.getTimeInSec(_idx); + } + public void setTimeStep(final int _idx) { if (_idx >= 0 && _idx < getNbTimeStep()) { selection_.setSelectionInterval(_idx, _idx); Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileFlowrateFille.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileFlowrateFille.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/meshviewer/profile/MvProfileFlowrateFille.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -10,22 +10,19 @@ import java.awt.Color; import java.awt.Dimension; -import javax.swing.AbstractListModel; -import javax.swing.ListModel; +import javax.swing.event.ListDataListener; import org.fudaa.ctulu.CtuluLibArray; import org.fudaa.ctulu.CtuluLibString; - +import org.fudaa.ctulu.CtuluNumberFormatI; import org.fudaa.dodico.commun.DodicoLib; import org.fudaa.dodico.h2d.type.H2dVariableType; - import org.fudaa.ebli.courbe.EGAxeHorizontal; import org.fudaa.ebli.courbe.EGAxeVertical; import org.fudaa.ebli.courbe.EGCourbeChild; import org.fudaa.ebli.courbe.EGGraphe; import org.fudaa.ebli.courbe.EGGrapheTreeModel; import org.fudaa.ebli.courbe.EGGroup; - import org.fudaa.fudaa.commun.courbe.FudaaCourbeTime; import org.fudaa.fudaa.commun.courbe.FudaaCourbeTimeListModel; import org.fudaa.fudaa.commun.courbe.FudaaCourbeTimeModel; @@ -42,6 +39,7 @@ public final class MvProfileFlowrateFille extends FudaaGrapheTimeAnimatedFille { private int idx_; private int idxVolume_; + // private static int idxFrame_; protected static class FlowrateTreeModel extends EGGrapheTreeModel { @@ -50,7 +48,6 @@ return true; } - } public static String getCommonTitle(final FudaaCommonImplementation _impl) { @@ -76,10 +73,11 @@ _impl.getRootPane().putClientProperty("fudaa.flowrate.frame.idx", new Integer(next)); return fille; } + EGGroup grQ_; EGGroup grVolume_; double[] commonTime_; - ListModel commonTimeModel_; + FudaaCourbeTimeListModel commonTimeModel_; protected MvProfileFlowrateFille(final FudaaGrapheTimeAnimatedVisuPanel _g, final String _titre, final FudaaCommonImplementation _appli, final FudaaCourbeTimeListModel _timeFmt) { @@ -87,7 +85,7 @@ getGraphe().setXAxe(EGAxeHorizontal.buildDefautTimeAxe(_timeFmt == null ? null : _timeFmt.getTimeFmt())); } - protected class CommonListModel extends AbstractListModel { + protected class CommonListModel implements FudaaCourbeTimeListModel { final double[] times_; public CommonListModel(final double[] _times) { @@ -103,6 +101,30 @@ return times_ == null ? 0 : times_.length; } + public void fireContentChanged() {} + + public void fireStructureChanged() {} + + public CtuluNumberFormatI getTimeFmt() { + return MvProfileFlowrateFille.this.getTimeFmt(); + } + + public double getTimeInSec(int _i) { + return times_[_i]; + } + + public double[] getTimesInSec() { + return CtuluLibArray.copy(times_); + } + + public void setTimeFmt(CtuluNumberFormatI _fmt) { + MvProfileFlowrateFille.this.setTimeFmt(_fmt); + } + + public void addListDataListener(ListDataListener _l) {} + + public void removeListDataListener(ListDataListener _l) {} + } protected double[] getTime(final double[] _t) { @@ -115,10 +137,8 @@ } - protected ListModel getTimeModel(final double[] _t) { - if (_t == commonTime_ && commonTime_ != null) { - return commonTimeModel_; - } + protected FudaaCourbeTimeListModel getTimeModel(final double[] _t) { + if (_t == commonTime_ && commonTime_ != null) { return commonTimeModel_; } return new CommonListModel(_t); } @@ -134,7 +154,7 @@ mQCumulue.setTitle(cTitle); createFlowrateGroup(); - final ListModel timeModel = getTimeModel(time); + final FudaaCourbeTimeListModel timeModel = getTimeModel(time); final EGCourbeChild courbeChild = new FudaaCourbeTime(grQ_, mQ, timeModel); grQ_.addEGComponent(courbeChild); /* Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/TrLauncherDefault.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/TrLauncherDefault.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/TrLauncherDefault.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -134,8 +134,8 @@ infoSoft = new BuInformationsSoftware(); infoSoft.name = "prepro"; - infoSoft.version = "0.92-MAQUETTE-V3"; - infoSoft.date = "2008-09-12"; + infoSoft.version = "0.92-MAQUETTE-V4"; + infoSoft.date = "2008-09-20"; infoSoft.rights = TrResource.getS("Tous droits r\xE9serv\xE9s") + ". CETMEF (c)2003-2007"; infoSoft.contact = "fre...@fu..."; infoSoft.license = "GPL2"; Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/common/Tr3DCalque.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/common/Tr3DCalque.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/common/Tr3DCalque.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -74,7 +74,13 @@ public int getNbTimeStep() { return srcInit_.getNbTimeStep(); } + + + public double getTimeStepValueSec(int _idx) { + return srcInit_.getTimeStep(_idx); + } + public boolean getRange(final CtuluRange _r) { getSrc().getExtrema(_r, getVarDisplayed(), null, null, false); return true; Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoLayer.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoLayer.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoLayer.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -60,12 +60,8 @@ } public static EbliUIProperties saveTime(final EbliUIProperties _prop, final BSelecteurListTimeTarget _timeTarget) { - if (_prop == null) { - return null; - } - if (_timeTarget == null || _timeTarget.getTimeListSelectionModel().isSelectionEmpty()) { - return _prop; - } + if (_prop == null) { return null; } + if (_timeTarget == null || _timeTarget.getTimeListSelectionModel().isSelectionEmpty()) { return _prop; } if (!_timeTarget.getTimeListSelectionModel().isSelectionEmpty()) { final int i = _timeTarget.getTimeListSelectionModel().getMaxSelectionIndex(); _prop.put("post.timeSelected", i); @@ -74,13 +70,9 @@ } public static void restoreTime(final EbliUIProperties _prop, final BSelecteurListTimeTarget _timeTarget) { - if (_prop == null || _timeTarget == null) { - return; - } + if (_prop == null || _timeTarget == null) { return; } final int size = _timeTarget.getTimeListModel().getSize(); - if (size == 0) { - return; - } + if (size == 0) { return; } int idx = _prop.getInteger("post.timeSelected", size - 1); if (idx < 0 || idx >= size) { idx = size - 1; @@ -160,6 +152,10 @@ return getIsoModel().getT(_idx); } + public double getTimeStepValueSec(int _idx) { + return getIsoModel().getTInSec(_idx); + } + public JComponent getTimeTargetComponent() { return this; } @@ -231,9 +227,7 @@ } public void valueChanged(final ListSelectionEvent _e) { - if (_e.getValueIsAdjusting()) { - return; - } + if (_e.getValueIsAdjusting()) { return; } if (_e.getSource() == mainTimeSelectionModel_) { getIsoModel().setT(this.mainTimeSelectionModel_.getMinSelectionIndex()); // FuLog.warning(new Throwable()); Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoModel.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoModel.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrIsoModel.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -282,6 +282,10 @@ public String getT(final int _i) { return (String) timeModel_.getElementAt(_i); } + + public double getTInSec(final int _i) { + return s_.getTimeStep(_i); + } public ListModel getTimeList() { return timeModel_; Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheLayer.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheLayer.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheLayer.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -431,6 +431,10 @@ return (String) initModel_.getTimeListModel().getElementAt(_idx); } + public double getTimeStepValueSec(int _idx) { + return initModel_.getTimeStep(_idx); + } + public JComponent getTimeTargetComponent() { return this; } Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheModel.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheModel.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/tr/post/TrPostFlecheModel.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -314,6 +314,11 @@ public final int getTimeIdx() { return timeIdx_; } + + public final double getTimeStep(int _i){ + return s_.getTimeStep(_i); + + } /** * @return la liste des pas de temps. Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/tr/Test3D.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/tr/Test3D.java 2008-09-21 23:14:14 UTC (rev 3965) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/tr/Test3D.java 2008-09-21 23:14:52 UTC (rev 3966) @@ -105,6 +105,10 @@ return initSrc_.getTimeListModel().getElementAt(_idx).toString(); } + public double getTimeStepValueSec(int _idx) { + return initSrc_.getTime().getTimeStep(_idx); + } + public String getTitle() { return super.getName(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <de...@us...> - 2008-10-30 17:11:53
|
Revision: 4125 http://fudaa.svn.sourceforge.net/fudaa/?rev=4125&view=rev Author: deniger Date: 2008-10-30 17:11:51 +0000 (Thu, 30 Oct 2008) Log Message: ----------- Modified Paths: -------------- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/vag/VagCalqueOrthogonalesInteraction.java branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestJDebit.java branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestProfile.java Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/vag/VagCalqueOrthogonalesInteraction.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/vag/VagCalqueOrthogonalesInteraction.java 2008-10-30 17:11:11 UTC (rev 4124) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/src/org/fudaa/fudaa/vag/VagCalqueOrthogonalesInteraction.java 2008-10-30 17:11:51 UTC (rev 4125) @@ -6,6 +6,7 @@ * @mail de...@fu... */ package org.fudaa.fudaa.vag; + import java.awt.Color; import java.awt.Container; import java.awt.Font; @@ -41,22 +42,20 @@ /** * Un calque d'interaction pour les resultats de Vag. - * - * @version $Revision: 1.11 $ $Date: 2007-06-28 09:28:18 $ by $Author: deniger $ - * @author Axel von Arnim + * + * @version $Revision: 1.11 $ $Date: 2007-06-28 09:28:18 $ by $Author: deniger $ + * @author Axel von Arnim */ -public class VagCalqueOrthogonalesInteraction - extends BCalqueInteraction - implements MouseListener { +public class VagCalqueOrthogonalesInteraction extends BCalqueInteraction implements MouseListener { // donnees membres privees - static int PAS_CALCUL= 1; - static int ORTHOGONALE= 2; - private static String ANGLE= "Angle"; - private static String LONGUEUR_ONDE= "Longueur d'onde"; - private static String HAUTEUR_EAU= "Hauteur d'eau"; - private static String HAUTEUR_HOULE= "Hauteur de houle"; - static String TABLEAU_ORTH= "Tableau Orth"; - static String TABLEAU_IORTH= "Tableau Inter"; + static int PAS_CALCUL = 1; + static int ORTHOGONALE = 2; + private static String ANGLE = "Angle"; + private static String LONGUEUR_ONDE = "Longueur d'onde"; + private static String HAUTEUR_EAU = "Hauteur d'eau"; + private static String HAUTEUR_HOULE = "Hauteur de houle"; + static String TABLEAU_ORTH = "Tableau Orth"; + static String TABLEAU_IORTH = "Tableau Inter"; VagPopupMessage popup_; boolean isPopupShown; int xsel, ysel; @@ -68,94 +67,92 @@ SResultatPasCalcul05 selectedPas; SResultatUnitaire05 selectedOrth; SResultatUnitaireInterOrth selectedIOrth; + // Constructeur - public VagCalqueOrthogonalesInteraction( - VagCalqueOrthogonales _calque, - BGraphe _graphe, - VagTableauResultats _tableau) { - calque_= _calque; - isPopupShown= false; - stask= null; - nf_= NumberFormat.getInstance(Locale.FRENCH); + public VagCalqueOrthogonalesInteraction(VagCalqueOrthogonales _calque, BGraphe _graphe, VagTableauResultats _tableau) { + calque_ = _calque; + isPopupShown = false; + stask = null; + nf_ = NumberFormat.getInstance(Locale.FRENCH); nf_.setMaximumFractionDigits(2); - nf2_= NumberFormat.getInstance(Locale.US); + nf2_ = NumberFormat.getInstance(Locale.US); nf2_.setMaximumFractionDigits(2); nf2_.setGroupingUsed(false); - nf3_= NumberFormat.getInstance(Locale.US); + nf3_ = NumberFormat.getInstance(Locale.US); nf3_.setMaximumFractionDigits(3); nf3_.setGroupingUsed(false); - graphe_= _graphe; - tableau_= _tableau; + graphe_ = _graphe; + tableau_ = _tableau; } + private double nord_; + public void setFlecheNord(double angle) { - nord_= angle; + nord_ = angle; tableau_.setFlecheNord(angle); } + /**********************************************/ // EVENEMENTS /**********************************************/ // Mouse public void mousePressed(MouseEvent _evt) { - if (isGele()) - return; + if (isGele()) return; if (_evt.getModifiers() == InputEvent.BUTTON1_MASK) { - //int yclick=calque_.getPreferredSize().height-_evt.getY(); - //Graphics g=calque_.getGraphics(); - //g.setColor(Color.blue); - //g.drawRect((int)click.x-1, calque_.getPreferredSize().height-(int)click.y-1, 2, 2); - //g.drawRect((int)click.x-1, (int)click.y-1, 2, 2); - stask= new SelectTask(_evt.getX(), _evt.getY(), PAS_CALCUL); + // int yclick=calque_.getPreferredSize().height-_evt.getY(); + // Graphics g=calque_.getGraphics(); + // g.setColor(Color.blue); + // g.drawRect((int)click.x-1, calque_.getPreferredSize().height-(int)click.y-1, 2, 2); + // g.drawRect((int)click.x-1, (int)click.y-1, 2, 2); + stask = new SelectTask(_evt.getX(), _evt.getY(), PAS_CALCUL); stask.start(); } else if (_evt.getModifiers() == InputEvent.BUTTON3_MASK) { - stask= new SelectTask(_evt.getX(), _evt.getY(), ORTHOGONALE); + stask = new SelectTask(_evt.getX(), _evt.getY(), ORTHOGONALE); stask.start(); } } + public void mouseReleased(MouseEvent _evt) { - if (isGele()) - return; + if (isGele()) return; if (isPopupShown) { - if ((_evt.getModifiers() == InputEvent.BUTTON1_MASK) - || (_evt.getModifiers() == InputEvent.BUTTON3_MASK)) { - if (popup_ != null) - popup_.dispose(); + if ((_evt.getModifiers() == InputEvent.BUTTON1_MASK) || (_evt.getModifiers() == InputEvent.BUTTON3_MASK)) { + if (popup_ != null) popup_.dispose(); calque_.paintImmediately(xsel - 2, ysel - 2, 4, 4); } - isPopupShown= false; + isPopupShown = false; } else if (stask != null) { stask.stopSelect(); - stask= null; + stask = null; } } + public void mouseClicked(MouseEvent _evt) {} + public void mouseEntered(MouseEvent _evt) {} + public void mouseExited(MouseEvent _evt) {} + // Pas beau: trouver autre methode de recuperer l'espacement des orth - // private double espacementOrth=1.; - // public void setEspacementOrth(double _e) { espacementOrth=_e; } + // private double espacementOrth=1.; + // public void setEspacementOrth(double _e) { espacementOrth=_e; } // Methodes privees - String getInfoResultat( - SResultatPasCalcul05 r, - SResultatPasInterOrth s) { - String info= ""; + String getInfoResultat(SResultatPasCalcul05 r, SResultatPasInterOrth s) { + String info = ""; info += "pas : " + r.numeroPas + "\n"; info += "x : " + nf_.format(r.pointCourantX) + " (m)\n"; info += "y : " + nf_.format(r.pointCourantY) + " (m)\n"; - info += "angle : " - + nf_.format(r.angleHoriz * 180 / Math.PI - nord_) - + " (degr\xE9s)\n"; + info += "angle : " + nf_.format(r.angleHoriz * 180 / Math.PI - nord_) + " (degr\xE9s)\n"; info += "longueur d'onde : " + nf_.format(r.longueurOnde) + " (m)\n"; info += "hauteur d'eau : " + nf_.format(r.hauteurEau) + " (m)\n"; - if (s != null) - info += "hauteur de houle: " + nf_.format(s.hauteurHoule) + " (m)\n"; + if (s != null) info += "hauteur de houle: " + nf_.format(s.hauteurHoule) + " (m)\n"; return info; } + void popInfoBox(String info) { - Graphics g= calque_.getGraphics(); - Font f= g.getFont(); - Color c= g.getColor(); - popup_= new VagPopupMessage(calque_); + Graphics g = calque_.getGraphics(); + Font f = g.getFont(); + Color c = g.getColor(); + popup_ = new VagPopupMessage(calque_); popup_.setText(info); popup_.setFont(new Font("Courier", f.getStyle(), f.getSize())); popup_.setLocation(xsel, ysel); @@ -163,179 +160,167 @@ g.setColor(new Color(0, 200, 20)); g.drawRect(xsel - 1, ysel - 1, 2, 2); g.setColor(c); - isPopupShown= true; + isPopupShown = true; } + void popInfoMenu(String title) { - OrthMenuListener listener= new OrthMenuListener(); - JPopupMenu menu= new JPopupMenu(); + OrthMenuListener listener = new OrthMenuListener(); + JPopupMenu menu = new JPopupMenu(); menu.add(new TitleMenuItem(title)); menu.addSeparator(); JMenuItem mi; - mi= new JMenuItem(ANGLE); + mi = new JMenuItem(ANGLE); mi.addActionListener(listener); menu.add(mi); - mi= new JMenuItem(LONGUEUR_ONDE); + mi = new JMenuItem(LONGUEUR_ONDE); mi.addActionListener(listener); menu.add(mi); - mi= new JMenuItem(HAUTEUR_EAU); + mi = new JMenuItem(HAUTEUR_EAU); mi.addActionListener(listener); menu.add(mi); - mi= new JMenuItem(HAUTEUR_HOULE); + mi = new JMenuItem(HAUTEUR_HOULE); mi.addActionListener(listener); - if (selectedIOrth == null) - mi.setEnabled(false); + if (selectedIOrth == null) mi.setEnabled(false); menu.add(mi); - mi= new JMenuItem(TABLEAU_ORTH); + mi = new JMenuItem(TABLEAU_ORTH); mi.addActionListener(listener); menu.add(mi); - mi= new JMenuItem(TABLEAU_IORTH); + mi = new JMenuItem(TABLEAU_IORTH); mi.addActionListener(listener); menu.add(mi); menu.show(this, xsel, ysel); - isPopupShown= true; + isPopupShown = true; } - void sendToGraph( - SResultatUnitaire05 orth, - SResultatUnitaireInterOrth iorth, - String courbe) { - String titre= "Orthogonale " + orth.numeroOrth; - String ordUnite= ""; - String crbTitre= ""; - Vector vals= new Vector(); - Valeur v= null; - double s= 0.; - double maxVal= 0.; - double minVal= 0.; - double deltaX= 0., deltaY= 0.; - if (orth.pas.length == 0) - return; + + void sendToGraph(SResultatUnitaire05 orth, SResultatUnitaireInterOrth iorth, String courbe) { + String titre = "Orthogonale " + orth.numeroOrth; + String ordUnite = ""; + String crbTitre = ""; + Vector vals = new Vector(); + Valeur v = null; + double s = 0.; + double maxVal = 0.; + double minVal = 0.; + double deltaX = 0., deltaY = 0.; + if (orth.pas.length == 0) return; if (courbe.equals(ANGLE)) { - ordUnite= "deg"; - crbTitre= "angle(s)"; + ordUnite = "deg"; + crbTitre = "angle(s)"; // angle ./. Nord - double angle= orth.pas[0].angleHoriz * 180 / Math.PI - 90.; - v= new Valeur(); - v.s_= s; - v.v_= angle; + double angle = orth.pas[0].angleHoriz * 180 / Math.PI - 90.; + v = new Valeur(); + v.s_ = s; + v.v_ = angle; vals.add(v); - maxVal= minVal= angle; + maxVal = minVal = angle; } else if (courbe.equals(LONGUEUR_ONDE)) { - ordUnite= "m"; - crbTitre= "lambda(s)"; - v= new Valeur(); - v.s_= s; - v.v_= orth.pas[0].longueurOnde; + ordUnite = "m"; + crbTitre = "lambda(s)"; + v = new Valeur(); + v.s_ = s; + v.v_ = orth.pas[0].longueurOnde; vals.add(v); - maxVal= minVal= orth.pas[0].longueurOnde; + maxVal = minVal = orth.pas[0].longueurOnde; } else if (courbe.equals(HAUTEUR_EAU)) { - ordUnite= "m"; - crbTitre= "he(s)"; - v= new Valeur(); - v.s_= s; - v.v_= orth.pas[0].hauteurEau; + ordUnite = "m"; + crbTitre = "he(s)"; + v = new Valeur(); + v.s_ = s; + v.v_ = orth.pas[0].hauteurEau; vals.add(v); - maxVal= minVal= orth.pas[0].hauteurEau; + maxVal = minVal = orth.pas[0].hauteurEau; } else if (courbe.equals(HAUTEUR_HOULE)) { - ordUnite= "m"; - crbTitre= "hh(s)"; - // double hhoule=0.; - // try { hhoule=calculeHauteurHoule(orth.numeroOrth, 0); } - // catch( HauteurHouleException e ) {}; - double hhoule= iorth.pas[0].hauteurHoule; - v= new Valeur(); - v.s_= s; - v.v_= hhoule; + ordUnite = "m"; + crbTitre = "hh(s)"; + // double hhoule=0.; + // try { hhoule=calculeHauteurHoule(orth.numeroOrth, 0); } + // catch( HauteurHouleException e ) {}; + double hhoule = iorth.pas[0].hauteurHoule; + v = new Valeur(); + v.s_ = s; + v.v_ = hhoule; vals.add(v); - maxVal= minVal= hhoule; + maxVal = minVal = hhoule; } - for (int i= 1; i < orth.pas.length; i++) { - deltaX= orth.pas[i].pointCourantX - orth.pas[i - 1].pointCourantX; - deltaY= orth.pas[i].pointCourantY - orth.pas[i - 1].pointCourantY; - s += Math.sqrt(deltaX * deltaX + deltaY * deltaY); + for (int i = 1; i < orth.pas.length; i++) { + deltaX = orth.pas[i].pointCourantX - orth.pas[i - 1].pointCourantX; + deltaY = orth.pas[i].pointCourantY - orth.pas[i - 1].pointCourantY; + s += Math.hypot(deltaX, deltaY); if (courbe.equals(ANGLE)) { - double angle= orth.pas[i].angleHoriz * 180 / Math.PI - 90.; - v= new Valeur(); - v.s_= s; - v.v_= angle; + double angle = orth.pas[i].angleHoriz * 180 / Math.PI - 90.; + v = new Valeur(); + v.s_ = s; + v.v_ = angle; vals.add(v); - if (angle > maxVal) - maxVal= angle; - if (angle < minVal) - minVal= angle; + if (angle > maxVal) maxVal = angle; + if (angle < minVal) minVal = angle; } else if (courbe.equals(LONGUEUR_ONDE)) { - v= new Valeur(); - v.s_= s; - v.v_= orth.pas[i].longueurOnde; + v = new Valeur(); + v.s_ = s; + v.v_ = orth.pas[i].longueurOnde; vals.add(v); - if (orth.pas[i].longueurOnde > maxVal) - maxVal= orth.pas[i].longueurOnde; - if (orth.pas[i].longueurOnde < minVal) - minVal= orth.pas[i].longueurOnde; + if (orth.pas[i].longueurOnde > maxVal) maxVal = orth.pas[i].longueurOnde; + if (orth.pas[i].longueurOnde < minVal) minVal = orth.pas[i].longueurOnde; } else if (courbe.equals(HAUTEUR_EAU)) { - v= new Valeur(); - v.s_= s; - v.v_= orth.pas[i].hauteurEau; + v = new Valeur(); + v.s_ = s; + v.v_ = orth.pas[i].hauteurEau; vals.add(v); - if (orth.pas[i].hauteurEau > maxVal) - maxVal= orth.pas[i].hauteurEau; - if (orth.pas[i].hauteurEau < minVal) - minVal= orth.pas[i].hauteurEau; + if (orth.pas[i].hauteurEau > maxVal) maxVal = orth.pas[i].hauteurEau; + if (orth.pas[i].hauteurEau < minVal) minVal = orth.pas[i].hauteurEau; } else if (courbe.equals(HAUTEUR_HOULE)) { - // double hhoule=0.; - // try { hhoule=calculeHauteurHoule(orth.numeroOrth, i); } - // catch( HauteurHouleException e ) {}; - if (i == iorth.pas.length) - break; - double hhoule= iorth.pas[i].hauteurHoule; - v= new Valeur(); - v.s_= s; - v.v_= hhoule; + // double hhoule=0.; + // try { hhoule=calculeHauteurHoule(orth.numeroOrth, i); } + // catch( HauteurHouleException e ) {}; + if (i == iorth.pas.length) break; + double hhoule = iorth.pas[i].hauteurHoule; + v = new Valeur(); + v.s_ = s; + v.v_ = hhoule; vals.add(v); - if (hhoule > maxVal) - maxVal= hhoule; - if (hhoule < minVal) - minVal= hhoule; - titre= "InterOrthogonale " + iorth.orth1 + " - " + iorth.orth2; + if (hhoule > maxVal) maxVal = hhoule; + if (hhoule < minVal) minVal = hhoule; + titre = "InterOrthogonale " + iorth.orth1 + " - " + iorth.orth2; } } - Graphe graphe= new Graphe(); - graphe.titre_= titre + " : " + courbe; - graphe.animation_= false; - graphe.legende_= true; - graphe.marges_= new Marges(); - graphe.marges_.gauche_= 60; - graphe.marges_.droite_= 80; - graphe.marges_.haut_= 45; - graphe.marges_.bas_= 30; - Axe ax= new Axe(); - ax.titre_= "s"; - ax.unite_= "m"; - ax.vertical_= false; - ax.graduations_= true; - ax.grille_= true; - ax.minimum_= 0.; - double xx= Math.round(s); - xx= xx - xx % 10; - ax.pas_= (xx - ax.minimum_) / 10; - ax.maximum_= s; + Graphe graphe = new Graphe(); + graphe.titre_ = titre + " : " + courbe; + graphe.animation_ = false; + graphe.legende_ = true; + graphe.marges_ = new Marges(); + graphe.marges_.gauche_ = 60; + graphe.marges_.droite_ = 80; + graphe.marges_.haut_ = 45; + graphe.marges_.bas_ = 30; + Axe ax = new Axe(); + ax.titre_ = "s"; + ax.unite_ = "m"; + ax.vertical_ = false; + ax.graduations_ = true; + ax.grille_ = true; + ax.minimum_ = 0.; + double xx = Math.round(s); + xx = xx - xx % 10; + ax.pas_ = (xx - ax.minimum_) / 10; + ax.maximum_ = s; graphe.ajoute(ax); - Axe ay= new Axe(); - ay.titre_= courbe; - ay.unite_= ordUnite; - ay.vertical_= true; - ay.graduations_= true; - ay.grille_= true; - ay.minimum_= minVal; - ay.maximum_= maxVal; - ay.pas_= (Math.round(maxVal) - Math.round(minVal)) / 10; - ay.pas_= Math.round(ay.pas_); + Axe ay = new Axe(); + ay.titre_ = courbe; + ay.unite_ = ordUnite; + ay.vertical_ = true; + ay.graduations_ = true; + ay.grille_ = true; + ay.minimum_ = minVal; + ay.maximum_ = maxVal; + ay.pas_ = (Math.round(maxVal) - Math.round(minVal)) / 10; + ay.pas_ = Math.round(ay.pas_); graphe.ajoute(ay); - CourbeDefault c= new CourbeDefault(); - c.titre_= crbTitre; - //c.type="aire"; - c.trace_= "lineaire"; - c.marqueurs_= true; - c.valeurs_= vals; + CourbeDefault c = new CourbeDefault(); + c.titre_ = crbTitre; + // c.type="aire"; + c.trace_ = "lineaire"; + c.marqueurs_ = true; + c.valeurs_ = vals; graphe.ajoute(c); graphe_.setGraphe(graphe); } @@ -345,136 +330,117 @@ public TitleMenuItem(String title) { super(title); } + public boolean isSelected() { return false; } + public void setSelected(boolean b) {} + public boolean isArmed() { return false; } + public void setArmed(boolean b) {} } + class OrthMenuListener implements ActionListener { public void actionPerformed(ActionEvent evt) { - String s= evt.getActionCommand(); + String s = evt.getActionCommand(); if (s.equals(TABLEAU_ORTH)) { tableau_.setResultats05(selectedOrth); - Container frame= tableau_.getParent(); + Container frame = tableau_.getParent(); while ((frame != null) && (!(frame instanceof JInternalFrame))) - frame= frame.getParent(); - if (frame != null) - ((JInternalFrame)frame).setTitle( - "Orthogonale " + selectedOrth.numeroOrth); + frame = frame.getParent(); + if (frame != null) ((JInternalFrame) frame).setTitle("Orthogonale " + selectedOrth.numeroOrth); } else if (s.equals(TABLEAU_IORTH)) { if (selectedIOrth != null) { tableau_.setResultatsInterOrth(selectedIOrth); - Container frame= tableau_.getParent(); + Container frame = tableau_.getParent(); while ((frame != null) && (!(frame instanceof JInternalFrame))) - frame= frame.getParent(); - if (frame != null) - ((JInternalFrame)frame).setTitle( - "Inter-Orthogonale " - + selectedIOrth.orth1 - + "-" - + selectedIOrth.orth2); + frame = frame.getParent(); + if (frame != null) ((JInternalFrame) frame).setTitle("Inter-Orthogonale " + selectedIOrth.orth1 + "-" + + selectedIOrth.orth2); } } else { sendToGraph(selectedOrth, selectedIOrth, evt.getActionCommand()); - if (!graphe_.isInteractif()) - graphe_.setInteractif(true); + if (!graphe_.isInteractif()) graphe_.setInteractif(true); } } } + class SelectTask extends Thread { int xclick, yclick, mode; boolean stop_; + public SelectTask(int _xclick, int _yclick, int _mode) { - xclick= _xclick; - yclick= _yclick; - mode= _mode; + xclick = _xclick; + yclick = _yclick; + mode = _mode; } - public void stopSelect(){ - stop_=true; - selectedPas= null; - selectedOrth= null; - selectedIOrth= null; + public void stopSelect() { + stop_ = true; + selectedPas = null; + selectedOrth = null; + selectedIOrth = null; } + public void run() { - stop_=false; + stop_ = false; double dist, mindist; - GrPoint click= new GrPoint(xclick, yclick, 0.).applique(getVersReel()); - SResultats05 r= calque_.getResultats05(); - SResultatsInterOrth s= calque_.getResultatsInterOrth(); - selectedPas= null; - selectedOrth= null; - selectedIOrth= null; - int noOrth= 0, noPoint= 0; - mindist= - calque_.getPolyligne(0).sommets_.renvoie(0).distance(click); - for (int o= 0; o < r.orthogonales.length; o++) { - for (int p= 0; p < r.orthogonales[o].pas.length; p++) { - GrPoint curp= - new GrPoint( - r.orthogonales[o].pas[p].pointCourantX, - r.orthogonales[o].pas[p].pointCourantY, - 0.); - if ((dist= curp.distance(click)) < mindist) { - mindist= dist; - selectedOrth= r.orthogonales[o]; - if (o < s.interOrth.length) - selectedIOrth= s.interOrth[o]; - else - selectedIOrth= null; - selectedPas= r.orthogonales[o].pas[p]; - noOrth= o; - noPoint= p; + GrPoint click = new GrPoint(xclick, yclick, 0.).applique(getVersReel()); + SResultats05 r = calque_.getResultats05(); + SResultatsInterOrth s = calque_.getResultatsInterOrth(); + selectedPas = null; + selectedOrth = null; + selectedIOrth = null; + int noOrth = 0, noPoint = 0; + mindist = calque_.getPolyligne(0).sommets_.renvoie(0).distance(click); + for (int o = 0; o < r.orthogonales.length; o++) { + for (int p = 0; p < r.orthogonales[o].pas.length; p++) { + GrPoint curp = new GrPoint(r.orthogonales[o].pas[p].pointCourantX, r.orthogonales[o].pas[p].pointCourantY, 0.); + if ((dist = curp.distance(click)) < mindist) { + mindist = dist; + selectedOrth = r.orthogonales[o]; + if (o < s.interOrth.length) selectedIOrth = s.interOrth[o]; + else selectedIOrth = null; + selectedPas = r.orthogonales[o].pas[p]; + noOrth = o; + noPoint = p; } } } - if(stop_) return; + if (stop_) return; if (selectedPas != null) { - GrPoint sel= - new GrPoint( - selectedPas.pointCourantX, - selectedPas.pointCourantY, - 0.).applique( - getVersEcran()); + GrPoint sel = new GrPoint(selectedPas.pointCourantX, selectedPas.pointCourantY, 0.).applique(getVersEcran()); if (sel.distance(new GrPoint(xclick, yclick, 0.)) < 10) { - xsel= (int)sel.x_; - ysel= (int)sel.y_; + xsel = (int) sel.x_; + ysel = (int) sel.y_; if (mode == PAS_CALCUL) { // calcul hauteur de houle - // double H=0.; - // boolean Hok=true; - // try { H=calculeHauteurHoule(noOrth, noPoint); } - // catch( HauteurHouleException e ) { Hok=false; } - popInfoBox( - "Orthogonale " - + noOrth - + "\n" - + getInfoResultat( - selectedPas, - (selectedIOrth == null ? null : selectedIOrth.pas[noPoint]))); + // double H=0.; + // boolean Hok=true; + // try { H=calculeHauteurHoule(noOrth, noPoint); } + // catch( HauteurHouleException e ) { Hok=false; } + popInfoBox("Orthogonale " + noOrth + "\n" + + getInfoResultat(selectedPas, (selectedIOrth == null ? null : selectedIOrth.pas[noPoint]))); } else if (mode == ORTHOGONALE) { popInfoMenu("Orthogonale " + noOrth); } System.err.println("Orthogonale " + noOrth + ", Point " + noPoint); } else { - xsel= xclick; - ysel= yclick; + xsel = xclick; + ysel = yclick; popInfoBox("Pas de point\nr\xE9sultat ici"); } } } } /* - class HauteurHouleException extends Exception - { - public HauteurHouleException() { super(); } - public HauteurHouleException(Exception e) { super(e.getMessage()); } - public HauteurHouleException(String msg) { super(msg); } - } - */ + * class HauteurHouleException extends Exception { public HauteurHouleException() { super(); } public + * HauteurHouleException(Exception e) { super(e.getMessage()); } public HauteurHouleException(String msg) { + * super(msg); } } + */ } Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestJDebit.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestJDebit.java 2008-10-30 17:11:11 UTC (rev 4124) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestJDebit.java 2008-10-30 17:11:51 UTC (rev 4125) @@ -11,15 +11,11 @@ import junit.framework.TestCase; -import com.vividsolutions.jts.geom.Coordinate; -import com.vividsolutions.jts.geom.LineString; - import org.fudaa.ctulu.CtuluAnalyze; import org.fudaa.ctulu.CtuluVariable; import org.fudaa.ctulu.collection.CtuluCollectionDoubleUnique; import org.fudaa.ctulu.gis.GISGeometryFactory; import org.fudaa.ctulu.interpolation.InterpolationVectorContainer; - import org.fudaa.dodico.ef.EfData; import org.fudaa.dodico.ef.EfDataAdapter; import org.fudaa.dodico.ef.EfDataElement; @@ -31,16 +27,17 @@ import org.fudaa.dodico.ef.EfNode; import org.fudaa.dodico.ef.impl.EfGrid; import org.fudaa.dodico.ef.impl.EfGridDataDefault; -import org.fudaa.dodico.ef.interpolation.EfGridDataInterpolatorDefault; -import org.fudaa.dodico.ef.interpolation.EfInterpolator; +import org.fudaa.dodico.ef.interpolation.EfGridDataInterpolator; import org.fudaa.dodico.ef.operation.EfLineFlowrateResult; import org.fudaa.dodico.ef.operation.EfLineIntersectionsResultsI; import org.fudaa.dodico.ef.operation.EfLineIntersectionsResultsMng; import org.fudaa.dodico.ef.operation.EfLineIntersectorActivity; import org.fudaa.dodico.h2d.type.H2dVariableType; - import org.fudaa.fudaa.meshviewer.export.MvExportT6Activity; +import com.vividsolutions.jts.geom.Coordinate; +import com.vividsolutions.jts.geom.LineString; + /** * @author fred deniger * @version $Id: TestJDebit.java,v 1.5 2007-06-13 12:58:12 deniger Exp $ @@ -54,7 +51,7 @@ * +----+-----+ + * | 0 | | 5 | * +----+-----+ + - * 0 1 2 6 + * 0 1 2 6 * </pre> */ // 14 noeuds @@ -103,7 +100,7 @@ InterpolationVectorContainer vectContainer = new InterpolationVectorContainer(); /** * <pre> - * + * * 100 ------ ------ * \ / * \_________/ @@ -135,8 +132,7 @@ final EfData vy = new EfDataAdapter(new CtuluCollectionDoubleUnique(vyValue), true); EfGridDataDefault datas = getDataAdapter(grid, bathy, hauteurEau, vx, vy); // vectContainer.addVxVy(H2dVariableType.VITESSE_U, H2dVariableType.VITESSE_V); - EfGridDataInterpolatorDefault support = new EfGridDataInterpolatorDefault(datas, new EfInterpolator(datas, - vectContainer)); + EfGridDataInterpolator support = new EfGridDataInterpolator(datas, vectContainer); EfLineIntersectorActivity act = new EfLineIntersectorActivity(support); EfLineIntersectionsResultsMng resMng = act.computeForMeshes(string, null); EfLineIntersectionsResultsI res = resMng.getDefaultRes(); @@ -204,7 +200,7 @@ MvExportT6Activity toT6 = new MvExportT6Activity(datas); EfGridData t6 = toT6.process(null, new CtuluAnalyze()); assertTrue(t6.getGrid().getEltType() == EfElementType.T6); - support = new EfGridDataInterpolatorDefault(t6, new EfInterpolator(t6, vectContainer)); + support = new EfGridDataInterpolator(t6, vectContainer); act = new EfLineIntersectorActivity(support); resMng = act.computeForNodes(string, null); res = resMng.getDefaultRes(); Modified: branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestProfile.java =================================================================== --- branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestProfile.java 2008-10-30 17:11:11 UTC (rev 4124) +++ branches/Prepro-0.92-SNAPSHOT/fudaa/test/org/fudaa/fudaa/mv/TestProfile.java 2008-10-30 17:11:51 UTC (rev 4125) @@ -29,7 +29,7 @@ import org.fudaa.dodico.ef.EfGridData; import org.fudaa.dodico.ef.EfGridInterface; -import org.fudaa.dodico.ef.interpolation.EfInterpolator; +import org.fudaa.dodico.ef.interpolation.EfGridDataInterpolator; import org.fudaa.ebli.courbe.EGDialog; @@ -64,7 +64,7 @@ return src_; } - public EfInterpolator getInterpolator() { + public EfGridDataInterpolator getInterpolator() { return src_.getInterpolator(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |