Click to See Complete Forum and Search --> : Searching QuickTime pals !!!!


ceciloup
April 14th, 1999, 08:12 AM
I'm using QuickTime for Windows with my Visual C++, and sometimes...(say: anytime) I have some problems...
I'll be very happy to find some QT users to discuss with, and to help each other!!
Let's have fun....

Cecile.


:) :) :) :) :) :)
Thanks for any help...

Marc Howe
April 25th, 1999, 09:28 PM
I use QT 3.02...what problems are you having?

Marc

ceciloup
April 26th, 1999, 04:17 AM
Hello, Marc, and thank you for your answer...
I have created a splitter window with a TreeCtrl on the right pane, and a view on the left one.
Ihave implemented the drag & drop operation : when I'm drag&dropping an image file name from the tree to the view, I'm calling my DrawImage function to open the image in the view.
As you can see, I'm using some QuickTime functions to open the image in the view.
The problem is when I'm resizing my window, the images displaued in the view disappear.
I think it's a QT problem, but I'm a beginner with QT, and I really don't know what I can do.

I hope you can help me...
Here is my code :
void CGenSplitView::DrawImage (void)
{
FSSpec spec;
Rect imageRect;

char* pName = (GetApp()->path).GetBuffer((GetApp()->path).GetLength()+20);
NativePathNameToFSSpec (pName,&spec,0);

imageRect.left = 50*(GetApp()->countx);
imageRect.top = 50*(GetApp()->county);
imageRect.right = imageRect.left + 50;
imageRect.bottom = imageRect.top + 50;

(GetApp()->countx)++;

if(imageRect.right > 350)
{
(GetApp()->county)++;
(GetApp()->countx) = 0;
}

MacSetPort(CreatePortAssociation(m_hWnd, NULL, 0));

DrawImageFile( spec, imageRect);

CWnd::UpdateWindow();
DestroyPortAssociation((CGrafPort *)GetHWNDPort(m_hWnd));


}

void DrawImageFile( const FSSpec& theSpec, const Rect& boundsRect )
{
GraphicsImportComponent gi;
CGrafPtr port;
GDHandle gd;

GetGraphicsImporterForFile(&theSpec, &gi);
// These lines required to get the image to draw within the window
GetGWorld(&port, &gd);
GraphicsImportSetGWorld(gi, port, gd);

GraphicsImportSetBoundsRect(gi,&boundsRect);
GraphicsImportDraw(gi);
CloseComponent(gi);
}


:) :) :) :) :) :)
Thanks for any help...

Marc Howe
April 29th, 1999, 10:07 AM
I'm sorry if I gave you the wrong impression...I am a novice programmer. Extremely novice! I hardly understand any C++ yet as my background was Pascal and a little bit (very little) of C back when I had Win 3.1 & a 386 SX-16!

I thought you were having some sort of a conflict in using VC++6 & QT3.02 on the same machine.

I'm sorry for any inconvenience.

Good luck,
Marc