Best video file format?

Windows specific questions.
grindstone
Posts: 726
Joined: May 05, 2015 5:35
Location: Germany

Re: Best video file format?

Postby grindstone » Jul 31, 2015 10:04

Tourist Trap wrote:Do you know a way to hide the interface from the command line?

Code: Select all

...
End With
SetWindowPlacement(hWndThisWindow,@wpDF)
ShowWindow(hWndThisWindow,SW_MINIMIZE) '<<<<<<< insert this line

GetStartupInfo(@siVLC) 'get default values
...

You could also set the show state to SW_HIDE, but I would not recommend it, because afterwards you have no more access to the window, so you have to use the task manager to terminate the programme.
Tourist Trap
Posts: 2880
Joined: Jun 02, 2015 16:24

Re: Best video file format?

Postby Tourist Trap » Jul 31, 2015 10:11

I reformulate. Though this is useful to minimize the console at the playtime (thanks for the tip), my question was from VLC command line, is there a way to launch it without its full interface, so with no menu, no button, or anything (useless here)?

I've tried this :
\vlc.exe -I rc
but would hide totally vlc.
D.J.Peters
Posts: 8027
Joined: May 28, 2005 3:28
Contact:

Re: Best video file format?

Postby D.J.Peters » Jul 31, 2015 10:23

Tourist Trap
Posts: 2880
Joined: Jun 02, 2015 16:24

Re: Best video file format?

Postby Tourist Trap » Jul 31, 2015 10:44

D.J.Peters wrote:FreeBASIC and xvid https://www.youtube.com/watch?v=aJvW320mdZg

Nice but difficult to figure out why xvid is required here. To make the final render?
grindstone
Posts: 726
Joined: May 05, 2015 5:35
Location: Germany

Re: Best video file format?

Postby grindstone » Jul 31, 2015 11:45

Cheerfully fulfilling all your special requests (and some more):

Code: Select all

...
'launch VLC-Player with remote control (align path if necessary)
CreateProcess(0,"C:\Programme\VideoVLC\vlc.exe --extraintf rc --qt-minimal-view --zoom=0.3",0,0,0,0,0,0,@siVLC,@pi)

Do 'wait till rc-window is opened
   Sleep 1
Loop Until FindWindow(0,"Window")
hWndRC = FindWindow(0,"Window") 'memorize window handle

Do 'wait, till VLC-Player is running
   hWndVLC = FindWindow(0,"VLC media player")
   Sleep 1
Loop Until IsWindowVisible(hWndVLC)
Dim As UInteger windowstyle = GetWindowLong(hWndVLC,GWL_STYLE)
windowstyle And= -1 And WS_DLGFRAME 'remove title bar
SetWindowLong(hWndVLC,GWL_STYLE,windowstyle)

'place VLC beneath console window
GetWindowPlacement(hWndVLC,@wpVLC)
...

With the --zoom - option you can smooth resize the video.

If you want a complete list of all available VLC-options (there are hundreds of them) just type "VLC --longhelp --advanced" at the command line. VLC will create a file named vlc-help.txt you can view with notepad.
datwill310
Posts: 355
Joined: May 29, 2015 20:37

Re: Best video file format?

Postby datwill310 » Jul 31, 2015 12:36

grindstone wrote:Have you set the path of the 'CreateProcess...' - statement to your VLC directory?

