←Select platform

View Property

Summary
Gets or sets the view to use when loading VFF (Sun TAAC Bitmap) images.
Syntax
C#
Objective-C
C++/CLI
Java
Python
public CodecsVffView View { get; set; } 
@property (nonatomic, assign) LTCodecsVffView view; 
public CodecsVffView getView() 
public void setView(CodecsVffView view) 
public: 
property CodecsVffView View { 
   CodecsVffView get(); 
   void set (    CodecsVffView ); 
} 
View # get and set (CodecsVffLoadOptions) 

Property Value

The view to use when loading VFF (Sun TAAC Bitmap) images.

Example
C#
Java
using Leadtools; 
using Leadtools.Codecs; 
 
using Leadtools.ImageProcessing.Core; 
using Leadtools.Pdf; 
 
public void CodecsVffLoadOptionsExample() 
{ 
   RasterCodecs codecs = new RasterCodecs(); 
 
   string srcFileName = Path.Combine(LEAD_VARS.ImagesDir, "Image1.vff"); 
   string dstFileName1 = Path.Combine(LEAD_VARS.ImagesDir, "Image1_Vff_UpToDown.bmp"); 
   string dstFileName2 = Path.Combine(LEAD_VARS.ImagesDir, "Image1_Vff_LeftToRight.bmp"); 
 
   // Set the load options to use up to down along the X-Axis 
   // CodecsVffOptions & CodecsVffLoadOptions reference 
   codecs.Options.Vff.Load.View = CodecsVffView.UpToDown; 
 
   // Load the source file 
   using (RasterImage image = codecs.Load(srcFileName)) 
   { 
      // Save the image as BMP 
      codecs.Save(image, dstFileName1, RasterImageFormat.Bmp, 24); 
   } 
 
   // Now, set the load options to use left to right along the Y-Axis 
   codecs.Options.Vff.Load.View = CodecsVffView.LeftToRight; 
 
   // Re-load the source file 
   using (RasterImage image = codecs.Load(srcFileName)) 
   { 
      // Save the image as BMP 
      codecs.Save(image, dstFileName2, RasterImageFormat.Bmp, 24); 
   } 
 
   // Clean up 
   codecs.Dispose(); 
} 
 
static class LEAD_VARS 
{ 
   public const string ImagesDir = @"C:\LEADTOOLS23\Resources\Images"; 
} 
 
import java.io.File; 
import java.io.IOException; 
import java.net.URI; 
import java.net.URISyntaxException; 
import java.nio.file.Paths; 
 
import org.junit.*; 
import org.junit.runner.JUnitCore; 
import org.junit.runner.Result; 
import org.junit.runner.notification.Failure; 
import static org.junit.Assert.*; 
 
import leadtools.*; 
import leadtools.codecs.*; 
import leadtools.imageprocessing.core.MinMaxBitsCommand; 
 
 
public void CodecsVffLoadOptionsExample(){ 
   final String LEAD_VARS_IMAGES_DIR ="C:\\LEADTOOLS23\\Resources\\Images"; 
   RasterCodecs codecs = new RasterCodecs(); 
   String srcFileName = combine(LEAD_VARS_IMAGES_DIR, "aortas_vehicle_crop.vff"); 
   String dstFileName1 = combine(LEAD_VARS_IMAGES_DIR, 
   "Image1_Vff_UpToDown.bmp"); 
   String dstFileName2 = combine(LEAD_VARS_IMAGES_DIR, 
   "Image1_Vff_LeftToRight.bmp"); 
 
   // Set the load options to use up to down along the X-Axis 
   // CodecsVffOptions & CodecsVffLoadOptions reference 
   codecs.getOptions().getVff().getLoad().setView(CodecsVffView.VFF_VIEW_UPTODOWN); 
 
   // Load the source file 
   RasterImage image = codecs.load(srcFileName); 
   // Save the image as BMP 
   codecs.save(image, dstFileName1, RasterImageFormat.BMP, 24); 
 
   assertTrue("File unsuccessfully saved to " + dstFileName1, (new 
   File(dstFileName1)).exists()); 
   System.out.printf("File successfully saved to %s%n", dstFileName1); 
 
   image = null; 
 
   // Now, set the load options to use left to right along the Y-Axis 
   codecs.getOptions().getVff().getLoad().setView(CodecsVffView.VFF_VIEW_LEFTTORIGHT); 
 
   // Re-load the source file 
   image = codecs.load(srcFileName); 
 
   // Save the image as BMP 
   codecs.save(image, dstFileName2, RasterImageFormat.BMP, 24); 
 
   assertTrue("File unsuccessfully saved to " + dstFileName2, (new 
   File(dstFileName2)).exists()); 
   System.out.printf("File successfully saved to %s%n", dstFileName2); 
 
   // Clean up 
   image.dispose();; 
   codecs.dispose(); 
} 
Requirements

Target Platforms

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

Leadtools.Codecs Assembly

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