<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/rss-style.xsl" type="text/xsl"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	    xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	     xmlns:dc="http://purl.org/dc/elements/1.1/"
	   xmlns:atom="http://www.w3.org/2005/Atom"
	     xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	  xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>
<channel>
	<title>u3d &#8211; Terence Eden’s Blog</title>
	<atom:link href="https://shkspr.mobi/blog/tag/u3d/feed/" rel="self" type="application/rss+xml" />
	<link>https://shkspr.mobi/blog</link>
	<description>Regular nonsense about tech and its effects 🙃</description>
	<lastBuildDate>Mon, 10 Feb 2025 11:46:14 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://shkspr.mobi/blog/wp-content/uploads/2023/07/cropped-avatar-32x32.jpeg</url>
	<title>u3d &#8211; Terence Eden’s Blog</title>
	<link>https://shkspr.mobi/blog</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title><![CDATA[Help! How do I extract 3D objects from PDFs?]]></title>
		<link>https://shkspr.mobi/blog/2016/02/help-how-do-i-extract-3d-objects-from-pdfs/</link>
					<comments>https://shkspr.mobi/blog/2016/02/help-how-do-i-extract-3d-objects-from-pdfs/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Tue, 02 Feb 2016 14:52:03 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[3d]]></category>
		<category><![CDATA[pdf]]></category>
		<category><![CDATA[u3d]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=22382</guid>

					<description><![CDATA[You know how the Democratic People&#039;s Republic of Korea is neither democratic, nor particularly for the people, nor a republic?  Yeah, so it turns out the &#34;Universal 3D&#34; format is pretty far from Universal!  A little backstory... The Europeana Carare Project has some gorgeous 3D scans of ancient monuments and heritage sites.  The only problem is that the 3D files are trapped inside PDFs.  Yup -…]]></description>
										<content:encoded><![CDATA[<p>You know how the Democratic People's Republic of Korea is neither democratic, nor particularly for the people, nor a republic?  Yeah, so it turns out the "Universal 3D" format is pretty far from Universal!</p>

<p>A little backstory... The <a href="https://carare.eu/en/training/3d-and-virtual-reality/">Europeana Carare Project has some gorgeous 3D scans of ancient monuments and heritage sites</a>.  The only problem is that the 3D files are trapped inside PDFs.  Yup - did you know the PDF spec supported 3D models? Me neither.</p>

<p>The only way to view these is with the Official Adobe Viewer (<a href="http://ubuntuhandbook.org/index.php/2014/10/install-adobe-reader-ubuntu-14-10/">install it on Linux following these instructions</a>).</p>

<p>This is what it looks like:</p>

<p></p><div style="width: 620px;" class="wp-video"><video class="wp-video-shortcode" id="video-22382-2" width="620" height="349" preload="metadata" controls="controls"><source type="video/mp4" src="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D_Objects_in_PDF.mp4?_=2"><source type="video/webm" src="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D_Objects_in_PDF.webm?_=2"><source type="video/ogg" src="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D-Objects-in-PDF.ogv?_=2"><a href="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D_Objects_in_PDF.mp4">https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D_Objects_in_PDF.mp4</a></video></div><p></p>

<p>Nifty, right?</p>

<p>So, <a href="http://superuser.com/questions/758379/extract-u3d-object-from-pdf/1034179">how do we extract that 3D file</a>?</p>

<ol>
    <li><a href="http://blog.didierstevens.com/programs/pdf-tools/">Download and install the Pythong PDF Parser</a></li>
    <li>Search for the 3D object:<br><code>./pdf-parser.py -t /3D input.pdf </code></li>
    <li>You'll get a response like this:<br><pre lang="bash">obj 48 0
 Type: /3D
 Referencing: 58 0 R, 59 0 R
 Contains stream

  &lt;&lt;
    /AN 58 0 R
    /Length 6066066
    /Subtype /PRC
    /Type /3D
    /VA 59 0 R
  &gt;&gt;
</pre></li>
    <li>The Object ID (in this case 48) is what we need to extract.</li>
    <li><code>./pdf-parser.py -o 48 -d output.u3d input.pdf</code></li>
</ol>

<p>You can <a href="https://shkspr.mobi/blog/wp-content/uploads/2016/02/output.u3d.zip" rel="">download the U3D file</a>.</p>

<p>Unfortunately, <em>nothing</em> opens it.  I've tried <a href="http://sourceforge.net/p/meshlab/discussion/499532/thread/da02c8bc/">Meshlab</a>, <a href="https://www.blender.org/forum/viewtopic.php?t=17757">Blender</a>, <a href="https://github.com/FreeCAD/FreeCAD">FreeCAD</a>, <a href="http://3doc.i3dconverter.com/">i3D Converter</a>, online service <a href="https://web.archive.org/web/20160203075714/https://www.babel3d.com/">Babel3D</a>, and even Unity 3D on a Windows box.</p>

<p>Nothing!  Not a single application would recognise it - let alone convert it.</p>

<p>There is a <a href="https://github.com/ningfei/u3d">U3D library on GitHub</a> - but I'm not skilled enough to integrate it into anything.</p>

<p>I've found <a href="https://web.archive.org/web/20161121095041/https://play.google.com/store/apps/details?id=com.afanche.android.U3DViewRS">an Android app which claims to convert U3D files</a> - but it has no downloads, no reviews, and costs £6!</p>

<p>So, gentle reader, if you know of a way to extract and view 3D models from PDFs, <strong>please</strong> let me know!</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=22382&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2016/02/help-how-do-i-extract-3d-objects-from-pdfs/feed/</wfw:commentRss>
			<slash:comments>23</slash:comments>
		
		<enclosure url="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D_Objects_in_PDF.mp4" length="4109537" type="video/mp4" />
<enclosure url="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D_Objects_in_PDF.webm" length="2237750" type="video/webm" />
<enclosure url="https://shkspr.mobi/blog/wp-content/uploads/2016/02/3D-Objects-in-PDF.ogv" length="4952088" type="video/ogg" />

			</item>
	</channel>
</rss>
