Class MPSMatrixCopyToImage

  • All Implemented Interfaces:
    NSCoding, NSCopying, NSSecureCoding, NSObject

    public class MPSMatrixCopyToImage
    extends MPSKernel
    MPSMatrixCopyToImage The MPSMatrixCopyToImage copies matrix data to a MPSImage. The operation is the reverse of MPSImageCopyToMatrix.
    • Constructor Detail

      • MPSMatrixCopyToImage

        protected MPSMatrixCopyToImage​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • allocWithZone

        public static java.lang.Object allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(java.lang.Object aTarget,
                                                                                 org.moe.natj.objc.SEL aSelector,
                                                                                 java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        public static org.moe.natj.objc.Class classForKeyedUnarchiver()
      • dataLayout

        public long dataLayout()
        [@property] dataLayout The data layout to use Returns the data layout. When copying from a MPSMatrix to a MPSImage, this describes the order in which the image values are to be stored in the buffer associated with the MPSMatrix. Default: MPSDataLayoutFeatureChannelsxHeightxWidth
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • encodeToCommandBufferSourceMatrixDestinationImage

        public void encodeToCommandBufferSourceMatrixDestinationImage​(MTLCommandBuffer commandBuffer,
                                                                      MPSMatrix sourceMatrix,
                                                                      MPSImage destinationImage)
        Encode a kernel that copies a MPSMatrix to a MPSImage into a command buffer using a MTLComputeCommandEncoder. The kernel copies feature channels from sourceMatrix to the destinationImage. The kernel will not begin to execute until after the command buffer has been enqueued and committed. NOTE: The sourceMatrix.dataType must match the feature channel data type in destinationImage.
        Parameters:
        commandBuffer - A valid MTLCommandBuffer.
        sourceMatrix - A valid MPSMatrix or MPSTemporaryMatrix object describing the source matrix.
        destinationImage - A valid MPSImage describing the image to copy to.
      • hash_static

        public static long hash_static()
      • initWithCoderDevice

        public MPSMatrixCopyToImage initWithCoderDevice​(NSCoder aDecoder,
                                                        java.lang.Object device)
        NSSecureCoding compatability While the standard NSSecureCoding/NSCoding method -initWithCoder: should work, since the file can't know which device your data is allocated on, we have to guess and may guess incorrectly. To avoid that problem, use initWithCoder:device instead.
        Overrides:
        initWithCoderDevice in class MPSKernel
        Parameters:
        aDecoder - The NSCoder subclass with your serialized MPSKernel
        device - The MTLDevice on which to make the MPSKernel
        Returns:
        A new MPSKernel object, or nil if failure.
      • initWithDevice

        public MPSMatrixCopyToImage initWithDevice​(java.lang.Object device)
        Description copied from class: MPSKernel
        Standard init with default properties per filter type
        Overrides:
        initWithDevice in class MPSKernel
        Parameters:
        device - The device that the filter will be used on. May not be NULL.
        Returns:
        a pointer to the newly initialized object. This will fail, returning nil if the device is not supported. Devices must be MTLFeatureSet_iOS_GPUFamily2_v1 or later.
      • initWithDeviceDataLayout

        public MPSMatrixCopyToImage initWithDeviceDataLayout​(MTLDevice device,
                                                             long dataLayout)
        Initialize a MPSMatrixCopyToImage object on a device
        Parameters:
        device - The device the kernel will run on
        dataLayout - The data layout
        Returns:
        A valid MPSMatrixCopyToImage object or nil, if failure.
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • keyPathsForValuesAffectingValueForKey

        public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(java.lang.String key)
      • new_objc

        public static java.lang.Object new_objc()
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setSourceMatrixBatchIndex

        public void setSourceMatrixBatchIndex​(long value)
        [@property] sourceMatrixBatchIndex The index of the source matrix in the batch. This property is modifiable and defaults to 0 at initialization time.
      • setSourceMatrixOrigin

        public void setSourceMatrixOrigin​(MTLOrigin value)
        [@property] sourceMatrixOrigin The origin, relative to [0, 0] in the source matrix. This property is modifiable and defaults to [0, 0] at initialization time. If a different origin is desired then this should be modified prior to encoding the kernel. The z value must be 0.
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • sourceMatrixBatchIndex

        public long sourceMatrixBatchIndex()
        [@property] sourceMatrixBatchIndex The index of the source matrix in the batch. This property is modifiable and defaults to 0 at initialization time.
      • sourceMatrixOrigin

        public MTLOrigin sourceMatrixOrigin()
        [@property] sourceMatrixOrigin The origin, relative to [0, 0] in the source matrix. This property is modifiable and defaults to [0, 0] at initialization time. If a different origin is desired then this should be modified prior to encoding the kernel. The z value must be 0.
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • supportsSecureCoding

        public static boolean supportsSecureCoding()
      • _supportsSecureCoding

        public boolean _supportsSecureCoding()
        Description copied from interface: NSSecureCoding
        This property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.
        Specified by:
        _supportsSecureCoding in interface NSSecureCoding
        Overrides:
        _supportsSecureCoding in class MPSKernel
      • version_static

        public static long version_static()