Package com.leia.sdk.views
Class InterlacedSurfaceViewConfigAccessor
- java.lang.Object
-
- com.leia.sdk.views.InterlacedSurfaceViewConfigAccessor
-
- All Implemented Interfaces:
AutoCloseable
public class InterlacedSurfaceViewConfigAccessor extends Object implements AutoCloseable
InterlacedSurfaceViewConfigAccessor ensures correct access toInterlacedSurfaceViewConfig
by holding a lock and validates the input values.It must be closed after use via
close()
. Keep the use of it short. Preferably, use the try-with-resources statement in Java or Kotlin's io.use inline function.
-
-
Constructor Summary
Constructors Constructor Description InterlacedSurfaceViewConfigAccessor(InterlacedView view, InterlacedSurfaceViewConfig config, Lock lock)
InterlacedSurfaceViewConfigAccessor owns the lock.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Unlocks the lock.void
enableDoNCorrection(boolean enable)
void
enablePhaseCorrection(boolean disable)
void
enableUserMatrix(boolean enabled)
float
getACTGammaX()
float
getACTGammaY()
float
getACTGammaZ()
float
getAlpha()
float
getBaselineScaling()
CalibrationPattern
getCalibrationPattern()
float
getConvergenceDistance()
boolean
getIsGuiVisible()
boolean
getIsHorizontalViewLayout()
float[]
getLocalMatrix()
int
getNumTilesX()
int
getNumTilesY()
float
getPhc()
float
getReconvergenceAmount()
ReconvergenceZoomType
getReconvergenceZoom()
ScaleType
getScaleType()
int
getSingleViewIndex()
boolean
getSingleViewMode()
boolean
getSourceMediaIsVideo()
float
getSourceMediaScaleX()
float
getSourceMediaScaleY()
Vector2i
getSourceSize()
boolean
getSupportsTransparency()
TileLayout
getTileLayout()
boolean
getUseAtlasForViews()
Matrix
getUserMatrix()
void
invertPhaseCorrection(boolean invert)
boolean
isUserMatrixEnabled()
void
setActCoef(float actCoef)
void
setACTGamma(float actGammaX, float actGammaY, float actGammaZ)
void
setAlpha(float alpha)
void
setBaselineScaling(float baselineScaling)
void
setCalibrationPattern(CalibrationPattern calibrationPattern)
void
setConvergenceDistance(float convergenceDistance)
void
setDOverN(float dOverN)
void
setIsGuiVisible(boolean isGuiVisible)
void
setIsHorizontalViewLayout(boolean isHorizontalViewLayout)
void
setLocalMatrix(float[] localTransform)
void
setN(float n)
void
setNumTiles(int numTilesX, int numTilesY)
void
setPhc(float phc)
void
setReconvergenceAmount(float reconvergenceAmount)
void
setReconvergenceZoom(ReconvergenceZoomType reconvergenceZoom)
void
setScaleType(ScaleType scaleType)
void
setSingleViewIndex(int singleViewIndex)
void
setSingleViewMode(boolean singleViewMode)
void
setSourceMediaIsVideo(boolean isVideo)
void
setSourceMediaScaleX(float scaleX)
void
setSourceMediaScaleY(float scaleY)
void
setSourceSize(int x, int y)
void
setSourceSize(Vector2i size)
void
setTileLayout(TileLayout tileLayout)
void
setUseAtlasForViews(boolean useAtlasForViews)
void
setUserMatrix(Matrix userMatrix)
void
setZonePlate(float posX, float posY, float scaleX, float scaleY)
void
setZonePlate(float posX, float posY, float scaleX, float scaleY, float overrideSupportCirclePhase)
-
-
-
Constructor Detail
-
InterlacedSurfaceViewConfigAccessor
public InterlacedSurfaceViewConfigAccessor(InterlacedView view, InterlacedSurfaceViewConfig config, Lock lock)
InterlacedSurfaceViewConfigAccessor owns the lock.
-
-
Method Detail
-
close
public void close()
Unlocks the lock. InterlacedSurfaceViewConfigAccessor is not valid to be used after it.- Specified by:
close
in interfaceAutoCloseable
-
getSourceSize
public Vector2i getSourceSize()
-
setSourceSize
public void setSourceSize(int x, int y)
-
setSourceSize
public void setSourceSize(Vector2i size)
- Parameters:
size
- if null, source size is set toInterlacedSurfaceViewConfig.LENGTH_UNSET
.
-
getSourceMediaIsVideo
public boolean getSourceMediaIsVideo()
-
setSourceMediaIsVideo
public void setSourceMediaIsVideo(boolean isVideo)
-
getSourceMediaScaleX
public float getSourceMediaScaleX()
-
setSourceMediaScaleX
public void setSourceMediaScaleX(float scaleX)
-
getSourceMediaScaleY
public float getSourceMediaScaleY()
-
setSourceMediaScaleY
public void setSourceMediaScaleY(float scaleY)
-
getReconvergenceAmount
public float getReconvergenceAmount()
-
setReconvergenceAmount
public void setReconvergenceAmount(float reconvergenceAmount)
-
getReconvergenceZoom
public ReconvergenceZoomType getReconvergenceZoom()
-
setReconvergenceZoom
public void setReconvergenceZoom(ReconvergenceZoomType reconvergenceZoom)
-
getIsHorizontalViewLayout
public boolean getIsHorizontalViewLayout()
-
setIsHorizontalViewLayout
public void setIsHorizontalViewLayout(boolean isHorizontalViewLayout)
-
getScaleType
public ScaleType getScaleType()
-
setScaleType
public void setScaleType(ScaleType scaleType)
-
getSingleViewMode
public boolean getSingleViewMode()
-
setSingleViewMode
public void setSingleViewMode(boolean singleViewMode)
-
getSingleViewIndex
public int getSingleViewIndex()
-
setSingleViewIndex
public void setSingleViewIndex(int singleViewIndex)
-
getAlpha
public float getAlpha()
-
setAlpha
public void setAlpha(float alpha)
SetInterlacedSurfaceViewConfig.alpha
. InterlacedSurfaceView must be configured with transparency support to accept alpha values less than 1.
-
getLocalMatrix
public float[] getLocalMatrix()
-
setLocalMatrix
public void setLocalMatrix(float[] localTransform)
-
isUserMatrixEnabled
public boolean isUserMatrixEnabled()
-
enableUserMatrix
public void enableUserMatrix(boolean enabled)
-
getUserMatrix
public Matrix getUserMatrix()
-
setUserMatrix
public void setUserMatrix(Matrix userMatrix)
-
getCalibrationPattern
public CalibrationPattern getCalibrationPattern()
-
setCalibrationPattern
public void setCalibrationPattern(CalibrationPattern calibrationPattern)
-
setZonePlate
public void setZonePlate(float posX, float posY, float scaleX, float scaleY, float overrideSupportCirclePhase)
-
setZonePlate
public void setZonePlate(float posX, float posY, float scaleX, float scaleY)
-
getNumTilesX
public int getNumTilesX()
-
getNumTilesY
public int getNumTilesY()
-
setNumTiles
public void setNumTiles(int numTilesX, int numTilesY)
-
setTileLayout
public void setTileLayout(TileLayout tileLayout)
-
getTileLayout
public TileLayout getTileLayout()
-
getACTGammaX
public float getACTGammaX()
-
getACTGammaY
public float getACTGammaY()
-
getACTGammaZ
public float getACTGammaZ()
-
setACTGamma
public void setACTGamma(float actGammaX, float actGammaY, float actGammaZ)
-
getIsGuiVisible
public boolean getIsGuiVisible()
-
setIsGuiVisible
public void setIsGuiVisible(boolean isGuiVisible)
-
getBaselineScaling
public float getBaselineScaling()
-
setBaselineScaling
public void setBaselineScaling(float baselineScaling)
-
getConvergenceDistance
public float getConvergenceDistance()
-
setConvergenceDistance
public void setConvergenceDistance(float convergenceDistance)
-
getPhc
public float getPhc()
-
setPhc
public void setPhc(float phc)
-
setDOverN
public void setDOverN(float dOverN)
-
setN
public void setN(float n)
-
setActCoef
public void setActCoef(float actCoef)
-
enablePhaseCorrection
public void enablePhaseCorrection(boolean disable)
-
invertPhaseCorrection
public void invertPhaseCorrection(boolean invert)
-
enableDoNCorrection
public void enableDoNCorrection(boolean enable)
-
getUseAtlasForViews
public boolean getUseAtlasForViews()
-
setUseAtlasForViews
public void setUseAtlasForViews(boolean useAtlasForViews)
-
getSupportsTransparency
public boolean getSupportsTransparency()
-
-