Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to get face byte[] from userId? #2

Open
Madina-S opened this issue Jan 23, 2022 · 0 comments
Open

How to get face byte[] from userId? #2

Madina-S opened this issue Jan 23, 2022 · 0 comments

Comments

@Madina-S
Copy link

I have tried to use modify, delete and add face info methods to get face info. I have just changed parameter types and enum value.

public static NET_OUT_GET_FACE_INFO getFaceInfo(String userId) {
        NET_IN_GET_FACE_INFO stIn = new NET_IN_GET_FACE_INFO();
        System.arraycopy(userId.getBytes(), 0, stIn.szUserID, 0, userId.getBytes().length);
        NET_OUT_GET_FACE_INFO stOut = new NET_OUT_GET_FACE_INFO();

        stIn.write();
        stOut.write();

        boolean bRet = LoginModule.netsdk.CLIENT_FaceInfoOpreate(LoginModule.m_hLoginHandle, EM_FACEINFO_OPREATE_TYPE.EM_FACEINFO_OPREATE_GET, stIn.getPointer(), stOut.getPointer(), 5000);
        if (bRet) {
            System.out.println("find face info!");
        } else {
            System.err.println("error in reading face!" + ToolKits.getErrorCodePrint());
            return null;
        }

        stIn.read();
        stOut.read();

        return stOut;
    }

But, it says:

{error code: (0x80000000|21).参考  NetSDKLib.java } - {error info:Error occurs when verify returned data}

Please, help to find what is wrong

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant