48 points
*

I am assuming it inputs the byte stream of the file to the text parser and only glibberish comes out

permalink
report
reply
17 points

can confirm

permalink
report
parent
reply
3 points

Doing god’s work, child.

permalink
report
parent
reply
1 point

teaching intro CS to middle schoolers?

permalink
report
parent
reply
47 points
*
Removed by mod
permalink
report
reply
15 points

Open a text file in media player? Also straight to jail

permalink
report
parent
reply
28 points

The app will find the file incomprehensible and will tell you that the file is corrupted or in a format the app can’t understand.

An app that works with raw next (Windows’ Editor or notepad++ or any IDE) will try to parse the binary data as text and fail miserably, showing you lots of undecodable-unicode characters.

Example:

%.š/BûT¹Ò;lŠ^œ{åúvž’Û X“—دa%“9HúU”¿ú¦¥N̉Čԝ¿†«dd’º•©“ÜÈê*è9$mÕ lfN‹„‘ª$bÿû°@§  gÂqâ`tŒøn<cm-‰ Ljmð3¡|ñ°k§û–ÿîo<©ªxgTZ¯óT†"x¦1Q®ÔÚóI# 3édgþ™>´dʶ̏þB…o™ÜË7bMûö”]«ê|= ®©w„Ïɳ²NdÅh˜Ñ#´¦ïÕ®ºAd`‹®«R²•]‡ÐÏE päX 0PÛnE”Ø΋şçÒñD]îbwNðèB$¤“nnzráiqÖ›XåÄvØÉË\ø\¦P¼¶Xæ‰Â6…”ææ†?äÖåœ:m|?B3C+dW»f†`Ê$Lˆmìóz¯xK>‘)ƒÜÉTÝ ¨@‘Š£Ð:¨õ¹|!„D QC#£öªJ¼×u›³ÕÒ©˜gV"!V«; áäi³EJ…3;zã[±0&ËsÖ_Ë·³‡ ó8MaTô”ÖBïKßïùl4zHJE’N¢ìo™iÒg$½›—U.ºtÉW›SXGÓÐŒ§N¢–L¨YþïZOPNìÌÙŸN ŽŠióyÄ,QÍfÙ¬

permalink
report
reply
12 points

Hey I recognise that part of the song!

permalink
report
parent
reply
5 points

Rick rolled agian

permalink
report
parent
reply
2 points

But is sound reproducible this way?

permalink
report
parent
reply
11 points

Imagine you have a book that’s written in Korean. If you gave it to me and asked me to read it out loud, I wouldn’t be able to make sense out of it. If you gave it to a Korean person, however, they could read it perfectly fine.

The book itself hasn’t changed — just the person reading the book. And that person has a different set of skills (or instructions, if you will).

permalink
report
parent
reply

I feel like you want to but binary data into text. You may be interested in base64, or base32 for easier human processing.

Example of short low bitrate Opus audio in base64:
T2dnUwACAAAAAAAAAAAypxK0AAAAAG4HHqwBE09wdXNIZWFkAQGcAMBdAAAAAABPZ2dTAAAAAAAAAAAAADKnErQBAAAAWb8XtAG5T3B1c1RhZ3MNAAAATGF2ZjU3LjU2LjEwMQYAAAAdAAAAZW5jb2Rlcj1MYXZjNTcuNjQuMTAxIGxpYm9wdXMdAAAAVElUTEU9TmV2ZXIgR29ubmEgR2l2ZSBZb3UgVXASAAAAQVJUSVNUPVJpY2sgQXN0bGV5IAAAAEFMQlVNPVdoZW5ldmVyIFlvdSBOZWVkIFNvbWVib2R5CQAAAFlFQVI9MjAwNw8AAABEQVRFPTIwMDctMDYtMTFPZ2dTAACAuwAAAAAAADKnErQCAAAAKjsEJTIQFA8SERISFBQTEBARDxAUEhoQEw4SEQ8MDxETERESExgSEQ8LDxANCw0MDxAREhEREAiFgrfBwpjwLVZcCVgqmGAImEP/bxA+LnLkHbRYkSA5ZpTmIAiYQFTPtTNZFp3Z6utyQAiYDl7gsRKYWq8Xvkjie5T9oAiXmJQHdPPon60oDHQSImrECJf5qIXFWDf19lZemxKQRGdjCL0cZ2ArYBQwWThfc14JZmLgCL0c9XXa8WkXUeY16P6UCTutLsgIvRdo2sChsZd8GXao22NBdmw3gAiX4+0TwmGf+tNeAQVubRTNUTQIl4wJTHzJ+ahzgb9S4HNgCJdJZieBkXIV3TBQnlDn5AiYQyxiLbwoJOQ1PMkCs994CIXqR2jXreOteWcOEDSQCIXoiq24lEVfa2aWDzIDwAiYOTvHHfOs80gRhiiaRSI/IYjACJfD2Yh5/my3kw97vQarOqJ8CLzRs2OU4wAUOysUIipNg43epqfSv9MrE6AIhemYmtZV3I15XB0EeNSACJhMOrgqmX79NzifpntZnjmHOgiYQvk3LZ5CXUj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FGxYAiYObxPNgbk0p1rYBNJgAiYHXfRKpaUeVGmX1b+E512CJgdVUGsH4L1WqqRY/ulecAImCs3IkXV5qYqoLJjq8eG4AiYNzw2qK/XrPFiv1sAtdYrQAiYEgdj3jIre7Qv5Ndqrf8RoAiYN25s8MaPLLdVmO0h5zCepgiYH26t376eV1Ti3UzByfgIvO3ddkCI3awYTtEA7CD6J7o5mVDACLzIvnerP+iLSBGWpE7/Pp0gCLy+Zam4p4w2TXLcTR2xsGofBwi8qBFWA26uwJf6wAiYPXis+lJaUdx9yEfN5gIIcTyyCJgfF5Ye2gjg4NvkNp3t0TwImBsdrOW46dbAxv815ydACLzyTK6YvBKbmMR4ooXLCL/2ZN5MR8qAdpZPAiC5pz1HwiAIvJTAzDB12AlfQa3RgayuCLx1WURkB9TzegsGTEu8hAi8do94abB6QAEdtF/zBmPFgAi8VWFPLdwVsm3JLUKVsnL+gAg/rSMGtwix5fVYC0chCJdE/GKTaNrGM65nrEAIP57C75inzTAv2pNxQAg/nt4Ng0NicXIVewXjaggGdIPFO1Bz9ONQCD+spQ38pmv0v/z+vJgIP6Q/CbA8S66sdmw6RAg/lxCY1Pz4o40esMI46QiXT2orWwQTzlm1yi1xCJdm5HpuqfXi+2ecMoAIl0BYxASzK8u8/IVytQg/pOSmSHqD1dPmz8Cg

Is that what you are looking for?

permalink
report
parent
reply
6 points

Ya, I’m just amazed at how audio is able to be digitally represented

permalink
report
parent
reply
2 points
*

@MentalEdge@sopuli.xyz 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

permalink
report
parent
reply
2 points

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.

permalink
report
parent
reply
2 points
*

What do you even mean by that?

The text program obviously can’t process and play the audio, it will try to open the file as if it contains text.

But it’s not like opening the file destroys it. You can still just close the text program, and then open the file using a suitable media program instead.

permalink
report
parent
reply
0 points

Here’s the thing: Let’s say your text editor interprets the file as ASCII.

Several characters in the ASCII table aren’t printable. The first 32 characters in the table are control characters, so they don’t get displayed on screen as text you could copy and paste. So if you opened an audio file in a text editor as an ASCII file, copied the text, pasted it in another text field, then saved that file, any bytes that were between 0 and 32 decimal would be missing.

permalink
report
parent
reply
15 points

my afternoon project recommendation is to open a jpg or bmp in audacity, cut the first bit off to save the header then apply random audio effects to the rest. you can create really cool trippy glitch art this way

permalink
report
reply
2 points

Wouldnt removing the header mess with reading the file?

permalink
report
parent
reply
5 points

I think they’re saying snip the header off so you don’t affect it, then reapply at the end.

permalink
report
parent
reply
15 points

Try it and see. It won’t hurt anything.

permalink
report
reply
9 points
*

I feel like there’s a very large number of people that are afraid of trying things on their computer just to see what happens. And it correlates pretty closely with the type of person that doesn’t know where anything is on their computer.

OP is at least asking questions, and that’s a great step towards learning by yourself.

permalink
report
parent
reply

Eeh, they’ve got a point though. This is the result of accidentally cating an image in TTY:

Fixable with a reboot. Shouldn’t cause issues with any normal text editor, but because it shouldn’t doesn’t mean it necessarily won’t.

permalink
report
parent
reply
6 points
*

Now cat a plain text file to your sound device as it exists in /dev (e.g., /dev/audio). Then do an audio file. You should hear stuff come out of your speakers.

PS. When your terminal looks like that, you should be able to type reset and press enter to fix it without a reboot.

permalink
report
parent
reply
-5 points
*

Isn’t that also what you say about your dog? Like moments before it’ll bite someone? (…It just wants to play…)

permalink
report
parent
reply

Ask Lemmy

!asklemmy@lemmy.world

Create post

A Fediverse community for open-ended, thought provoking questions

Please don’t post about US Politics. If you need to do this, try !politicaldiscussion@lemmy.world


Rules: (interactive)


1) Be nice and; have fun

Doxxing, 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 spam

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


4) NSFW is okay, within reason

Just remember to tag posts with either a content warning or a [NSFW] tag. Overtly sexual posts are not allowed, please direct them to either !asklemmyafterdark@lemmy.world or !asklemmynsfw@lemmynsfw.com. 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 info@lemmy.world. 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


Community stats

  • 11K

    Monthly active users

  • 2.5K

    Posts

  • 77K

    Comments