Jump to content


Photo
- - - - -

Changing video size and compression

video compression aspect

  • Please log in to reply
5 replies to this topic

#1 dmcfarlan

dmcfarlan

    Member

  • Members
  • PipPip
  • 12 posts

Posted 19 December 2013 - 08:29 PM

Currently when I upload a video and the flv file is created, I would like the quality to be a little better.

How can I change the KB rate?  Also, how can I change the frame size.  I would like all my videos

to be 640x360 once uploaded.  Also is there a way to change the size of the video player.  Currently it

is 450 x 340, and my videos will play in that box at 450 x 260, since all of my videos are 16 x 9.  I would like

all of my videos to play in the player set to 630 x 360.

 

Darren



#2 alexstorm

alexstorm

    Verified Member

  • Customers
  • PipPipPip
  • 623 posts

Posted 20 December 2013 - 01:54 AM

The standard CS format has a left window player with a column on the right with information.  If you are using that format, then your maximum playable size is 560 wide.  You can set the video to encode for larger which may look better for full screen, but it will resize down to 560 wide for the player to fit where it is.

 

If you make the player larger, the page breaks and the right column is either overlapped or pushed down.

 

640 x 360 is a good size for compression, so that is a good choice.

 

Changing the encoding size is controlled by the siteadmin controls for your player.

 

Changing the player size is controled in the /tempates/view_video_player.tpl width and height is hard coded here, because the page will break if you go beyond 560 width and height needs to take into consideration if you use a disappearing control bar or not.  The disappearing control bar will allow flush 4:3 videos to be 560 *.75 = 420.  16:9 then gets black bars top and bottom.  If you have a fixed control bar that does not disappear you should allow the height of the bar to be added to the 420.  If the controller is 27 pixels high, then you need to do 420 + 27 = 447,  so height will become 560 x 447.  This is only to make flush to edges playback for 4:3 videos.  If you wish to favor only 16:9 the math changes:

 

560 x 315 for disappearing control bar

560 x 342 for non-disappearing control bar 27 pixels high.

 

Then 4:3 videos will always get left and right black bars.

 

===

 

Trying to change this width and height to 640 x 360 will break your view_video.tpl page at the format level, which means you need a redesigned page. This requires changing the view_video.tpl and the style.css accordingly.  Not an easy task.  I would suggest you find another clip-share site that has what you want and offer to buy the new template.  Nuevo player has a lot of good options including different looking players.  Remember your users can always just click full monitor, if they really want larger view.

 

===

 

Check out my site popmodal.com to see a lot of player and encoding custom mods.  A lot of the player playback is because it is using Nuevoplayer.

 

Hope that helps.


Edited by alexstorm, 20 January 2014 - 02:02 AM.


#3 dmcfarlan

dmcfarlan

    Member

  • Members
  • PipPip
  • 12 posts

Posted 20 December 2013 - 02:23 PM

The standard CS format has a left window player with a column on the right with information.  If you are using that format, then your maximum playable size is 560 wide.  You can set the video to encode for larger which may look better for full screen, but it will resize down to 560 wide for the player to fit where it is.

 

If you make the player larger, the page breaks and the right column is either overlapped or pushed down.

 

640 x 360 is a good size for compression, so that is a good choice.

 

Changing the encoding size is controlled by the siteadmin controls for your player.

 

Changing the player size is controled in the /tempates/view_video_player.tpl width and height is hard coded here, because the page will break if you go beyond 560 width and height needs to take into consideration if you use a disappearing control bar or not.  The disappearing control bar will allow flush 4:3 videos to be 560 *.75 = 420.  16:9 then gets balck bars top and bottom.  If you have a fixed control bar that does not disappear you should allow the height of the bar to be added to the 420.  If the controller is 27 pixels high, then you need to do 420 + 27 = 447.  so height will become 560 x 447.  This is only to make flush to edges playback for 4:3 videos.  If you wish to favor only 16:9 the math changes:

 

560 x 315 for disappearing control bar

560 x 342 for non-disappearing control bar 27 pixels high.

 

Then 4:3 videos will always get left and right black bars.

 

===

 

Trying to change this width and height to 640 x 360 will break your view_video.tpl page at the format level, which means you need a redesigned page. This requires changing the view_video.tpl and the style.css accordingly.  Not an easy task.  I would suggest you find another clip-sahre site that has what you want and offer to buy the new template.  Nuevo player has a lot of good options including different looking players.  Remember your users can always just click full monitor if they really want larger view.

 

