×

Discussion Board

Results 1 to 5 of 5
  1. #1
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    114

    does symbian support float type??

    I have following in the h file
    #include <e32base.h>
    #include <e32cmn.h>
    #include <e32std.h>

    class CCanny
    {
    //method
    public:
    CCanny();
    ~CCanny();
    void processL(RArray<TInt8>&pixel, TInt temp_width,TInt temp_height );
    //method
    private:


    void computeGradients(RArray<TInt8>&pixel, float kernelRadius,TInt kernelWidth, RArray<TInt> &magnitude);
    void performHysteresis(TInt low, TInt high);
    }

    but when I compile, i got an error on performHysteresis(...) saying that error: candidate is void CCanny:erformHysteresis(..). Is this because I am using float data type in the previous line? what can i do to overcome this problem? btw, does symbian support float data type? I have had libc installed

  2. #2
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    114

    Re: does symbian support float type??

    the issue has been solved...

    btw, how to use the function in math.h?

    I have the folloing code, where hypotf is from math.h from libc


    #include <math.h> // i also try #include <libc\math.h> here!
    ...
    ..
    float gradMag = hypotf(xGrad, yGrad);
    but when I compile the code, it generate "hypotf not defined"
    can anyone help?
    Last edited by sandy_zeng; 2008-01-16 at 09:28.

  3. #3
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    28,748

    Re: does symbian support float type??

    Since the word hypotf does not appear in any of the .lib files in the SDK-s I have checked (2nd, 2nd FP2, 3rd MR, 3rd FP1), my guess would be that it is not supported.

  4. #4
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    114

    Re: does symbian support float type??

    but it appears in the libc math.h file

    actually none of the following can get compiled ..


    #define gaussian(x, sigma) (expf(-(x * x)) / (2 * sigma * sigma))

    ...

    TInt low = (TInt)round(lowThreshold * MAGNITUDE_SCALE);
    TInt high = (TInt)round( highThreshold * MAGNITUDE_SCALE);
    float nMag = hypotf(xGradient[indexN], yGradient[indexN]);

    all of them said xx not defined (xx stand for the function name)

    but when i search the math.h file in the libc, it does exist..

  5. #5
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    28,748

    Re: does symbian support float type??

    I have also seen the .h file, you can bet. However a header is useless without the implementation. And if the words declared (but not #defined/inline-d) in the .h are not appearing in the implementation (estlib.lib in particular), they are unusable.

Similar Threads

  1. UPnP/DLNA support in Symbian Version 9.X ?
    By rajivc in forum Symbian Networking & Messaging (Closed)
    Replies: 7
    Last Post: 2008-07-18, 08:21
  2. Urgent! Does symbian support DHCP
    By xhsoldier in forum Symbian
    Replies: 6
    Last Post: 2007-06-11, 10:26
  3. Does Symbian C++ SIP API support IPv6?
    By zhengkun in forum Symbian Networking & Messaging (Closed)
    Replies: 1
    Last Post: 2006-11-09, 04:52
  4. Support for multiple "c=" lines in a single SDP message body (Symbian 3.0 SIP stack)
    By springsonv in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2005-05-25, 10:10
  5. Replies: 3
    Last Post: 2003-07-17, 04:11

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×