Ignore:
Timestamp:
08/19/11 18:04:03 (14 years ago)
Author:
Eric.Larour
Message:

Major rewrite of the code so that IoModel now has a parameters dataset, which gets
loaded with all the int,char and double objects in the input file.
This is a lot more flexible, as anyone can add a field to the model, and it will
automatically appear in the IoModel parameters dataset.

Not debugged with respect to nightly runs yet. Trying to get the whole change finished.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/c/objects/Loads/Icefront.cpp

    r9320 r9356  
    4343        int segment_width;
    4444        int element;
    45         int num_nodes;
     45        int num_nodes;
     46        int dim;
     47        int numberofelements;
    4648
    4749        /*icefront constructor data: */
     
    5052        int  icefront_node_ids[NUMVERTICESQUA]; //initialize with largest size
    5153        int  icefront_fill;
     54       
     55        /*find parameters: */
     56        iomodel->parameters->FindParam(&dim,DimEnum);
     57        iomodel->parameters->FindParam(&numberofelements,NumberOfElementsEnum);
    5258
    5359        /*First, retrieve element index and element type: */
    54         if (iomodel->dim==2){
     60        if (dim==2){
    5561                segment_width=4;
    5662        }
     
    6268        /*Build ids for hook constructors: */
    6369        icefront_eid=(int) *(iomodel->pressureload+segment_width*i+segment_width-2); //matlab indexing
    64         icefront_mparid=iomodel->numberofelements+1; //matlab indexing
     70        icefront_mparid=numberofelements+1; //matlab indexing
    6571
    6672        if (in_icefront_type==MacAyeal2dIceFrontEnum || in_icefront_type==MacAyeal3dIceFrontEnum){
Note: See TracChangeset for help on using the changeset viewer.