Quantcast
Channel: CodeGuru Forums - Visual C++ Programming
Viewing all articles
Browse latest Browse all 3042

optionally enable the params

$
0
0
Hello ,
In the following class

Code:

class PixelCovCellInfo
{
:::::::::::::::::

private:

        unsigned int        m_cellIndex;
        unsigned char        m_carrierIndex;                        // Index of carrier on cell (for CDMA2000), or subCell on cell (for GSM)


        // Ctrl channel pathloss and antenna
        ANTENNAINDEX        m_ctrl_antIndexWrtCell;
        unsigned char        m_ctrl_pathlossDB;
        bool                        m_ctrl_LOS;                        // Line-of-sight flag

        // Traffic channel pathloss and antenna
        ANTENNAINDEX        m_traf_antIndexWrtCell;
        unsigned char        m_traf_pathlossDB;
        bool                        m_traf_LOS;                                // Line-of-sight flag

        unsigned short        m_traf_encoded_rank;
        short                        m_traf_ricefactor;                // mB
        unsigned char        m_traf_delayspread;                // dBns  (dB nanoseconds)
        int                                m_traf_angularspread;        // mBrad (mB radians)

};

The class already exists, and new params (in red)were added as part. Now based on some variable, i want to make the new params optional. Is there anyway to use the same format, and use these fields as optional. Because this class is used for many pixels, so it is very imp in keeping the memory optimal.
Whatabout putting these under union ? will it help.

thankyou
pdk

Viewing all articles
Browse latest Browse all 3042

Trending Articles