Skip to content

Commit

Permalink
feat: upgrade native sdk 4.2.6.240 (#1834)
Browse files Browse the repository at this point in the history
Update native sdk 4.2.6.240 dependencies

> This pull request is trigger by bot, you can checkout this branch and
update it.

---------

Co-authored-by: littleGnAl <littleGnAl@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
3 people authored Jun 14, 2024
1 parent 7971237 commit 9a870b0
Show file tree
Hide file tree
Showing 52 changed files with 1,957 additions and 1,262 deletions.
71 changes: 71 additions & 0 deletions .github/workflows/code-gen.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: Code gen

on:
workflow_dispatch:
inputs:
target_branch:
description: The branch to run code-gen
type: string
required: true
default: 'main'

version:
description: 'The version of native sdk in terra-script'
required: false
type: string
default: ''

jobs:
run_code_gen:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: ${{ inputs.target_branch }}
fetch-depth: 0
- name: enable corepack
run: corepack enable
- name: set node
uses: actions/setup-node@v4
with:
node-version: 'lts/*'
- name: Reconfigure git to use HTTP authentication
run: |
git config --global url."https://${{ secrets.GH_TOKEN }}@github.com/".insteadOf ssh://git@github.com/
- name: Install LLVM and Clang
uses: KyleMayes/install-llvm-action@v1
with:
version: "15.0.6" # Need ping version to 15.x
directory: ${{ runner.temp }}/llvm
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
- name: Run code-gen
run: |
bash scripts/code_gen.sh ${{ inputs.version }}
- name: Get current date
id: date
run: echo "date=$(date +'%Y%m%d')" >> "$GITHUB_OUTPUT"

- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "Auto generate codes for native sdk version ${{ inputs.version }}"
committer: GitHub <noreply@github.com>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
signoff: false
branch: auto-code-gen-${{ steps.date.outputs.date }}
base: ${{ inputs.target_branch }}
delete-branch: true
title: "Auto generate codes for native sdk ${{ inputs.version }}"
body: |
Auto generate codes for native sdk version ${{ inputs.version }}
*This pull request is opened by bot*
labels: |
ci:skip
reviewers: |
littleGnAl
6 changes: 3 additions & 3 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@ dependencies {
if (isDev(project)) {
implementation fileTree(dir: "libs", include: ["*.jar"])
} else {
api 'io.agora.rtc:iris-rtc:4.2.6.10-build.1'
api 'io.agora.rtc:agora-special-full:4.2.6.12'
api 'io.agora.rtc:full-screen-sharing:4.2.6.12'
api 'io.agora.rtc:iris-rtc:4.2.6.240-build.1'
api 'io.agora.rtc:agora-special-full:4.2.6.240'
api 'io.agora.rtc:full-screen-sharing:4.2.6.240'
}
}

Expand Down
54 changes: 29 additions & 25 deletions android/src/main/cpp/third_party/include/agora_rtc/AgoraBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -690,6 +690,14 @@ enum ERROR_CODE_TYPE {
ERR_PCMSEND_FORMAT = 200, // unsupport pcm format
ERR_PCMSEND_BUFFEROVERFLOW = 201, // buffer overflow, the pcm send rate too quickly

// 250~270 RDT error code
ERR_RDT_USER_NOT_EXIST = 250,
ERR_RDT_USER_NOT_READY = 251,
ERR_RDT_DATA_BLOCKED = 252,
ERR_RDT_CMD_EXCEED_LIMIT = 253,
ERR_RDT_DATA_EXCEED_LIMIT = 254,
ERR_RDT_ENCRYPTION = 255,

/// @cond
// signaling: 400~600
ERR_LOGIN_ALREADY_LOGIN = 428,
Expand Down Expand Up @@ -1320,18 +1328,6 @@ enum AUDIO_CODEC_TYPE {
* 12: LPCNET.
*/
AUDIO_CODEC_LPCNET = 12,
/**
* 13: Opus codec, supporting 4-channel audio.
*/
AUDIO_CODEC_OPUS4C = 13,
/**
* 14: Opus codec, supporting 6-channel audio.
*/
AUDIO_CODEC_OPUS6C = 14,
/**
* 15: Opus codec, supporting 8-channel audio.
*/
AUDIO_CODEC_OPUS8C = 15,
};

/**
Expand Down Expand Up @@ -2928,14 +2924,6 @@ enum REMOTE_AUDIO_STATE_REASON
* 7: The remote user leaves the channel.
*/
REMOTE_AUDIO_REASON_REMOTE_OFFLINE = 7,
/**
* 8: Not receive any audio packet from remote user.
*/
REMOTE_AUDIO_REASON_REMOTE_NO_PACKET_RECEIVE = 8,
/**
* 8: Not receive any audio packet from remote user.
*/
REMOTE_AUDIO_REASON_REMOTE_LOCAL_PLAY_FAILED = 9,
};

/**
Expand Down Expand Up @@ -5743,11 +5731,7 @@ enum EAR_MONITORING_FILTER_TYPE {
/**
* 4: Enable noise suppression to the in-ear monitor.
*/
EAR_MONITORING_FILTER_NOISE_SUPPRESSION = (1<<2),
/**
* 32768: Enable audio filters by reuse post-processing filter to the in-ear monitor.
*/
EAR_MONITORING_FILTER_REUSE_POST_PROCESSING_FILTER = (1<<15),
EAR_MONITORING_FILTER_NOISE_SUPPRESSION = (1<<2)
};

