 	{
 		private static const SIDE_X : Vector.<Number> = new <Number>[2, 0, 1, 1, 1, 3];
 		private static const SIDE_Y : Vector.<Number> = new <Number>[1, 1, 0, 2, 1, 1];
-		
+
+		private static const FORMAT_BGRA				: String	= 'bgra';
+		private static const FORMAT_COMPRESSED			: String	= 'compressed';
+		private static const FORMAT_COMPRESSED_ALPHA 	: String 	= 'compressedAlpha';
+
+		private static const TEXTURE_FORMAT_TO_SAMPLER	: Array 	= []
+		{
+			TEXTURE_FORMAT_TO_SAMPLER[FORMAT_BGRA] 				= SamplerFormat.RGBA;
+			TEXTURE_FORMAT_TO_SAMPLER[FORMAT_COMPRESSED] 		= SamplerFormat.COMPRESSED;
+			TEXTURE_FORMAT_TO_SAMPLER[FORMAT_COMPRESSED_ALPHA] 	= SamplerFormat.COMPRESSED_ALPHA;
+		}
+
 		private var _bitmapDatas	: Vector.<BitmapData>;
 		private var _resource		: CubeTexture;
 		private var _size			: uint;
         private var _mipMapping     : Boolean;
+		private var _atf			: ByteArray;
+		private var _atfFormat		: uint;
+		private var _format 		: String;
 		
         public function get format() : uint
         {
-            return SamplerFormat.RGBA;
+	        return TEXTURE_FORMAT_TO_SAMPLER[_format];
         }
         
         public function get mipMapping() : Boolean

		{
			_bitmapDatas = new <BitmapData>[];
            _mipMapping = mipmap;
			
			var width	: Number = bitmapData.width / 4;
			var height	: Number = bitmapData.height / 3;
			

				
				_bitmapDatas = null;
			}
			else if (_atf)
			{
				_resource.uploadCompressedTextureFromByteArray(_atf, 0);
				_atf = null;
			}
			
			if (!_resource)
				throw new Error();
