{"id":1226,"date":"2017-12-02T01:39:39","date_gmt":"2017-12-01T16:39:39","guid":{"rendered":"https:\/\/www.utsbox.com\/?p=1226"},"modified":"2021-01-06T23:45:36","modified_gmt":"2021-01-06T14:45:36","slug":"vst3-6%e3%81%ae%e5%b0%8f%e3%83%8d%e3%82%bf-vst3-6%e3%81%ab%e3%81%8a%e3%81%91%e3%82%8b%e3%82%b5%e3%82%a4%e3%83%ac%e3%83%b3%e3%82%b9%e5%87%a6%e7%90%86","status":"publish","type":"post","link":"https:\/\/www.utsbox.com\/?p=1226","title":{"rendered":"VST3\u306b\u304a\u3051\u308b\u30b5\u30a4\u30ec\u30f3\u30b9\u51e6\u7406"},"content":{"rendered":"<h1>VST3\u306b\u304a\u3051\u308b\u30b5\u30a4\u30ec\u30f3\u30b9\u51e6\u7406<\/h1>\n<p>process()\u95a2\u6570\u306e\u5f15\u6570 data\u306e\u5165\u529b\u30aa\u30fc\u30c7\u30a3\u30aa\u30d0\u30b9\u306b\u306f\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3068\u3044\u3046\u3082\u306e\u304c\u3042\u308a\u3001\u300c<strong>\u97f3\u58f0\u5165\u51fa\u529b\u30d0\u30c3\u30d5\u30a1\u306e\u5024\u304c\u3059\u3079\u30660\u306e\u5834\u5408\u3001\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3092\u7acb\u3066\u308b<\/strong>\u300d\u3068\u3044\u3046\u6c7a\u307e\u308a\u304c\u3042\u308b\u3088\u3046\u3067\u3059\u3002<\/p>\n<p>\u3053\u306e\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u306f\u3001\u300c<strong>\u4f55\u3082\u97f3\u58f0\u5165\u529b\u304c\u306a\u3044\u5834\u5408\u306b\u7121\u99c4\u306a\u51e6\u7406\u3092\u884c\u308f\u306a\u3044\u3053\u3068\u3067\u30b3\u30f3\u30d4\u30e5\u30fc\u30bf\u30fc(CPU)\u306e\u8ca0\u8377\u3092\u4e0b\u3052\u308b<\/strong>\u300d\u305f\u3081\u306b\u3042\u308a\u307e\u3059\u3002<br \/>\n(\u591a\u5206\u3001\u3053\u306e\u30d5\u30e9\u30b0\u304c<a href=\"https:\/\/japan.steinberg.net\/jp\/company\/technology\/vst3.html\" rel=\"noopener\" target=\"_blank\">Steinberg Web\u30b5\u30a4\u30c8\u306b\u3042\u308b\u300cVST3\u65b0\u6a5f\u80fd\u300d\u306e\u300c\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u306e\u6539\u5584\u300d<\/a>\u306b\u3042\u305f\u308b\u3082\u306e\u3068\u601d\u308f\u308c\u307e\u3059\u3002)<\/p>\n<p>\u97f3\u58f0\u51fa\u529b\u306b\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3092\u7acb\u3066\u308b\u306e\u306f\u3001VST3\u30d7\u30e9\u30b0\u30a4\u30f3\u304c\u8907\u6570 \u63a5\u7d9a\u3055\u308c\u308b\u53ef\u80fd\u6027\u3092\u60f3\u5b9a\u3057\u3066\u3044\u308b\u305f\u3081\u3067\u3059\u3002<br \/>\n\u81ea\u8eab\u306e\u4f5c\u6210\u3057\u305fVST3\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u97f3\u58f0\u51fa\u529b\u306f\u6b21\u306eVST3\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u97f3\u58f0\u5165\u529b\u3068\u306a\u308b\u305f\u3081\u3001\u97f3\u58f0\u51fa\u529b\u304c\u3059\u3079\u30660\u306e\u5834\u5408\u306f\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3092\u7acb\u3066\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u306e\u51e6\u7406\u65b9\u6cd5\u306fVST3\u30d7\u30e9\u30b0\u30a4\u30f3\u306b\u3088\u3063\u3066\u7570\u306a\u308a\u307e\u3059\u3002<br \/>\n\u300c\u97f3\u58f0\u5165\u529b\u306e\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u304c\u7acb\u3063\u3066\u3044\u308b\u3088\u3046\u3067\u3042\u308c\u3070\u3001\u97f3\u58f0\u51fa\u529b\u3082\u3059\u3079\u30660\u306b\u3057\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3092\u7acb\u3066\u308b\u300d\u3068\u3044\u3063\u305f\u51e6\u7406\u3092\u884c\u3046VST\u30d7\u30e9\u30b0\u30a4\u30f3\u3082\u3042\u308c\u3070\u3001\u30b7\u30f3\u30bb\u30b5\u30a4\u30b6\u30fc\u3084\u30ea\u30d0\u30fc\u30d6(\u6b8b\u97ff)\u30a8\u30d5\u30a7\u30af\u30c8\u306a\u3069\u306e\u3088\u3046\u306b\u300c\u97f3\u58f0\u5165\u529b\u306e\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u304c\u7acb\u3063\u3066\u3044\u3066\u3082\u3001\u5c11\u3057\u524d\u306e\u97f3\u58f0\u5165\u529b\u3084MIDI\u5165\u529b\u304b\u3089\u97f3\u58f0\u51fa\u529b\u3092\u8a08\u7b97\u3057\u7d9a\u3051\u308b\u300d\u3082\u306e\u3082\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u5b9f\u88c5\u65b9\u6cd5\u306e\u4e00\u4f8b\u3068\u3057\u3066\u3001\u300c\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u304c\u7acb\u3063\u3066\u3044\u308b\u5834\u5408\u306f\u3001\u97f3\u58f0\u51fa\u529b\u3082\u3059\u3079\u30660\u306b\u3059\u308b\u300d\u65b9\u6cd5\u3092\u4e0b\u8a18\u306b\u8a18\u8f09\u3057\u307e\u3059\u3002<\/p>\n<p>\u307e\u305a\u97f3\u58f0\u51e6\u7406\u30af\u30e9\u30b9\u306b\u30b5\u30a4\u30ec\u30f3\u30b9\u51e6\u7406\u3092\u884c\u3046\u95a2\u6570\u3092\u5b9f\u88c5\u3057\u307e\u3059\u3002<\/p>\n<p>[crayon]<br \/>\n\/\/ \u30b5\u30a4\u30ec\u30f3\u30b9\u51e6\u7406\u3092\u884c\u3046\u95a2\u6570 (process()\u95a2\u6570\u5185\u3067\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u304c\u7acb\u3063\u3066\u3044\u305f\u5834\u5408\u306b\u547c\u3073\u51fa\u3055\u308c\u308b\u95a2\u6570)<br \/>\nvoid MyVSTProcessor::processSilence(Sample32* inL, Sample32* inR, Sample32* outL, Sample32* outR, int32 numSamples)<br \/>\n{<br \/>\n\t\/\/ \u51fa\u529b\u3092\u7121\u97f3\u306b\u3059\u308b(0\u3092\u51fa\u529b\u3059\u308b\u3002\u30b4\u30df\u30c7\u30fc\u30bf\u306a\u3069\u304c\u6b8b\u3063\u3066\u3044\u308b\u5834\u5408\u304c\u3042\u308b\u306e\u3067\u3002)<\/p>\n<p>\t\/\/ \u5165\u529b\u3068\u51fa\u529b\u304c\u540c\u3058\u30dd\u30a4\u30f3\u30bf\u306e\u5834\u5408\u304c\u3042\u308b\u306e\u3067\u5ff5\u306e\u305f\u3081\u78ba\u8a8d(DAW\u304cCubase\u306a\u3069)<br \/>\n\tif (inL != outL)<br \/>\n\t{<br \/>\n\t\t\/\/ \u51fa\u529b\u30d0\u30c3\u30d5\u30a1\u30920\u3067\u57cb\u3081\u308b<br \/>\n\t\tmemset(outL, 0, numSamples * sizeof(float));<br \/>\n\t}<br \/>\n\tif (inR != outR)<br \/>\n\t{<br \/>\n\t\t\/\/ \u51fa\u529b\u30d0\u30c3\u30d5\u30a1\u30920\u3067\u57cb\u3081\u308b<br \/>\n\t\tmemset(outR, 0, numSamples * sizeof(float));<br \/>\n\t}<\/p>\n<p>\t\/\/ VST\u5185\u90e8\u306e\u72b6\u614b\u306a\u3069\u3092\u66f4\u65b0\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b\u5834\u5408\u306f\u3053\u3053\u306b\u8a18\u8f09<br \/>\n\t\/\/ \u4eca\u56de\u306f\u4f55\u3082\u66f4\u65b0\u3057\u306a\u3044\u306e\u3067\u8a18\u8f09\u306f\u306a\u3057<br \/>\n}<br \/>\n[\/crayon]<\/p>\n<p>\u305d\u306e\u5f8c\u3001process()\u95a2\u6570\u5185\u306e\u300c<a href=\"https:\/\/www.utsbox.com\/?p=887#\u97f3\u58f0\u51e6\u7406\u30af\u30e9\u30b9\u3067\u306e\u97f3\u58f0\u4fe1\u53f7\u306e\u51e6\u7406\">\u5165\u529b\u30fb\u51fa\u529b\u30d0\u30c3\u30d5\u30a1\u306e\u30dd\u30a4\u30f3\u30bf\u3092\u308f\u304b\u308a\u3084\u3059\u3044\u5909\u6570\u306b\u683c\u7d0d<\/a>\u300d\u306e\u5f8c\u306b\u4e0a\u8a18\u95a2\u6570\u3092\u5165\u308c\u307e\u3059\u3002<br \/>\n(<a href=\"https:\/\/www.utsbox.com\/?p=1219\">\u30d0\u30a4\u30d1\u30b9\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc<\/a>\u3068\u5408\u308f\u305b\u3066\u4e0b\u8a18\u306e\u3088\u3046\u306b\u5b9f\u88c5\u3057\u307e\u3059\u3002)<\/p>\n<p>[crayon]<br \/>\n\t\/\/ \u5165\u529b\u30fb\u51fa\u529b\u30d0\u30c3\u30d5\u30a1\u306e\u30dd\u30a4\u30f3\u30bf\u3092\u308f\u304b\u308a\u3084\u3059\u3044\u5909\u6570\u306b\u683c\u7d0d<br \/>\n\t\/\/ inputs[]\u3001outputs[]\u306fAudioBus\u306e\u6570\u3060\u3051\u3042\u308b(addAudioInput()\u3001addAudioOutput()\u3067\u8ffd\u52a0\u3057\u305f\u5206\u3060\u3051)<br \/>\n\t\/\/ \u4eca\u56de\u306fAudioBus\u306f1\u3064\u3060\u3051\u306a\u306e\u3067 0 \u306e\u307f\u3068\u306a\u308b<br \/>\n\t\/\/ channelBuffers32\u306f32bit\u6d6e\u52d5\u5c0f\u6570\u70b9\u578b\u306e\u30d0\u30c3\u30d5\u30a1\u3067\u97f3\u58f0\u4fe1\u53f7\u306e\u30c1\u30e3\u30f3\u30cd\u30eb\u6570\u5206\u3042\u308b<br \/>\n\t\/\/ \u30e2\u30ce\u30e9\u30eb(kMono)\u306a\u3089 0 \u306e\u307f\u3067\u3001\u30b9\u30c6\u30ec\u30aa(kStereo)\u306a\u3089 0(Left) \u3068 1(Right) \u3068\u306a\u308b<br \/>\n\tSample32* inL = data.inputs[0].channelBuffers32[0];<br \/>\n\tSample32* inR = data.inputs[0].channelBuffers32[1];<br \/>\n\tSample32* outL = data.outputs[0].channelBuffers32[0];<br \/>\n\tSample32* outR = data.outputs[0].channelBuffers32[1];<\/p>\n<p>\t\/\/ \u5165\u529b\u306e\u30d0\u30a4\u30d1\u30b9\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u3092\u78ba\u8a8d<br \/>\n\tif (bypass == 1.0)<br \/>\n\t{<br \/>\n\t\t\/\/ \u30d0\u30a4\u30d1\u30b9\u51e6\u7406\u3092\u884c\u3046<br \/>\n\t\treturn processBypass(inL, inR, outL, outR, numSamples);<br \/>\n\t}<\/p>\n<p>\t\/\/ \u5165\u529b\u306e\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3092\u78ba\u8a8d<br \/>\n\tif (data.inputs[0].silenceFlags != 0)<br \/>\n\t{<br \/>\n\t\t\/\/ \u5165\u529b\u306e\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u304c\u7acb\u3063\u3066\u3044\u308b\u5834\u5408\u306e\u51e6\u7406<\/p>\n<p>\t\t\/\/ \u51fa\u529b\u306e\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3082\u5165\u529b\u3068\u540c\u3058\u306b\u8a2d\u5b9a\u3059\u308b<br \/>\n\t\tdata.outputs[0].silenceFlags = data.inputs[0].silenceFlags;<br \/>\n\t\t\/\/ \u7121\u97f3\u306b\u3057\u3066\u51fa\u529b\u3059\u308b(\u30c7\u30fc\u30bf\u30920\u306b\u3059\u308b)<br \/>\n\t\treturn processSilence(inL, inR, outL, outR, numSamples);<br \/>\n\t}<\/p>\n<p>\t\/\/ \u30b5\u30a4\u30ec\u30f3\u30b9\u72b6\u614b\u3067\u306f\u306a\u3044\u306e\u3067\u901a\u5e38\u51e6\u7406<br \/>\n\t\/\/ numSamples\u3067\u793a\u3055\u308c\u308b\u30b5\u30f3\u30d7\u30eb\u5206\u3001\u97f3\u58f0\u3092\u51e6\u7406\u3059\u308b<br \/>\n\tfor (int32 i = 0; i < data.numSamples; i++)\n[\/crayon]\n\nsilenceFlags\u306f\u30aa\u30fc\u30c7\u30a3\u30aa\u30d0\u30b9\u306eSpeakerArrangement\u3068\u540c\u3058\u3067\u3042\u308b\u305f\u3081\u3001\u300c\u3069\u306e\u30d5\u30e9\u30b0\u304c\u7acb\u3063\u3066\u3044\u308b\u304b\uff1f\u300d\u3092\u5224\u65ad\u3059\u308b\u3053\u3068\u3067\u7279\u5b9a\u306e\u30c1\u30e3\u30f3\u30cd\u30eb\u3060\u3051\u3092\u30b5\u30a4\u30ec\u30f3\u30b9\u306b\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002\n\n\u4e0a\u8a18\u4ee5\u5916\u306b\u3082VST3.6\u306b\u3064\u3044\u3066\u306e\u60c5\u5831\u304c\u3042\u308a\u307e\u3059\u3002\u4e0b\u8a18\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002\n\n\n<ul>\n<li><a href=\"https:\/\/www.utsbox.com\/?page_id=1316\">\u306f\u3058\u3081\u3066\u306eVST3\u30d7\u30e9\u30b0\u30a4\u30f3\u4f5c\u308a<\/a><\/li>\n<\/ul>\n<p>\u307e\u305f\u3001\u8cea\u554f\u3084\u3054\u6307\u6458\u306f\u30b3\u30e1\u30f3\u30c8\u6b04\u3084<a href=\"https:\/\/jbbs.shitaraba.net\/computer\/42917\/\" title=\"\u63b2\u793a\u677f\" target=\"_blank\" rel=\"noopener\">\u63b2\u793a\u677f<\/a>\u3001<a href=\"https:\/\/twitter.com\/vstcpp\">Twitter<\/a>\u3067\u3044\u305f\u3060\u3051\u3070\u3068\u304a\u3082\u3044\u307e\u3059\u3002<\/p>\n<p>\u25a0<a href=\"https:\/\/jbbs.shitaraba.net\/computer\/42917\/\" title=\"\u63b2\u793a\u677f\" target=\"_blank\" rel=\"noopener\">\u63b2\u793a\u677f<\/a><br \/>\n\u25a0Twitter\u30a2\u30ab\u30a6\u30f3\u30c8\uff1a@vstcpp\u3000\u3000\u3000URL\uff1a<a href=\"https:\/\/twitter.com\/vstcpp\">https:\/\/twitter.com\/vstcpp<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>VST3\u306b\u304a\u3051\u308b\u30b5\u30a4\u30ec\u30f3\u30b9\u51e6\u7406 process()\u95a2\u6570\u306e\u5f15\u6570 data\u306e\u5165\u529b\u30aa\u30fc\u30c7\u30a3\u30aa\u30d0\u30b9\u306b\u306f\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3068\u3044\u3046\u3082\u306e\u304c\u3042\u308a\u3001\u300c\u97f3\u58f0\u5165\u51fa\u529b\u30d0\u30c3\u30d5\u30a1\u306e\u5024\u304c\u3059\u3079\u30660\u306e\u5834\u5408\u3001\u30b5\u30a4\u30ec\u30f3\u30b9\u30d5\u30e9\u30b0\u3092\u7acb\u3066\u308b\u300d\u3068\u3044\u3046\u6c7a\u307e\u308a\u304c\u3042\u308b\u3088\u3046\u3067 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[17],"tags":[],"class_list":["post-1226","post","type-post","status-publish","format-standard","hentry","category-vst3"],"aioseo_notices":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p5fXUX-jM","jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/www.utsbox.com\/index.php?rest_route=\/wp\/v2\/posts\/1226","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.utsbox.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.utsbox.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.utsbox.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.utsbox.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1226"}],"version-history":[{"count":10,"href":"https:\/\/www.utsbox.com\/index.php?rest_route=\/wp\/v2\/posts\/1226\/revisions"}],"predecessor-version":[{"id":3253,"href":"https:\/\/www.utsbox.com\/index.php?rest_route=\/wp\/v2\/posts\/1226\/revisions\/3253"}],"wp:attachment":[{"href":"https:\/\/www.utsbox.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1226"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.utsbox.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1226"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.utsbox.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1226"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}