English Amiga Board


Go Back   English Amiga Board > Main > Amiga scene

 
 
Thread Tools
Old 22 December 2013, 14:36   #41
pandy71
Registered User
 
Join Date: Jun 2010
Location: PL
Posts: 1,546
Perhaps there is some Python specialist?
There is http://www.vapoursynth.com/ - on this base with Python, very efficient video processor (script/plugin) to convert to Amiga formats, perhaps native to IFF ANIM format should be possible.

PS
i will try to learn Python anyway but... it take some time.
pandy71 is offline  
AdSense AdSense  
Old 28 January 2014, 17:20   #42
turrican3
Moon 1969 = amiga 1985

turrican3's Avatar
 
Join Date: Apr 2007
Location: belgium
Age: 41
Posts: 3,157
is it possible to make a 256 colours video with this tool or less ???
Do we have a player whch support left mouse button or joy button to exit the display ?
turrican3 is offline  
Old 28 January 2014, 21:38   #43
pandy71
Registered User
 
Join Date: Jun 2010
Location: PL
Posts: 1,546
Quote:
Originally Posted by turrican3 View Post
is it possible to make a 256 colours video with this tool or less ???
Be more specific - what kind of 256 colors video? fixed palette, each frame new palette, fixed bit (3-3-2 etc)

Quote:
Originally Posted by turrican3 View Post
Do we have a player whch support left mouse button or joy button to exit the display ?
I assume most of Amiga players exit on mouse button.
pandy71 is offline  
Old 07 June 2014, 21:20   #44
skullscandle
 
Posts: n/a
Completing the idea of jimbob, using the current version of ffmpeg "version N-63623-g2e532aa" it is possible to create the video and sound output stream file in one step, like this:

OCS/ECS:

ffmpg\bin\ffmpeg -i c:\tmp\The_Pink_Panther.flv -map 0:a -ar 16000 -sample_fmt u8 -acodec pcm_u8 c:\tmp\The_Pink_Panther.wav -map 0:v -r 15 -s320x216 -vcodec rawvideo -pix_fmt rgb555le -vf "vflip" c:\tmp\The_Pink_Panther.avi

AVI4HV.EXE c:\tmp\The_Pink_Panther.avi

AGA:

ffmpg\bin\ffmpeg -i c:\tmp\The_Pink_Panther.flv -map 0:a -ar 16000 -sample_fmt u8 -acodec pcm_u8 c:\tmp\The_Pink_Panther.wav -map 0:v -r 15 -s 320x216 -vcodec rawvideo -pix_fmt bgr24 -vf "vflip" c:\tmp\The_Pink_Panther_aga.avi

AVI4AGA.EXE c:\tmp\The_Pink_Panther_aga.avi

Note: The vertical flip option was neccessary, because the ouput was v-flipped. This is maybe a bug of the current ffmpeg, so if you use this option and the image is mirrored again, cancel the option out.

Last edited by skullscandle; 09 June 2014 at 00:01.
 
Old 07 June 2014, 23:27   #45
pandy71
Registered User
 
Join Date: Jun 2010
Location: PL
Posts: 1,546
Quote:
Originally Posted by skullscandle View Post
OCS/ECS:
Code:
@rem set samplerate=28604
@set samplerate=15977
@ffmpeg -i %1 -map 0:v -c:v rawvideo -vf "pp=hb/vb/dr/al|f/tmpnoise|4|4|4,decimate=cycle=2,scale='if(gt(a,4/3),320,-1)':'if(gt(a,4/3),-1,216)':sws_dither=a_dither:sws_flags=bicubic,format=pix_fmts=rgb555le,pad=320:216:(ow-iw)/2:(oh-ih)/2,setsar=sar=1/1,format=pix_fmts=rgb555le,vflip" -y %1.avi -map 0:a -c:a pcm_u8 -af "aformat=sample_fmts=fltp,pan=stereo|FL < FL + 1.414FC + .5BL + .5SL + 0.25LFE|FR < FR + 1.414FC + .5BR + .5SR + 0.25LFE,compand='.3 .35:1 1:-60/-40 -40/-30:6:-0.15:-90:0.2',volume=1.0,aresample=resampler=soxr:osr=%samplerate%:cutoff=0.99:dither_method=0,aformat=sample_fmts=u8:channel_layouts=stereo" -y %1.wav
----
Hope it is last version - skullscandle idea used (multiple outputs) - thank You skullscandle! - samplerate defined as separate parameter, vflip seem to be mandatory (rawvideo in AVI probably use Windows DIB organization - vertically flipped).
----
As always - framerate conversion is very crude - it is advised to use some motion compensated frame rate conversion method.

