1. 14 Dec, 2016 1 commit
  2. 12 Dec, 2016 2 commits
  3. 09 Dec, 2016 1 commit
  4. 07 Dec, 2016 3 commits
  5. 06 Dec, 2016 5 commits
    • Mark OLESEN's avatar
      Merge branch 'feature-objectRegistry' into 'develop' · eed44631
      Mark OLESEN authored
      ENH: improve objectRegistry functionality (issue #322)
      
      - Recursive searching for objects within a registry is now optional
        (previous it was always done).
      
        A recursive search effectively blocks the construction of sub-sub-registries
        if their names are 'masked' by some parent level sub-registry with
        the same name! (BUG)
      
      - Recursive search is now turned OFF by default, which makes it consistent
        with dictionary and probably causes the least number of surprises.
      
      ----
      Various new convenience methods added:
      
      lookupObjectRef()
      - returns a non-const reference.
        For example,
      
            volScalarField& U = mesh().lookupObjectRef<volScalarField>("U");
      
        Instead of
      
            volScalarField& U = const_cast<volScalarField&>
            (
                mesh().lookupObject<volScalarField>("U")
            );
      
      --
      lookupObjectPtr()
      - returns a const pointer, and nullptr on failure.
        For example,
      
            const volScalarField* Uptr = mesh().lookupObjectPtr<volScalarField>("U");
            if (Uptr)
            {
                const volScalarField& U = *Uptr;
                ...
            }
      
        Instead of
      
            if (mesh().foundObject<volScalarField>("U"))
            {
                const volScalarField& U = mesh().lookupObject<volScalarField>("U");
                ...
            }
      
      --
      lookupObjectRefPtr()
      - returns a non-const pointer, and nullptr on failure.
        For example,
      
            volScalarField* Uptr = mesh().lookupObjectRefPtr<volScalarField>("U");
            if (Uptr)
            {
                volScalarField& U = *Uptr;  // use as reference
                (*Uptr) = ...;              // or use directly
            }
      
        Instead of
      
            if (mesh().foundObject<volScalarField>("U"))
            {
                volScalarField& U = const_cast<volScalarField&>
                (
                    mesh().lookupObject<volScalarField>("U")
                );
            }
      
      --
      sortedNames()
      - now works with template parameters and with regular expression
        matching as well.
        For example,
      
            wordList names  = mesh().sortedNames();
            wordList fields = mesh().sortedName<volScalarField>();
      
        Instead of
      
            wordList names  = mesh().sortedNames();
            wordList fields = mesh().names<volScalarField>();
            Foam::sort(fields);
      
      --
      
      See merge request !83
      eed44631
    • Andrew Heather's avatar
      Merge branch 'feature-runtime-post-pro-camera-update' into 'develop' · a54e9f8d
      Andrew Heather authored
      runTimePostProcessing FO camera update
      
      - Removed the camera 'mode'
          - The (old) static camera was only appropriate when parallel
            projection was inactive, and the view was centred at (0 0 0)
          - Camera input now always requires 'position' and 'focalPoint'
          - Clip box is now optional.  Note that this is applied after the
            camera
            set-up and so will override the camera position
          - View angle is only appropriate when not using parallel projection
          - Zoom now required, applied after all other operations
            - 1 = do nothing, >1 = zoom in, <1 = zoom out
      
          Example input:
      
      ```
              camera
              {
                  // Total number of frames to generate
                  nFrameTotal 1;
      
                  // Parallel projection flag
                  parallelProjection no;
      
                  focalPoint  (0 0 0);
                  up          (0 1 0);
                  position    (0 0 1);
      
                  // Optional entries
                  clipBox     (-0.0206 -0.0254 -0.0005) (0.29 0.0254 0.0005);
                  viewAngle   20;
                  zoom        1.1;
              }
      ```
      
      See merge request !81
      a54e9f8d
    • Andrew Heather's avatar
      f70ddc0a
    • Andrew Heather's avatar
      a51ff5cf
    • mattijs's avatar
      ENH: redistributePar: remove shm data · 0817de90
      mattijs authored
      0817de90
  6. 05 Dec, 2016 6 commits
  7. 02 Dec, 2016 9 commits
  8. 01 Dec, 2016 6 commits
    • mark's avatar
      ENH: improve IOobjectList functionality (issue #322) · b4c998a2
      mark authored
      - provide additional filtering methods on names(), sortedNames()
        For example,
      
            IOobjectList objects = ...;
            wordReList selection = ...;
      
            objects.sortedNames(VolFieldType::typeName, selection);
      b4c998a2
    • mark's avatar
      STYLE: simplify logic statement · 7658aefe
      mark authored
      7658aefe
    • mattijs's avatar
    • mattijs's avatar
    • mark's avatar
      ENH: improve objectRegistry functionality (issue #322) · 57e70437
      mark authored
      - Recursive searching for objects within a registry is now optional
        (previous it was always done).
      
        A recursive search effectively blocks the construction of sub-sub-registries
        if their names are 'masked' by some parent level sub-registry with
        the same name! (BUG)
      
      - Recursive search is now turned OFF by default, which makes it consistent
        with dictionary and probably causes the least number of surprises.
      
      ----
      Various new convenience methods added:
      
      lookupObjectRef()
      - returns a non-const reference.
        For example,
      
            volScalarField& U = mesh().lookupObjectRef<volScalarField>("U");
      
        Instead of
      
            volScalarField& U = const_cast<volScalarField&>
            (
                mesh().lookupObject<volScalarField>("U")
            );
      
      --
      lookupObjectPtr()
      - returns a const pointer, and nullptr on failure.
        For example,
      
            const volScalarField* Uptr = mesh().lookupObjectPtr<volScalarField>("U");
            if (Uptr)
            {
                const volScalarField& U = *Uptr;
                ...
            }
      
        Instead of
      
            if (mesh().foundObject<volScalarField>("U"))
            {
                const volScalarField& U = mesh().lookupObject<volScalarField>("U");
                ...
            }
      
      --
      lookupObjectRefPtr()
      - returns a non-const pointer, and nullptr on failure.
        For example,
      
            volScalarField* Uptr = mesh().lookupObjectRefPtr<volScalarField>("U");
            if (Uptr)
            {
                volScalarField& U = *Uptr;  // use as reference
                (*Uptr) = ...;              // or use directly
            }
      
        Instead of
      
            if (mesh().foundObject<volScalarField>("U"))
            {
                volScalarField& U = const_cast<volScalarField&>
                (
                    mesh().lookupObject<volScalarField>("U")
                );
            }
      
      --
      sortedNames()
      - now works with template parameters and with regular expression
        matching as well.
        For example,
      
            wordList names  = mesh().sortedNames();
            wordList fields = mesh().sortedName<volScalarField>();
      
        Instead of
      
            wordList names  = mesh().sortedNames();
            wordList fields = mesh().names<volScalarField>();
            Foam::sort(fields);
      
      --
      57e70437
    • mark's avatar
      ENH: add Test-objectRegistry (issue #322) · 8e9d4198
      mark authored
      - test clearly shows failure to insert a sub-registry when it has
        the same name as one of the parent sub-registry.
      8e9d4198
  9. 29 Nov, 2016 7 commits