Squashed 'external/toxcore/c-toxcore/' changes from 1701691d5..640e6cace
640e6cace fix(toxav): remove extra copy of video frame on encode Tested and works, but there might be alignment issues and other stuff. 6f7f51554 chore(toxav): use realtime deadline for vp8 encoder Technically all this does is choose a quality based on frame duration, which we always set to 1, and as such is always realtime. (In same timebase as pts, which we use as a frame counter...) 5047ae5a2 chore: make the source tarball exhibit the old behavior 14804a4b8 chore: Fix sonar-scan CI action. e2db7d946 cleanup: Exclude lan_discovery test from running on macos, instead of excluding it from the project. 3accade67 chore: Fix CI, disabling some tests that no longer run on CI. ef8d767e6 cleanup: Fix comment formatting errors. 34ec822da cleanup: Fix some clang-19 format warnings. 40b3f0b46 refactor: Use clang's nullability qualifiers instead of attributes. f81e30679 refactor: Use per-parameter nullability annotations. REVERT: 1701691d5 chore(toxav): use realtime deadline for vp8 encoder Technically all this does is choose a quality based on frame duration, which we always set to 1, and as such is always realtime. (In same timebase as pts, which we use as a frame counter...) REVERT: a87505867 fix(toxav): remove extra copy of video frame on encode Tested and works, but there might be alignment issues and other stuff. git-subtree-dir: external/toxcore/c-toxcore git-subtree-split: 640e6cace81b4412c45977b94eb9c41e53c54035
This commit is contained in:
@@ -74,8 +74,7 @@ uint32_t tox_events_get_size(const Tox_Events *events)
|
||||
return events == nullptr ? 0 : events->events_size;
|
||||
}
|
||||
|
||||
nullable(1)
|
||||
static const Tox_Event *tox_events_get_events(const Tox_Events *events)
|
||||
static const Tox_Event *tox_events_get_events(const Tox_Events *_Nullable events)
|
||||
{
|
||||
return events == nullptr ? nullptr : events->events;
|
||||
}
|
||||
@@ -107,16 +106,14 @@ Tox_Events *tox_events_iterate(Tox *tox, bool fail_hard, Tox_Err_Events_Iterate
|
||||
return state.events;
|
||||
}
|
||||
|
||||
non_null()
|
||||
static bool tox_event_pack_handler(const void *arr, uint32_t index, const Logger *logger, Bin_Pack *bp)
|
||||
static bool tox_event_pack_handler(const void *_Nonnull arr, uint32_t index, const Logger *_Nonnull logger, Bin_Pack *_Nonnull bp)
|
||||
{
|
||||
const Tox_Event *events = (const Tox_Event *)arr;
|
||||
assert(events != nullptr);
|
||||
return tox_event_pack(&events[index], bp);
|
||||
}
|
||||
|
||||
non_null(3) nullable(1, 2)
|
||||
static bool tox_events_pack_handler(const void *obj, const Logger *logger, Bin_Pack *bp)
|
||||
static bool tox_events_pack_handler(const void *_Nullable obj, const Logger *_Nullable logger, Bin_Pack *_Nonnull bp)
|
||||
{
|
||||
const Tox_Events *events = (const Tox_Events *)obj;
|
||||
return bin_pack_obj_array(bp, tox_event_pack_handler, tox_events_get_events(events), tox_events_get_size(events), logger);
|
||||
@@ -132,8 +129,7 @@ bool tox_events_get_bytes(const Tox_Events *events, uint8_t *bytes)
|
||||
return bin_pack_obj(tox_events_pack_handler, events, nullptr, bytes, UINT32_MAX);
|
||||
}
|
||||
|
||||
non_null()
|
||||
static bool tox_events_unpack_handler(void *obj, Bin_Unpack *bu)
|
||||
static bool tox_events_unpack_handler(void *_Nonnull obj, Bin_Unpack *_Nonnull bu)
|
||||
{
|
||||
Tox_Events *events = (Tox_Events *)obj;
|
||||
|
||||
|
Reference in New Issue
Block a user