I should also mention that using sample rates from PC in Amiga is bad idea - there is no 16000 or 22050 or 11025 or 24000 - Amiga sample rates are like:28604, 23646, 22168, 15977, 11260 etc This is important as video and audio will be quickly out of sync - preferable is to have video framerate equal to native Amiga framerate and sample rate closest as possible to Amiga. Also it is good to resample any audio to native Amiga sample rate otherwise it will be played or faster or slower than on original (higher or lower pitch).

Last edited by pandy71; 11 June 2014 at 22:38.
pandy71 is offline  
Old 13 July 2014, 22:42   #46
skullscandle
 
Posts: n/a
Thanks a lot pandy71 for the details.

I checked your updated ffmpg command line. It gives an improved and smaller output.

I re-assembled the asm code of the hamvid player provided by hyakushiki.net and removed the cpu depending delay loop in the end. It was very slow on slow machines. Here are the few lines of code that I changed:

Code:
;    --------------------------------------------------------------------

a100
        move.w #15,$96(a5)    ; dmacon - turn off audio

        moveq #99,d5
        move.l _GfxBase(pc),a6
.delay: jsr _LVOWaitTOF(a6)
        dbf d5,.delay

        move.w #$8020,$96(a5) ; dmacon - turn sprites back on

closefile
I also found a bug in the program in the exit code, that may crash the machine:

Code:
.nosignal:
        move.l _WBenchMsg(pc),d0
        beq.s .notwb
        move.l a0,a1 ; must be d0,a1
        jsr _LVOForbid(a6) ; Not sure that a1 is not modified!
        jsr _LVOReplyMsg(a6)
The code should be changed to this:

Code:
.nosignal:
        move.l _WBenchMsg(pc),d6
        beq.s .notwb
        jsr _LVOForbid(a6)
        move.l d6,a1
        jsr _LVOReplyMsg(a6)
In the end I have added Workbench project file support. So, you may have now an icon for your video and use hamvid.run as tool now. In the same way, as you would do it for a text file.

If anyone is interessed, I can send the updated file. Finally I will send the changes to hyakushiki.net.

Last edited by skullscandle; 14 July 2014 at 01:26.
 
Old 15 July 2014, 23:24   #47
skullscandle
 
Posts: n/a
I just got e-mail. TJ Edmister (hyakushiki.net) has updates the AVI4HV / HAMVid archive on his site. Thanks TJ Edmister!
 
Old 07 August 2014, 01:13   #48
abbalah
Registered User

 
Join Date: Jan 2014
Location: .
Posts: 10
I tried HAM video for the first time today and I'm impressed - for certain definitions of impressed - well you understand

I thought I'd describe my Linux-centric process in case it could benefit someone.

I started by downloading http://www.hyakushiki.net/junk/avi4hv.zip and https://1.node1.de/hvconvert.tgz.

I decided to use the hvconvert script and will delve into the default conversion parameters another day. As hvconvert uses Libav which is not readily available in Fedora I decided to use one of my Debian sandboxes instead. I also decided to recompile the AVI4HV executable since the one included is probably not the latest version.

First I had to install FreeBasic. The instructions included are straightforward.

As I'm running a 64 bit Debian Wheezy I need to specifically tell Debian that I want to enable 32 bit packages before proceeding:
sudo dpkg --add-architecture i386


The FreeBasic prerequisites can be installed using the following command:
sudo apt-get install gcc-multilib g++-multilib lib32ncurses5-dev libx11-dev:i386 libxext-dev:i386 libxrender-dev:i386 libxrandr-dev:i386 libxpm-dev:i386


The FreeBasic installation script should now run successfully. This means AVI4HV.BAS can be compiled.

Before running the hvconvert script I need to install the libav-tools package:
sudo apt-get install libav-tools


That's it - I'm now able to run ./hvconvert.sh <filename>.

On my Amiga 1200 I was not able to run HAMNEW.RUN <filename> to watch the video, all I got was a single screen flash. I don't know how to troubleshoot on the Amiga.

I was able to change the default tool in the .info file by right clicking the video and selecting "Info". Now I'm able to watch the video by simply double clicking.
abbalah is offline  
Old 22 August 2014, 16:14   #49
pandy71
Registered User
 
Join Date: Jun 2010
Location: PL
Posts: 1,546
Fixed version for ffmpeg (aspect ratio auto calculation works now with non ususal aspect ratios, overall flexibility improved, new: anti-aliasing* added - optional, improved audio syntax, still issues with color space - ffmpeg ignore (partially?) syntax and seem that issue is raised on ffmpeg bug-list - solution for today: piping - perhaps in next version)

Code:
@rem echo --audio--
@rem possible samplerates are for example: 28604, 23646, 22168, 15977, 11260
@set samplerate=15977

