Page 1 of 1

Zooming video

Posted: 10 Aug 2009 17:51
by kryptonite
I'm using 1.0.1 and trying to implement the zoom/magnify feature.
I used libvlc_video_set_scale()
However, I see no effect and libvlc_video_get_scale() returns 0.0
Is there some sequence of calls or something special I need to add?
The '-vvv' only spits out [0x3ee8e2c] main input debug: control type=1

Could someone please help me out, thanks.

Re: Zooming video

Posted: 10 Aug 2009 20:07
by Rémi Denis-Courmont
Is the video already active when you call the function? Is the video embedded in the application?

Re: Zooming video

Posted: 11 Aug 2009 09:20
by kryptonite
Thank you, Rémi.
Yes, the video is already active & playing.

My app is Java based - I do the usual creating instances followed by:

Code: Select all

libvlc_media_player_set_media() libvlc_media_release() libvlc_media_player_set_drawable() libvlc_media_player_play()
I then call libvlc_video_set_scale() on a button click
Based on your comment, I did try putting the 'scale change' just before 'play' in the above sequence but an exception was raised with msg="I/P is null" so I guess this is not the correct sequence.

My video url is an rtsp stream: rtsp://10.8.0.1:8901/pb0017
My VLC args: :reset-config, :aspect-ratio=720:576, :rtsp-user=admin, :rtsp-pwd=00ulTIyPkHezE, :rtsp-tcp, :no-skip-frame, :no-drop-late-frame, :no-ffmpeg-hurry-up, :ffmpeg-skiploopfilter, 4

Re: Zooming video

Posted: 12 Aug 2009 13:42
by kryptonite
Ok, so after hunting around, I added the "--no-autoscale" option.
Now, libvlc_video_get_scale() gives me the correct value - 1.0 [or if I use --scale=2.0 it returns 2.0]
- I then use libvlc_video_set_scale() passing a new float value, libvlc_video_get_scale() then returns 0.0 thereafter
- Also, I don't see the visual effect of scaling.

Any pointers appreciated.
Thanks!