summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/graphics/win/QTMovie.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/platform/graphics/win/QTMovie.cpp')
-rw-r--r--WebCore/platform/graphics/win/QTMovie.cpp60
1 files changed, 60 insertions, 0 deletions
diff --git a/WebCore/platform/graphics/win/QTMovie.cpp b/WebCore/platform/graphics/win/QTMovie.cpp
index cc1349a..375d8c2 100644
--- a/WebCore/platform/graphics/win/QTMovie.cpp
+++ b/WebCore/platform/graphics/win/QTMovie.cpp
@@ -28,6 +28,7 @@
#include "QTMovieTask.h"
#include "QTMovieWinTimer.h"
+#include <FixMath.h>
#include <GXMath.h>
#include <Movies.h>
#include <QTML.h>
@@ -279,6 +280,16 @@ QTMovie::~QTMovie()
delete m_private;
}
+void QTMovie::disableComponent(uint32_t cd[5])
+{
+ ComponentDescription nullDesc = {'null', 'base', kAppleManufacturer, 0, 0};
+ Component nullComp = FindNextComponent(0, &nullDesc);
+ Component disabledComp = 0;
+
+ while (disabledComp = FindNextComponent(disabledComp, (ComponentDescription*)&cd[0]))
+ CaptureComponent(disabledComp, nullComp);
+}
+
void QTMovie::addClient(QTMovieClient* client)
{
if (client)
@@ -696,6 +707,16 @@ bool QTMovie::hasAudio() const
return (GetMovieIndTrackType(m_private->m_movie, 1, AudioMediaCharacteristic, movieTrackCharacteristic | movieTrackEnabledOnly));
}
+QTTrackArray QTMovie::videoTracks() const
+{
+ QTTrackArray tracks;
+ long trackIndex = 1;
+
+ while (Track theTrack = GetMovieIndTrackType(m_private->m_movie, trackIndex++, VisualMediaCharacteristic, movieTrackCharacteristic | movieTrackEnabledOnly))
+ tracks.append(QTTrack::create(theTrack));
+
+ return tracks;
+}
bool QTMovie::hasClosedCaptions() const
{
@@ -830,6 +851,45 @@ void QTMovie::getSupportedType(unsigned index, const UChar*& str, unsigned& len)
}
+CGAffineTransform QTMovie::getTransform() const
+{
+ ASSERT(m_private->m_movie);
+ MatrixRecord m = {0};
+ GetMovieMatrix(m_private->m_movie, &m);
+
+ ASSERT(!m.matrix[0][2]);
+ ASSERT(!m.matrix[1][2]);
+ CGAffineTransform transform = CGAffineTransformMake(
+ Fix2X(m.matrix[0][0]),
+ Fix2X(m.matrix[0][1]),
+ Fix2X(m.matrix[1][0]),
+ Fix2X(m.matrix[1][1]),
+ Fix2X(m.matrix[2][0]),
+ Fix2X(m.matrix[2][1]));
+ return transform;
+}
+
+void QTMovie::setTransform(CGAffineTransform t)
+{
+ ASSERT(m_private->m_movie);
+ MatrixRecord m = {{
+ {X2Fix(t.a), X2Fix(t.b), 0},
+ {X2Fix(t.c), X2Fix(t.d), 0},
+ {X2Fix(t.tx), X2Fix(t.ty), fract1},
+ }};
+
+ SetMovieMatrix(m_private->m_movie, &m);
+ m_private->cacheMovieScale();
+}
+
+void QTMovie::resetTransform()
+{
+ ASSERT(m_private->m_movie);
+ SetMovieMatrix(m_private->m_movie, 0);
+ m_private->cacheMovieScale();
+}
+
+
bool QTMovie::initializeQuickTime()
{
static bool initialized = false;