FrameHeight Property

Summary
Gets the frame height value in lines (525 for a frame rate of 60 Hz or 625 for 50 Hz).
Syntax
C#
C++/CLI
public int FrameHeight { get; } 
public: 
property int FrameHeight { 
   int get(); 
} 

Property Value

A value representing the frame height in lines.

Remarks

Gets the frame height value in lines (525 for a frame rate of 60 Hz or 625 for 50 Hz).

Example
C#
using Leadtools; 
using Leadtools.Multimedia; 
using LeadtoolsMultimediaExamples.Fixtures; 
 
 
public bool _result = false; 
public ConvertCtrlForm _form = new ConvertCtrlForm(); 
 
public void UseDVDSourceExample() 
{ 
   // reference the convert control 
   ConvertCtrl convertctrl = _form.ConvertCtrl; 
 
   // input and output files 
   string inFile = Path.Combine(LEAD_VARS.MediaDir, @"VIDEO_TS\VIDEO_TS.IFO"); 
   string outFile = Path.Combine(LEAD_VARS.MediaDir, "ConvertCtrl_UseDVDSourceExample.avi"); 
 
   try 
   { 
      DVDSource dvdSource; 
      DVDTitle title; 
      DVDChapter chapter; 
      DVDSubpictureStream subpictureStream; 
      DVDAudioStream audioStream; 
      DVDVideoCompression comp; 
      DVDAudioAppMode appMode; 
      DVDAudioFormat audFormat; 
      DVDAudioLangExt audLangExt; 
      DVDSubpictureCoding subPicCoding; 
      DVDSubpictureLangExt subPicLangExt; 
      DVDSubpictureType subPicType; 
 
      int i; 
      int lCount; 
      long lVal; 
      bool bVal; 
      double dVal; 
      string strPlayList; 
 
      // force to use the DVD source 
      convertctrl.UseDVDSource = true; 
 
      // set the input and output files 
      convertctrl.SourceFile = inFile; 
      convertctrl.TargetFile = outFile; 
 
      // reference the DVDSource object 
      dvdSource = (DVDSource)convertctrl.GetSubObject(ConvertObject.SourceFilter); 
 
      //  Select the main title on the disc 
      if ((dvdSource.Selected != DVDSourceSelectedState.MainSelected)) 
         dvdSource.Selected = DVDSourceSelectedState.MainSelected; 
 
      //  Get the disc duration 
      dVal = dvdSource.TotalDuration; 
      //  Get the selected title duration 
      dVal = dvdSource.SelectedDuration; 
 
      //  Get the play list settings 
      strPlayList = dvdSource.PlayList; 
 
      //  You can save this to a file and restore the settings later 
      //  Restore the playlist settings 
      dvdSource.PlayList = strPlayList; 
 
      //  Get the title count in the disc 
      lCount = dvdSource.TitleCount; 
 
      for (i = 0; (i <= (lCount - 1)); i++) 
      { 
         //  Get the title interface 
         title = dvdSource.GetTitle(i); 
 
         //  Get the X and Y aspects 
         lVal = title.AspectX; 
         lVal = title.AspectY; 
 
         //  Get if the title is a film mode or camera mode 
         bVal = title.IsFilmMode; 
 
         //  Get if there is a user data in line 21, field 1 
         bVal = title.Line21Field1InGOP; 
 
         //  Get if there is a user data in line 21, field 2 
         bVal = title.Line21Field2InGOP; 
 
         //  Get the compression 
         comp = title.Compression; 
 
         //  Get the X source resolution 
         lVal = title.SourceResolutionX; 
 
         //  Get the Y source resolution 
         lVal = title.SourceResolutionY; 
 
         //  Get the Frame Height 
         lVal = title.FrameHeight; 
 
         //  Get the Frame Rate 
         lVal = title.FrameRate; 
 
         //  Get if the source is a letter boxed 
         bVal = title.IsSourceLetterboxed; 
 
         //  Get if the picture can be shown as letterbox 
         bVal = title.LetterboxPermitted; 
 
         //  Get if the picture can be shown as pan-scan 
         bVal = title.PanscanPermitted; 
 
         //  Get the title duration 
         dVal = title.TotalDuration; 
 
         //  Select all title chapters 
         if ((title.Selected != DVDTitleSelectedState.Selected)) 
            title.Selected = DVDTitleSelectedState.Selected; 
 
         //  Get the selected chapter duration 
         dVal = title.SelectedDuration; 
 
         //  Get the audio stream count in the title 
         if ((title.AudioStreamCount > 0)) 
         { 
            //  Select the first audio stream 
            if ((title.SelectedAudioStream == -1)) 
               title.SelectedAudioStream = 0; 
 
            //  Get the first audio stream 
            audioStream = title.GetAudioStream(0); 
 
            //  Select the audio stream 
            if ((audioStream.Selected == false)) 
               audioStream.Selected = true; 
 
            //  Get the application mode 
            appMode = audioStream.AppMode; 
 
            //  Get the application mode data 
            lVal = audioStream.AppModeData; 
 
            //  Get the auido format 
            audFormat = audioStream.AudioFormat; 
 
            //  Get the number of channels 
            lVal = audioStream.Channels; 
 
            //  Get the frequency 
            lVal = audioStream.Frequency; 
 
            //  Get the language 
            lVal = audioStream.Language; 
 
            //  Get the language extension 
            audLangExt = audioStream.LanguageExtension; 
 
            //  Get the quantization 
            lVal = audioStream.Quantization; 
 
            if ((title.SubpictureStreamCount > 0)) 
            { 
               //  Select the first subpicture stream 
               if ((title.SelectedSubpictureStream == -1)) 
                  title.SelectedSubpictureStream = 0; 
 
               //  Get the first subpicture stream 
               subpictureStream = title.GetSubpictureStream(0); 
 
               //  Select the subpicture stream 
               if ((subpictureStream.Selected == false)) 
                  subpictureStream.Selected = true; 
 
               //  Get the coding mode 
               subPicCoding = subpictureStream.CodingMode; 
 
               //  Get the langauge 
               lVal = subpictureStream.Language; 
 
               //  Get the language extension 
               subPicLangExt = subpictureStream.LanguageExtension; 
 
               //  Get the type 
               subPicType = subpictureStream.Type; 
            } 
            //  Get the chapter count 
            if ((title.ChapterCount > 0)) 
            { 
               //  Get the first chapter 
               chapter = title.GetChapter(0); 
 
               //  Get the chapter duration 
               dVal = chapter.Duration; 
 
               //  Get if the chapter is selected 
               if ((chapter.Selected == false)) 
                  chapter.Selected = true; 
            } 
         } 
      } 
   } 
   catch (COMException) 
   { 
      _result = false; 
   } 
   catch (Exception) 
   { 
      _result = false; 
   } 
 
   // we'll loop on the state and pump messages for this example. 
   // but you should not need to if running from a Windows Forms application. 
   while (convertctrl.State == ConvertState.Running) 
      Application.DoEvents(); 
} 
 
static class LEAD_VARS 
{ 
   public const string MediaDir = @"C:\LEADTOOLS23\Media"; 
} 
Requirements

Target Platforms

See Also

Reference

DVDTitle Class

DVDTitle Members

Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Multimedia Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.