===

 

Check out my site popmodal.com to see a lot of player and encoding custom mods.  A lot of the player playback is because it is using Nuevoplayer.

 

Hope that helps.

Thank you Alex!  Good stuff.



#4 joelmch

joelmch

    Advanced Member

  • Members
  • PipPipPip
  • 47 posts

Posted 19 January 2014 - 12:59 PM

By the way, it is always a good practice to make a back up of the original view_video_player.tpl before you make any changes. It will save you a lot of headache in the future. smile2.png



#5 Steel Rat

Steel Rat

    Member

  • Members
  • PipPip
  • 11 posts

Posted 07 September 2014 - 05:24 PM

 

You can set the video to encode for larger which may look better for full screen, but it will resize down to 560 wide for the player to fit where it is.

 

Sorry to revive this old thread, but I have a question.

 

I would rather an uploaded video is not resized when converted. I understand that visually it's "resized" to fit in the player, but in full screen I would expect the original quality to be there. The default bit rate for converted videos is 800k, pretty low. And it shows when a video with a variable bit rate of 6-10 mb is converted. I cranked it up to 5000k (5mb), but the quality is still pretty low.

 

So my question(s): Is an uploaded video resized, even though the resize option is set to no? If so, how do I stop that?

 

Thanks!



#6 alexstorm

alexstorm

    Verified Member

  • Customers
  • PipPipPip
  • 623 posts

Posted 08 September 2014 - 07:36 PM

The reason Youtube has multiple resolutions for playback is that without that they would lose people that cannot view high res versions of a video due to bandwidth, net traffic, number of hops, limits of end users lower cost smartphone, tablet, notebook, etc.  

 

Having high quality beautiful videos without a low res version will mean, many of your visitors may try to play the video, encounter long buffering delays, leave and never come back.  So you have to decide based on your business plan, your target client and if you wish to only show video quality to broadband customers like yourself who are perhaps close to the server location and let all other customers go jump in the lake.

 

Some years ago the recommended bit rate for users with low-speed bandwidth was 550 Kbps on Youtube.  It's up a little since then and typically, I think it's around 800 Kbps. Going higher is usually done with a HD mod that allows two versions to be available.  A good place to get that is with an HD mod, is with http://www.nuevolab.com/plugins.

 

Setting the bit rate on your current encode is usually done in Siteadmin, however because mods are often made to Clip-share, the settings in Siteadmin may include multiple encoding settings and the oldest original may no longer have any affect.

 

Original size videos not changing their size is not a good idea.  There are 1920 x 1080 videos out there and if you don't re-encode those, the original can be greater than 100 MB.  For all slow bandwidth or smartphone / tablet users on a slow connection, or Wifi, this could cause perhaps longer than 1 to 2 minutes buffering before any playback and the playback at 1920 x 1080 can choke many smartphones.  Hence, users can try a few times on a couple of videos, get nothing, leave and never return.

 

ffmpeg config settings:

===================

Usually command lines to convert videos are in

 /convert.php

 

Siteadmin has a direct import option which hardly anyone uses.  It's config settings are in:

 /siteadmin/modules//videos/edit.php

 

 

3rd party mods may put these encode commands in other files.

 

 

Video issues that affect encoding quality:

  1. Do not encode to odd pixel dimensions
  2. Encoding to dimensions divisible by 16 is best, divisible by 8 is good, divisible by 4 is alright and only divisible by 2 is perhaps 20% less efficient than divisible by 16.
  3. Original content with meta data missing will often play back find in players but can cause sync problems ffmpeg or mencode conversions.
  4. Sizes exactly 50% of the original look excellent, 75%,  33.3 , 25% look good.  Other reductions will have pixelation artifacts.
  5. Original videos from SD source with rectangle pixels are wrong for online playback, but many sites still have these.  They are originally 720 x 480.  Encoding them to a smaller size may cause interlace sync and wavy field lines.  Original content should already be native square pixels or correctly converted rectangle to square pixels.  This issue is going away, because it applies to videos from Standard def TV and DVD's and rectangular pixes are not present in widescreen 720 or 1080 HD.

Hope that helps.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users