This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #notes: | |
| #follow the instructions on https://github.com/ottokiksmaler/gear360_modding to get to the point of opening the Gear 360's web server -- http://192.168.43.1:8888 | |
| #the below series of commands when pasted & executed in the "Execute a command" box will produce 14 bracketed exposures. | |
| #14 exposures is probably overkill. I think probably 5 would work fine. (Maybe 1/8th - 1/2000th) | |
| #The first section sets several variables. For the full list see https://github.com/ottokiksmaler/nx500_nx1_modding/blob/master/ST_CAP_CAPDTM.md | |
| #30 = USERDATA_ISONR -- turn off ISO noise removal | |
| #31 = USERDATA_LTNR -- turn off long exposure noise removal | |
| #5 = USERDATA_ISO -- set ISO to 100 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Combine, Crop, and Remove similar frames | |
| find *.mkv | sed 's:\ :\\\ :g'| sed 's/^/file /' > fl.txt; ffmpeg -f concat -i fl.txt -filter:v "crop=704:452:0:28",mpdecimate=hi=1536:lo=640:frac=0.5,setpts=N/FRAME_RATE/TB -qscale:v 2 ../output.mp4 | |
| Adjust speed to your liking | |
| ffmpeg -i input.mp4 -r 30 -filter:v "setpts=0.01*PTS" -q:v 10 ouput.mp4 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* add to an email or on a website like this: | |
| <img alt="" width="1" height="1" src="pixel.php?e=jim.smith@qwerty.com&fn=jim&ln=smith&c=testing"> | |
| the information will be logged. | |
| this approach has some limitations, so if you expect heavy volumes you might try something else. | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # --background=00000000 makes a transparent background, to make it easier for placement in other materials | |
| qrencode -s 60 -l H --background=00000000 -o "output.png" "https://www.asdf.com/querty" | |
| pngcrush output.png output_c.png |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* | |
| Takes a Wordpress Post export and changes the case of the words in the <title> tag to title-case. | |
| This will print out a list of titles at the top with the title case and then the original case, so | |
| you can check over and make sure that you don't need to add any special cases: | |
| Add acronyms or words with non-standard capitalization to the array $caps_words. (note, add spaces | |
| around the word/phrase i.e. ' GitHub '. | |
| To update existing posts requires a temporary addition to your functions file -- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* | |
| Note that the cleaner sends the html to DirtyMarkup for formatting. | |
| Example input: | |
| <div class=WordSection1> | |
| <p class=MsoNormal align=center style='text-align:center'><span | |
| style='font-size:16.0pt;line-height:107%;font-family:"Abadi Extra Light",sans-serif'>Test | |
| Clean<o:p></o:p></span></p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| #to compress a folder: | |
| #for i in *;do ./compress.sh "$i";done | |
| new_file_name=$(sed 's/ /_/g' <<< "${1%.*}_c.jpg") | |
| cjpeg "$1" | jpegtran -o | exiftool - -all= > "$new_file_name" | |
| before_size=$(wc -c "$1" | awk '{print $1}') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import re | |
| def get_face(img_name): | |
| #find your imagga curl user info on your account | |
| #saves face data as a json | |
| command = f"curl -s --user \"_________imagga-user-code__________\" -F \"image=@{img_name}\" \"https://api.imagga.com/v2/faces/detections\" > {img_name}.json" | |
| os.system(command) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <pre><?php | |
| /* | |
| For generating spinning videos from spherical panos using pano2vr: | |
| https://www.youtube.com/watch?v=l_VrEJUUh64 | |
| Fill out the config below. | |
| Run the code, copy and paste the output into a file named "spin.p2vr" or similar. | |
| Make sure your input image is in the same location as your spin.p2vr file. | |
| Open the spin.p2vr file and then hit 'create all' at the bottom right. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mkdir no-audio; for f in *.MP4; do ffmpeg -i "$f" -an -c:v copy no-audio/$f; done |