Expression Encoder

The team blog for Expression Encoder.

Posts
  • Expression Encoder

    Announcing Expression Encoder 2 SP1

    • 37 Comments

    Since the release of Expression Encoder 2 back in May of this year, we’ve been hard at work on new features. Today we are announcing Expression Encoder 2 SP1, which we plan to release by the end of the year as a free upgrade to Expression Encoder 2. There are a wide variety of enhancements across many areas of the product in this release and you’ll find a comprehensive list below. The three top-line features are: Silverlight 2 templates, H.264 support and WebDAV publishing available out of the box. Additionally, and consistent with a service pack release, we’ve fixed a decent number of bugs.

    Silverlight 2 Player Templates

    Our SIlverlight Player templates provide a quick and easy way to get a Silverlight video experience created including rich functionality such as DVD style chapter navigation, subtitles and metadata. With the advent of Silverlight 2, the first Silverlight release to including the .NET CLR, we have completely rewritten our player from the ground up.

    MediaPlayer control

    For starters, we’ve made a Silverlight 2 custom control called MediaPlayer. This is a core component shared by all of our new templates. It is completely customizable via our integrated “Edit in Blend”, just like the Silverlight 2 intrinsic controls.

    image

    Some of the new properties of the player include

    • Utilization of Silverlight 2 controls e.g. buttons, sliders that can be independently styled
    • Use of the Visual State Manager to enable declarative states e.g. for fullscreen mode
    • Adaptive layout for better resizing
    • Playlist support in all players (including metadata display)
    • Byte-range seeking: When a user clicks forward on the timeline into a non-downloaded region, the player will cancel the current progressive download and start a new one from the point that has been seeked to.

    You can use the MediaPlayer control outside of our player templates simply by referencing the project (source code included in the box). It is quick and easy to get up and running in XAML. Reference the control and instantiate thus:

    image

    When editing in Blend, rich UI is available for editing properties (e.g. playlists as shown here:)

    image

    Finally, we’ve removed all of the complex JavaScript needed to invoke the player from an HTML page; this is now accomplished with a simple <object/> tag.

    H.264 encoding for devices

    Since we shipped our V1 release, we’ve heard loud and clear from customers that they’d like more output formats than just VC-1. One of the most common scenarios that kept cropping up is content producers that are embracing Silverlight for web video but also wish to make the content available as a Podcast for devices.

    We are therefore happy to announce that, starting with V2 SP1, we are adding H.264/AAC encoding to the product. For this release we are supporting two device profiles: a baseline 320x240 for smaller flash memory based devices and a 640x480 profile for larger screen resolutions.

    Since it has been announced that Silverlight is going to support H.264 you can expect us to broaden our encoding support for the format in the future.

    A/B compare enhancements

    Band mode allows you to drag out a number of bands (as many or as few as you need) to better discern the difference between original and encoded videos. As before, you can play back in the mode and rotate the bands through 90 degrees.

    image

    Diff Mode plots the degree of difference of the source vs encoded as a luminance map. If the encoded clip is identical to the source, its difference would be rendered all black (this can be inverted by double-clicking).

    image

    Audio Overlays

    Audio overlays work just like video overlays only they now enable you to overlay an audio track complete with relative level and fade in / out.

    They also enable a workflow for adding an external audio track to a mute video source and outputting a muxed A/V output.

    We’ve also enabled the audio from a video overlay to be enabled / mixed in if desired.

    WebDAV publishing in the box

    Publish to IIS, Sharepoint and other servers that support the WebDAV protocol.

    image

    Bug fixes / minor features

    There is a reasonably large list of small fixes that have gone into this release, many too minor to mention. The following are the more noteworthy:

    · Copy/paste markers and script commands: e.g. to/from Excel

    · Cancelling multi-file encode no longer deletes completed items

    · Removing items from jobs no longer deletes output

    · Enhanced trimming of overlays (from front, drag middle)

    · Run encode as background priority: so you can still use your machine for other tasks. Controllable via a setting

    · Mouse wheel support for zooming, mouse pan support

    · Enhanced Warning Triangles

    · Better default for cropping output. E.g. If you have a 16:9 video that only had 4:3 video inside it, if you choose 4:3 output and select crop, we’ll automatically crop out the correct portion in the middle.

    · Edit in Visual Studio option for templates

    · Couple of additional VC-1 advanced encoding properties

    · We now index unindex WMV/ASF files

    · Source Mode stream copying will now work even for cases where we don’t support the source CODEC as an output type in our UI e.g. WMScreen

    So there we have it. As always, feedback gratefully received,

    Hope this helps

    The Expression Encoder Team

  • Expression Encoder

    Video: Hello World

    • 30 Comments

    Welcome to the new Expression Encoder team blog!  As Charles says in the video, we plan on posting a bunch for hints and tips over the coming weeks.  We also encourage you to give us your feedback.

    All of our video blog posts are made with Expression Encoder and published using Silverlight on the Silverlight Streaming by Windows Live video hosting service.

    We are currently hard at work on the next release and look forward to sharing the details soon.  Thanks for watching / reading!

    The Expression Encoder Team

  • Expression Encoder

    Announcing Expression Encoder 2

    • 29 Comments

    Helloooo from Mix 08.. we can finally talk about what the Expression Encoder team have been up to for the last 6 months. Let's talk (and apologies in advance for the length of this post!).

    Today we are announcing Expression Encoder 2, the second version of Microsoft’s contemporary video authoring platform.

    image

    In a nutshell we have been extremely busy incorporating your feedback and balancing our small, nimble resources across a number of competing goals:

    1) to satisfy video compressionist’s desire for a best of breed VC-1 encoding tool

    2) to bring new tools into the hands of all comers wishing to embrace the Silverlight video tidal wave and..

    3) to enable the rapid authoring of interactive media by integrating enhanced content creation tools into the encoder.

    Expression Encoder 2 is now a product in its own right rather than a feature imageof Expression Media. It’s part of Expression Studio 2 and also available standalone.

    Before we step through what’s new, it's also worth mentioning that there are some really exciting new features that you've asked us for that we are not ready to announce just yet.  Stay tuned for more details.

    Another point to call out: Expression Encoder 2 continues to target Silverlight 1 experiences; the updated templates use loose XAML and JavaScript as before.  This is in common with the whole of Expression Studio 2.  At MIX, we are demoing an early preview of our Silverlight 2 managed Baseplayer.  This component provides all of the playback functionality inside an Expression template.  The new managed baseplayer enables the template developer to extend the base functionality (playback, chapters, captions etc) using the managed languages they know and love and add interactivity, custom behaviors etc.  We'll be talking more about that in the coming weeks.

    So to the list..

    Better Encoding

    • VC-1 advanced authoring SDK integration: by adopting the new VC-1 authoring SDK, Expression Encoder 2 is able to author better quality video faster.  We've exposed a set of presets for tuning the encoder as well as detailed settings with comprehensive tooltips for the advanced compressionist.image
    • New profiles, and CODECS: Encoder 2 supports a number of new modes and codecs including Quality VBR, WMA Pro (stereo), WMA Lossless, 24 bit audio and audio/video encoding stream selection.
    • Improved MPEG source support: We now include an MPEG 2 decoder in the product to give a consistent story across platforms.  The decoder we ship supports transport streams (so you are able to work with sources that originated from HDV cameras.  Seeking performance and accuracy has been greatly improved.
    • Better multi-core performance: we are not done with performance enhancements by any means but have made decent progress in Expression Encoder 2, particularly on multi-core systems.
    • Improved aspect ratio handling: by default, the new Profile Adaptive mode is selected which preserves the width specified in the profile but varies the height according to the aspect ratio of the source.  Translation: it just works.  Additionally, when Source compression is used the aspect ratio mode as well as pixel aspect settings are fixed up to ensure source compression will just work.
    • Pre-processing enhancements: the new Pre-processing palette contains a number of settings for controlling resizing (Bicubic, Lanczos, Supersampling in addition to nearest neighbor and bilinear), de-interlacing and audio options.  As well as detecting the need to de-interlace from the header of the file, the user can manually override the defaults.  In addition to the V1 capabilities, Expression Encoder 2 includes inverse telecine as well as a new pixel-adaptive de-interlacer.  On the audio side, there is a volume leveling filter as well as a volume control.
      image

    Better Silverlight Interactive experiences

    The second bucket of functionality covers improvements to Silverlight output.

    • New templates:  We've revisited both the functionality and the design of our core Silverlight Templates.  As before these support core functionality such as Chapter points and close captioning and are user extensible.
    • Template Parameters:  We have had a lot of requests for more and easier control of how templates behave.  Examples include not automatically playing (or buffering) the video, being able to control the background color of the HTML and more.  In Expression Encoder 2 we've added parameters to templates.  The parameter system is extensible enabling developers to easily expose custom things e.g. skin primary color etc.
      image
    • Gallery Templates: Often you want to publish multiple videos into a single experience.  We now have a number of such templates in the product including one made by Quiksilver for the Pro France surfing competition!
      image
    • Template preview: as you pick templates from the list, you will see a real-time preview rendered in Silverlight in the Output palette.
    • Edit in Expression Blend: This is one of our favorite features!  There are many times when it is desirable to be able to take a default Silverlight template and modify the look (or even completely replace the look).  It is now quick and easy to copy one of the defaults and edit in Expression Blend adding or changing individual XAML elements or completely replacing everything.  Since elements are hooked up to behaviors declaratively using well known names, zero knowledge of JavaScript or code is required.  Once Expression Blend has been launched, saving any of the files you are working on will immediately reload the template into Expression Encoder in the background ready to try.
      image
    • Partial rebuild:  Hand in hand with Edit in Expression Blend is another feature that makes iterative changes incredibly quick and easy.  Each time you click encode, instead of recreating everything every time, the minimal amount of work is done.  If you change encoding settings, the file will have to be re-encoded but if you are just moving markers or script commands, changing the poster frame or modifying the template the previously encoded results are used.  This works nicely for tasks such as template customization, adding/moving caption markers or adding a new source to a multi-clip gallery. Oh and if you encode a job, save the job, and re-launch the partial rebuild state is maintained. Yippee!
    • ASP.NET Development Server: we now use the same design-time web server component as Expression Blend and Visual Studio enabling template content to include server side code, web services and other dynamic goodness.
    • Hooks for Silverlight 2 templates: Whilst we are not shipping any in the box, the hooks are in place to enable easy integration of Silverlight 2 output in the future.

    Enhanced Content Creation tools

    • Brand new imaging pipeline: We've made some good investments in our core imaging pipeline that enable new functionality in Expression Encoder 2 and beyond.  Some of the benefits are listed below.
    • Burn-in of moving overlays:  be it video, alpha video or crisp vector-based motion graphics in the form of XAML, overlays are no longer static!  Control over opacity, placement and looping are all provided including real-time preview at design time.
      image
      XAML can also be used for leaders and trailers and will similarly get rendered into the output video. 
    • Cuts editing: in recognition of the fact that it is often necessary to trim not just the start and end of clips but also pieces from the middle, we made sure that the upgraded pipeline supported simple editing.  The core scenario for this feature is taking a long piece of content and re-purposing it as a short-form version.  Note that in Encoder 2 we do not support the editing together of arbitrary clips into a sequence.
    • Smart re-compression.  One of the disadvantages of using a full-blown editor for the above task is that it will take more time to import, edit and export.  With smart re-compression, our pipeline copies as much of the original compressed streams as possible.  Only at the joins where the cadence changes is it necessary to re-encode.  The advantages here are: one less tool in the change, quality preservation and speed.  Stream copying is way faster than re-encoding.
    • New Timeline UI:  hand in hand with the above improvements in the compression engine goes our new timeline UI.  This provides simple cutting and splicing and trimming controls.  It is also zoomable enabling more accuracy with edits and marker/script placement.  Once you have removed sections, it is possible to toggle a display that shows the sections that you removed in case you want to change your mind.  Script commands are intelligently grouped according to type making it easier to work with different interactivity types on on the same clip.  The timeline UI allows graphic placement of the overlay.
      image

    Object model

    We heard loud and clear that developers wanted to be able to programmatically use our encoding engine.

    • API assemblies available from the GAC
    • Code in any Managed language (including managed C++)
    • Access to complete batch encoding capabilities including overlays, cuts etc.
      image

    Other Stuff

    There are a ton of other improvements that are too many to list in full.  Among these are:

    • Enhancements to Live Encoding mode: · Encoding improvements (including dynamic complexity) via the VC-1 SDK, Encoding Profile editing , Silverlight live preview template
    • file extension for jobs: open jobs by double clicking on them.  Yea.
    • Most Recently Used menu: for re-opening recent jobs
    • Persistence of UI settings in job e.g. preview in browser
    • More robust job and preset loading when dependent files are missing
    • Enhancements to marker handing allowing a preset to merge or replace markers and script commands
    • Interlaced / Progressive indicator in media list

    So there is the list for now.  You can get our beta bits as part of the Expression Studio 2 beta package from here.

    Please continue to give us great feedback and stay tuned for our MIX video podcasts where we'll be recording some demos and other goodness over the next few days.

    Thanks,

    The Expression Encoder Team

  • Expression Encoder

    What’s new in Expression Encoder 3

    • 27 Comments

    image We on the Expression Encoder team are proud to announce that Expression Encoder 3 is complete and will shortly be available!  Since releasing V2 SP1 back in November of 2008 we have worked hard to improve core encoding capabilities,  continued to enhance new features such as Smooth Streaming, H.264 and editing as well as broaden the applicability of the product by adding new features such as Screen Capture.

    We have also focused heavily on our Silverlight output upgrading the MediaPlayer control to Silverlight 3 and the template skins that are based on it.  We’ll drill into the details of what is new over the course of this post and look forward to hearing your feedback.

    So how do you get Encoder 3? We’ll keep you in suspense a little while longer and direct you to the http://team.silverlight.net blog for the official announcement of Expression Studio 3.

    Encoder Enhancements

    We’ll start our tour of what’s new with the enhancements to the core encoding engine of the product.

    Improved H.264.  First up, we’ve improved the H.264 encoder that was part of V2 SP1 by adding support for custom resolutions (V2 SP1 was limited to two portable device-specific resolutions), single pass CBR, VBR Constrained, VBR unconstrained and Quality-based VBR rate control methods, Main Profile support, B-Frame support and advanced settings which include the ability to choose between the two major Entropy modes of Context-adaptive variable-length coding (CAVLC) and Context-adaptive binary arithmetic coding (CAVAC).

    image

    VBR Smooth Streaming.  Microsoft is investing heavily in Smooth Streaming across its product lines, which in conjunction with Silverlight, enables everyone to watch great quality video on the web at up to full HD 1080p. One of the results, that we are very excited to be shipping, is a brand new VC-1 encoder that has been optimized specifically for the multi-bitrate, multi-resolution nature of IIS Smooth Streaming.  Some of the features of the new technology include:

    • A new rate control that uses an analysis pass to distribute rate across GOPs
    • Support for variable GOP duration (the original CBR form of encoding requires fixed GOPs)
    • Dynamic optimization of coded resolution based on scene complexity and bitrate.  Additionally, directional energy measurements are used to change resolution both horizontally and vertically
    • An optimized polyphase filter for resizing resulting in better speed and quality that has been optimized for the SSE4 instruction set.   
    • Significant performance optimizations such as sharing motion information across bitrates and a faster analysis pass
    • Ability to cancel an encode if QPs start to spike, and restart with lower resolution

    Source CODECs.  In Encoder 3, we’ve broadened our support for source CODECs.  We have improved the performance of our H.264 decoder as well as adding support for AVCHD format.  We’ve also added some enhancements to our QuickTime stack to enable compatibility with ProRes which will help with post production workflows.  We are also pleased to be shipping Dolby Digital decoding in the box.  Finally, we’ve added the ability to import Smooth Streaming files so that you can review an encode outside Silverlight.  In this case, you are able to open the .ism file and the largest stream will be rendered.  This final feature is also available outside of Expression Encoder because we register the decoder on the system.  This means that once the full version of Expression Encoder has been installed, other applications on the system that can make use of DirectShow source filters will be able to open .ismv files.

    Audio Enhancements.  We heard your feedback and added support for multi-channel audio output:

    image
    We have also added the ability to select between multiple audio streams, where sources have them, as well as support for the Voice codec and VBR audio encoding. Last but not least, we dynamically determine what audio encoding capabilities are available from the host OS.

    Performance.  Performance is something we are never done with.  In Encoder 3 we’ve made great progress, particularly on multi-core, multi-processor scenarios.  First off, our core encoders have been rev’d to include support for newer Intel SSE instructions as well as support for up to 8 physical cores.  Secondly, we’ve improved CPU utilization on multi-core systems by parallelizing preprocessing tasks.  To illustrate the improvements, here are some before and after comparison charts based on analysis of Encoder 2 and Encoder 3 performance:

    image  
    Core 2 Duo Laptop; Vertical axis time in seconds – smaller is better; V2 in blue, V3 in red; results aggregated from 6 different source files

    image 
    Dual proc 8 Core Xeon; Vertical axis time in seconds – smaller is better; V2 in blue, V3 in red; results aggregated from 6 different source files

    We are working on more performance comparisons including i7 Nehalem systems which we’ll publish in due course.

    Live Encoding.  We spent a bunch of time in this release moving the Live portion of our encoder over to using the new encoding pipeline first introduced in Encoder 2.  This results in some immediate benefits such as better performance and de-interlacing support as well as some potential future benefits.  We’ve also added support for WMA Pro audio in Live, a new object model for Live (more details on this in the API section) and support for a broader range of capture devices.

    Expression Screen Capture

    In recent years, screen-casting has become an extremely popular way of sharing information you are looking at on your system with other users; encompassing eLearning, product support, user-generated content and many other domains. Included with Expression Encoder 3 is a new application called Expression Encoder Screen Capture available in the start menu or from within the main Expression Encoder UI.

    image

    You simply decide if you want to record webcam, and mic as well as the screen and system sound, pick a screen region with the easy to use Window picker (or by free-form selection):

    image 

    .. and start capturing.  One of the benefits of our new implementation is that we capture to a light weight intermediate CODEC, developed by Microsoft Research, rather than attempting to capture and encode directly to VC-1 or H.264.  This leaves more of the CPU available for the application you are capturing.  After capture, it is easy to import the sources into Expression Encoder for final encoding and Silverlight templating if required.

    UI Enhancements

    Improved profile palette.  As Expression Encoder has evolved between versions, the old Encoding settings palette had became increasingly unwieldy.. so for Encoder 3 we rebuilt it from the ground up. 

    image

    The most common encoding settings are now easier to find and set.  The advanced encoding settings are hidden by default so you only see the options you need.  And the ability to address different output CODECs is now explicitly designed in.

    Inside audio and video sections, there are many enhancements that make day to day tasks easier such as changing the aspect ratio or configuring multiple streams for Smooth Streaming.

    image

    Preset Palette.  Encoder 3 now has a more extensive library of encoding presets including an expanded set that target devices such as Xbox, iPod, Zune and the forthcoming Zune HD, online video services such as Facebook and YouTube and an expanded and improved set that target IIS Smooth Streaming.  As well as the expanded library, we have also added a new searchable preset palette where both system and user presets are stored as well as the ability to easily apply presets to all items via right-click.

    image

    Dockable palettes.  In common with the rest of the Expression 3 suite, Encoder 3 now uses the common palette docking framework which enables you to lay out your interface however you choose by simply dragging palettes and either popping them out into floating windows or grouping them into docked locations.  The Hide Palettes function has also been enhanced allowing the hidden palettes to pop open on hover.

    Summary Palette. Summary information has been moved into a separate palette which can be displayed via the Window menu.

    image

    Cog Menus.  In order to streamline palette-specific functions, we’ve introduced cog menus:

    image

    Cog menus are present on all palettes.  We’ve also got rid of the small white dot menus that were somewhat undiscoverable :-).

    Editing Enhancements.   In Encoder 2, we had the concept of adding a leader and trailer to a main file.  In Encoder 3, we have removed leader and trailer and replaced it with an extended Clips palette which enables multiple items to be stitched together.  This enables scenarios such as multiple leaders / trailers, Ad insertion and simple editing.  

    image

    It is also possible to set the stretch mode per clip and choose to apply crop which was not previously possible with leader and trailer.  You can append still frames (and set their duration) as well as XAML animations. Note that all of the enhanced editing capabilities are also available through the object model.

    Silverlight 3 MediaPlayers


    The Silverlight mediaplayers that have shipped in the box with Expression Encoder since V1 make it really easy to publish videos that target Silverlight.  In Encoder 3, we have updated all of the included templates to be based upon Silverlight 3 which means they are offered in the easy to use and deploy XAP format and all share the same common MediaPlayer control at their core.  We have also exposed the core MediaPlayer control in the Blend 3 toolbox which makes it easy for designers to embed and customize a full featured MediaPlayer in their projects that supports captions, chapters, smooth streaming etc.

    SL3 specific features.  We have added a number of Silverlight 3 specific features to all of the new players including

    • Cached composition:  Think of cached composition as hardware acceleration for the final frame presentation step.  Enabling cached composition (on by default) is as simple as a checkbox and results in much lower CPU utilization which helps general playback performance particularly on lower end systems such as NetBooks.  It also means that setting Stretch Mode Uniform incurs no performance penalty.
    • Offline support : Offline also known as Out Of Browser (OOB) is a new feature of Silverlight 3 that enables users to install Silverlight apps locally on their Mac or Windows machine.  In Encoder 3, if you choose to enable offline support when you publish a Silverlight video, the user will have the option of downloading and installing not only the media player code but also the video and audio files.

      This feature also works in conjunction with IIS Smooth Streaming so you get the benefit of adaptive streaming when online and a downloaded, high quality version to watch when away from a network.

      To show this in action, I created the following screencast.  Note that you can actually try the offline feature on the screencast it by clicking on the cog menu and selecting Offline :-)



    • We’ve made some changes to the Adaptive Streaming support that is baked into our MediaPlayer control.  Firstly, we’ve improved the bandwidth heuristics in a number of ways such as using the new CPU load metrics available from the Silverlight 3 runtime and constraining the playback resolution based on the size of the video window (to prevent bandwidth wasted by downloading e.g. 720p when the window size is only e.g. 320x240).

      We have also moved the heuristics into a separate XAP so that the adaptive streaming module can be loaded only when necessary thus helping to reduce the core download size.  Finally, we have changed the way we distribute the Media Steam Source (MSS) that implements the client portion of IIS Smooth Streaming.  We have moved to a model where we ship object code for this component, not source.  Source code is shipped for all other MediaPlayer functionality and is usable, redistributable and modifiable under the MS-PL.

    New Player Skins.  We have worked with ace design firm Archetype to create some great new player skins featuring smoothly animating controls and new Silverlight 3 features such as perspective transform.

    image

    image

    image

    image 

    Other Silverlight Improvements:

    • XAP Size reduction: we’ve taken steps to reduce the size of the MediaPlayer control.. the core player is now 109k down from 162k in Encoder 2 SP1.
    • Popout: We’ve added a Popout feature to the templates that allows a video to be popped out of a webpage as a webpage dialog.. you can then drag to another monitor and go fullscreen to keep watching while you work.   
    • Scriptability: The core mediaplayer control is now fully scriptable from Javascript.
    • Improved Install Experience: Expression Encoder now automatically generates a Content Gate install experience for users that don’t have Silverlight Installed:

      image
         
    • Improved accessibility on Silverlight Media Player: We’ve added tooltips to buttons on the MediaPlayer and done some additional testing with screen readers.
    • Edit in Expression Web:  We offer the ability to edit the output of a job in Expression Web.
        
    • Preview in Browser:  You can now open a Smooth Streaming job previously encoded and saved and start up the Smooth Streaming preview server and launch the default browser without having to re-encode the job.

      image
    • MediaPlayer control available in Blend Asset Palette:  When Expression Encoder is installed on the same system as Blend, the Expression MediaPlayer control becomes available in the Blend asset palette.  This enables designers and developers to easily use and customize our base player and take advantage of all the built-in functionality such as chapter points, closed captions, play lists smooth streaming, Offline support etc.
    • Transcoding in Expression Web:  Expression Web ships with Expression Encoder and utilizes the API to offer simplified transcoding functionality integrated right in.

    API Enhancements

    Expression Encoder has had a .NET API since Version 2.  In Version 3, we are making some changes:

    Object Model for Live Encoding. Live encoding now has an object model so you can create applications that capture and stream from live capture sources as shown here:

       1: using (LiveJob job = new LiveJob())
       2:            {
       3:                // Create a new file source from the file name we were passed in
       4:                LiveFileSource fileSource = job.AddFileSource(fileToEncode);
       5:  
       6:                fileSource.PlaybackMode = FileSourcePlaybackMode.Loop;
       7:  
       8:                //Alternatively, enumerate a capture device (not shown here)
       9:  
      10:                job.ActivateSource(fileSource);
      11:  
      12:                WindowsMediaBroadcastOutputFormat outputFormat = new WindowsMediaBroadcastOutputFormat();
      13:  
      14:                // Let's broadcast on the local machine on port 8080
      15:                outputFormat.BroadcastPort = 8080;
      16:  
      17:                // Set the output format on the job
      18:                job.OutputFormat = outputFormat;
      19:  
      20:                // Start encoding
      21:                Console.Out.Write("Press 'x' to stop encoding...");
      22:                job.StartEncoding();
      23:  
      24:                while (Console.ReadKey(true).Key != ConsoleKey.X)
      25:                {
      26:                    // We are waiting for the 'x' key
      27:                }
      28:  
      29:                // Stop our encoding
      30:                Console.Out.WriteLine("Encoding stopped.");
      31:                job.StopEncoding();
      32:            }


    Refactored Encoding Profile OM.  In addition to refactoring the Encoding profile palette, we have also refactored the underlying object model for configuring profiles making it simpler to use.  Instead of a monolithic Profile class, settings have been broken into a class hierarchy allowing the app to more easily and logically support multiple output CODECs such as H.264 and VC-1.

    SDK in the Box.  The SDK is now shipped along with the application.  It has also been updated to include more samples, including a Powershell cmdlet sample.

    image

    Redistributable version of Expression Encoder.  We will also be offering a no fee redistributable version of Expression Encoder for developers who wish to ship applications using the SDK.  Stay tuned for more information on this that we’ll share here on the blog in due course. 

    General

    Windows 7 Superbar Progress: View at a glance how far through the encode has progressed:

    First pass:
    image

    Second pass:
    image

    Removal of PS 2.0 requirement: We had feedback from users of older graphics cards that did not support Pixel Shader 2.0 that they were unhappy that they could not preview video.  So in Encoder 3, we still take advantage of PS 2.0 if present, but do not require it for preview.

    Support for LargeAddressAware flag:  Some of the new features, in particular the new VBR Smooth Streaming Encoder, can require a lot of memory in certain scenarios.  In Encoder 3, we set the /LARGEADDRESSAWARE bit in the application’s PE header which enables 3GB of addressable memory on x86 systems (requires BCDEDIT /Set IncreaseUserVa 3072) and 4GB on x64 systems.  For more information on this and how to configure an x86 system to take advantage of this feature, see http://msdn.microsoft.com/en-us/library/aa906217.aspx and http://blogs.technet.com/brad_rutkowski/archive/2006/10/03/Hey-where-did-_2F00_3GB-go-in-Longhorn-and-Vista_3F00_.aspx

    Removal of command-line encoder:  One of the tough trade-offs we had to make for this release was what to do with the command-line.  In Encoder 2 SP1 the command-line encoder was functionally behind what was possible in the UI and the Object Model.  We also observed a lot of community support for specialized command-line alternatives such as WMCmd.vbs by Alex Zambelli.  So, for Encoder 3 we took the difficult decision of removing the command-line encoder from the product.  Instead we directed our energies into making the .NET Object Model full fidelity in order to give application developers the maximum API surface area possible, including support for Live encoding.  To mitigate the decision, we are shipping working sample code in the box in the form of a Powershell cmdlet wrapper around the object model which provides basic Powershell-based command-line encoding supporting batch operations via the Powershell object pipeline:

     image

    Additionally, we are keen to work with the community to get an equivalent to WMCmd.vbs built and published on Codeplex to satisfy users who really want to automate encoder using cmd.exe rather than from Powershell or C#.  We hope you agree that this was the right trade-off to make.  If you have any opinions, positive or negative, please do send us your feedback.

    Summary

    We look forward to making the release available for download in the coming weeks and talking more about its capabilities.  Stay tuned and, as ever, your feedback is welcome.
    The Expression Encoder Team.

  • Expression Encoder

    Expression Encoder 2 SDK Released

    • 25 Comments

     

    Last week we released the Expression Encoder 2 SDK. Here's a little video of Charles and I, giving a quick introduction. Apologies for the rather close camera angle as Charles was just holding the camera with his left hand, and it didn't help that our makeup and wardrobe department was out that day.

    You can get it from the following location.

    Microsoft® Expression® Encoder 2 SDK

    Please try it out and don't hesitate to send us your feedback.

  • Expression Encoder

    What’s New in the Expression Encoder 3 SDK?

    • 21 Comments

    When Encoder 3 is installed we now install the API help file, intellisense files and the sample projects, so you’re ready to go with the SDK as soon as Encoder is installed. You will find a SDK link on the start menu that will take you to the folder from where you can find the samples (in C# and Visual Basic) and the help CHM file.

    Live Encoding Support

    I know a bunch of you have been waiting for this for a while now and you’ll be glad to see that V3 has full support for the Live mode of the application through the object model.

    e.g.

    // Create a new LiveJob to begin broadcasting this file.
    using (LiveJob job = new LiveJob())
    {
        // Create a new file source from the file name we were passed in
       LiveFileSource fileSource = job.AddFileSource(@"C:\myvideo.wmv");
    
        // Set this source to Loop when finished
       fileSource.PlaybackMode = FileSourcePlaybackMode.Loop;
    
        // Make this source the active one
       job.ActivateSource(fileSource);
    …

    From the LiveJob object you can get a list of video and audio capture devices installed on the system and add them as sources as well. See the Microsoft.Expression.Encoder.Live namespace for further details and the new Live SDK sample that is installed.

    Redesigned profile support with full support for H.264 customization.

    In V3 we now have separate profile classes for each profile type. This way if you’re dealing with the Main H.264 video profile for instance you’ll just see the properties that pertain to that profile on the object. (Note that you need the full version of Encoder for H.264 support). Along with this you now specify the profiles within the OutputFormat property on the MediaItem.

    Bitrate is specified by using one of the new bitrate classes, ConstantBitrate, VariableConstrainedBitrate, VariableUnconstrainedBitrate and VariableQualityBitrate. Again this is so that only the properties that make sense are exposed on the class. For example when using VariableConstrainedBitrate there is a PeakBitrate property but that property isn’t exposed on any of the other bitrate classes as it only applies to the variable constrained bitrate type.

    e.g.

    MainVC1VideoProfile videoProfile = new MainVC1VideoProfile();
    videoProfile.Bitrate = new ConstantBitrate(350);
    videoProfile.Complexity = VideoComplexity.Fastest;
    videoProfile.Size = new System.Drawing.Size(640, 480);
    
    MediaItem item = new MediaItem(@"C:\myvideo.wmv");
    item.OutputFormat = new WindowsMediaOutputFormat()
    {
        VideoProfile = videoProfile
    };

    Smooth Streaming

    The Encoder SDK supports encoding to the smooth streaming output format (when using the full version of Expression Encoder). The video profile class now has a streams property which is used to specify the details of each stream that you wish to encode. Smooth Streaming can be used when encoding to constant bitrate for VC-1 and H.264 and to variable constrained bitrate when using VC-1. Additionally when using VC-1 and variable constrained bitrate you can specify that the sizes of the streams should be automatically determined by the encoder based upon the content and the bitrate. In this case you specify the maximum width and height to use for each stream.

    e.g.

    AdvancedVC1VideoProfile videoProfile = new AdvancedVC1VideoProfile();
    
    // When you create a VideoProfile you'll get one stream by default.
    // In this example remove that one as we’re going to explicity 
    // add the three streams below.
    videoProfile.Streams.RemoveAt(0);
    videoProfile.Streams.Add(
        new VariableConstrainedBitrate(1450, 1600),
        new System.Drawing.Size(800, 600));
    videoProfile.Streams.Add(
        new VariableConstrainedBitrate(1050, 1600),
        new System.Drawing.Size(640, 480));
    videoProfile.Streams.Add(
        new VariableConstrainedBitrate(600, 1600),
        new System.Drawing.Size(400, 300));
    
    // Use smooth streaming with automatically sized streams.
    videoProfile.SmoothStreaming = true;
    videoProfile.Streams.AutoSize = true;

    Encoding Multiple Sources Together

    In V2 you could essentially combine up to three sources by using the leader, main video and trailer. In V3 you can move past this limit and combine multiple sources into one by using the new Source class.

    e.g.

    MediaItem item = new MediaItem("mymovie1.wmv");
    item.Sources.Add(new Source("mymovie2.wmv"));
    item.Sources.Add(new Source("mymovie3.avi"));
    item.Sources.Add(new Source("mymovie4.wmv"));

    File Information

    There are new classes to help analyze an existing media file to determine information about its video streams and audio streams (in case the file has more than one).

    e.g.

    AudioVideoFile source = new AudioVideoFile("myvideo.wmv");
    Console.WriteLine(source.VideoStreams[0].VideoSize);
    Console.WriteLine(source.VideoStreams[0].AspectRatio);
    Console.WriteLine(source.VideoStreams[0].Duration);
    Console.WriteLine(source.AudioStreams[0].Channels);
    Console.WriteLine(source.AudioStreams[0].SampleSize);

    If the source file does have more than one audio stream you can now specify which stream is used when encoding by setting the AudioStreamIndex property on the Source object.

    e.g.

    item.Sources[0].AudioStreamIndex = 2;

    Presets

    For all the standard presets that are installed with the application we have specified pre-defined static instances for each one to make it easier to use in case you don’t want to set all the properties of the profiles individually.

    e.g.

    mediaItem.ApplyPreset(Presets.VC1HighSpeedBroadbandVBR);

    If you look at the Presets Members in the SDK help file you’ll see all the options along with descriptions.

    So there you have a quick introduction to some of the new changes and improvements to the Expression Encoder object model in version 3. You can check out the What’s New section in the SDK help file for further details and feel free to give us your feedback and ask questions either by adding a comment here or over in the Expression Encoder Forum

  • Expression Encoder

    Microsoft Expression Encoder 3 is available for download

    • 18 Comments

    We are very pleased to announce that both Expression Studio 3 trial and Expression Encoder 3  are now available to download:

    Encoder: here

    Studio: here

    In this release we have taken on board your feedback and simplified the product line. There are now two versions: Expression Encoder and Expression Encoder with IIS Smooth Streaming. We have retired the Express version and, instead, have made all the features in Expression Encoder available for free with no more 30 day limit.

    So what do you get in Expression Encoder with IIS Smooth Streaming?

    · CODECs (AC3 Decode, MPEG2/TS Decode, AVC-HD Decode, H.264 Encode, AAC-LC Encode/Decode)

    · Unlimited Screen Capture (Expression Encoder can capture up to 10 minutes)

    · IIS Smooth Streaming

    Other than that, all functionality in the Expression Encoder is freely available with no time limit (Full VC-1 encode, Live encoding, Overlays, Screen Capture up to 10 minutes).

    If you wish to obtain the fully licensed version of Expression Encoder with IIS Smooth Streaming, it is available in both of the Expression Studio 3 and Expression Web 3 SKUs as well as in the Expression Professional Subscription which can be ordered from the Microsoft Store or your favorite online retailer.

    As previously mentioned, there will be a freely redistributable version of Expression Encoder 3 available in the future, that can be shipped as part of 3rd party applications.

  • Expression Encoder

    Silverlight Streaming Publishing Plugin for Expression Encoder 2 is out!

    • 17 Comments

    I'm pleased to announced that we just pushed a preview of the SLS publishing plugin for Expression Encoder 2 live:

    http://download.microsoft.com/download/2/2/a/22a8da23-ffa7-4e5a-8fed-8239d3a7b322/SLSPlugin for Expression Encoder 2.msi

    This plugin makes it very easy to publish and manage your encoded Silverlight video experiences online via the Silverlight Streaming service from within the Expression Encoder application.

    As well as adding support for Expression Encoder 2, the plugin has a number of enhancements:

    1. File-by-file upload:  Removes the zip step and improves uploaded reliability and performance.
    2. Better upload progress reporting.
    3. Quota display that shows available/remaining online storage space.
    4. Support for application republishing: you can replace or merge existing applications.
      image
    5. UI enhancements (eg resizable preview window, application list sorted in inverse date order etc).

    Hope this helps,

    James

    image
  • Expression Encoder

    Expression Encoder 4 SP2 released!

    • 17 Comments

    A new service pack is now available for Expression Encoder 4, which includes over 300 bug fixes as well as these new features:

    General Encoding

    Support for Intel QSV GPU encoding (Pro only) – GPU-accelerated encoding has added support for the Intel HD Graphics GPU included in Sandy Bridge processors, in addition to the improved Nvidia CUDA support. You can use both of these devices when encoding for increased speed and performance. More information available here. QSV and Cuda performance reports are also available.

    Support for 1 and 2-pass VBR for offline H.264 encodes (Pro only) – You can now select 1-pass VBR for MP4 encodes as well as both 1-pass and 2-pass VBR for H.264-based Smooth Streaming encodes.

    Support for more AAC audio options (Pro only) – You can now choose multiple-channel audio along with more bitrate and sample rate options when you use the AAC codec.

    Support for SRS audio encoding – You can now choose to enable SRS to convert an audio stream from multiple audio channels to two SRS 5.1 surround sound channels.

    Live

    Manage publishing points from within Expression Encoder (Pro only) – In a Live Broadcasting Project, you can now create, restart or update publishing points on an IIS Smooth Streaming server. You can also choose to automatically update a broadcast’s EventID.

    Live crop – You can now crop your live or file sources in a Live Broadcasting project.

    Support for Windows Media Streaming MBR in a Live broadcast – You can now add multiple bitrate streams to your WM Streaming broadcast in a Live Broadcasting Project.

    Support for Live H.264 VBR 1-pass (Pro only) – You can now select 1-pass VBR encoding for H.264-based Live Smooth Streaming encodes.

    Other

    No Screen Capture limit – The 10-minute Screen Capture limit has been removed from Expression Encoder.

    Follow mouse cursor – You can now enable the screen capture area to follow your mouse cursor in Screen Capture.

    Template improvements – Offline playback of DRM content, SRS playback support, improved TTML support, audio volume on startup, auto-repeat, etc.

    New SDK samples – Following your requests and suggestions, we added 5 C# and 6 VB.NET samples, including a thumbnail generator, a performance tool and a Live console application.

     

    Let us know what you think! Thanks.

  • Expression Encoder

    Expression Encoder 2 SP1 is released

    • 13 Comments

    SP1 has just gone live here:

    http://www.microsoft.com/downloads/details.aspx?FamilyId=A29BE9F9-29E1-4E70-BF67-02D87D3E556E&displaylang=en

    In addition to the enhancements that are documented in this post, the update includes support for the authoring of IIS Smooth Streaming content.

    Note that the authoring of both IIS Smooth Streaming and H.264 for devices are only available in the full product, not the trial.  The remainder of the features such as audio overlays and WebDAV publishing are available both in the trial and the full product.

  • Expression Encoder

    Getting started with the Expression Encoder Object Model (RTM Version)

    • 11 Comments

    This post is an update to the previous Getting started with the Expression Encoder Object Model post, but updated to work with the RTM version of Expression Encoder V2 as the progress event handler changed a little from Beta to RTM.

    (This post assume you’ve already installed Expression Encoder V2 available from here, and that you have Visual Studio 2005 or 2008 installed.)

    First of all start Visual Studio and select File… New Project… You can choose which type of application you would prefer, like a WPF or Windows Forms application. For my test here, I’m just going to choose a Console Application. Give it a suitable name.

    image

    Go ahead and click OK.

    Before you can start coding against the Expression Encoder object model you need to add references to the applicable assemblies. Select Project…Add Reference from the menu. When the dialog comes up you need to select

    Microsoft.Expression.Encoder
    Microsoft.Expression.Encoder.Types
    Microsoft.Expression.Encoder.Utilites

    and because some of our types derive from ObservableCollection you also need to select

    WindowsBase.

    You can select them one at a time or hold down CTRL and multi-select each one before clicking OK.

    image

    Now we're ready to do some coding.

    To make it easier to pick up the Encoder classes let's first of all add a using statement. Just add the following near the top of the file where the other using statements are.

    using Microsoft.Expression.Encoder;

    One of the main classes that you'll end up dealing with in Expression Encoder is the MediaItem class. This allows you to find out information about a video or audio file and ultimately allow you to encode it. To create one of these you just pass the filename of the media file you want.to the constructor.

    e.g.
    MediaItem mediaItem = new MediaItem(@"C:\input\video.avi");

    Obviously, you'll change the filename to the one you want to use.

    Once this has been created you'll be able to access a bunch of information about the file

    e.g.
    FileDuration
    OriginalAspectRatio
    OriginalVideoSize

    This is also the way you'll control how the video is encoded. If you type mediaItem followed by a "." you should trigger the Intellisense drop down which shows you all the properties and methods on this item. You should see a lot of properties that correspond to options in the UI of the main Encoder application. If you want Intellisense comments to appear and want to check out the help file, see this post.

    For now we'll just use the defaults.

    Before we can encode the file we need to create and add it to a Job.

    This is simply done by the following statements.

    Job job = new Job();
    job.MediaItems.Add(mediaItem);

    If you want to encode multiple files in the same job you can go ahead and create multiple MediaItem's and add them to the job.

    Before you encode you need to set the directory where the output will go. This is done by setting the OutputDirectory property.

    job.OutputDirectory = @"C:\output";

    By default Expression Encoder will create output in sub folders named using the Job Id. These will be something along the lines of your machine name followed by the current date and time, e.g. "DEAN 4-21-2008 11.00.47 PM".

    You can turn this feature off by setting the CreateSubfolder property.

    job.CreateSubfolder = false;

    Then the output will be created in the output directory directly.

    For the simplest case, that’s all you need before encoding the job. This is done by just calling the Encode method.

    job.Encode();

    Putting it all together your program should look something like this.

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using Microsoft.Expression.Encoder;
    
    namespace MyEncoderApplication
    {
        class Program
        {
            static void Main(string[] args)
            {
                MediaItem mediaItem = new MediaItem(@"C:\input\video.avi");


    // Create a job and the media item for the video we wish // to encode.
    Job job = new Job(); job.MediaItems.Add(mediaItem);
                // Set the output directory and encode
                job.OutputDirectory = @"C:\output";
                job.Encode();
            }
        }
    }

    Now you should be able to compile and run the application. After it's finished running, you should have the encoded output file underneath the output directory. It should have a filename that matches the original, but with a .wmv file extension.

    If you run the application and it crashes, then that is probably because an exception was thrown that is not currently being caught. For example if your MediaItem points to a file that doesn't exist or isn't a valid media file, you will see that an InvalidMediaFileException is thrown. You can then run it under the debugger to get more details.

    Assuming everything worked OK then for your next step you'll probably want to show some progress during the encode. First of all you need to a add a progress event handler function. Something like the following

    static void OnProgress(object sender, EncodeProgressEventArgs e)
    {
        Console.WriteLine(e.Progress);
    }
    

    Obviously here we're just dumping the progress to the screen on each line. If you were writing a GUI app you would probably update a progress bar or something similar.

    To tell Encoder to call this function you need the following line when you're creating the job.

    job.EncodeProgress 
        += new EventHandler<EncodeProgressEventArgs>(OnProgress);
    

    Now you’re code should look something like the following.

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using Microsoft.Expression.Encoder;
    
    namespace MyEncoderApplication
    {
        class Program
        {
            static void Main(string[] args)
            {
                MediaItem mediaItem = new MediaItem(@"C:\input\video.avi");
    
                // Create a job and the media item for the video we wish
                // to encode.
                Job job = new Job();
                job.MediaItems.Add(mediaItem);
    
                // Set up the progress callback function
                job.EncodeProgress 
                    += new EventHandler<EncodeProgressEventArgs>(OnProgress);
    
                // Set the output directory and encode.
                job.OutputDirectory = @"C:\output";
                
                job.Encode();
            }
    
            static void OnProgress(object sender, EncodeProgressEventArgs e)
            {
                Console.WriteLine(e.Progress);
            }
        }
    }
    
    

    When you compile and run the application you should now see a bunch of numeric values going to 100, something like the following.

    clip_image002

    That’s it for a basic encoding app. From here you can now try experimenting with various properties on the MediaItem. For example, if you want to try tweaking the output profile, you can look at this post – Changing the output profile.

    Note that if you’re running a 64-bit OS then you may also need to change your Target Platform within Visual Studio from “Any CPU” to "x86” as Expression Encoder is 32-bit.

  • Expression Encoder

    T09 at MIX is done

    • 10 Comments

    Charles and I presented our Session at MIX08 on Expression Encoder 2 this morning.  It went reasonably well.  With luck the video should appear here shortly.  We'll re-publish it on the blog sometime next week.

    We also have a couple of other MIX videos to publish soon.  In the meantime, here are some pix that David shot:

    IMG_1130 IMG_1134 IMG_1147

  • Expression Encoder

    Expression Encoder 2 SP1 and IIS Smooth Streaming

    • 10 Comments

    Today we are announcing:

    • IIS Smooth Streaming, a new adaptive streaming technology evolved from work done for the web distribution NBC Olympics.
    • Akamai is launching a preview of a new service called “Akamai AdaptiveEdge Streaming for Microsoft Silverlight” that will enable HD video experiences on the web (see http://www.smoothHD.com for more info).

    As part of the announcement we will be shipping support for IIS Smooth Streaming in Expression Encoder 2 SP1 including the ability to simultaneously encode to multiple bitrates required to enable an adaptive streaming scheme, support for outputting to the new file format as well as support for the format in our Silverlight 2 player skins.

    In simple terms, adaptive streaming is an approach that enables video playback to adapt, in real time, to changing network conditions and PC load and be able to offer the appropriate bitrate at any particular instant.  The IIS Smooth Streaming implementation offers various optimizations that make deployment and management of such a scheme simpler and more cost effective.  IIS Smooth Streaming will be an upcoming feature of the IIS Media Pack.

    Expression Encoder 2 SP1 will be available real soon now.. when it drops, we’ll be following up with more info on the new features and how to create IIS Smooth Streaming content.  In the meantime you can check out the demos over at http://www.smoothHD.com.

  • Expression Encoder

    Creating XAML overlays for Microsoft Expression Encoder

    • 10 Comments

    A XAML overlay is a vector-based graphic that is rendered into the users video like a lower third, a logo bug, etc...  XAML is Extensible Application Markup Language and is a declarative XML-based language created by Microsoft which is used to initialize structured values and objects.  Below are examples of XAML overlays.

    james2smily_face

    The goal of the this walk through is to allow you to be able to understand how to get your XAML design from Expression Design into Expression Encoder. 

    To create a XAML overlay start by creating your graphic in Microsoft Expression Design or importing a design into Microsoft Expression Design.

    After finishing your design you need to make the XAML overlay you created digestible by Microsoft Expression Blend (if you want to animate it) by completing the following steps using Microsoft Expression Design.

    Select All

    File>Export

    Export as XAML WPF Canvas(Take note of where you save this file)

    Silverlight XAML is not supported

    export

    At this point you can use the XAML overlay as a static graphic overlay in Microsoft Expression Encoder.

     

    If you wish to animate the overlay follow these instructions.

    Open Microsoft Expression Blend

    Create a new project a WPF Application (.exe)

    image

    In the project panel right click on csproj file and Link to Existing Item…

    image

    Navigate to the XAML file you created in Microsoft Expression Design and Double click on the XAML file in the project tab

    image

    This will open up the XAML file that you created in Microsoft Expression Design and open it in Microsoft Expression Blend.

    At this point you should be able to animate the XAML.

    Add a new storyboard then add your animation key frames to create your animation.

    image

    Then navigate to the file menu and select save and your animated XAML overlay is ready for Microsoft Expression Encoder.

    In Microsoft Expression Encoder add overlay and navigate to original Microsoft Expression Design XAML file from design and add this file as an overlay.  After adding the overlay you can customize length visible, fade in, and fade out.  On the video window you can scale the graphic and place it in the desired position. Since it is vector-based, the quality of text and graphical elements will be maintained.

    image image

  • Expression Encoder

    Expression Encoder 2 SDK Updated for Service Pack 1

    • 10 Comments

    image We’ve just released an update to the SDK, which now incorporates the new features in Expression Encoder 2 Service Pack 1.

    Here are the main things that are new in the SDK :-

  • We’ve improved the formatting of the help file so things are hopefully a little easier to read.

  • We have a new updated object model layout diagram.

  • New files to give updated Intellisense comments.

  • Some new samples in Visual Basic.

  • Added ASF indexing support. For more information, see AsfIndexer in the Programming
    Reference.
  • A new Mode property, EncoderSku, which gives more accurate SKU information than Mode.IsExpress.

  • A new MediaItem property, FileOutputMode, which you can use to select ASF MBR as well as "Adaptive Smooth Streaming" output modes.

  • Enhancements to how output files are generated and accessed.

  • New audio overlay functionality for MediaItem.

  • Two new AAC base profiles for AudioProfiles.

  • Two new H.264 base profiles for VideoProfiles.

  • A new AdaptiveStreaming profile for both AudioProfiles and VideoProfiles.

  • A new VideoProfile profile, VideoProfileMbrDeltaCollection, which you can use to customize MBR and/or AdaptiveStreaming output streams.

  • A new default resize mode of SuperSampling instead of Bicubic.

    Here’s the link to download the updated SDK.

    http://www.microsoft.com/downloads/details.aspx?FamilyId=9A077A3D-58CE-454C-B486-153F0578BE4A&displaylang=en

  • Expression Encoder

    A new way to get the full version of Expression Encoder 3

    • 9 Comments

    We have just made available a new option that allows users to purchase the full version of Expression Encoder as a standalone product.  To recap what this means, let’s start with the free version of Expression Encoder.  This is available from here:image

    http://www.microsoft.com/downloads/details.aspx?FamilyID=b6c8015b-e5de-46c0-98cd-1be12eef89a8&displaylang=en

    and contains the full feature set of the product with the following limitations:

    • Screen capture up to 10 minutes
    • No Smooth Streaming output
    • The following CODECs are not present: AC3 Decoder, MPEG2/TS Decoder, AVC-HD Decoder, H.264 Encoder, AAC-LC Encoder/Encoder

    (Note.. the installer is currently miss-labeled as Encoder_Trial_en.exe but is, in fact fully featured bar the above list and also not time-bombed as in previous versions.)

    If you try and access these features you’ll get the following message:

    image

    As of today, the purchase link now points to a new Microsoft Store page where you can get an Expression Encoder 3 license for $49:

    image

    Expression Encoder 3 is still available as part of Expression Studio 3, Expression Web 3 as well as through the Expression Professional Subscription and MSDN programs.

  • Expression Encoder

    Expression Encoder 2 VB.NET update

    • 9 Comments

    We've just released an update to Expression Encoder 2 that allows VB.NET developers to build solutions using the Expression Encoder 2 SDK

    You can get the update here:

    http://www.microsoft.com/downloads/details.aspx?FamilyId=8727DD51-61B3-4692-ABDE-4FDD2779B0D0&displaylang=en

    The cool part is that the update is only required on developer machines.  Any apps created in VB.NET on a machine with the fix will run against the unmodified Expression Encoder 2 release bits.

    Hope this helps

    James

  • Expression Encoder

    Getting started with the Expression Encoder Object Model

    • 8 Comments

    (UPDATE: This post was written against the Beta of Expression Encoder v2. Now that the RTM version is out we recommend that you install that version and check out the RTM version of this post instead)

    (This post assume you’ve already installed Expression Encoder Beta 2 available from here, and that you have Visual Studio 2005 or 2008 installed.)

    First of all start Visual Studio and select File… New Project… You can choose which type of application you would prefer, like a WPF or Windows Forms application. For my test here, I’m just going to choose a Console Application. Give it a suitable name.

    image

    Go ahead and click OK.

    Before you can start coding against the Expression Encoder object model you need to add references to the applicable assemblies. Select Project…Add Reference from the menu. When the dialog comes up you need to select

    Microsoft.Expression.Encoder
    Microsoft.Expression.Encoder.Types
    Microsoft.Expression.Encoder.Utilites

    and because some of our types derive from ObservableCollection you also need to select

    WindowsBase.

    You can select them one at a time or hold down CTRL and multi-select each one before clicking OK.

    image

    Now we're ready to do some coding.

    To make it easier to pick up the Encoder classes let's first of all add a using statement. Just add the following near the top of the file where the other using statements are.

    using Microsoft.Expression.Encoder;

    One of the main classes that you'll end up dealing with in Expression Encoder is the MediaItem class. This allows you to find out information about a video or audio file and ultimately allow you to encode it. To create one of these you just pass the filename of the media file you want.to the constructor.

    e.g.
    MediaItem mediaItem = new MediaItem(@"C:\input\video.avi");

    Obviously, you'll change the filename to the one you want to use.

    Once this has been created you'll be able to access a bunch of information about the file

    e.g.
    FileDuration
    OriginalAspectRatio
    OriginalVideoSize

    This is also the way you'll control how the video is encoded. If you type mediaItem followed by a "." you should trigger the Intellisense drop down which shows you all the properties and methods on this item. You should see a lot of properties that correspond to options in the UI of the main Encoder application.

    For now we'll just use the defaults.

    Before we can encode the file we need to create and add it to a Job.

    This is simply done by the following statements.

    Job job = new Job();
    job.MediaItems.Add(mediaItem);

    If you want to encode multiple files in the same job you can go ahead and create multiple MediaItem's and add them to the job.

    Before you encode you need to set the directory where the output will go. This is done by setting the OutputDirectory property.

    job.OutputDirectory = @"C:\output";

    By default Expression Encoder will create output in sub folders named using the Job Id. These will be something along the lines of your machine name followed by the current date and time, e.g. "DEAN 4-21-2008 11.00.47 PM".

    You can turn this feature off by setting the CreateSubfolder property.

    job.CreateSubfolder = false;

    Then the output will be created in the output directory directly.

    For the simplest case, that’s all you need before encoding the job. This is done by just calling the Encode method.

    job.Encode();

    Putting it all together your program should look something like this.

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using Microsoft.Expression.Encoder;
    
    namespace MyEncoderApplication
    {
        class Program
        {
            static void Main(string[] args)
            {
                MediaItem mediaItem = new MediaItem(@"C:\input\video.avi");


    // Create a job and the media item for the video we wish // to encode.
    Job job = new Job(); job.MediaItems.Add(mediaItem);
                // Set the output directory and encode
                job.OutputDirectory = @"C:\output";
                job.Encode();
            }
        }
    }

    Now you should be able to compile and run the application. After it's finished running, you should have the encoded output file underneath the output directory. It should have a filename that matches the original, but with a .wmv file extension.

    If you run the application and it crashes, then that is probably because an exception was thrown that is not currently being caught. For example if your MediaItem points to a file that doesn't exist or isn't a valid media file, you will see that an InvalidMediaFileException is thrown. You can then run it under the debugger to get more details.

    Assuming everything worked OK then for your next step you'll probably want to show some progress during the encode. First of all you need to a add a progress event handler function. Something like the following

    static void OnProgress(objectsender, PublishProgressEventArgs e)
    {
        Console.WriteLine(e.Progress);
    }

    Obviously here we're just dumping the progress to the screen on each line. If you were writing a GUI app you would probably update a progress bar or something similar.

    To tell Encoder to call this function you need the following line when you're creating the job.

    job.PublishProgress +=
        new EventHandler<PublishProgressEventArgs>(OnProgress);

    Now you’re code should look something like the following.

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using Microsoft.Expression.Encoder;
    
    namespace MyEncoderApplication
    {
        class Program
        {
            static void Main(string[] args)
            {
                MediaItem mediaItem = new MediaItem(@"C:\input\video.avi");
     
                // Create a job and the media item for the video we wish 
                // to encode.
                Job job = new Job();
                job.MediaItems.Add(mediaItem);
    
                // Set up the progress callback function
                job.PublishProgress +=
                    new EventHandler<PublishProgressEventArgs>(OnProgress);
    
                // Set the output directory and encode.
                job.OutputDirectory = @"C:\output";
                job.Encode();
            }
    
            static void OnProgress(object sender, 
                PublishProgressEventArgs e)
            {
                Console.WriteLine(e.Progress);
            }
        }
    }

    When you compile and run the application you should now see a bunch of numeric values going to 100, something like the following.

    clip_image002

    That’s it for a basic encoding app. From here you can now try experimenting with various properties on the MediaItem. For example, if you want to try tweaking the output profile, you can look at this post – Changing the output profile.

    UPDATE: If you’re running a 64-bit OS then you may also need to change your Target Platform within Visual Studio from “Any CPU” to "x86” as Expression Encoder is 32-bit.

  • Expression Encoder

    GPU ENCODING IN EXPRESSION ENCODER 4 PRO SP2

    • 8 Comments

    Introduction

    This document is to complement the original Expression Encoder 4 SP1 GPU Encoding white paper and discuss the changes that SP2 introduced on this subject. The latest service pack includes a major revision of the CUDA H.264 encoder as well as the introduction of Intel Sandy Bridge QSV support, which both will be discussed in depth below.

    Please note that an updated performance report for Cuda GPU Encoding as well as a new one for QSV GPU Encoding are available.

     

    General GPU Encoding Recommendations

     

    To Maximize Performance

    As before, we recommend applying the proper GPU for video processing load. We provide below basic guidelines for optimizing your performance using a GPU to encode. Using proper GPU hardware and a conservative "GPU Stream" setting can reduce the chances of maxing out the GPU resources. Another way to reduce the GPU memory footprint is by lowering the "Number of Reference Frames". GPU-Z is a great freeware to monitor the load and memory usage.

    To calculate the appropriate number of GPU streams setting for a specific scenario, we also created a simple performance tool. More information is available here.

    Finally, since available GPU memory is more important than ever, we recommend closing any other applications to minimize GPU memory usage outside of Encoder.

     

    To Maximize Quality

    • Consider using 1-pass constrained VBR over CBR.
    • Make the "Buffer Window" longer. Note that this will impact latency.
    • Use accurate pre-processing settings (aka de-interlacing and resizing methods) for a given source. For example, using the wrong de-interlacing method can introduce weave artifacts, which are hard to encode and will significantly impact overall output quality.
    • Consider removing any letterboxing introduced by the source and/or the encode settings. Those introduce hard high-contrast edges which are hard to encode and will also impact output quality.

     

    Second Generation of CUDA GPU Encoding

    In collaboration with our partners at Main Concept, a lot of work was done on the CUDA H.264 encoder to optimize the performance of the GPU, as well as improving output quality and adding new encode functionality like true CBR and HRD support. Those changes have significantly impacted its behavior, especially in terms of performance:

    1. GPU memory requirements have doubled using with the same settings when compared to SP1.
    2. GPU load has more than doubled too.
    3. CPU load has been reduced when encoding with CUDA.

    In other words, you will experience better quality and less CPU load, at the cost of higher GPU load and some overall performance loss.

    Finally, because the CUDA encoder doesn't support 2-pass encodings, they have been disabled. Please note that while Encoder will revert to software encoding if a 2-pass encode is selected, the new 1-pass H.264 VBR encoding options are fully supported in both CUDA and QSV-based encoding.

     

    Recommendations

    Because of the new behavior, we now recommend using only higher-end CUDA GPUs for this feature. A rough suggestion would be to get CUDA hardware with a minimum of 200 CUDA cores per HD stream to be encoded via CUDA and at the least 1 GB of video memory (2 GB or more preferred). It means that for encoding a single HD stream on the GPU, at the least a GeForce GTX 550 Ti or Quadro 2000 GPU is recommended, while encoding 2 or more HD streams on the GPU would require at the least a GeForce GTX 570, Quadro 6000 or Tesla C2050 card. As in Encoder SP1, multiple video cards can be used to speed up Smooth Streaming encodes. Note that we also changed our default of number of GPU streams to 2, which can be tweaked to take full advantage of the hardware used.

    Since the GPU is taking more of the load, matching the CPU may not be as important for single stream encodes. Because most current CUDA GPUs can't take more that 2-3 HD streams at a time, a powerful CPU is still required for HD Smooth Streaming encodes.

    Finally, make sure to install the latest Nvidia drivers available from Nvidia's website here. Note that the GPU driver version is required to be higher than 267.91 for SP2.


    New Intel Sandy Bridge QSV GPU Encoding Support

     

    What is QSV?

    Intel Quick Sync Video (QSV) is a GPU acceleration technology available on some Intel processors that can dramatically increase the speed of transcoding media files. It is available on most 2nd generation i3, i5 and i7 processors (aka "Sandy Bridge"), as well as some newer Xeon CPUs, like the E3-1285. More information about QSV is available on Intel's website. Please note that the newly Sandy Bridge E CPU line (example: i7-3960X) does not have an embedded GPU, and thus does not support QSV.

    QSV encoding support has been integrated in Encoder 4 Pro SP2, which can be used in a similar fashion as CUDA encoding to speed up MP4 and H.264-based Smooth Streaming encode operations.


    Usage

    QSV GPU encoding works the same way than CUDA encoding as explained in the Encoder SP1 GPU Encoding white paper. Because the two GPU-based H.264 encoders behave very differently, Expression Encoder 4 Pro SP2 provides a way to control the number of streams independently between CUDA and QSV, which are defaulting to 2 and 8 respectively (see below). As with CUDA, QSV encoding is turned on by default in the Encoder application and turned off in the SDK.

     

     

    As for the SDK, the QSV device is enumerated in the H264EncodeDevices.Devices along with the CUDA devices. A new H264EncodeDevice property, DeviceType of type H264DeviceType, provides a way to differentiate between the two GPU types. H264EncodeDevices.MaxNumberGPUStream keeps controlling the number of streams to be encoded by CUDA, while H264EncodeDevices.MaxNumberIntelHDGraphicsStream controls the streams encoded by QSV.

     

    Multi GPU Encoding

    Both CUDA and QSV encoding can be used together, either on one multi-stream encode or multiple instances of encoder, which may provide even better performance results. While encoding multiple streams on a PC with both technologies, the streams will be allocated in a snake pattern starting with the Intel GPU (1-2-2-1, 1-2-3-3-2-1) from the highest resolution stream down.

    It's worth mentioning that, when used with a discrete GPU, Intel QSV requires the Intel GPU to be enabled as default video adapter in the BIOS and needs to be active and connected to a monitor. Note that LucidLogix Virtu technology, bundled with some Sandy Bridge PCs, enables virtualization of the discrete GPU through the Intel GPU, enabling the usage of both QSV and Cuda and using only one output. More information is available on LucidLogix' website.

     

    Limitations

    Like the CUDA implementation, the QSV supports only a subset of encode settings. For instance, those encoding features are not supported:

    1. Reference B-frames
    2. Adaptive B-frames
    3. Multi pass encoding (2-pass encodes will use software encoding)

    QSV encoding is not supported on XP.

    An active Intel HD Graphics GPU is required to be accessible. This means that:

    1. The PC's motherboard needs to support the Intel Accelerator GPU (most 1155-H67 and 1155-Z68 motherboards do, but all 1155-P67 don't).
    2. The GPU needs to be connected to a screen and be activated.
    3. Accessing the PC via Remote Access, VM, or via a service isn't supported.
    4. If the PC is locked or accessed via Remote Desktop, the next encode operation will fail to use the GPU since it will not be available.

    As with CUDA, QSV encoding is an approximation of what the software-only based encoding can provide. Output quality differences, especially at low bitrates should be expected. Because of this, we recommend using the software H.264 encoder if highest quality results are a priority over higher performance.


    Recommendations

    The integrated Intel Accelerator 3000 GPU, found in high-end mobile CPUs and in the K line of 2nd generation i5 and i7 based desktops as well as on some Xeon and i3 CPUs, is highly recommended. See the Intel website for more details.

    Because memory is shared, we highly recommend having a minimum of 4 GB for single stream encoding and 8 GB or more for Smooth Streaming and/or parallel encoding. Running out of system memory will greatly affect performance.

    It is highly recommended to install the very latest drivers directly from the Intel website to ensure best stability and reliability.

    While the QSV encoding can take a large load of concurrent streams, it is worth noting that a blend of hardware and software encoding will likely result in better performance in most Smooth Streaming cases.


    Known Issues

    A few issues were found in the recent sets of Intel drivers currently available. While all of them have been investigated and resolved, some of the fixes didn't make it into the latest drivers, but will be available in the next driver version (ETA early 2012). Here is the short list:

    1. When using either Intel's driver 8.15.10.2361 or 8.15.10.2509, about 5% of H.264 Smooth Streaming encodes using QSV will hang at the start of the encode or may contain a corrupted stream. This issue was fixed in the driver 8.15.10.2559.
    2. When using Intel's driver 8.15.10.2361 and encoding to QVBR in H.264 Main or High profile using QSV, output will be corrupted. The issue was fixed in the driver 8.15.10.2509.
    3. Windows 8 Beta Users: Intel's current Windows 8 drivers do not yet support QSV, but will be in the future.


    Other GPU Acceleration Technologies

    OpenCL and DirectCompute technologies were evaluated but deemed not ready for integration in Expression Encoder 4 Pro SP2. We are planning to continue monitoring them and investigating potential integration in the future.

  • Expression Encoder

    Expression Encoder 4 SP1 released!

    • 7 Comments

    Today we have released a service pack for Expression Encoder 4 that includes some new features and a bunch of bug fixes.  Here is a list of the new features we have added:

     

    • GPU encoding - If you have an NVIDIA CUDA-accelerated GPU board in your system, you can now take advantage of the additional processors to speed up encoding time or squeeze more live streams into your broadcasts.  Check out Eric Juteau's white paper for all the details.
    • Screen capture as a live source - Now you can select the screen as a device in Live projects to stream or archive.  
    • Live templates - Before if you wanted to use the Expression Encoder templates, you needed to hand edit the template to point to your live source.  Now you can generate the template directly from the Live project and we will hook up all the links.  The workflow is slightly different than on-demand templates.  Since these templates usually need to be live before you start broadcasting, you will need to generate the files manually beforehand.  Once you have selected your output type, the Generate button will enable on the Templates panel where you can manually create the files or upload them to a WebDAV enabled server.  If the panel doesn't appear after upgrade, you can find it on the Windows menu.
    • Live Push/Pull - Now you can broadcast and publish to a Windows Media Services publish point at the same time.
    • Improved De-interlacing Options - We have added a new de-interlacing option called 'Selective Blend' which provides a higher quality picture without the high CPU requirements of Pixel Adaptive.  We have also exposed this and the other de-interlacing options in live.
    • Import script commands - Both in live (no timing) and on-demand, you can now import multiple captioning formats (ISMT, DFXP, SRT, XML, SAMI, SUB, TXT) to the Script Command panel.  This allows you to pre-propagate your captions in live from a script or do some basic editing of your scripts before encoding.  If you do not have a caption file for you encode or broadcast, you can now easily create a 'return-delimited' TXT file with your captions to import in either project type as well.
    • DRM Content Key - If you PlayReady license server supports Content Key encryption, we now allow you to specify this key instead of a Key Seed to enable individual keys per item.
    • HE-AAC - We have added both Version 1 and Version 2 of the HE-AAC codec to allow encoding for supported devices.
    • New Windows Phone 7 presets - Now that the WIndows Phone 7 is out (they rock!), we have created presets to enable direct playback (WMV, MP4) or creating video to use in a Smooth Streaming application using the Silverlight Media Framework phone template.

     

    Check it out and let us know what you think!  Thanks

     

    Jamie

     

  • Expression Encoder

    Expression Encoder Customer Panel

    • 7 Comments

    Now that Expression Encoder 2 has been released, the team is hard at work on the next version of the product.
    We want to be as responsive to community feedback as possible, and would like to set up a panel of customers with whom we can have ongoing conversations.

    What is the Customer Panel?

    The Customer Panel is a way for us to build strong relationships with users of our product. We'll use it as a way to understand your needs, workflows as well as how you use the product. We'll also use it to float future feature ideas and get feedback on them

    What is the time requirement?

    The Customer Panel is an ongoing project. The overall impact should be minimal and if at any point you no longer want to participate, just tell us. Typically we'll aim to reach out the Panel every couple of months or so. There may some times when we reach out more frequently.

    How is this different to a Technology Adoption Program (TAP)?

    TAPs are for specific releases and focus on getting you pre-releases of the software to play with. We'll use the same framework for the Customer Panel, but it is longer lived and goes beyond a particular release. This is an opportunity to have lasting impact on product direction.

    OK sign me up!

    If you want to take part, please send me an email by clicking here.

  • Expression Encoder

    Microsoft® Expression® Encoder 3 QFE Released

    • 7 Comments

    A QFE has been released for Expression Encoder v3. The download can be found here:

    http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=3fa77346-6838-4963-9561-ad6ea7b62fbb

     The QFE contains a significant number of fixes and enhancements including:

    ·         The Audio panel now appears when the user selects two or more media files in the Media Content panel.

    ·         You can now read or write to MP4 files of 4 GB or greater size.

    ·         Audio recordings created using certain USB microphones no longer contain distortion.

    ·         You can successfully encode to MP4 CBR when the bitrate is set to 4.

    ·         Substantial drops in playback bit rates no longer occur during CPU spikes while playing smooth streaming content.

    ·         Smooth Streaming content no longer stutters after 10 or more minutes of full-screen playback in some scenarios.

    ·         Playback of Smooth Streaming content encoded with the VC1 Smooth Streaming 720P VBR preset has been improved.

    ·         You no longer receive an error when repeatedly editing a Silverlight template in Expression Blend 3 using the Edit the template in Expression Blend command.

    ·         You no longer receive an error when playing back Smooth Streaming content from a server that is different from the one where the Silverlight template resides.

    ·         Performance has been improved in the Black Glass template.

    ·         In Live Encoding mode, you can now publish to a publishing point that requires authentication.

    ·         Expression Encoder now includes support for AVC1 files.

    ·         You can now compile the PowerShell code sample from the Expression Encoder SDK when working in Windows 7.

    ·         Running Expression Encoder as a SYSTEM level service no longer causes an exception.

    ·         The Silverlight player no longer crashes when you load a file containing unsupported East Asian characters. You will receive an error message, however, if the player does not support the characters.

    ·         You will now be able to select Adaptive GOP and Closed GOP in the VC-1 Settings options when you have chosen VC-1 Main as your video codec.

    ·         Expression Encoder will now use its native MP4 codec to decode MP4 files, instead of using QuickTime.

    ·         Fixes have been made to better support importing and editing Smooth Streaming files.

    ·         The Expression Encoder Timeline will now display the proper length of imported AVCHD files.

    ·         Playlists and chapters now correctly display when performing offline playback.

    ·         Imported WTV files now play back correctly.

    ·         Seeking has been improved during playback of Smooth Streaming files.

    ·         If you choose the VC-1 Simple profile for encoding, the bitrate in the Video category will now correctly switch to one is valid for the Simple profile.

  • Expression Encoder

    Using the XBox360 Preset to Encode HD Content

    • 6 Comments

    To allow the encoded files to playback seamlessly in most environments, including when streamed on a wireless network, the XBox 360 preset uses a bandwidth of 4Mbps while preserving the video frame size of the original file. This is fine for standard definition content however will produce mediocre output for 720p sources and will be even worse for 1080p content. Because of that, I would advise tweaking the video bitrate to your specific needs. So, if network speed isn't an issue, I would personally recommend changing the video bitrate to something like 6-7Mbps for 720p content or 8-10Mbps for 1080p content, which is still within the Xbox360 supported limits for VC-1 decoding.

     

    Finally, it's important to note that the Advanced VC-1 video profile is not supported by the Xbox360 (nor the PS3 through Media Connect), so it's probably best to leave it as "VC-1 Main", like the XBox 360 Preset does.

  • Expression Encoder

    Hello from Mix 08

    • 6 Comments

    Charles and I have arrived here at The Venetian ready for Mix08.

    Our session is currently blacklisted but should appear here shortly:

    http://sessions.visitmix.com/

    If you are attending and want to meet up with us, do send email.

    Need to test that image uploading is working so here is a view from my window:

    IMAGE_332
  • Expression Encoder

    New Encoder build available (1651)

    • 6 Comments

    We have updated our build on the download center to resolve a couple of issues related to the screen capture application.  Some machines with Expresion Encoder 4 Pro were incorrectly limiting the screen capture time limit and we had an issue with XESC files being played back in the Windows Media Player on 64-bit Vista and Windows Server 2008.  

    In order to upgrade, simply grab the newest version of the free Encoder (available here) and install over the current one. The version number will go from 4.0.1639.0 to 4.0.1651.0. Note that there is no need to uninstall the older version, setup will upgrade it for you. Please also take note that those international versions already have the fixes mentioned above, so there is no need to upgrade them.

  • Page 1 of 2 (46 items) 12