/[svn]/linuxsampler/trunk/src/engines/sfz/sfz.h
ViewVC logotype

Diff of /linuxsampler/trunk/src/engines/sfz/sfz.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4015 by schoenebeck, Mon Jan 3 15:10:25 2022 UTC revision 4016 by schoenebeck, Mon Jan 3 15:36:02 2022 UTC
# Line 702  namespace sfz Line 702  namespace sfz
702          /// Returns a pointer to the instrument object          /// Returns a pointer to the instrument object
703          Instrument* GetInstrument();          Instrument* GetInstrument();
704    
705            /// Returns true if file was modified since last call
706            bool checkFileModified(std::string filename = "");
707    
708        protected:
709            struct Time {
710                intmax_t sec;
711                uint32_t nsec;
712    
713                bool operator==(const Time& o) const {
714                    return sec == o.sec && nsec == o.nsec;
715                }
716    
717                bool operator!=(const Time& o) const {
718                    return !(*this == o);
719                }
720            };
721    
722      private:      private:
723          void  push_header(std::string token);          void  push_header(std::string token);
724          void  push_opcode(std::string token);          void  push_opcode(std::string token);
# Line 737  namespace sfz Line 754  namespace sfz
754          std::string default_path;          std::string default_path;
755          int octave_offset;          int octave_offset;
756          int note_offset;          int note_offset;
757    
758            /// to detect when files were modified (e.g. by some external app)
759            std::map<std::string,Time> mod_times;
760    
761            static optional<File::Time> getModTimeOfFile(std::string filename);
762      };      };
763    
764  } // !namespace sfz  } // !namespace sfz

Legend:
Removed from v.4015  
changed lines
  Added in v.4016

  ViewVC Help
Powered by ViewVC