this post was submitted on 20 Jul 2024
54 points (89.7% liked)

Ask Lemmy

26734 readers
2835 users here now

A Fediverse community for open-ended, thought provoking questions

Please don't post about US Politics.


Rules: (interactive)


1) Be nice and; have funDoxxing, trolling, sealioning, racism, and toxicity are not welcomed in AskLemmy. Remember what your mother said: if you can't say something nice, don't say anything at all. In addition, the site-wide Lemmy.world terms of service also apply here. Please familiarize yourself with them


2) All posts must end with a '?'This is sort of like Jeopardy. Please phrase all post titles in the form of a proper question ending with ?


3) No spamPlease do not flood the community with nonsense. Actual suspected spammers will be banned on site. No astroturfing.


4) NSFW is okay, within reasonJust remember to tag posts with either a content warning or a [NSFW] tag. Overtly sexual posts are not allowed, please direct them to either [email protected] or [email protected]. NSFW comments should be restricted to posts tagged [NSFW].


5) This is not a support community.
It is not a place for 'how do I?', type questions. If you have any questions regarding the site itself or would like to report a community, please direct them to Lemmy.world Support or email [email protected]. For other questions check our partnered communities list, or use the search function.


Reminder: The terms of service apply here too.

Partnered Communities:

Tech Support

No Stupid Questions

You Should Know

Reddit

Jokes

Ask Ouija


Logo design credit goes to: tubbadu


founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 2 points 3 months ago* (last edited 3 months ago) (1 children)

@[email protected] is right. I’ll interpret your question as “can I send this to someone and they will be able to play it” – ~~then the answer is yes. You can take a binary file like mp4, pretend it’s text like I did above, and send it via chat or a lemmy post. The recipient will need to copy that text, enter it in, for instance, notepad++ and save the file on their disk. Renaming the file from the-text.txt to the-text.mp4 should be sufficient for any audio player to pick the file up and play it.~~

Edit: doesn’t actually work

[–] [email protected] 2 points 3 months ago

Not entirely true. There are bits in binary files that cannot be rendered correctly by text editors. In fact, if a text editor cannot read a bit, it might omit it or substitute it with a generic placeholder. Instead, what you would do is encode the file into a text format and the transmit it to somebody, who would then decode the text back into its original file format.

This is how email attachments and uploading/downloading files from the web work. Usually that text format is called base64. In email attachments, they go one step further and typically limit the encoded data to fixed length lines called chunks.

But yeah, sending raw binary data as text requires special formatting first. Opening it up in a text editor and copying and pasting is not enough.