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

payload_type hardcoded #609

Closed
zoff99 opened this issue Nov 2, 2017 · 9 comments
Closed

payload_type hardcoded #609

zoff99 opened this issue Nov 2, 2017 · 9 comments
Assignees
Labels
messenger Messenger P3 Low priority question Questions
Milestone

Comments

@zoff99
Copy link

zoff99 commented Nov 2, 2017

rtp_TypeAudio = 192,

should this be:
PACKET_ID_LOSSLESS_RANGE_START + PACKET_ID_LOSSLESS_RANGE_SIZE
?

but seems to be hardcoded now

@zugz
Copy link

zugz commented Nov 2, 2017 via email

@zoff99
Copy link
Author

zoff99 commented Nov 2, 2017

i think its used as lossless packet type

call->audio.first = rtp_new(rtp_TypeAudio, av->m, call->friend_number, call->bwc,

RTPSession *rtp_new(int payload_type, Messenger *m, uint32_t friendnumber,

rdata[0] = session->payload_type;

@zugz
Copy link

zugz commented Nov 3, 2017 via email

@zoff99
Copy link
Author

zoff99 commented Nov 3, 2017

so it should be:

rtp_TypeAudio = (PACKET_ID_LOSSLESS_RANGE_START + PACKET_ID_LOSSLESS_RANGE_SIZE),

instead of:

rtp_TypeAudio = 192,



and why is this defined in net_crypto.h

toxcore/net_crypto.h:#define PACKET_ID_LOSSY_RANGE_START 192

and this in Messenger.h

toxcore/Messenger.h:#define PACKET_ID_LOSSLESS_RANGE_START 160
toxcore/Messenger.h:#define PACKET_ID_LOSSLESS_RANGE_SIZE 32

?

should be all in 1 place

@zugz
Copy link

zugz commented Nov 4, 2017 via email

@zugz
Copy link

zugz commented Nov 4, 2017 via email

@zoff99
Copy link
Author

zoff99 commented Nov 4, 2017

hmm. at least make if a defined constant, to make it easier to find / read.
i am trying to add lossless video packets, so thats how i stumbled upon this issue

@sudden6
Copy link

sudden6 commented Nov 8, 2017

I agree with @zoff99 better make it a named constant.

@zugz
Copy link

zugz commented Nov 8, 2017 via email

@SkyzohKey SkyzohKey added question Questions messenger Messenger P3 Low priority labels Nov 19, 2017
@iphydf iphydf added this to the v0.2.0 milestone Jan 16, 2018
@iphydf iphydf modified the milestones: v0.2.0, v0.2.x Feb 18, 2018
@iphydf iphydf modified the milestones: v0.2.1, v0.2.x Mar 9, 2018
@zoff99 zoff99 closed this as completed Nov 4, 2018
@robinlinden robinlinden modified the milestones: v0.2.x, v0.2.9 Jan 3, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
messenger Messenger P3 Low priority question Questions
Projects
None yet
Development

No branches or pull requests

6 participants