/**
Expand Down Expand Up @@ -6046,6 +6030,26 @@ struct LocalAccessPointConfiguration {
LocalAccessPointConfiguration() : ipList(NULL), ipListSize(0), domainList(NULL), domainListSize(0), verifyDomainName(NULL), mode(ConnectivityFirst) {}
};

/**
* Reliable Data Transmission Tunnel message type
*/
enum RdtStreamType {
RDT_STREAM_CMD, // Reliable; High priority; Limit 256 bytes per packet, 100 packets per second
RDT_STREAM_DATA, // Reliable; Low priority; Restricted by congestion control; Limit 128K bytes per packet
RDT_STREAM_COUNT,
};

/**
* Reliable Data Transmission tunnel state
*/
enum RdtState {
RDT_STATE_CLOSED, // initial or closed
RDT_STATE_OPENED, // opened and can send data
RDT_STATE_BLOCKED, // send buffer is full, can't send data, but can send cmd
RDT_STATE_PENDING, // reconnecting tunnel, can't send data
RDT_STATE_BROKEN, // rdt tunnel broken, will auto reset and rebuild tunnel
};


} // namespace rtc

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,6 @@ enum VIDEO_SOURCE_TYPE {
/** Video for fourth screen sharing.
*/
VIDEO_SOURCE_SCREEN_FOURTH = 14,
/** Video for voice drive.
*/
VIDEO_SOURCE_SPEECH_DRIVEN = 15,

VIDEO_SOURCE_UNKNOWN = 100
};
Expand Down Expand Up @@ -196,19 +193,6 @@ enum RAW_AUDIO_FRAME_OP_MODE_TYPE {
RAW_AUDIO_FRAME_OP_MODE_READ_WRITE = 2,
};

/**
* The mix policy of the track per connection.
* For default, this connections mix policy is REMOTE | LOCAL(3).
*/
enum TRACK_AUDIO_MIXED_POLICY_TYPE {
/** 0: All remote track that created by remote UID would be mixed.
*/
TRACK_AUDIO_MIXED_LOCAL = 1 << 0,
/** 1: All local publish track would be mixed, microphone track, mpk track etc.
*/
TRACK_AUDIO_MIXED_REMOTE = 1 << 1,
};

/**
* The struct of AudioDeviceInfo.
*
Expand Down Expand Up @@ -325,10 +309,6 @@ enum MEDIA_SOURCE_TYPE {
* 12: Video for transcoded.
*/
TRANSCODED_VIDEO_SOURCE = 12,
/**
* 13: Video for voice drive.
*/
SPEECH_DRIVEN_VIDEO_SOURCE = 13,
/**
* 100: Internal Usage only.
*/
Expand Down Expand Up @@ -597,10 +577,6 @@ enum VIDEO_PIXEL_FORMAT {
* 17: ID3D11Texture2D, only support DXGI_FORMAT_B8G8R8A8_UNORM, DXGI_FORMAT_B8G8R8A8_TYPELESS, DXGI_FORMAT_NV12 texture format
*/
VIDEO_TEXTURE_ID3D11TEXTURE2D = 17,
/**
* 18: I010. 10bit I420 data.
*/
VIDEO_PIXEL_I010 = 18,
};

