Trait opencv::bioinspired::TransientAreasSegmentationModule[][src]

pub trait TransientAreasSegmentationModule: AlgorithmTrait + TransientAreasSegmentationModuleConst {
    fn as_raw_mut_TransientAreasSegmentationModule(&mut self) -> *mut c_void;

    fn get_size(&mut self) -> Result<Size> { ... }
fn setup_from_file(
        &mut self,
        segmentation_parameter_file: &str,
        apply_default_setup_on_failure: bool
    ) -> Result<()> { ... }
fn setup_from_storage(
        &mut self,
        fs: &mut FileStorage,
        apply_default_setup_on_failure: bool
    ) -> Result<()> { ... }
fn setup(&mut self, new_parameters: SegmentationParameters) -> Result<()> { ... }
fn get_parameters(&mut self) -> Result<SegmentationParameters> { ... }
fn print_setup(&mut self) -> Result<String> { ... }
fn run(
        &mut self,
        input_to_segment: &dyn ToInputArray,
        channel_index: i32
    ) -> Result<()> { ... }
fn get_segmentation_picture(
        &mut self,
        transient_areas: &mut dyn ToOutputArray
    ) -> Result<()> { ... }
fn clear_all_buffers(&mut self) -> Result<()> { ... } }

Required methods

Provided methods

return the sze of the manage input and output images

try to open an XML segmentation parameters file to adjust current segmentation instance setup

  • if the xml file does not exist, then default setup is applied
  • warning, Exceptions are thrown if read XML file is not valid
Parameters
  • segmentationParameterFile: : the parameters filename
  • applyDefaultSetupOnFailure: : set to true if an error must be thrown on error
C++ default parameters
  • segmentation_parameter_file: “”
  • apply_default_setup_on_failure: true

try to open an XML segmentation parameters file to adjust current segmentation instance setup

  • if the xml file does not exist, then default setup is applied
  • warning, Exceptions are thrown if read XML file is not valid
Parameters
  • fs: : the open Filestorage which contains segmentation parameters
  • applyDefaultSetupOnFailure: : set to true if an error must be thrown on error
C++ default parameters
  • apply_default_setup_on_failure: true

try to open an XML segmentation parameters file to adjust current segmentation instance setup

  • if the xml file does not exist, then default setup is applied
  • warning, Exceptions are thrown if read XML file is not valid
Parameters
  • newParameters: : a parameters structures updated with the new target configuration

return the current parameters setup

parameters setup display method

Returns

a string which contains formatted parameters information

main processing method, get result using methods getSegmentationPicture()

Parameters
  • inputToSegment: : the image to process, it must match the instance buffer size !
  • channelIndex: : the channel to process in case of multichannel images
C++ default parameters
  • channel_index: 0

access function return the last segmentation result: a boolean picture which is resampled between 0 and 255 for a display purpose

cleans all the buffers of the instance

Implementations

allocator

Parameters
  • inputSize: : size of the images input to segment (output will be the same size)

Implementors