I've made a search in my C:\ drive, and I can't find vlc.exe! X(
MrSwiss
Posts: 3539
Joined: Jun 02, 2013 9:27
Location: Switzerland

Re: Best video file format?

Postby MrSwiss » Jul 31, 2015 12:52

datwill310 wrote:
grindstone wrote:Have you set the path of the 'CreateProcess...' - statement to your VLC directory?

I've made a search in my C:\ drive, and I can't find vlc.exe! X(

You can download it straight from the creators site at:
http://www.videolan.org/vlc/
Version WIN is 2.2.1, size approx. 20MB ...
Tourist Trap
Posts: 2880
Joined: Jun 02, 2015 16:24

Re: Best video file format?

Postby Tourist Trap » Jul 31, 2015 13:04

grindstone wrote:Cheerfully fulfilling all your special requests (and some more):

Code: Select all

...
...


Thanks this leads to great expectations. However I'm encoutering many issues. First is solved : if you had your playlist window docked, it will be displayed, not hidden with qt-minimal. Second thing the size of VLC window is the size memorized before, so it may not fit. Third is weird, I've all working nice but the video is only a small line at top. Or sometimes no video at all. However I've been lauching a wmv, I'll try with an avi file also even if I don't think it would change this.

About the documentation I'd been searching the website https://wiki.videolan.org/VLC_command-line_help/. But it's so dense that I failed to extract the precious item. Great that you've been succesfull here. However I've been intrigated by this :
Embedded window video
--drawable-hwnd=<integer [-2147483648 .. 2147483647]>
Window handle (HWND)
Video will be embedded in this pre-existing window. If zero, a new
window will be created.
datwill310
Posts: 355
Joined: May 29, 2015 20:37

Re: Best video file format?

Postby datwill310 » Jul 31, 2015 13:07

MrSwiss wrote:
datwill310 wrote:
grindstone wrote:Have you set the path of the 'CreateProcess...' - statement to your VLC directory?

I've made a search in my C:\ drive, and I can't find vlc.exe! X(

You can download it straight from the creators site at:
http://www.videolan.org/vlc/
Version WIN is 2.2.1, size approx. 20MB ...

I've read the license agreement and it's extremely helpful that I can distribute VLC without change. My game will be free.
Tourist Trap
Posts: 2880
Joined: Jun 02, 2015 16:24

Re: Best video file format?

Postby Tourist Trap » Jul 31, 2015 13:17

datwill310 wrote:I've read the license agreement and it's extremely helpful that I can distribute VLC without change. My game will be free.

I thought you knew this. Moreover it's crossplatform. Do the video play correctly for you with the last program? Just put the bas file in your vlc exec folder and compile it there. Throw also a video file there so you won't have to bother with the path.
grindstone
Posts: 726
Joined: May 05, 2015 5:35
Location: Germany

Re: Best video file format?

Postby grindstone » Jul 31, 2015 13:45

Tourist Trap wrote:Second thing the size of VLC window is the size memorized before, so it may not fit

The window will resize automatically to the size of the video as soon as you play it. The empty VLC window by default launches with the same size it was former closed with. But there are also options to determine the initial size.

Tourist Trap wrote:I've all working nice but the video is only a small line at top. Or sometimes no video at all.
I don't know what's going wrong, here it works. I only know that the VLC-player freezes when the side ratio changes within the video.

With --drawable-hwnd= the VLC-player can be assigned to a different parent window without closing and relaunching it. It doesn't mean that a video can be displayed inside the specified window.
datwill310
Posts: 355
Joined: May 29, 2015 20:37

Re: Best video file format?

Postby datwill310 » Jul 31, 2015 14:04

grindstone wrote:If you want a complete list of all available VLC-options (there are hundreds of them) just type "VLC --longhelp --advanced" at the command line. VLC will create a file named vlc-help.txt you can view with notepad.

I have done so, but I don't know where the file is located. The help documentation doesn't say anything about it, and I've looked in the VLC directory.
datwill310
Posts: 355
Joined: May 29, 2015 20:37

Re: Best video file format?

Postby datwill310 » Jul 31, 2015 14:31

Tourist Trap wrote:Do the video play correctly for you with the last program?

I have used a 24-bit (true Colour) AVI file, running with 10 fps and a dozen images; it has worked perfectly!
Tourist Trap
Posts: 2880
Joined: Jun 02, 2015 16:24

Re: Best video file format?

Postby Tourist Trap » Jul 31, 2015 14:36

grindstone wrote:I don't know what's going wrong, here it works. I only know that the VLC-player freezes when the side ratio changes within the video

Ok, I'll take at look at this closer. This left aside this works very well.
grindstone wrote:With --drawable-hwnd= the VLC-player can be assigned to a different parent window without closing and relaunching it. It doesn't mean that a video can be displayed inside the specified window.

So it may be done by operating via vmem lib. To be continued.. ;-)

datwill310 wrote:
Tourist Trap wrote:Do the video play correctly for you with the last program?

I have used a 24-bit (true Colour) AVI file, running with 10 fps and a dozen images; it has worked perfectly!

Nice.
Tourist Trap
Posts: 2880
Joined: Jun 02, 2015 16:24

Re: Best video file format?

Postby Tourist Trap » Jul 31, 2015 14:40

datwill310 wrote:I have done so, but I don't know where the file is located. The help documentation doesn't say anything about it, and I've looked in the VLC directory.

The help file spawns in vlc directory. You can also read it online : https://wiki.videolan.org/VLC_command-line_help/. It's rather dense, i must warn.

Return to “Windows”

Who is online

Users browsing this forum: No registered users and 3 guests