/**
Expand Down Expand Up @@ -678,7 +654,6 @@ struct ExternalVideoFrame {
metadata_buffer(NULL),
metadata_size(0),
alphaBuffer(NULL),
fillAlphaBuffer(false),
d3d11_texture_2d(NULL),
texture_slice_index(0){}

Expand Down Expand Up @@ -797,18 +772,11 @@ struct ExternalVideoFrame {
*/
int metadata_size;
/**
* Indicates the alpha channel of current frame, which is consistent with the dimension of the video frame.
* The value range of each pixel is [0,255], where 0 represents the background; 255 represents the foreground.
* The default value is NULL.
* @technical preview
* Indicates the output data of the portrait segmentation algorithm, which is consistent with the size of the video frame.
* The value range of each pixel is [0,255], where 0 represents the background; 255 represents the foreground (portrait).
* The default value is NULL
*/
uint8_t* alphaBuffer;
/**
* Extract alphaBuffer from bgra or rgba data. Set it true if you do not explicitly specify the alphabuffer.
* The default value is false
* @technical preview
*/
bool fillAlphaBuffer;

/**
* [Windows Texture related parameter] The pointer of ID3D11Texture2D used by the video frame.
Expand Down Expand Up @@ -926,10 +894,9 @@ struct VideoFrame {
*/
float matrix[16];
/**
* Indicates the alpha channel of current frame, which is consistent with the dimension of the video frame.
* The value range of each pixel is [0,255], where 0 represents the background; 255 represents the foreground.
* The default value is NULL.
* @technical preview
* Indicates the output data of the portrait segmentation algorithm, which is consistent with the size of the video frame.
* The value range of each pixel is [0,255], where 0 represents the background; 255 represents the foreground (portrait).
* The default value is NULL
*/
uint8_t* alphaBuffer;
/**
Expand Down Expand Up @@ -1077,10 +1044,6 @@ class IAudioFrameObserverBase {
* The number of the audio track.
*/
int audioTrackNumber;
/**
* RTP timestamp of the first sample in the AudioFrame
*/
uint32_t rtpTimestamp;

AudioFrame() : type(FRAME_TYPE_PCM16),
samplesPerChannel(0),
Expand All @@ -1091,8 +1054,7 @@ class IAudioFrameObserverBase {
renderTimeMs(0),
avsync_type(0),
presentationMs(0),
audioTrackNumber(0),
rtpTimestamp(0) {}
audioTrackNumber(0) {}
};

enum AUDIO_FRAME_POSITION {
Expand Down Expand Up @@ -1711,21 +1673,6 @@ struct MediaRecorderConfiguration {
MediaRecorderConfiguration() : storagePath(NULL), containerFormat(FORMAT_MP4), streamType(STREAM_TYPE_BOTH), maxDurationMs(120000), recorderInfoUpdateInterval(0) {}
MediaRecorderConfiguration(const char* path, MediaRecorderContainerFormat format, MediaRecorderStreamType type, int duration, int interval) : storagePath(path), containerFormat(format), streamType(type), maxDurationMs(duration), recorderInfoUpdateInterval(interval) {}
};

class IFaceInfoObserver {
public:
/**
* Occurs when the face info is received.
* @param outFaceInfo The output face info.
* @return
* - true: The face info is valid.
* - false: The face info is invalid.
*/
virtual bool onFaceInfo(const char* outFaceInfo) = 0;

virtual ~IFaceInfoObserver() {}
};

/**
* Information for the recording file.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,20 +73,6 @@ class IMediaEngine {
* - < 0: Failure.
*/
virtual int registerVideoEncodedFrameObserver(IVideoEncodedFrameObserver* observer) = 0;

/**
* Registers a face info observer object.
*
* @note
* Ensure that you call this method before \ref IRtcEngine::joinChannel "joinChannel".
*
* @param observer A pointer to the face info observer object: IFaceInfoObserver.
*
* @return
* - 0: Success.
* - < 0: Failure.
*/
virtual int registerFaceInfoObserver(IFaceInfoObserver* observer) = 0;

/**
* Pushes the external audio data to the app.
Expand Down
Loading

0 comments on commit 9a870b0

Please sign in to comment.