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
/* | |
Gyroscope の ANE に付属の Gyroscope クラスをインポートして使用しています。 | |
プロジェクトは FlashBuilder の ActionScript モバイルプロジェクトを | |
AIR for iOS(AIR 3.3)でビルドしました。 | |
link | |
http://www.digifie.jp/blog/archives/998 | |
http://www.adobe.com/devnet/air/native-extensions-for-air/extensions/gyroscope.html | |
*/ | |
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
//@see http://renaun.com/blog/2011/03/tips-for-ios-air-development/ | |
import flash.desktop.NativeApplication; | |
// I put this in a try/catch so it does break SWF desktop testing with non-AIR testing | |
try | |
{ | |
var descriptor:XML = NativeApplication.nativeApplication.applicationDescriptor; | |
var ns:Namespace = descriptor.namespaceDeclarations()[0]; | |
versionNumber = descriptor.ns::versionNumber; | |
} catch(error:Error) { } |
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
// note from http://tyleregeto.com/drawing-ios-uiviews-to-as3-bitmapdata-via-air | |
A major draw back to displaying native iOS UIView objects on top of your Adobe AIR applications is that they... well... are on top. Here is a quick code snippet for rendering native iOS view objects to ActionScript bitmapData objects via the recently released native extensions support. This allows you to add them to the display list (at the loss of all their native functionality). With native extensions we can update the bitmapData directly in memory which results in very fast updates. The possibilities are endless. | |
FREObject drawToBitmap(FREContext ctx, void* funcData, uint32_t argc, FREObject argv[]) { | |
// grab the AS3 bitmapData object for writing to | |
FREBitmapData bmd; |
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
refer to : http://www.kirupa.com/forum/showthread.php?374071-stage3d-AGAL-how-to-use-the-kil-opcode | |
AGAL: | |
[ | |
"tex ft0, v0, fs0 <2d,clamp," + TextureSmoothing.NONE + ">", //store texture in ft0 | |
"sub ft1.x ft0.a fc0.x", //store alpha - threshold (fc0.x) in temp ft.x | |
"kil ft1.x", //kill based on that | |
"mov oc, ft0" // move to output colour | |
] |
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
if(/Android|webOS|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent) ) | |
{ | |
// some code.. | |
} |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project name="Adobe Native Extension Packager" default="all" basedir="."> | |
<property name="extensionName" value="UserPhotosExtension"/> | |
<property name="flexsdk" value="/Users/palebluedot/Documents/Libraries/Flex/flex-4.6.0.23201-air-3.6-asc2-preview5"/> | |
<target name="all" depends="clean,init,ios,compileswc,extractswf,copyfiles,package"/> | |
<target name="clean"> | |
<delete dir="build"/> |
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
// refer to : http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/76315dfa-6764-4feb-a3e2-1f173fc5bdfd | |
// will get all entries of all USB devices, the USB host controllers, the USB Root hubs , hubs and usb devices. | |
// The results that are located at "USB\VID_xxx&PID_yyyy\zzzz" | |
// it may happen that you have more than one USB device with the same VID and PID on the system. | |
// Therfore you must also check for the serial# (the zzzz in the bold text). A USB device is only unique with VID+PID+seial#. | |
// with some decated fixed working via VS express 2012 | |
// 2013/06/08 |
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
export XLIB="/Users/christo.smal/Library/Developer/Xcode/DerivedData/wherever-lib.a" | |
export CERT="/wherever/if/you/want/to/sign/ane.p12" | |
export FLEXLIBPATH="../Path/of/flex/library/project" | |
export XIBPATH="/Path/of/where/xib/files/are" | |
export SWCFNAME="FWAne.swc" | |
export ANEFNAME="FWAne.ane" | |
ls -la $XLIB | |
echo Copying files ... |
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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using System.Diagnostics; | |
using System.ComponentModel; | |
namespace Foo | |
{ |
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
// don't forget to link shell32.lib; via Linker -> Input | |
#include "stdafx.h" | |
#include <Windows.h> | |
#include <shellapi.h> | |
int _tmain(int argc, _TCHAR* argv[]) | |
{ | |
ShellExecute(NULL, TEXT("open"), TEXT("http://sleepydesign.com"), NULL, NULL, SW_SHOWNORMAL); | |
return 0; |
OlderNewer