pub(crate) type GPUOrigin2DDict = GPUOrigin2DDict;
Aliased Type§
struct GPUOrigin2DDict {
pub x: u32,
pub y: u32,
}
Fields§
§x: u32
§y: u32
Implementations
Source§impl GPUOrigin2DDict
impl GPUOrigin2DDict
pub fn empty() -> GPUOrigin2DDict
pub fn new( cx: JSContext, val: Handle<'_, Value>, ) -> Result<ConversionResult<GPUOrigin2DDict>, ()>
Source§impl GPUOrigin2DDict
impl GPUOrigin2DDict
pub unsafe fn to_jsobject( &self, cx: *mut JSContext, obj: MutableHandle<'_, *mut JSObject>, )
Trait Implementations
Source§impl Default for GPUOrigin2DDict
impl Default for GPUOrigin2DDict
Source§fn default() -> GPUOrigin2DDict
fn default() -> GPUOrigin2DDict
Returns the “default value” for a type. Read more
Source§impl FromJSValConvertible for GPUOrigin2DDict
impl FromJSValConvertible for GPUOrigin2DDict
Source§unsafe fn from_jsval(
cx: *mut JSContext,
value: Handle<'_, Value>,
_option: (),
) -> Result<ConversionResult<GPUOrigin2DDict>, ()>
unsafe fn from_jsval( cx: *mut JSContext, value: Handle<'_, Value>, _option: (), ) -> Result<ConversionResult<GPUOrigin2DDict>, ()>
Convert
val
to type Self
.
Optional configuration of type T
can be passed as the option
argument.
If it returns Err(())
, a JSAPI exception is pending.
If it returns Ok(Failure(reason))
, there is no pending JSAPI exception.