Signaling (previously RTM) v1.4.8 API Reference for Unity
Public Member Functions | List of all members
agora_rtm.ImageMessage Class Reference

Inherits agora_rtm.IMessage.

Public Member Functions

 ImageMessage (IntPtr MessagePtr)
 
 ImageMessage (IntPtr MessagePtr, MESSAGE_FLAG MessageFlag)
 
 ImageMessage (ImageMessage imageMessage, MESSAGE_FLAG MessageFlag)
 
Int64 GetSize ()
 
string GetMediaId ()
 
void SetThumbnail (byte[] thumbnail)
 
byte[] GetThumbnail ()
 
void SetFileName (string fileName)
 
string GetFileName ()
 
void SetWidth (int width)
 
int GetWidth ()
 
void SetHeight (int height)
 
int GetHeight ()
 
void SetThumbnailWidth (int thumbnailWidth)
 
int GetThumbnailWidth ()
 
void SetThumbnailHeight (int height)
 
int GetThumbnailHeight ()
 
- Public Member Functions inherited from agora_rtm.IMessage
Int64 GetMessageId ()
 
MESSAGE_TYPE GetMessageType ()
 
void SetText (string text)
 
string GetText ()
 
byte[] GetRawMessageData ()
 
int GetRawMessageLength ()
 
Int64 GetServerReceiveTs ()
 
bool IsOfflineMessage ()
 
IntPtr GetPtr ()
 
void SetMessagePtr (IntPtr messagePtr)
 

Additional Inherited Members

- Public Attributes inherited from agora_rtm.IMessage
int _Length = 0
 
- Protected Member Functions inherited from agora_rtm.IMessage
void Release ()
 
- Protected Attributes inherited from agora_rtm.IMessage
MESSAGE_FLAG _MessageFlag = MESSAGE_FLAG.RECEIVE
 
IntPtr _MessagePtr = IntPtr.Zero
 
Int64 _MessageId = 0
 
MESSAGE_TYPE _MessageType = MESSAGE_TYPE.MESSAGE_TYPE_UNDEFINED
 
string _MessageText = ""
 
bool _IsOfflineMessage = false
 
Int64 _Ts = 0
 
byte[] _RawMessageData = null
 

Constructor & Destructor Documentation

◆ ImageMessage() [1/3]

agora_rtm.ImageMessage.ImageMessage ( IntPtr  MessagePtr)
inline

◆ ImageMessage() [2/3]

agora_rtm.ImageMessage.ImageMessage ( IntPtr  MessagePtr,
MESSAGE_FLAG  MessageFlag 
)
inline

◆ ImageMessage() [3/3]

agora_rtm.ImageMessage.ImageMessage ( ImageMessage  imageMessage,
MESSAGE_FLAG  MessageFlag 
)
inline

Member Function Documentation

◆ GetFileName()

string agora_rtm.ImageMessage.GetFileName ( )
inline

Gets the filename of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Returns
The filename of the uploaded image.

◆ GetHeight()

int agora_rtm.ImageMessage.GetHeight ( )
inline

Gets the height of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
  • If the uploaded image is in JPG, JPEG, BMP, or PNG format, the SDK automatically calculates the width and height of the image. You can call this method directly to get the height of the image.
  • Image height that is set by calling SetHeight overrides the height calculated by the SDK.
Returns
The height of the uploaded image.

◆ GetMediaId()

string agora_rtm.ImageMessage.GetMediaId ( )
inline

Gets the media ID of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
  • The media ID is automatically populated once the file is uploaded to the file server.
  • The media ID is valid for 7 days because the Agora server keeps all uploaded images for 7 days only.
Returns
The media ID of the uploaded image.

◆ GetSize()

Int64 agora_rtm.ImageMessage.GetSize ( )
inline

Gets the size of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Returns
The size of the uploaded image in bytes.

◆ GetThumbnail()

byte [] agora_rtm.ImageMessage.GetThumbnail ( )
inline

Gets the thumbnail data of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Returns
The thumbnail data of the uploaded image.

◆ GetThumbnailHeight()

int agora_rtm.ImageMessage.GetThumbnailHeight ( )
inline

Gets the height of the thumbnail.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Returns
The height of the thumbnail.

◆ GetThumbnailWidth()

int agora_rtm.ImageMessage.GetThumbnailWidth ( )
inline

Gets the width of the thumbnail.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Returns
The width of the thumbnail.

◆ GetWidth()

int agora_rtm.ImageMessage.GetWidth ( )
inline

Gets the width of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
  • If the uploaded image is in JPG, JPEG, BMP, or PNG format, the SDK automatically calculates the width and height of the image. You can call this method directly to get the width of the image.
  • Image width that is set by calling SetWidth overrides the width calculated by the SDK.
Returns
The width of the uploaded image. Returns 0 if the SDK does not support the format of the uploaded image.

◆ SetFileName()

void agora_rtm.ImageMessage.SetFileName ( string  fileName)
inline

Sets the filename of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Parameters
fileNameThe filename of the uploaded image. The total size of thumbnail and fileName must not exceed 32 KB.

◆ SetHeight()

void agora_rtm.ImageMessage.SetHeight ( int  height)
inline

Sets the height of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
  • If the uploaded image is in JPG, JPEG, BMP, or PNG format, the SDK automatically calculates the width and height of the image. You can call GetHeight directly to get the height of the image.
  • Image height that is set by calling this method overrides the height calculated by the SDK.
Parameters
heightThe height of the uploaded image. Returns 0 if the SDK does not support the format of the uploaded image.

◆ SetThumbnail()

void agora_rtm.ImageMessage.SetThumbnail ( byte[]  thumbnail)
inline

Sets the thumbnail of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Parameters
thumbnailThe thumbnail of the uploaded image.

◆ SetThumbnailHeight()

void agora_rtm.ImageMessage.SetThumbnailHeight ( int  height)
inline

Sets the height of the thumbnail.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
You need to work out the height of the thumbnail by yourself, because the SDK does not work out the value for you.
Parameters
heightThe height of the thumbnail.

◆ SetThumbnailWidth()

void agora_rtm.ImageMessage.SetThumbnailWidth ( int  thumbnailWidth)
inline

Sets the width of the thumbnail.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
You need to work out the height of the thumbnail by yourself, because the SDK does not work out the value for you.
Parameters
thumbnailWidththe The width of the thumbnail.

◆ SetWidth()

void agora_rtm.ImageMessage.SetWidth ( int  width)
inline

Sets the width of the uploaded image.

Deprecated:
This method is deprecated. Agora recommends that you do not use it.
Note
  • If the uploaded image is in JPG, JPEG, BMP, or PNG format, the SDK automatically calculates the width and height of the image. You can call getWidth directly to get the width of the image.
  • Image width that is set by calling this method overrides the width calculated by the SDK.
Parameters
widthThe width of the uploaded image.

The documentation for this class was generated from the following file: