Skip to content

Commit

Permalink
switched to using writetime instead of atime for more consistent resu…
Browse files Browse the repository at this point in the history
…lts; fixed make so it makes
  • Loading branch information
jaredmales committed Oct 1, 2023
1 parent 51f121e commit 20a6e0c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 8 deletions.
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,21 @@ endif

##############################

all: bin/librtimv.so bin/rtimv
all: librtimv rtimv

makefile.librtimv: librtimv.pro
$(QMAKE) -makefile librtimv.pro

makefile.rtimv: rtimv.pro
$(QMAKE) -makefile rtimv.pro

bin/librtimv.so: makefile.librtimv
librtimv: makefile.librtimv
$(MAKE) -f makefile.librtimv

bin/rtimv: makefile.rtimv
rtimv: makefile.rtimv
$(MAKE) -f makefile.rtimv

install: makefile.librtimv makefile.rtimv bin/librtimv.so bin/rtimv
install: makefile.librtimv makefile.rtimv librtimv rtimv
$(MAKE) -f makefile.librtimv install
$(MAKE) -f makefile.rtimv install

Expand All @@ -44,4 +44,4 @@ clean:
rm -f bin/librtimv.so*
rm -f bin/rtimv

.PHONY: all install clean
.PHONY: all install clean librtimv rtimv
2 changes: 1 addition & 1 deletion src/images/shmimImage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ int shmimImage::update()
if(cnt0 != m_lastCnt0) //Only redraw if it's actually a new image.
{
m_data = ((char *) (m_image.array.raw)) + curr_image*snx*sny*m_typeSize;
m_imageTime = m_image.md->atime.tv_sec + ((double) m_image.md->atime.tv_nsec)/1e9;
m_imageTime = m_image.md->writetime.tv_sec + ((double) m_image.md->writetime.tv_nsec)/1e9;

m_lastCnt0 = cnt0;
m_age_counter = 0;
Expand Down
8 changes: 6 additions & 2 deletions src/rtimvMainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -830,10 +830,14 @@ void rtimvMainWindow::updateAge()
{
ui.graphicsView->fpsGageText(m_images[0]->fpsEst());
}
else
else if(age < 86400*10000) //only if age is reasonable
{
ui.graphicsView->fpsGageText(age, true);
}
}
else
{
ui.graphicsView->fpsGageText("");
}
}

for(size_t n=0;n<m_overlays.size(); ++n)
Expand Down

0 comments on commit 20a6e0c

Please sign in to comment.