@rem possible ngain are for example: -3.0103, -6.0206, -9.0309
@set ngain=-6.0206

@rem possible audither are: 0,1,2,3
@set audither=1

@rem possible volume value are for example: 3.0103dB, 6.0206dB, 9.0309dB, 12.0412dB, 18.0618dB or 1.5 2 etc
@set avol=1

@rem echo --video--
@rem possible vidither are: 0,1,2,3,4,5,6 or "bayer","ed","a_dither", "x_dither"
@set vidither=bayer
@rem possible video color space are: rgb555le (15 bit), rgb444le (12 bit - native Amiga) ;CLUT format not suitable for AVI conatiner but fine GIF (or similar format) bgr4_byte (4 bit CLUT), rgb8 (8 bit CLUT) 
@set cspc=rgb555le

@ffmpeg -threads %NUMBER_OF_PROCESSORS%+1 -i %1 -map 0:v -c:v rawvideo -vf hqdn3d=6:6:8:8,decimate=cycle=2,pp="hb/vb/dr/al|f",format=pix_fmts=rgb24[midv1];[midv1]scale="'if(gt(a,4/3),320,-1)':'if(gt(a,4/3),-1,216)':sws_flags=spline:sws_dither=%vidither%",pad=320:216:(ow-iw)/2:0[midv2];[midv2]scale=320:-1:sws_flags=spline:sws_dither=%vidither%,vflip,format=pix_fmts=%cspc% -sws_dither %vidither% -y %1.avi -map 0:a:0 -c:a pcm_u8 -af "[in]aformat=sample_fmts=fltp[mida1] ; [mida1]pan=stereo|FL < FL + 1.414FC + .5BL + .5SL + 0.25LFE|FR < FR + 1.414FC + .5BR + .5SR + 0.25LFE[mida2] ; [mida2]highpass=f=2.5,compand='.13|.13:.35|.35:-70/-35|-35/-20|-20/-15|-15/-15:6:%ngain%:-90:0.2',treble=g=%ngain%*-2:f=%samplerate%/4,volume=%avol%[mida3];[mida3]aresample=resampler=soxr:osr=%samplerate%:cutoff=0.995:dither_method=%audither%,aformat=sample_fmts=u8:channel_layouts=stereo[out]" -y %1.wav

@rem ffmpeg -threads %NUMBER_OF_PROCESSORS%+1 -i %1 -map 0:v -c:v rawvideo -vf hqdn3d=6:6:8:8,decimate=cycle=2,pp="hb/vb/dr/al|f"[midv1];[midv1]scale="'if(gt(a,4/3),320,-1)':'if(gt(a,4/3),-1,216)'",pad=320:216:(ow-iw)/2:0[midv2];[midv2]format='pix_fmts=bgr24',hqx=2,scale=iw/2:-1:sws_flags=spline:sws_dither=%vidither%,vflip,format=pix_fmts=%cspc% -sws_dither %vidither% -y %1_hqx.avi -map 0:a:0 -c:a pcm_u8 -af "[in]aformat=sample_fmts=fltp[mida1] ; [mida1]pan=stereo|FL < FL + 1.414FC + .5BL + .5SL + 0.25LFE|FR < FR + 1.414FC + .5BR + .5SR + 0.25LFE[mida2] ; [mida2]highpass=f=2.5,compand='.13|.13:.35|.35:-70/-35|-35/-20|-20/-15|-15/-15:6:%ngain%:-90:0.2',treble=g=%ngain%*-2:f=%samplerate%/4,volume=%avol%[mida3];[mida3]aresample=resampler=soxr:osr=%samplerate%:cutoff=0.995:dither_method=%audither%,aformat=sample_fmts=u8:channel_layouts=stereo[out]" -y %1_hqx.wav
*AA implemented as hqx http://en.wikipedia.org/wiki/Hqx - slower, not universal, but improvements visible - to turn ON - un-rem second ffmpeg.

Automatic Audio can't be implemented currently without at least 2 pass or pipe - perhaps in future sufficient filter for ffmpeg can be used to do this.

enjoy
pandy71 is offline  
AdSense AdSense  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Deuteros (Amiga) video tutorial Mendel Retrogaming General Discussion 1 08 June 2013 02:15
Video Tutorial: ADF from PC <--> AMIGA Jawsykilla support.Hardware 88 28 December 2009 13:53
ClassicWB Tutorial Video - Using extra partitions for Games & Demos Bloodwych project.ClassicWB 27 15 December 2009 00:45
EasyADF Video Tutorial amigakit.com Amiga scene 9 24 February 2009 20:09
HAM Demo Frazor request.Demos 2 06 August 2003 15:36

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 00:04.


Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Page generated in 0.25221 seconds with 12 queries