|
6 | 6 | */ |
7 | 7 |
|
8 | 8 | //***********************************************************************// |
9 | | -// Copyright 2015, 2016, 2017 Jared R. Males (jaredmales@gmail.com) |
| 9 | +// Copyright 2025 Jared R. Males (jaredmales@gmail.com) |
10 | 10 | // |
11 | 11 | // This file is part of mxlib. |
12 | 12 | // |
@@ -403,11 +403,35 @@ class milkImage |
403 | 403 | */ |
404 | 404 | void post(); |
405 | 405 |
|
| 406 | + /// Get the creation time |
| 407 | + /** |
| 408 | + * \returns the ImageStream creationtime |
| 409 | + */ |
| 410 | + const timespec & creationtime() const; |
| 411 | + |
| 412 | + /// Get the last access time |
| 413 | + /** |
| 414 | + * \returns ImageStream lastaccesstime |
| 415 | + */ |
| 416 | + const timespec & lastaccesstime() const; |
| 417 | + |
| 418 | + /// Get the acquisition time |
| 419 | + /** |
| 420 | + * \returns ImageStream acquisition time |
| 421 | + */ |
| 422 | + const timespec & atime() const; |
| 423 | + |
| 424 | + /// Get the write time |
| 425 | + /** |
| 426 | + * \returns ImageStream writetime |
| 427 | + */ |
| 428 | + const timespec & writetime() const; |
| 429 | + |
406 | 430 | /// Get the value of cnt0 (the frame counter) |
407 | 431 | /** |
408 | 432 | * \returns the current value of cnt0 |
409 | 433 | */ |
410 | | - uint64_t cnt0(); |
| 434 | + const uint64_t & cnt0() const; |
411 | 435 | }; |
412 | 436 |
|
413 | 437 | template <typename dataT> |
@@ -792,11 +816,36 @@ void milkImage<dataT>::post() |
792 | 816 | } |
793 | 817 |
|
794 | 818 | template <typename dataT> |
795 | | -uint64_t milkImage<dataT>::cnt0() |
| 819 | +const timespec & milkImage<dataT>::creationtime() const |
| 820 | +{ |
| 821 | + return m_image->md->creationtime; |
| 822 | +} |
| 823 | + |
| 824 | +template <typename dataT> |
| 825 | +const timespec & milkImage<dataT>::lastaccesstime() const |
| 826 | +{ |
| 827 | + return m_image->md->lastaccesstime; |
| 828 | +} |
| 829 | + |
| 830 | +template <typename dataT> |
| 831 | +const timespec & milkImage<dataT>::atime() const |
| 832 | +{ |
| 833 | + return m_image->md->atime; |
| 834 | +} |
| 835 | + |
| 836 | +template <typename dataT> |
| 837 | +const timespec & milkImage<dataT>::writetime() const |
| 838 | +{ |
| 839 | + return m_image->md->writetime; |
| 840 | +} |
| 841 | + |
| 842 | +template <typename dataT> |
| 843 | +const uint64_t & milkImage<dataT>::cnt0() const |
796 | 844 | { |
797 | 845 | return m_image->md->cnt0; |
798 | 846 | } |
799 | 847 |
|
| 848 | + |
800 | 849 | } // namespace improc |
801 | 850 | } // namespace mx |
802 | 851 |
|
|
0 commit comments