I am beginning with QT5 and trying to load an image from base64 json data. I can load directly from a base64 string but is unsuccessful when trying to load from json object.
the error i am getting is error: conversion from 'QJsonValueRef' to non-scalar type 'QByteArray' requested
I tried changing toUtf8 toAcsii() etc. but similar error are being produced. Any help and suggestions will be much appreciated.
Qt Code:
QJsonDocument jsonResponse = QJsonDocument::fromJson(strReply.toUtf8()); QJsonObject jsonObj = jsonResponse.object(); QImage img; ui->outputImage->setScaledContents( true );To copy to clipboard, switch view to plain text mode
Bookmarks