Assc Posted November 21, 2019 Share Posted November 21, 2019 I would like to make sure about GetValidity() in SRanipal Unreal SDK. (I'm using Unreal Engine 4.22.3, SRanipal_Runtime 1.1.2.0, SRanipalSDK 1.1.0.1.) I have checked the source code concerned to GetValidity() in SDK (see TEXT1 below) and seemed to discover that GetValidity() is incorrect in a part of the code. If the validity as an argument with GetValidity() is SINGLE_EYE_DATA_GAZE_ORIGIN_VALIDITY and its flug also be been on in an eye_data_validata_bit_mask, the function should return the TRUE, however, it returns FALSE. Because, SINGLE_EYE_DATA_GAZE_ORIGIN_VALIDITY defines 0 in the SingleEyeDataValidity(TEXT1) as enum. Therefore, the source code should be corrected as GetValidity() in TEXT2, or SINGLE_EYE_DATA_GAZE_ORIGIN_VALIDITY should be not 0, how is this? -TEXT1(This is SRanipal_Eyes_Enums.h)- enum SingleEyeDataValidity { SINGLE_EYE_DATA_GAZE_ORIGIN_VALIDITY, SINGLE_EYE_DATA_GAZE_DIRECTION_VALIDITY, SINGLE_EYE_DATA_PUPIL_DIAMETER_VALIDITY, SINGLE_EYE_DATA_EYE_OPENNESS_VALIDITY, SINGLE_EYE_DATA_PUPIL_POSITION_IN_SENSOR_AREA_VALIDITY }; typedef struct SingleEyeData { /** The bits containing all validity for this frame.*/ uint64_t eye_data_validata_bit_mask; bool GetValidity(SingleEyeDataValidity validity) { return (eye_data_validata_bit_mask & (uint64)validity) > 0; } }SingleEyeData; -TEXT2- bool GetValidity(SingleEyeDataValidity validity) { return (eye_data_validata_bit_mask & ((uint64)1 << (uint64)validity)) > 0; } Thank you. @Daniel_Y @zzy Link to comment Share on other sites More sharing options...
Andy.YC_Wang Posted November 29, 2019 Share Posted November 29, 2019 Hi @Assc, You're right Thanks for the information Regards, Andy.YC Wang Link to comment Share on other sites More sharing options...
Assc Posted December 2, 2019 Author Share Posted December 2, 2019 @Andy.YC_Wang Sorry for the late reply. Thank you very much for your answer. Regards, Assc Link to comment Share on other sites More sharing options...
guilhermedaniel Posted December 10, 2019 Share Posted December 10, 2019 Hi, do you have any hints of where to start to get the data using the SRanipal SDK in Unreal? I need to save data in a log file for each framerate displayed by the HMD. Thank you! @Andy.YC_Wang Link to comment Share on other sites More sharing options...
Andy.YC_Wang Posted December 16, 2019 Share Posted December 16, 2019 Hi @guilhermedaniel You can try to add an UE_Log in UpdateData function Regards, Andy.YC Wang Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now