<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>pigshape</author_name>
  <author_url>https://blog.hatena.ne.jp/pigshape/</author_url>
  <blog_title>littlewing</blog_title>
  <blog_url>https://littlewing.hatenablog.com/</blog_url>
  <categories>
    <anon>unity</anon>
  </categories>
  <description>UnityでGameObjectの原点ではなく、指定した点を中心にScaleを変更する方法。 rotationは原点と回転軸を指定して回転できる RotateAround があるけど、Scaleには無いので作った。 タッチパネルの2本指操作や、両手VRコントローラで拡大させる時に、拡大の中心を動的に変更できて便利。 /// pivot を中心に、target のScaleを変化させる public void ScaleAround(GameObject target, Vector3 pivot, Vector3 newScale) { Vector3 targetPos = target.t…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Flittlewing.hatenablog.com%2Fentry%2F2020%2F10%2F16%2F010410&quot; title=&quot;Unityで特定の点を中心にScaleを変化させる (ScaleAround) - littlewing&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2020-10-16 01:04:10</published>
  <title>Unityで特定の点を中心にScaleを変化させる (ScaleAround)</title>
  <type>rich</type>
  <url>https://littlewing.hatenablog.com/entry/2020/10/16/010410</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
