OSDN Git Service

Merge branch 'feature/#36529_SlimDXからSharpDXへの移行' into develop
[dtxmania/dtxmania.git] / SlimDXc_Jun2010(VC++2008) / source / direct3d9 / CompressedAnimationSet.cpp
diff --git a/SlimDXc_Jun2010(VC++2008)/source/direct3d9/CompressedAnimationSet.cpp b/SlimDXc_Jun2010(VC++2008)/source/direct3d9/CompressedAnimationSet.cpp
deleted file mode 100644 (file)
index bc0b730..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-#include "stdafx.h"\r
-/*\r
-* Copyright (c) 2007-2010 SlimDX Group\r
-* \r
-* Permission is hereby granted, free of charge, to any person obtaining a copy\r
-* of this software and associated documentation files (the "Software"), to deal\r
-* in the Software without restriction, including without limitation the rights\r
-* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\r
-* copies of the Software, and to permit persons to whom the Software is\r
-* furnished to do so, subject to the following conditions:\r
-* \r
-* The above copyright notice and this permission notice shall be included in\r
-* all copies or substantial portions of the Software.\r
-* \r
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\r
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\r
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\r
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\r
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\r
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\r
-* THE SOFTWARE.\r
-*/\r
-#include <d3d9.h>\r
-#include <d3dx9.h>\r
-#include <vcclr.h>\r
-\r
-#include "../stack_array.h"\r
-#include "../ComObject.h"\r
-#include "../DataStream.h"\r
-\r
-#include "../Math/Vector3.h"\r
-\r
-#include "Device.h"\r
-#include "Mesh.h"\r
-#include "ProgressiveMesh.h"\r
-#include "PatchMesh.h"\r
-#include "SkinInfo.h"\r
-#include "AnimationFrame.h"\r
-#include "CompressedAnimationSet.h"\r
-#include "Direct3D9Exception.h"\r
-\r
-using namespace System;\r
-\r
-namespace SlimDX\r
-{\r
-namespace Direct3D9\r
-{\r
-       CompressedAnimationSet::CompressedAnimationSet( String^ name, double ticksPerSecond,\r
-               SlimDX::Direct3D9::PlaybackType playbackType, DataStream^ compressedData,\r
-               array<CallbackKey>^ callbackKeys )\r
-       {\r
-               LPD3DXCOMPRESSEDANIMATIONSET pointer;\r
-               array<unsigned char>^ nameBytes = System::Text::ASCIIEncoding::ASCII->GetBytes( name );\r
-               pin_ptr<unsigned char> pinnedName = &nameBytes[0];\r
-               int count = callbackKeys->Length;\r
-\r
-               stack_array<D3DXKEY_CALLBACK> keys = stackalloc( D3DXKEY_CALLBACK, count );\r
-               for( int i = 0; i < count; i++ )\r
-               {\r
-                       keys[i].Time = callbackKeys[i].Time;\r
-                       keys[i].pCallbackData = callbackKeys[i].Data.ToPointer();\r
-               }\r
-\r
-               HRESULT hr = D3DXCreateCompressedAnimationSet( reinterpret_cast<LPCSTR>( pinnedName ), ticksPerSecond,\r
-                       static_cast<D3DXPLAYBACK_TYPE>( playbackType ), compressedData->GetD3DBuffer(), count,\r
-                       &keys[0], &pointer );\r
-\r
-               if( RECORD_D3D9( hr ).IsFailure )\r
-                       throw gcnew Direct3D9Exception( Result::Last );\r
-\r
-               Construct(pointer);\r
-       }\r
-\r
-       array<CallbackKey>^ CompressedAnimationSet::GetCallbackKeys()\r
-       {\r
-               int count = CallbackKeyCount;\r
-               stack_array<D3DXKEY_CALLBACK> keys = stackalloc( D3DXKEY_CALLBACK, count );\r
-\r
-               HRESULT hr = InternalPointer->GetCallbackKeys( &keys[0] );\r
-               \r
-               if( RECORD_D3D9( hr ).IsFailure )\r
-                       return nullptr;\r
-\r
-               array<CallbackKey>^ results = gcnew array<CallbackKey>( count );\r
-               for( int i = 0; i < count; i++ )\r
-                       results[i] = CallbackKey( keys[i] );\r
-\r
-               return results;\r
-       }\r
-\r
-       DataStream^ CompressedAnimationSet::GetCompressedData()\r
-       {\r
-               LPD3DXBUFFER buffer;\r
-\r
-               HRESULT hr = InternalPointer->GetCompressedData( &buffer );\r
-               \r
-               if( RECORD_D3D9( hr ).IsFailure )\r
-                       return nullptr;\r
-\r
-               return gcnew DataStream( buffer );\r
-       }\r
-\r
-       int CompressedAnimationSet::CallbackKeyCount::get()\r
-       {\r
-               return InternalPointer->GetNumCallbackKeys();\r
-       }\r
-\r
-       SlimDX::Direct3D9::PlaybackType CompressedAnimationSet::PlaybackType::get()\r
-       {\r
-               return static_cast<SlimDX::Direct3D9::PlaybackType>( InternalPointer->GetPlaybackType() );\r
-       }\r
-\r
-       double CompressedAnimationSet::SourceTicksPerSecond::get()\r
-       {\r
-               return InternalPointer->GetSourceTicksPerSecond();\r
-       }\r
-}\r
-}
\ No newline at end of file