[hamradio-commits] [gnss-sdr] 175/251: pass vectors by reference

Carles Fernandez carles_fernandez-guest at moszumanska.debian.org
Wed Sep 2 00:22:47 UTC 2015


This is an automated email from the git hooks/post-receive script.

carles_fernandez-guest pushed a commit to branch master
in repository gnss-sdr.

commit edb636cf2cfbb55bf089fb8725b751d27cb73332
Author: Carles Fernandez <carles.fernandez at gmail.com>
Date:   Fri Jun 12 17:54:02 2015 +0200

    pass vectors by reference
---
 .../gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.cc           | 10 +++++-----
 .../gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.h            | 10 +++++-----
 2 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.cc b/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.cc
index 5804ce8..36adb6d 100644
--- a/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.cc
+++ b/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.cc
@@ -324,7 +324,7 @@ void gps_l2_m_telemetry_decoder_cc::symbol_aligner_and_decoder::reset()
 }
 
 
-bool gps_l2_m_telemetry_decoder_cc::symbol_aligner_and_decoder::get_bits(const std::vector<double> symbols, std::vector<int> &bits)
+bool gps_l2_m_telemetry_decoder_cc::symbol_aligner_and_decoder::get_bits(const std::vector<double> & symbols, std::vector<int> & bits)
 {
     const int traceback_depth = 5 * d_KK;
     int nbits_requested = symbols.size() / GPS_L2_SYMBOLS_PER_BIT;
@@ -370,7 +370,7 @@ void gps_l2_m_telemetry_decoder_cc::frame_detector::reset()
 }
 
 
-void gps_l2_m_telemetry_decoder_cc::frame_detector::get_frame_candidates(const std::vector<int> bits, std::vector<std::pair<int,std::vector<int>>> &msg_candidates)
+void gps_l2_m_telemetry_decoder_cc::frame_detector::get_frame_candidates(const std::vector<int> & bits, std::vector<std::pair<int,std::vector<int>>> & msg_candidates)
 {
     //std::stringstream ss;
     unsigned int cnav_msg_length = 300;
@@ -434,7 +434,7 @@ void gps_l2_m_telemetry_decoder_cc::crc_verifier::reset()
 }
 
 
-void gps_l2_m_telemetry_decoder_cc::crc_verifier::get_valid_frames(const std::vector<msg_candiate_int_t> msg_candidates, std::vector<msg_candiate_int_t> &valid_msgs)
+void gps_l2_m_telemetry_decoder_cc::crc_verifier::get_valid_frames(const std::vector<msg_candiate_int_t> & msg_candidates, std::vector<msg_candiate_int_t> & valid_msgs)
 {
     std::vector <unsigned char> tmp_msg;
     LOG(INFO) << "get_valid_frames(): " << "msg_candidates.size()=" << msg_candidates.size();
@@ -461,7 +461,7 @@ void gps_l2_m_telemetry_decoder_cc::crc_verifier::get_valid_frames(const std::ve
 
 
 
-void gps_l2_m_telemetry_decoder_cc::crc_verifier::zerropad_back_and_convert_to_bytes(const std::vector<int> msg_candidate, std::vector<unsigned char> &bytes)
+void gps_l2_m_telemetry_decoder_cc::crc_verifier::zerropad_back_and_convert_to_bytes(const std::vector<int> & msg_candidate, std::vector<unsigned char> & bytes)
 {
     //std::stringstream ss;
     const size_t bits_per_byte = 8;
@@ -488,7 +488,7 @@ void gps_l2_m_telemetry_decoder_cc::crc_verifier::zerropad_back_and_convert_to_b
 
 
 
-void gps_l2_m_telemetry_decoder_cc::crc_verifier::zerropad_front_and_convert_to_bytes(const std::vector<int> msg_candidate, std::vector<unsigned char> &bytes)
+void gps_l2_m_telemetry_decoder_cc::crc_verifier::zerropad_front_and_convert_to_bytes(const std::vector<int> & msg_candidate, std::vector<unsigned char> & bytes)
 {
     //std::stringstream ss;
     const size_t bits_per_byte = 8;
diff --git a/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.h b/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.h
index 15d5d08..bf63bad 100644
--- a/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.h
+++ b/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2_m_telemetry_decoder_cc.h
@@ -127,7 +127,7 @@ private:
         symbol_aligner_and_decoder();
         ~symbol_aligner_and_decoder();
         void reset();
-        bool get_bits(const std::vector<double> symbols, std::vector<int> &bits);
+        bool get_bits(const std::vector<double> & symbols, std::vector<int> & bits);
     private:
         int d_KK;
         Viterbi_Decoder * d_vd1;
@@ -141,7 +141,7 @@ private:
     {
     public:
         void reset();
-        void get_frame_candidates(const std::vector<int> bits, std::vector<std::pair<int, std::vector<int>>> &msg_candidates);
+        void get_frame_candidates(const std::vector<int> & bits, std::vector<std::pair<int, std::vector<int>>> & msg_candidates);
     private:
         std::deque<int> d_buffer;
     } d_frame_detector;
@@ -152,12 +152,12 @@ private:
     {
     public:
         void reset();
-        void get_valid_frames(const std::vector<msg_candiate_int_t> msg_candidates,  std::vector<msg_candiate_int_t> &valid_msgs);
+        void get_valid_frames(const std::vector<msg_candiate_int_t> & msg_candidates, std::vector<msg_candiate_int_t> & valid_msgs);
     private:
         typedef boost::crc_optimal<24, 0x1864CFBu, 0x0, 0x0, false, false> crc_24_q_type;
         crc_24_q_type d_checksum_agent;
-        void zerropad_front_and_convert_to_bytes(const std::vector<int> msg_candidate, std::vector<unsigned char> &bytes);
-        void zerropad_back_and_convert_to_bytes(const std::vector<int> msg_candidate, std::vector<unsigned char> &bytes);
+        void zerropad_front_and_convert_to_bytes(const std::vector<int> & msg_candidate, std::vector<unsigned char> & bytes);
+        void zerropad_back_and_convert_to_bytes(const std::vector<int> & msg_candidate, std::vector<unsigned char> & bytes);
     } d_crc_verifier;
 
     Gps_CNAV_Navigation_Message d_CNAV_Message;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-hamradio/gnss-sdr.git



More information about the pkg-hamradio-commits mailing list