News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Using AVIStream for creating a video

Started by Farabi, March 26, 2010, 11:07:28 PM

Previous topic - Next topic

Farabi

Dave:
That was my problem too. On mine the avi had no header. I guess it was a common problem.
Those who had universe knowledges can control the world by a micro processor.
http://www.wix.com/farabio/firstpage

"Etos siperi elegi"

dedndave

surprise !
it actually does work with DivX and xVid - kinda - lol
for both of these formats, the last frame is not displayed for some reason
the first frame is displayed longer than the rest
for xVid, the frame rate seems to change - very odd - must have something to do with the compression technique
i made 30 frames and numbered some of them
you can make an AVI using the different codecs to see the different results...

dedndave

i played with some settings and got it to work with xVid   :P


oex

Note:
   szName               dword [64]
should be:
   szName               WORD   64 DUP (0)

AVISTREAMINFO struct
   fccType             dword 0
   fccHandler             dword 0
   dwFlags               dword 0
   dwCaps               dword 0
   wPriority            word 0
   wLanguage            word  0
   dwScale               dword 0
   dwRate               DWORD 0
   dwStart               DWORD 0
   dwLength            DWORD 0
   dwInitialFrames            DWORD 0
   dwSuggestedBufferSize          DWORD 0
   dwQuality            dword 0
   dwSampleSize            dword 0
   rcFrame               RECT <0>
   dwEditCount            dword 0
   dwFormatChangeCount         dword 0
   szName               WORD   64 DUP (0)
AVISTREAMINFO ends
We are all of us insane, just to varying degrees and intelligently balanced through networking

http://www.hereford.tv

ecube

can you define the PERR function please Farabi, also oex whats the point of uploading a binary with no source, when hes asking for help on his code?

oex

Quote from: E^cube on September 17, 2010, 07:01:05 AM
can you define the PERR function please Farabi

This post is old and fixed I believe but I noticed this evening the structure was in error

Quote from: E^cube on September 17, 2010, 07:01:05 AM
also oex whats the point of uploading a binary with no source, when hes asking for help on his code?

The binary contained much junk code and macros it was a rip from one of my apps so it was less confusing to test that the dlls were working as expected with a binary I was also on chat to Onan via YIM for the code but it was convenient to upload this binary via the forum....

:lol my code doesnt follow MASM syntax, too many automation macros for it to make much sense for quick fixes and this was quite a lot of code to manually convert
We are all of us insane, just to varying degrees and intelligently balanced through networking

http://www.hereford.tv

ecube

well farbi's code crashes, I managed to get it to assemble after jacking include files from http://www.masm32.com/board/index.php?PHPSESSID=9cff7ea2a9244fc89e79c01671bb51d0&topic=6315.0 and defining the few missing functions. He forgot to call invoke fVideoInitin the example too which was probably the reason for the 0's address error. But now it crashes somewhere inside xvid module, so whatever, I guess he went with your code?

oex

Quote from: E^cube on September 17, 2010, 07:23:31 AM
I guess he went with your code?

Yeah I think we got it fixed in the end via chat, the AVI code is a pain, I just noticed that structure bug tonight using another function in the set and it caused me all sorts of grief identifying that issue there are no error codes :lol
We are all of us insane, just to varying degrees and intelligently balanced through networking

http://www.hereford.tv

ecube

Quote from: oex on September 17, 2010, 07:26:08 AM
Quote from: E^cube on September 17, 2010, 07:23:31 AM
I guess he went with your code?

Yeah I think we got it fixed in the end via chat, the AVI code is a pain, I just noticed that structure bug tonight using another function in the set and it caused me all sorts of grief identifying that issue there are no error codes :lol

well if you or him ever wanna upload the fixed code here, you're welcome to  :U now that you and Farabi have intrigued the whole forum

oex

The original code is here: http://www.wischik.com/lu/programmer/avi_utils.html (In Onan's first post) I think the code is almost right but I cant remember what we found the error to be now it might have been specifying bad compression options.... The binary I posted works but was using a different method to test the same result, I dont have that code anymore it was just a temp build
We are all of us insane, just to varying degrees and intelligently balanced through networking

http://www.hereford.tv