This file contains 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
package; | |
import feathers.data.ArrayCollection; | |
import feathers.layout.VerticalLayout; | |
import feathers.layout.VerticalLayoutData; | |
import openfl.display.Sprite; | |
import openfl.Lib; | |
import feathers.events.ScrollEvent; | |
import feathers.controls.ScrollContainer; | |
import feathers.controls.PopUpListView; |
This file contains 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
//png sequence with alpha from video | |
ffmpeg -c:v libvpx -i myvideo.webm %02d.png | |
//video from png sequence | |
ffmpeg -framerate 30 -i image%d.png -c:v libx264 -crf 10 -b:v 1M output.mp4 | |
ffmpeg -framerate 30 -i image%d.png -c:v libvpx -crf 10 -b:v 1M output.webm | |
//video from png sequence with alpha | |
ffmpeg -framerate 30 -i image%d.png -c:v libvpx-vp9 -pix_fmt yuva420p output.webm | |
//gif to webm (quality 0 to 60, lower is better) |
This file contains 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 | |
# >>>>>> HELPER FUNCTIONS | |
function echoSection { | |
echo -en "\e[33m\n--------------------------------------------------------------------------------\n--\n-- " $1 "\n--\n----------------------------------------------------------------------------------\e[37m\n" | |
} | |
function echoLine { | |
echo -en "\e[33m\n-- " $1 "\e[37m" | |
} | |
function echoWarn { | |
echo -en "\e[38m\n--------------------------------------------------------------------------------\n--\n-- " $1 "\n--\n--------------------------------------------------------------------------------\e[37m\n" |
This file contains 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
Consecutives numbers sum => (max - min + 1) * (max + min) / 2 | |
e.g: 3 + 4 + 5 + 6 = (6 - 3 + 1) * (3 + 6) / 2 = 18 |
This file contains 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
*Add full stop period* | |
([a-zA-Z]+)]]> replace with $LAST_SUBMATCH_RESULT.]]> | |
Non breaking space between number and mm | |
([0-9]+) mm replace with $LAST_SUBMATCH_RESULT mm | |
Add non breaking space before : | |
([0-9a-zA-Z]) : replace with $LAST_SUBMATCH_RESULT : | |
Add non breaking space between number and word |
This file contains 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
//index.html | |
var video = document.createElement('video'); | |
video.id = "videoDisplay"; | |
video.autoPlay = false; | |
document.body.appendChild(video); | |
//yourproject.hx | |
#if html5 | |
var htmlVideo:VideoElement; | |
htmlVideo = cast(Browser.document.getElementById('videoDisplay'), VideoElement); |
This file contains 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
/** | |
* OpenFL Video help file for flash/html5 | |
* openfl=3.5.3 | |
* lime=2.8.3 | |
*/ | |
//vars | |
var duration:Int; | |
var ns:NetStream; | |
var vid:Video; | |
//create video |
This file contains 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
package; | |
import openfl.display.DisplayObjectContainer; | |
import openfl.text.TextField; | |
/** | |
* ... | |
* @author loudo | |
*/ | |
class FixText | |
{ |
This file contains 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
package; | |
/** | |
* Avoid holes or border artifacts between tiles. | |
* Sometimes the scale by 1.01 trick doesn't work, a greater value should be used. This method finds the correct value for you. | |
* If you use openfl_legacy, pack your atlas using reduceBorderArtifact option in TexturePacker. There is no need to use this option on openfl_next. | |
* You should update the scale of your tiles if your resize the screen during the game to always have the best scale value. | |
* @author loudo | |
*/ | |
class FixTile | |
{ |